diff options
Diffstat (limited to 'include/scsi/fc_encode.h')
-rw-r--r-- | include/scsi/fc_encode.h | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/include/scsi/fc_encode.h b/include/scsi/fc_encode.h index 6d293c846a46..be418d8448a5 100644 --- a/include/scsi/fc_encode.h +++ b/include/scsi/fc_encode.h | |||
@@ -46,16 +46,11 @@ struct fc_ct_req { | |||
46 | } payload; | 46 | } payload; |
47 | }; | 47 | }; |
48 | 48 | ||
49 | /** | 49 | static inline void __fc_fill_fc_hdr(struct fc_frame_header *fh, |
50 | * fill FC header fields in specified fc_frame | 50 | enum fc_rctl r_ctl, |
51 | */ | 51 | u32 did, u32 sid, enum fc_fh_type type, |
52 | static inline void fc_fill_fc_hdr(struct fc_frame *fp, enum fc_rctl r_ctl, | 52 | u32 f_ctl, u32 parm_offset) |
53 | u32 did, u32 sid, enum fc_fh_type type, | ||
54 | u32 f_ctl, u32 parm_offset) | ||
55 | { | 53 | { |
56 | struct fc_frame_header *fh; | ||
57 | |||
58 | fh = fc_frame_header_get(fp); | ||
59 | WARN_ON(r_ctl == 0); | 54 | WARN_ON(r_ctl == 0); |
60 | fh->fh_r_ctl = r_ctl; | 55 | fh->fh_r_ctl = r_ctl; |
61 | hton24(fh->fh_d_id, did); | 56 | hton24(fh->fh_d_id, did); |
@@ -68,6 +63,19 @@ static inline void fc_fill_fc_hdr(struct fc_frame *fp, enum fc_rctl r_ctl, | |||
68 | } | 63 | } |
69 | 64 | ||
70 | /** | 65 | /** |
66 | * fill FC header fields in specified fc_frame | ||
67 | */ | ||
68 | static inline void fc_fill_fc_hdr(struct fc_frame *fp, enum fc_rctl r_ctl, | ||
69 | u32 did, u32 sid, enum fc_fh_type type, | ||
70 | u32 f_ctl, u32 parm_offset) | ||
71 | { | ||
72 | struct fc_frame_header *fh; | ||
73 | |||
74 | fh = fc_frame_header_get(fp); | ||
75 | __fc_fill_fc_hdr(fh, r_ctl, did, sid, type, f_ctl, parm_offset); | ||
76 | } | ||
77 | |||
78 | /** | ||
71 | * fc_adisc_fill() - Fill in adisc request frame | 79 | * fc_adisc_fill() - Fill in adisc request frame |
72 | * @lport: local port. | 80 | * @lport: local port. |
73 | * @fp: fc frame where payload will be placed. | 81 | * @fp: fc frame where payload will be placed. |