diff options
author | James Bottomley <James.Bottomley@HansenPartnership.com> | 2009-02-08 22:59:48 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2009-03-12 13:58:13 -0400 |
commit | f290f1970f01287eaaffc798a677594a57ebd65e (patch) | |
tree | 534b3ab262c3c791f80c8fd32dee7192395973dc /include/scsi/scsi_cmnd.h | |
parent | 97218a1499391b174ea95e05b7a40fbb73e79813 (diff) |
[SCSI] Make scsi.h independent of the rest of the scsi includes
This allows it to compile and be used on the ps3 platform that wants
to use the #define values in scsi.h without actually having
CONFIG_SCSI set.
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'include/scsi/scsi_cmnd.h')
-rw-r--r-- | include/scsi/scsi_cmnd.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/include/scsi/scsi_cmnd.h b/include/scsi/scsi_cmnd.h index 855bf95963e7..43b50d36925c 100644 --- a/include/scsi/scsi_cmnd.h +++ b/include/scsi/scsi_cmnd.h | |||
@@ -291,4 +291,19 @@ static inline struct scsi_data_buffer *scsi_prot(struct scsi_cmnd *cmd) | |||
291 | #define scsi_for_each_prot_sg(cmd, sg, nseg, __i) \ | 291 | #define scsi_for_each_prot_sg(cmd, sg, nseg, __i) \ |
292 | for_each_sg(scsi_prot_sglist(cmd), sg, nseg, __i) | 292 | for_each_sg(scsi_prot_sglist(cmd), sg, nseg, __i) |
293 | 293 | ||
294 | static inline void set_msg_byte(struct scsi_cmnd *cmd, char status) | ||
295 | { | ||
296 | cmd->result |= status << 8; | ||
297 | } | ||
298 | |||
299 | static inline void set_host_byte(struct scsi_cmnd *cmd, char status) | ||
300 | { | ||
301 | cmd->result |= status << 16; | ||
302 | } | ||
303 | |||
304 | static inline void set_driver_byte(struct scsi_cmnd *cmd, char status) | ||
305 | { | ||
306 | cmd->result |= status << 24; | ||
307 | } | ||
308 | |||
294 | #endif /* _SCSI_SCSI_CMND_H */ | 309 | #endif /* _SCSI_SCSI_CMND_H */ |