[PATCH 2/4] aic7xxx: fix aicasm out-of-tree build

2017-07-28 Thread Michał Mirosław
Fix out-of-tree build with CONFIG_PREVENT_FIRMWARE_BUILD=n. [...] make[3]: *** No rule to make target 'drivers/scsi/aic7xxx/aicasm/*.[chyl]', needed by 'drivers/scsi/aic7xxx/aicasm/aicasm'. Stop. /mnt/src/jaja/git/scsi-upstream/Makefile:1682: recipe for target 'drivers/scsi/aic7xxx/' failed

[PATCH 4/4] aic7xxx: printk() lines unbroken

2017-07-28 Thread Michał Mirosław
Current code is not SMP-friendly and since now each printk() call generates a separate line in the log, the output is mostly unreadable. Make it better formatted. Signed-off-by: Michał Mirosław --- drivers/scsi/Kconfig | 3 +-

[PATCH 1/4] aic7xxx: remove empty function

2017-07-28 Thread Michał Mirosław
ahc_platform_dump_card_state() does nothing. Remove it. Signed-off-by: Michał Mirosław --- drivers/scsi/aic7xxx/aic7xxx_core.c | 1 - drivers/scsi/aic7xxx/aic7xxx_osm.c | 5 - drivers/scsi/aic7xxx/aic7xxx_osm.h | 1 - 3 files changed, 7 deletions(-) diff --git

[PATCH 0/4] aic7xxx: fix debugging printks

2017-07-28 Thread Michał Mirosław
This series aims to clean up printing of card state after a problem event. Now the output is pretty much unreadable, as it is spread over a lot of single-word lines. This series compiles (on x86), but is not tested, yet. Best Regards, Michał Mirosław --- Michał Mirosław (4): aic7xxx: remove

[PATCH 3/4] aic7xxx: regenerate firmware files

2017-07-28 Thread Michał Mirosław
Regenerate firmware files to make cleaner base for following fix. This removes some unused definitions and reorders some #defines, but the code remains the same. Signed-off-by: Michał Mirosław --- drivers/scsi/aic7xxx/aic79xx_reg.h_shipped | 1267

[PATCH] megaraid_sas: move command counter to correct place

2017-07-28 Thread Tomas Henzl
the eh reset function returns success when fw_outstanding equals zero, that means that the counter shouldn't be decremented when the driver still owns the command Signed-off-by: Tomas Henzl --- drivers/scsi/megaraid/megaraid_sas_fusion.c | 2 +- 1 file changed, 1

[PATCH 22/22] zfcp: early returns for traces disabled via level

2017-07-28 Thread Benjamin Block
From: Martin Peschke This patch adds early checks to avoid burning CPU cycles on the assembly of trace entries which would be skipped anyway. Introduce a static const variable to keep the trace level to check with debug_level_enabled() in sync with the actual trace

[PATCH 17/22] zfcp: fix kernel doc comment typos for struct zfcp_dbf_scsi

2017-07-28 Thread Benjamin Block
From: Steffen Maier Improves commit 250a1352b95e ("[SCSI] zfcp: Redesign of the debug tracing for SCSI records.") Signed-off-by: Steffen Maier Reviewed-by: Benjamin Block Signed-off-by: Benjamin Block

[PATCH 05/22] zfcp: fix queuecommand for scsi_eh commands when DIX enabled

2017-07-28 Thread Benjamin Block
From: Steffen Maier Since commit db007fc5e20c ("[SCSI] Command protection operation"), scsi_eh_prep_cmnd() saves scmd->prot_op and temporarily resets it to SCSI_PROT_NORMAL. Other FCP LLDDs such as qla2xxx and lpfc shield their queuecommand() to only access any of

[PATCH 01/22] zfcp: replace zfcp_qdio_sbale_count by sg_nents

2017-07-28 Thread Benjamin Block
From: LABBE Corentin The zfcp_qdio_sbale_count function do the same work than sg_nents(). So replace it by sg_nents() for removing duplicate code. Signed-off-by: LABBE Corentin Signed-off-by: Steffen Maier

