iscsi_tcp: propogate EAGAIN from sendpage to libiscsi
authorMike Christie <michaelc@cs.wisc.edu>
Tue, 16 Jun 2009 03:11:09 +0000 (22:11 -0500)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Sun, 21 Jun 2009 15:52:40 +0000 (10:52 -0500)
commit32382492eb18e8e20be382a1743d0c08469d1e84
tree8b612f29d04a0ecd39c64452a601a01f687b3fcc
parentd355e57d58193b89283b0c8153649f0427b0bdad
iscsi_tcp: propogate EAGAIN from sendpage to libiscsi

The net layer might return -EAGAIN because it could not
get space/mem within the sock sndtimeo or becuase the tcp/ip
connection was down. For the latter we do not want to retry
because the conn/session should just be shutdown and restarted.
libiscsi knows the state of the session recovery so propogate
this error to that layer. It will either do iscsi recovery
or have us retry the operation. Right now if we have partially
sent a pdu we would always retry the IO xmit slowing down
recovery.

Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
drivers/scsi/iscsi_tcp.c