smedia.h revision 3f7d54a6b84904c8f4d8daa4c7b577bede7df8b9
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
*/
#ifndef _SMEDIA_H_
#define _SMEDIA_H_
/*
* smedia.h header for libsmedia library
*/
#ifdef __cplusplus
extern "C" {
#endif
#include <fcntl.h>
#include <stdio.h>
#include <errno.h>
#include <synch.h>
typedef struct smdevice_info {
char *sm_vendor_name; /* Vendor name */
char *sm_product_name; /* Product name */
char *sm_firmware_version; /* Firmware version */
typedef void *smedia_handle_t;
#define SMDEVICE_INFO_V_1 1
/* Interface Types */
#define IF_SCSI 0x0
#define IF_FLOPPY 0x1
#define IF_PCMCIA 0x2
#define IF_BLOCK 0x3
typedef struct smmedium_property {
#define SMMEDIA_PROP_V_1 1
/*
* Media types not defined for DKIOCGMEDIAINFO
*/
/* FIXED_DISK + REMOVABLE */
#define SM_NOT_PRESENT 0xFFFF
#define MAX_PASSWD_LENGTH 32
#define PASSWD 0x1000
typedef struct smwp_state {
char sm_passwd[MAX_PASSWD_LENGTH];
#define SMWP_STATE_V_1 1
#define FORMAT 0x2000
/* Floppy specific options */
/* New Library interface prototypes */
#ifdef __cplusplus
}
#endif
#endif /* _SMEDIA_H_ */