cdparanoia hacks - add ENOMEDIUM, fake out scsi_inquiry() in CAM headers.
authorMatthew Dillon <dillon@apollo.backplane.com>
Wed, 26 Aug 2009 01:41:24 +0000 (18:41 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Wed, 26 Aug 2009 01:41:24 +0000 (18:41 -0700)
sys/bus/cam/scsi/scsi_all.h
sys/sys/errno.h

index 13b20e0..27bc17c 100644 (file)
@@ -1197,11 +1197,13 @@ void            scsi_request_sense(struct ccb_scsiio *csio, u_int32_t retries,
                                   u_int8_t tag_action, u_int8_t sense_len,
                                   u_int32_t timeout);
 
+#ifndef CAM_NO_SCSI_INQUIRY    /* hack for cdparanoia */
 void           scsi_inquiry(struct ccb_scsiio *csio, u_int32_t retries,
                             void (*cbfcnp)(struct cam_periph *, union ccb *),
                             u_int8_t tag_action, u_int8_t *inq_buf, 
                             u_int32_t inq_len, int evpd, u_int8_t page_code,
                             u_int8_t sense_len, u_int32_t timeout);
+#endif
 
 void           scsi_mode_sense(struct ccb_scsiio *csio, u_int32_t retries,
                                void (*cbfcnp)(struct cam_periph *,
index 6ae50bd..15ea636 100644 (file)
@@ -178,7 +178,7 @@ static __inline int *__error(void)
 #define        EPROTO          92              /* Protocol error */
 
 #ifndef _POSIX_SOURCE
-#define        EUNUSED93       93
+#define        ENOMEDIUM       93              /* linux */
 #define        EUNUSED94       94
 #define        EUNUSED95       95
 #define        EUNUSED96       96