From 0a72d6c42287fc511fee34783f0d1125b604bec2 Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Sun, 8 Aug 2004 20:28:28 -0700 Subject: [PATCH] [PATCH] allow broken apps to include kernel header Include compiler.h from sg.h as it uses the __user notation, and change the types in scsi.h to use user exportable types. Signed-off-by: Jens Axboe Signed-off-by: Linus Torvalds --- include/scsi/scsi.h | 26 +++++++++++++------------- include/scsi/sg.h | 2 ++ 2 files changed, 15 insertions(+), 13 deletions(-) diff --git a/include/scsi/scsi.h b/include/scsi/scsi.h index ef5ef24cda168..1c6d293846f06 100644 --- a/include/scsi/scsi.h +++ b/include/scsi/scsi.h @@ -214,25 +214,25 @@ static inline int scsi_status_is_good(int status) */ struct ccs_modesel_head { - u8 _r1; /* reserved */ - u8 medium; /* device-specific medium type */ - u8 _r2; /* reserved */ - u8 block_desc_length; /* block descriptor length */ - u8 density; /* device-specific density code */ - u8 number_blocks_hi; /* number of blocks in this block desc */ - u8 number_blocks_med; - u8 number_blocks_lo; - u8 _r3; - u8 block_length_hi; /* block length for blocks in this desc */ - u8 block_length_med; - u8 block_length_lo; + __u8 _r1; /* reserved */ + __u8 medium; /* device-specific medium type */ + __u8 _r2; /* reserved */ + __u8 block_desc_length; /* block descriptor length */ + __u8 density; /* device-specific density code */ + __u8 number_blocks_hi; /* number of blocks in this block desc */ + __u8 number_blocks_med; + __u8 number_blocks_lo; + __u8 _r3; + __u8 block_length_hi; /* block length for blocks in this desc */ + __u8 block_length_med; + __u8 block_length_lo; }; /* * ScsiLun: 8 byte LUN. */ struct scsi_lun { - u8 scsi_lun[8]; + __u8 scsi_lun[8]; }; /* diff --git a/include/scsi/sg.h b/include/scsi/sg.h index c8985dd1d4b2e..0a487fe26d4fe 100644 --- a/include/scsi/sg.h +++ b/include/scsi/sg.h @@ -1,6 +1,8 @@ #ifndef _SCSI_GENERIC_H #define _SCSI_GENERIC_H +#include + /* History: Started: Aug 9 by Lawrence Foard (entropy@world.std.com), to allow user -- 2.53.0