Skip to content

Commit a44074f

Browse files
Bart Van Asschedledford
authored andcommitted
IB/srp: Fix reconnection failure handling
Although it is possible to let SRP I/O continue if a reconnect results in a reduction of the number of channels, the current code does not handle this scenario correctly. Instead of making the reconnect code more complex, consider this as a reconnection failure. Signed-off-by: Bart Van Assche <[email protected]> Cc: Sagi Grimberg <[email protected]> Cc: Sebastian Parschauer <[email protected]> Cc: <[email protected]> #v3.19 Signed-off-by: Doug Ledford <[email protected]>
1 parent c014c8c commit a44074f

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

drivers/infiniband/ulp/srp/ib_srp.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1243,11 +1243,8 @@ static int srp_rport_reconnect(struct srp_rport *rport)
12431243

12441244
for (i = 0; i < target->ch_count; i++) {
12451245
ch = &target->ch[i];
1246-
if (ret || !ch->target) {
1247-
if (i > 1)
1248-
ret = 0;
1246+
if (ret || !ch->target)
12491247
break;
1250-
}
12511248
ret = srp_connect_ch(ch, multich);
12521249
multich = true;
12531250
}

0 commit comments

Comments
 (0)