[PATCH 18/22] zfcp: clean up redundant code with fall through in link down SRB switch case

2017-07-28 Thread Benjamin Block
From: Martin Peschke Signed-off-by: Martin Peschke [ma...@linux.vnet.ibm.com: re-worded short description for more details] Signed-off-by: Steffen Maier Reviewed-by: Benjamin Block

[PATCH 16/22] zfcp: use endianness conversions with common FC(P) struct fields

2017-07-28 Thread Benjamin Block
From: Steffen Maier Just to silence sparse. Since zfcp only exists for s390 and s390 is big endian, this has been working correctly without conversions and all the new conversions are NOPs so no performance impact. Nonetheless, use the conversion on the constant

[PATCH 20/22] zfcp: clean up a member of struct zfcp_qdio that was assigned but never used

2017-07-28 Thread Benjamin Block
From: Martin Peschke v2.6.38 commit a54ca0f62f95 ("[SCSI] zfcp: Redesign of the debug tracing for HBA records.") dropped trace information previously introduced with v2.6.27 commit c3baa9a26c5a ("[SCSI] zfcp: Add information about interrupt to trace.") but kept and

[PATCH 00/22] zfcp fixes and cleanups

2017-07-28 Thread Benjamin Block
Hi all, here is a series of (important) fixes and some additional cleanups for the zfcp driver. Our fixes are marked for stable accordingly. Patches 01 - 04 are cleanups and external patches (also cleanups) that we & 13 - 22 had queued for quite some time now Patches 05 - 12 are

[PATCH 21/22] zfcp: clean up unnecessary module_param_named() with no_auto_port_rescan

2017-07-28 Thread Benjamin Block
From: Martin Peschke Improves commit 43f60cbd56c4 ("[SCSI] zfcp: No automatic port_rescan on events") Signed-off-by: Martin Peschke [ma...@linux.vnet.ibm.com: reword, underscore in description to match sysfs] Signed-off-by: Steffen

[PATCH 11/22] zfcp: trace HBA FSF response by default on dismiss or timedout late response

2017-07-28 Thread Benjamin Block
From: Steffen Maier At the default trace level, we only trace unsuccessful events including FSF responses. zfcp_dbf_hba_fsf_response() only used protocol status and FSF status to decide on an unsuccessful response. However, this is only one of multiple possible sources

[PATCH 15/22] zfcp: use common code fcp_cmnd and fcp_resp with union in fsf_qtcb_bottom_io

2017-07-28 Thread Benjamin Block
From: Steffen Maier This eases crash dump analysis by automatically dissecting these protocol headers at least somewhat rather than getting a string interpretation of large unstructured character array buffer fields. Also, we can get rid of some unnecessary and

[PATCH 04/22] zfcp: convert bool-definitions to use 'true' instead of '1'

2017-07-28 Thread Benjamin Block
Better form and cleans remaining warnings. Found with scripts/coccinelle/misc/boolinit.cocci. Signed-off-by: Benjamin Block --- drivers/s390/scsi/zfcp_qdio.c | 2 +- drivers/s390/scsi/zfcp_scsi.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git

[PATCH 07/22] zfcp: fix capping of unsuccessful GPN_FT SAN response trace records

2017-07-28 Thread Benjamin Block
From: Steffen Maier v4.9 commit aceeffbb59bb ("zfcp: trace full payload of all SAN records (req,resp,iels)") fixed trace data loss of 2.6.38 commit 2c55b750a884 ("[SCSI] zfcp: Redesign of the debug tracing for SAN records.") necessary for problem determination, e.g. to

[PATCH 06/22] zfcp: add handling for FCP_RESID_OVER to the fcp ingress path

2017-07-28 Thread Benjamin Block
Up until now zfcp would just ignore the FCP_RESID_OVER flag in the FCP response IU. When this flag is set, it is possible, in regards to the FCP standard, that the storage-server processes the command normally, up to the point where data is missing and simply ignores those. In this case no CHECK

