]> www.infradead.org Git - users/jedix/linux-maple.git/commit
be2iscsi: Fix soft lockup in mgmt_get_all_if_id path using bmbx
authorJitendra Bhivare <jitendra.bhivare@avagotech.com>
Wed, 20 Jan 2016 08:40:45 +0000 (14:10 +0530)
committerChuck Anderson <chuck.anderson@oracle.com>
Thu, 10 Mar 2016 15:21:43 +0000 (07:21 -0800)
commit39ed2c3942ea13b914d455e651f910dc91ef1ea6
tree7987a2365fce46f4006eef5051c1d3e31ab96376
parent2f170911d18ea074603272132f35ea9b7c58ba6a
be2iscsi: Fix soft lockup in mgmt_get_all_if_id path using bmbx

Orabug: 22725588

We are taking mbox_lock spinlock which disables pre-emption before we
poll for mbox completion. Waiting there with spinlock held in excess of
20s will cause soft lockup.

Actual fix is to change mbox_lock to mutex. The changes are done in
phases. This is the first part.

1. Changed mgmt_get_all_if_id to use MCC where after posting lock is
released.

2. Changed be_mbox_db_ready_wait to busy wait for 12s max and removed
wait_event_timeout. Added error handling code for IO reads.
OPCODE_COMMON_QUERY_FIRMWARE_CONFIG mbox command takes 8s time when
unreachable boot targets configured.

Signed-off-by: Jitendra Bhivare <jitendra.bhivare@avagotech.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Dan Duval <dan.duval@oracle.com>
drivers/scsi/be2iscsi/be_cmds.c
drivers/scsi/be2iscsi/be_mgmt.c