Re: [PATCH v2] iscsi: Fix deadlock on recovery path during GFP_IO reclaim

2020-05-26 Thread Gabriel Krisman Bertazi
"Martin K. Petersen" writes: > On Tue, 19 May 2020 22:29:59 -0400, Gabriel Krisman Bertazi wrote: > >> iscsi suffers from a deadlock in case a management command submitted via >> the netlink socket sleeps on an allocation while holding the >> rx_queue_mutex,

[PATCH v2] iscsi: Fix deadlock on recovery path during GFP_IO reclaim

2020-05-19 Thread Gabriel Krisman Bertazi
Reviewed-by: Lee Duncan Signed-off-by: Gabriel Krisman Bertazi Changes since v1: - Rebase to v5.8/scsi-queue --- drivers/scsi/scsi_transport_iscsi.c | 64 + 1 file changed, 47 insertions(+), 17 deletions(-) diff --git a/drivers/scsi/scsi_transport_iscsi.c b/d

Re: [PATCH] iscsi: Fix deadlock on recovery path during GFP_IO reclaim

2020-05-19 Thread Gabriel Krisman Bertazi
ase resubmit. Hi Martin, Apparently it conflicted with my own code coming from -next. Sorry. I will resubmit as soon as I finish testing it. -- Gabriel Krisman Bertazi -- You received this message because you are subscribed to the Google Groups "open-iscsi" group. To unsubscribe from thi

Re: [PATCH] iscsi: Fix deadlock on recovery path during GFP_IO reclaim

2020-05-18 Thread Gabriel Krisman Bertazi
Lee Duncan writes: > On 5/7/20 10:59 PM, Gabriel Krisman Bertazi wrote: >> iscsi suffers from a deadlock in case a management command submitted via >> the netlink socket sleeps on an allocation while holding the >> rx_queue_mutex, if that allocation causes a memory reclaim

[PATCH] iscsi: Fix deadlock on recovery path during GFP_IO reclaim

2020-05-07 Thread Gabriel Krisman Bertazi
gned-off-by: Gabriel Krisman Bertazi --- drivers/scsi/scsi_transport_iscsi.c | 67 + 1 file changed, 49 insertions(+), 18 deletions(-) diff --git a/drivers/scsi/scsi_transport_iscsi.c b/drivers/scsi/scsi_transport_iscsi.c index 17a45716a0fe..d99c17306dff 100644 --

[PATCH RESEND v4] iscsi: Report connection state on sysfs

2020-03-17 Thread Gabriel Krisman Bertazi
ed-off-by: Gabriel Krisman Bertazi --- Changes since v3: - Change state type to enum (Bart) Changes since v2: - Use designated initializers (Bart) Changes since v1: - Remove dependency of state values (Bart) drivers/scsi/libiscsi.c | 7 ++- drivers/scsi/scsi_tran

[PATCH v4] iscsi: Report connection state on sysfs

2020-03-09 Thread Gabriel Krisman Bertazi
ed-off-by: Gabriel Krisman Bertazi --- Changes since v3: - Change state type to enum (Bart) Changes since v2: - Use designated initializers (Bart) Changes since v1: - Remove dependency of state values (Bart) drivers/scsi/libiscsi.c | 7 ++- drivers/scsi/scsi_tran

Re: [PATCH v2] iscsi: Report connection state on sysfs

2020-03-06 Thread Gabriel Krisman Bertazi
lflect the connection state. Cc: Khazhismel Kumykov Suggested-by: Junho Ryu Signed-off-by: Gabriel Krisman Bertazi --- Changes since v2: - Use designated initializers (Bart) Changes since v1: - Remove dependency of state values (Bart) drivers/scsi/libiscsi.c | 7 ++- drivers/

Re: [PATCH v2] iscsi: Report connection state on sysfs

