@@ -135,9 +135,8 @@ static int iscsi_iser_set(const char *val, const struct kernel_param *kp)
135
135
* Notes: In case of data length errors or iscsi PDU completion failures
136
136
* this routine will signal iscsi layer of connection failure.
137
137
*/
138
- void
139
- iscsi_iser_recv (struct iscsi_conn * conn , struct iscsi_hdr * hdr ,
140
- char * rx_data , int rx_data_len )
138
+ void iscsi_iser_recv (struct iscsi_conn * conn , struct iscsi_hdr * hdr ,
139
+ char * rx_data , int rx_data_len )
141
140
{
142
141
int rc = 0 ;
143
142
int datalen ;
@@ -172,8 +171,7 @@ iscsi_iser_recv(struct iscsi_conn *conn, struct iscsi_hdr *hdr,
172
171
* Netes: This routine can't fail, just assign iscsi task
173
172
* hdr and max hdr size.
174
173
*/
175
- static int
176
- iscsi_iser_pdu_alloc (struct iscsi_task * task , uint8_t opcode )
174
+ static int iscsi_iser_pdu_alloc (struct iscsi_task * task , uint8_t opcode )
177
175
{
178
176
struct iscsi_iser_task * iser_task = task -> dd_data ;
179
177
@@ -194,9 +192,8 @@ iscsi_iser_pdu_alloc(struct iscsi_task *task, uint8_t opcode)
194
192
* state mutex to avoid dereferencing the IB device which
195
193
* may have already been terminated.
196
194
*/
197
- int
198
- iser_initialize_task_headers (struct iscsi_task * task ,
199
- struct iser_tx_desc * tx_desc )
195
+ int iser_initialize_task_headers (struct iscsi_task * task ,
196
+ struct iser_tx_desc * tx_desc )
200
197
{
201
198
struct iser_conn * iser_conn = task -> conn -> dd_data ;
202
199
struct iser_device * device = iser_conn -> ib_conn .device ;
@@ -233,8 +230,7 @@ iser_initialize_task_headers(struct iscsi_task *task,
233
230
* Return: Returns zero on success or -ENOMEM when failing
234
231
* to init task headers (dma mapping error).
235
232
*/
236
- static int
237
- iscsi_iser_task_init (struct iscsi_task * task )
233
+ static int iscsi_iser_task_init (struct iscsi_task * task )
238
234
{
239
235
struct iscsi_iser_task * iser_task = task -> dd_data ;
240
236
int ret ;
@@ -268,8 +264,8 @@ iscsi_iser_task_init(struct iscsi_task *task)
268
264
* xmit.
269
265
*
270
266
**/
271
- static int
272
- iscsi_iser_mtask_xmit ( struct iscsi_conn * conn , struct iscsi_task * task )
267
+ static int iscsi_iser_mtask_xmit ( struct iscsi_conn * conn ,
268
+ struct iscsi_task * task )
273
269
{
274
270
int error = 0 ;
275
271
@@ -286,9 +282,8 @@ iscsi_iser_mtask_xmit(struct iscsi_conn *conn, struct iscsi_task *task)
286
282
return error ;
287
283
}
288
284
289
- static int
290
- iscsi_iser_task_xmit_unsol_data (struct iscsi_conn * conn ,
291
- struct iscsi_task * task )
285
+ static int iscsi_iser_task_xmit_unsol_data (struct iscsi_conn * conn ,
286
+ struct iscsi_task * task )
292
287
{
293
288
struct iscsi_r2t_info * r2t = & task -> unsol_r2t ;
294
289
struct iscsi_data hdr ;
@@ -322,8 +317,7 @@ iscsi_iser_task_xmit_unsol_data(struct iscsi_conn *conn,
322
317
*
323
318
* Return: zero on success or escalates $error on failure.
324
319
*/
325
- static int
326
- iscsi_iser_task_xmit (struct iscsi_task * task )
320
+ static int iscsi_iser_task_xmit (struct iscsi_task * task )
327
321
{
328
322
struct iscsi_conn * conn = task -> conn ;
329
323
struct iscsi_iser_task * iser_task = task -> dd_data ;
@@ -406,8 +400,7 @@ static void iscsi_iser_cleanup_task(struct iscsi_task *task)
406
400
*
407
401
* In addition the error sector is marked.
408
402
*/
409
- static u8
410
- iscsi_iser_check_protection (struct iscsi_task * task , sector_t * sector )
403
+ static u8 iscsi_iser_check_protection (struct iscsi_task * task , sector_t * sector )
411
404
{
412
405
struct iscsi_iser_task * iser_task = task -> dd_data ;
413
406
enum iser_data_dir dir = iser_task -> dir [ISER_DIR_IN ] ?
@@ -456,11 +449,9 @@ iscsi_iser_conn_create(struct iscsi_cls_session *cls_session,
456
449
* -EINVAL in case end-point doesn't exsits anymore or iser connection
457
450
* state is not UP (teardown already started).
458
451
*/
459
- static int
460
- iscsi_iser_conn_bind (struct iscsi_cls_session * cls_session ,
461
- struct iscsi_cls_conn * cls_conn ,
462
- uint64_t transport_eph ,
463
- int is_leading )
452
+ static int iscsi_iser_conn_bind (struct iscsi_cls_session * cls_session ,
453
+ struct iscsi_cls_conn * cls_conn ,
454
+ uint64_t transport_eph , int is_leading )
464
455
{
465
456
struct iscsi_conn * conn = cls_conn -> dd_data ;
466
457
struct iser_conn * iser_conn ;
@@ -515,8 +506,7 @@ iscsi_iser_conn_bind(struct iscsi_cls_session *cls_session,
515
506
* from this point iscsi must call conn_stop in session/connection
516
507
* teardown so iser transport must wait for it.
517
508
*/
518
- static int
519
- iscsi_iser_conn_start (struct iscsi_cls_conn * cls_conn )
509
+ static int iscsi_iser_conn_start (struct iscsi_cls_conn * cls_conn )
520
510
{
521
511
struct iscsi_conn * iscsi_conn ;
522
512
struct iser_conn * iser_conn ;
@@ -538,8 +528,7 @@ iscsi_iser_conn_start(struct iscsi_cls_conn *cls_conn)
538
528
* handle, so we call it under iser the state lock to protect against
539
529
* this kind of race.
540
530
*/
541
- static void
542
- iscsi_iser_conn_stop (struct iscsi_cls_conn * cls_conn , int flag )
531
+ static void iscsi_iser_conn_stop (struct iscsi_cls_conn * cls_conn , int flag )
543
532
{
544
533
struct iscsi_conn * conn = cls_conn -> dd_data ;
545
534
struct iser_conn * iser_conn = conn -> dd_data ;
@@ -574,8 +563,7 @@ iscsi_iser_conn_stop(struct iscsi_cls_conn *cls_conn, int flag)
574
563
*
575
564
* Removes and free iscsi host.
576
565
*/
577
- static void
578
- iscsi_iser_session_destroy (struct iscsi_cls_session * cls_session )
566
+ static void iscsi_iser_session_destroy (struct iscsi_cls_session * cls_session )
579
567
{
580
568
struct Scsi_Host * shost = iscsi_session_to_shost (cls_session );
581
569
@@ -584,8 +572,7 @@ iscsi_iser_session_destroy(struct iscsi_cls_session *cls_session)
584
572
iscsi_host_free (shost );
585
573
}
586
574
587
- static inline unsigned int
588
- iser_dif_prot_caps (int prot_caps )
575
+ static inline unsigned int iser_dif_prot_caps (int prot_caps )
589
576
{
590
577
int ret = 0 ;
591
578
@@ -704,9 +691,8 @@ iscsi_iser_session_create(struct iscsi_endpoint *ep,
704
691
return NULL ;
705
692
}
706
693
707
- static int
708
- iscsi_iser_set_param (struct iscsi_cls_conn * cls_conn ,
709
- enum iscsi_param param , char * buf , int buflen )
694
+ static int iscsi_iser_set_param (struct iscsi_cls_conn * cls_conn ,
695
+ enum iscsi_param param , char * buf , int buflen )
710
696
{
711
697
int value ;
712
698
@@ -756,8 +742,8 @@ iscsi_iser_set_param(struct iscsi_cls_conn *cls_conn,
756
742
*
757
743
* Output connection statistics.
758
744
*/
759
- static void
760
- iscsi_iser_conn_get_stats ( struct iscsi_cls_conn * cls_conn , struct iscsi_stats * stats )
745
+ static void iscsi_iser_conn_get_stats ( struct iscsi_cls_conn * cls_conn ,
746
+ struct iscsi_stats * stats )
761
747
{
762
748
struct iscsi_conn * conn = cls_conn -> dd_data ;
763
749
@@ -808,9 +794,9 @@ static int iscsi_iser_get_ep_param(struct iscsi_endpoint *ep,
808
794
* Return: iscsi_endpoint created by iscsi layer or ERR_PTR(error)
809
795
* if fails.
810
796
*/
811
- static struct iscsi_endpoint *
812
- iscsi_iser_ep_connect ( struct Scsi_Host * shost , struct sockaddr * dst_addr ,
813
- int non_blocking )
797
+ static struct iscsi_endpoint * iscsi_iser_ep_connect ( struct Scsi_Host * shost ,
798
+ struct sockaddr * dst_addr ,
799
+ int non_blocking )
814
800
{
815
801
int err ;
816
802
struct iser_conn * iser_conn ;
@@ -853,8 +839,7 @@ iscsi_iser_ep_connect(struct Scsi_Host *shost, struct sockaddr *dst_addr,
853
839
* or more likely iser connection state transitioned to TEMINATING or
854
840
* DOWN during the wait period.
855
841
*/
856
- static int
857
- iscsi_iser_ep_poll (struct iscsi_endpoint * ep , int timeout_ms )
842
+ static int iscsi_iser_ep_poll (struct iscsi_endpoint * ep , int timeout_ms )
858
843
{
859
844
struct iser_conn * iser_conn = ep -> dd_data ;
860
845
int rc ;
@@ -889,8 +874,7 @@ iscsi_iser_ep_poll(struct iscsi_endpoint *ep, int timeout_ms)
889
874
* and cleanup or actually call it immediately in case we didn't pass
890
875
* iscsi conn bind/start stage, thus it is safe.
891
876
*/
892
- static void
893
- iscsi_iser_ep_disconnect (struct iscsi_endpoint * ep )
877
+ static void iscsi_iser_ep_disconnect (struct iscsi_endpoint * ep )
894
878
{
895
879
struct iser_conn * iser_conn = ep -> dd_data ;
896
880
0 commit comments