[PATCH 19/22] zfcp: clean up no longer existent prototype from zfcp API header

2017-07-28 Thread Benjamin Block
From: Steffen Maier Commit a54ca0f62f95 ("[SCSI] zfcp: Redesign of the debug tracing for HBA records.") refactored zfcp_dbf_hba_berr into zfcp_dbf_hba_bit_err but added the prototype for the latter without removing it for the former. Suggested-by: Martin Peschke

[PATCH 10/22] zfcp: fix payload with full FCP_RSP IU in SCSI trace records

2017-07-28 Thread Benjamin Block
From: Steffen Maier If the FCP_RSP UI has optional parts (FCP_SNS_INFO or FCP_RSP_INFO) and thus does not fit into the fsp_rsp field built into a SCSI trace record, trace the full FCP_RSP UI with all optional parts as payload record instead of just FCP_SNS_INFO as

[PATCH 08/22] zfcp: fix passing fsf_req to SCSI trace on TMF to correlate with HBA

2017-07-28 Thread Benjamin Block
From: Steffen Maier Without this fix we get SCSI trace records on task management functions which cannot be correlated to HBA trace records because all fields related to the FSF request are empty (zero). Also, the FCP_RSP_IU is missing as well as any sense data if

[PATCH 09/22] zfcp: fix missing trace records for early returns in TMF eh handlers

2017-07-28 Thread Benjamin Block
From: Steffen Maier For problem determination we need to see that we were in scsi_eh as well as whether and why we were successful or not. The following commits introduced new early returns without adding a trace record: v2.6.35 commit a1dbfddd02d2 ("[SCSI] zfcp: Pass

[PATCH 14/22] zfcp: clarify that we don't need "link" test on failed open port

2017-07-28 Thread Benjamin Block
From: Steffen Maier Signed-off-by: Steffen Maier Reviewed-by: Benjamin Block Signed-off-by: Benjamin Block --- drivers/s390/scsi/zfcp_fsf.c | 4 +++- 1 file changed, 3 insertions(+), 1

[PATCH 12/22] zfcp: trace high part of "new" 64 bit SCSI LUN

2017-07-28 Thread Benjamin Block
From: Steffen Maier Complements debugging aspects of the otherwise functionally complete v3.17 commit 9cb78c16f5da ("scsi: use 64-bit LUNs"). While I don't have access to a target exporting 3 or 4 level LUNs, I did test it by explicitly attaching a non-existent fake 4

[PATCH 03/22] zfcp: Remove unneeded linux/miscdevice.h include

2017-07-28 Thread Benjamin Block
From: Corentin Labbe drivers/s390/scsi/zfcp_aux.c does not contain any miscdevice so the inclusion of linux/miscdevice.h is unnecessary. [ma...@linux.vnet.ibm.com: just for the records, this is in fact a minor missing code cleanup of the following older "feature"

[PATCH 13/22] zfcp: more fitting constant for fc_ct_hdr.ct_reason on port scan response

2017-07-28 Thread Benjamin Block
From: Steffen Maier v2.6.33 commit dbf5dfe9dbce ("[SCSI] zfcp: Use common code definitions for FC CT structs") replaced own definitions with common code definitions. While FC_BA_RJT_UNABLE happens to be defined with the same value 9 as FC_FS_RJT_UNABL and thus also

[PATCH 02/22] zfcp: use setup_timer instead of init_timer

2017-07-28 Thread Benjamin Block
From: Lukáš Korenčik Use initialization with setup_timer function instead of using init_timer function and data fields. It improves readability. Signed-off-by: Lukáš Korenčik Signed-off-by: Jiri Slaby Signed-off-by: Benjamin Block

[PATCH] MAINTAINERS: Add myself to S390 ZFCP DRIVER as a co-maintainer

2017-07-28 Thread Benjamin Block
I have been working with Steffen on zFCP for quite a while now and we decided adding me as a co-maintainer might be a good thing. Acked-by: Steffen Maier Signed-off-by: Benjamin Block --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+)