2020-03-05 Thread Gabriel Krisman Bertazi
Bart Van Assche writes: > On 3/5/20 7:35 AM, Gabriel Krisman Bertazi wrote: >> +static const struct { >> +int value; >> +char *name; >> +} connection_state_names[] = { >> +{ISCSI_CONN_UP, "up"}, >> +{ISCSI_CONN_D

[PATCH v2] iscsi: Report connection state on sysfs

2020-03-05 Thread Gabriel Krisman Bertazi
ed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/libiscsi.c | 7 +- drivers/scsi/scsi_transport_iscsi.c | 38 - include/scsi/scsi_transport_iscsi.h | 8 ++ 3 files changed, 51 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/libiscs

[PATCH] iscsi: Report connection state on sysfs

2020-03-04 Thread Gabriel Krisman Bertazi
ed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/libiscsi.c | 7 ++- drivers/scsi/scsi_transport_iscsi.c | 29 - include/scsi/scsi_transport_iscsi.h | 8 3 files changed, 42 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/libiscs

[PATCH RESEND v2] iscsi: Add support for asynchronous iSCSI session destruction

2020-02-27 Thread Gabriel Krisman Bertazi
locking required during the asynchronous removal. Reviewed-by: Lee Duncan Co-developed-by: Khazhismel Kumykov Signed-off-by: Khazhismel Kumykov Signed-off-by: Frank Mayhar Co-developed-by: Gabriel Krisman Bertazi Signed-off-by: Gabriel Krisman Bertazi --- changes since v1: - Add -ENOMEM error

[PATCH RESEND] iscsi: Add support for asynchronous iSCSI session destruction

2020-01-26 Thread Gabriel Krisman Bertazi
locking required during the asynchronous removal. Co-developed-by: Khazhismel Kumykov Signed-off-by: Khazhismel Kumykov Signed-off-by: Frank Mayhar Co-developed-by: Gabriel Krisman Bertazi Signed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/scsi_transport_iscsi.c | 36

Re: [PATCH RESEND v4] iscsi: Perform connection failure entirely in kernel space

2020-01-25 Thread Gabriel Krisman Bertazi
;> Hey, Thank you very much for the quick response! I checked here again and I didn't get the previous email, but I see it made into the ML archive, so my apologies, it must be something bad on my (or my employer's) setup. Thanks, -- Gabriel Krisman Bertazi -- You received this

[PATCH RESEND v4] iscsi: Perform connection failure entirely in kernel space

2020-01-24 Thread Gabriel Krisman Bertazi
by: Junho Ryu Signed-off-by: Junho Ryu Co-developed-by: Khazhismel Kumykov Signed-off-by: Khazhismel Kumykov Reviewed-by: Reviewed-by: Khazhismel Kumykov Signed-off-by: Bharath Ravi Co-developed-by: Gabriel Krisman Bertazi Signed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/scsi_tran

[PATCH] iscsi: Add support for asynchronous iSCSI session destruction

2020-01-17 Thread Gabriel Krisman Bertazi
locking required during the asynchronous removal. Co-developed-by: Khazhismel Kumykov Signed-off-by: Khazhismel Kumykov Signed-off-by: Frank Mayhar Co-developed-by: Gabriel Krisman Bertazi Signed-off-by: Gabriel Krisman Bertazi --- This patch requires a patch that just went upstream to apply

Re: [PATCH RESEND] iscsi: Don't destroy session if there are outstanding connections

2020-01-13 Thread Gabriel Krisman Bertazi
Gabriel Krisman Bertazi writes: > From: Nick Black > > Hi, > > I thought this was already committed for some reason, until it bit me > again today. Any opposition to this one? Hi, Pinging this patch. Any oposion? >>8 > > A faulty userspace that calls destroy_s

[PATCH 1/3] drivers: base: Support atomic version of attribute_container_device_trigger

2020-01-06 Thread Gabriel Krisman Bertazi
g the attribute_container_device_trigger API will not know whether any, some, or all callbacks succeeded. This patch implements a safe version of this dispatcher, to either succeed all the callbacks or revert to the original state. Signed-off-by: Gabriel Krisman Bertazi --- drivers

[PATCH 2/3] drivers: base: Propagate errors through the transport component

2020-01-06 Thread Gabriel Krisman Bertazi
The transport registration may fail. Make sure the errors are propagated to the callers. Signed-off-by: Gabriel Krisman Bertazi --- drivers/base/transport_class.c | 11 --- include/linux/transport_class.h | 6 +++--- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a

[PATCH 0/3] drivers base: transport component error propagation

2020-01-06 Thread Gabriel Krisman Bertazi
what you think. Gabriel Krisman Bertazi (3): drivers: base: Support atomic version of attribute_container_device_trigger drivers: base: Propagate errors through the transport component iscsi: Fail session and connection on transport registration failure drivers/base/attribute_contai

[PATCH 3/3] iscsi: Fail session and connection on transport registration failure

2020-01-06 Thread Gabriel Krisman Bertazi
annot remove the session afterwards, since the kernel is in an inconsistent state. root@debian-vm:~# iscsiadm -m node -T iqn:lun1 -p 127.0.0.1 -u iscsiadm: No matching sessions found Signed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/scsi_transport_iscsi.c | 18 -- 1

[PATCH v4] iscsi: Perform connection failure entirely in kernel space

2020-01-03 Thread Gabriel Krisman Bertazi
Pomazau Co-developed-by: Tahsin Erdogan Signed-off-by: Tahsin Erdogan Co-developed-by: Frank Mayhar Signed-off-by: Frank Mayhar Co-developed-by: Junho Ryu Signed-off-by: Junho Ryu Co-developed-by: Khazhismel Kumykov Signed-off-by: Khazhismel Kumykov Signed-off-by: Bharath Ra

Re: [PATCH v3] iscsi: Perform connection failure entirely in kernel space

2020-01-02 Thread Gabriel Krisman Bertazi
Khazhismel Kumykov writes: > On Thu, Dec 26, 2019 at 3:48 PM Gabriel Krisman Bertazi > wrote: >> >> From: Bharath Ravi >> >> Connection failure processing depends on a daemon being present to (at >> least) stop the connection and start recovery. This is

[PATCH v3] iscsi: Perform connection failure entirely in kernel space

2019-12-26 Thread Gabriel Krisman Bertazi
y: Gabriel Krisman Bertazi Signed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/scsi_transport_iscsi.c | 63 + include/scsi/scsi_transport_iscsi.h | 1 + 2 files changed, 64 insertions(+) diff --git a/drivers/scsi/scsi_transport_iscsi.c b/drivers/scsi/scsi_transpo

[PATCH RESEND] iscsi: Don't destroy session if there are outstanding connections

2019-12-26 Thread Gabriel Krisman Bertazi
ace a2d933ede7f730d8 ]--- Co-developed-by: Salman Qazi Signed-off-by: Salman Qazi Co-developed-by: Junho Ryu Signed-off-by: Junho Ryu Co-developed-by: Khazhismel Kumykov Signed-off-by: Khazhismel Kumykov Signed-off-by: Nick Black Co-developed-by: Gabriel Krisman Bertazi Signed-off-by: Gabriel Kris

