On Thu, Mar 15, 2001 at 02:09:36AM +0100, Björn Stenberg wrote:
> I have also added a definition of the very frequently used INQUIRY response
> data struct. It is currently duplicated in about a dozen different drivers
> and every new driver has to define it yet again. Better to have it in a
> central place IMHO.
> +/*
> + * The SCSI INQUIRY command result data format
> + * (From SCSI-2 final draft, section 8.2.5.1
> + * and SCSI-3 SPC draft 18, section 7.6.2)
> + */
> +
> +struct scsi_inquiry_response
> +{
> + unsigned int device_type : 5;
> + unsigned int qualifier : 3;
> + unsigned int _res1 : 7;
Don't use bitfields they are not endian neutral with gcc on different
architectures. SCSI structures are big-endian regardless of the system
architecture. Manifest constants (#define) should be used instead.
--
Bob Frey
[EMAIL PROTECTED]
-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to [EMAIL PROTECTED]