scsi: qedf: Limit number of CQs
authorThomas Bogendoerfer <tbogendoerfer@suse.de>
Tue, 25 Jul 2017 09:19:21 +0000 (11:19 +0200)
committerMartin K. Petersen <martin.petersen@oracle.com>
Thu, 27 Jul 2017 02:00:39 +0000 (22:00 -0400)
commit722477c4f2c50bc8d800d293a3bc5aa843f16e8d
tree05d8334dab8330b5a2febc257958a71640c04086
parentf9f22a86912f9d36b50e9b3b383fabfb9f22dd46
scsi: qedf: Limit number of CQs

FCOE offloading failed with:

[qed_sp_fcoe_func_start:150(sp-0-3b:00.02)]Cannot satisfy CQ amount. CQs
 requested 8, CQs available 6. Aborting function start
[qed_fcoe_start:821()]Failed to start fcoe
[__qedf_probe:3041]:6: Cannot start FCoE function.

The reason is a newly introduced check in the qed main part. This change
also provides the information about how many CQs are available, so we
simply limit the number of requested CQs..

Fixes: 3c5da9427802 ("qed: Share additional information with qedf")
Signed-off-by: Thomas Bogendoerfer <tbogendoerfer@suse.de>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Acked-by: Chad Dupuis <chad.dupuis@cavium.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/qedf/qedf.h
drivers/scsi/qedf/qedf_main.c