[PATCH v2] iscsi: Perform connection failure entirely in kernel space

2019-12-16 Thread Gabriel Krisman Bertazi
ed-by: Tahsin Erdogan Signed-off-by: Tahsin Erdogan Co-developed-by: Frank Mayhar Signed-off-by: Frank Mayhar Co-developed-by: Junho Ryu Signed-off-by: Junho Ryu Co-developed-by: Khazhismel Kumykov Signed-off-by: Khazhismel Kumykov Signed-off-by: Bharath Ravi Co-developed-by: Gabriel Krisman Be

Re: [PATCH] iscsi: Perform connection failure entirely in kernel space

2019-12-09 Thread Gabriel Krisman Bertazi
Lee Duncan writes: > On 12/9/19 10:20 AM, Gabriel Krisman Bertazi wrote: >> From: Bharath Ravi >> >> Connection failure processing depends on a daemon being present to (at >> least) stop the connection and start recovery. This is a problem on a >> multip

[PATCH] iscsi: Perform connection failure entirely in kernel space

2019-12-09 Thread Gabriel Krisman Bertazi
ff-by: Bharath Ravi Co-developed-by: Gabriel Krisman Bertazi Signed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/scsi_transport_iscsi.c | 46 + include/scsi/scsi_transport_iscsi.h | 1 + 2 files changed, 47 insertions(+) diff --git a/drivers/scsi/scsi_transport_iscsi

Re: [PATCH] iscsi: Don't send data to unbinded connection

2019-11-25 Thread Gabriel Krisman Bertazi
l make sure to CC the right list in the future. Although, looks like the MAINTAINERS file doesn't list linux-scsi as the target for iscsi patches. Would you take the fix below to address that? Thanks, -- >8 -- From: Gabriel Krisman Bertazi Subject: [PATCH] MAINTAINERS: Add the linux-s

[PATCH] iscsi: Don't destroy session if there are outstanding connections

2019-11-17 Thread Gabriel Krisman Bertazi
Ryu Co-developed-by: Khazhismel Kumykov Signed-off-by: Khazhismel Kumykov Signed-off-by: Nick Black Co-developed-by: Gabriel Krisman Bertazi Signed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/iscsi_tcp.c| 4 drivers/scsi/scsi_transport_iscsi.c | 26

[PATCH] iscsi: Don't send data to unbinded connection

2019-11-17 Thread Gabriel Krisman Bertazi
: Gabriel Krisman Bertazi Signed-off-by: Gabriel Krisman Bertazi --- drivers/scsi/iscsi_tcp.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/scsi/iscsi_tcp.c b/drivers/scsi/iscsi_tcp.c index cea7fda1dd23..b5dd1caae5e9 100644 --- a/drivers/scsi/iscsi_tcp.c +++ b/drivers/scsi