1. 19 9月, 2017 2 次提交
  2. 13 9月, 2017 1 次提交
  3. 08 9月, 2017 1 次提交
  4. 06 9月, 2017 3 次提交
  5. 29 8月, 2017 3 次提交
  6. 24 8月, 2017 1 次提交
    • C
      block: replace bi_bdev with a gendisk pointer and partitions index · 74d46992
      Christoph Hellwig 提交于
      This way we don't need a block_device structure to submit I/O.  The
      block_device has different life time rules from the gendisk and
      request_queue and is usually only available when the block device node
      is open.  Other callers need to explicitly create one (e.g. the lightnvm
      passthrough code, or the new nvme multipathing code).
      
      For the actual I/O path all that we need is the gendisk, which exists
      once per block device.  But given that the block layer also does
      partition remapping we additionally need a partition index, which is
      used for said remapping in generic_make_request.
      
      Note that all the block drivers generally want request_queue or
      sometimes the gendisk, so this removes a layer of indirection all
      over the stack.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NJens Axboe <axboe@kernel.dk>
      74d46992
  7. 23 8月, 2017 2 次提交
  8. 19 8月, 2017 7 次提交
  9. 16 8月, 2017 12 次提交
  10. 11 8月, 2017 8 次提交
    • M
      scsi: zfcp: early returns for traces disabled via level · f32c9e03
      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 emit with
      debug_event(). In order not to refactor the SAN tracing too much,
      simply use a define instead.
      
      This change is only for the non / semi hot paths,
      while the actual (I/O) hot path was already improved earlier:
      zfcp_dbf_scsi() is already guarded by its only caller _zfcp_dbf_scsi()
      since commit dcd20e23 ("[SCSI] zfcp: Only collect SCSI debug data for
      matching trace levels").
      zfcp_dbf_hba_fsf_res() is already guarded by its only caller
      zfcp_dbf_hba_fsf_response() since commit 2e261af8 ("[SCSI] zfcp: Only
      collect FSF/HBA debug data for matching trace levels").
      Signed-off-by: NMartin Peschke <mpeschke@linux.vnet.ibm.com>
      [maier@linux.vnet.ibm.com: rebase, reword, default level 3 branch prediction]
      Signed-off-by: NSteffen Maier <maier@linux.vnet.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      f32c9e03
    • M
      scsi: zfcp: clean up unnecessary module_param_named() with no_auto_port_rescan · b096ef86
      Martin Peschke 提交于
      Improves commit 43f60cbd ("[SCSI] zfcp: No automatic port_rescan on
      events")
      Signed-off-by: NMartin Peschke <mpeschke@linux.vnet.ibm.com>
      [maier@linux.vnet.ibm.com: reword, underscore in description to match sysfs]
      Signed-off-by: NSteffen Maier <maier@linux.vnet.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      b096ef86
    • M
      scsi: zfcp: clean up a member of struct zfcp_qdio that was assigned but never used · 5ec21960
      Martin Peschke 提交于
      v2.6.38 commit a54ca0f6 ("[SCSI] zfcp: Redesign of the debug tracing
      for HBA records.")
      dropped trace information previously introduced with
      v2.6.27 commit c3baa9a2 ("[SCSI] zfcp: Add information about interrupt
      to trace.")
      but kept and needlessly assigned a now no longer used struct field.
      Signed-off-by: NMartin Peschke <mpeschke@linux.vnet.ibm.com>
      [maier@linux.vnet.ibm.com: reword, added git history]
      Signed-off-by: NSteffen Maier <maier@linux.vnet.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      5ec21960
    • S
      scsi: zfcp: clean up no longer existent prototype from zfcp API header · 46e5ee1f
      Steffen Maier 提交于
      Commit a54ca0f6 ("[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: NMartin Peschke <mpeschke@linux.vnet.ibm.com>
      Signed-off-by: NSteffen Maier <maier@linux.vnet.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      46e5ee1f
    • M
      scsi: zfcp: clean up redundant code with fall through in link down SRB switch case · 5f03e98b
      Martin Peschke 提交于
      Signed-off-by: NMartin Peschke <mpeschke@linux.vnet.ibm.com>
      [maier@linux.vnet.ibm.com: re-worded short description for more details]
      Signed-off-by: NSteffen Maier <maier@linux.vnet.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      5f03e98b
    • S
      scsi: zfcp: fix kernel doc comment typos for struct zfcp_dbf_scsi · 5b2fc2a1
      Steffen Maier 提交于
      Improves commit 250a1352 ("[SCSI] zfcp: Redesign of the debug tracing
      for SCSI records.")
      Signed-off-by: NSteffen Maier <maier@linux.vnet.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      5b2fc2a1
    • S
      scsi: zfcp: use endianness conversions with common FC(P) struct fields · 9d464fc1
      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 expression where possible.
      
      NB: N_Port-IDs have always been handled with hton24 or ntoh24 conversions
      because they also convert to / from character array.
      
      Affected common code structs and .fields are:
      
      HOT I/O PATH:
      fcp_cmnd .fc_dl
         FCP command: regular SCSI I/O, including DIX case
      
      SEMI-HOT I/O PATH:
      fcp_cmnd .fc_dl
         recovery FCP command: task management function (LUN / target reset)
      fcp_resp_ext
         FCP response having FCP_SNS_LEN_VAL with .fr_rsp_len .fr_sns_len
         FCP response having FCP_RESID_UNDER with .fr_resid
      
      RECOVERY / DISCOVERY PATHS:
      fc_ct_hdr .ct_cmd .ct_mr_size
         zfcp auto port scan [GPN_FT] with fc_gpn_ft_resp.fp_wwpn,
         recovery for returned port [GID_PN] with fc_ns_gid_pn.fn_wwpn,
         get symbolic port name [GSPN],
         register symbolic port name [RSPN] (NPIV only).
      fc_els_rscn .rscn_plen
         incoming ELS (RSCN).
      fc_els_flogi .fl_wwpn .fl_wwnn
         incoming ELS (PLOGI),
         port open response with .fl_csp.sp_bb_data .fl_cssp[0..3].cp_class,
         FCP channel physical port,
         point-to-point peer (P2P only).
      fc_els_logo .fl_n_port_wwn
         incoming ELS (LOGO).
      fc_els_adisc .adisc_wwnn .adisc_wwpn
         path test after RSCN for gone target port.
      
      Since v4.10 commit 05de9700 ("linux/types.h: enable endian checks for
      all sparse builds"), below sparse endianness reports appear by default.
      Previously, one needed to pass argument CF="-D__CHECK_ENDIAN__" to make
      as in: $ make C=1 CF="-D__CHECK_ENDIAN__" M=drivers/s390/scsi.
      
      Silenced sparse warnings and one error:
      
      $ make C=1 M=drivers/s390/scsi
      ...
        CHECK   drivers/s390/scsi/zfcp_dbf.c
      drivers/s390/scsi/zfcp_dbf.c:463:22: warning: restricted __be16 degrades to integer
      drivers/s390/scsi/zfcp_dbf.c:476:28: warning: restricted __be16 degrades to integer
        CC      drivers/s390/scsi/zfcp_dbf.o
      ...
        CHECK   drivers/s390/scsi/zfcp_fc.c
      drivers/s390/scsi/zfcp_fc.c:263:26: warning: restricted __be16 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:299:41: warning: incorrect type in argument 2 (different base types)
      drivers/s390/scsi/zfcp_fc.c:299:41:    expected unsigned long long [unsigned] [usertype] wwpn
      drivers/s390/scsi/zfcp_fc.c:299:41:    got restricted __be64 [usertype] fl_wwpn
      drivers/s390/scsi/zfcp_fc.c:309:40: warning: incorrect type in argument 2 (different base types)
      drivers/s390/scsi/zfcp_fc.c:309:40:    expected unsigned long long [unsigned] [usertype] wwpn
      drivers/s390/scsi/zfcp_fc.c:309:40:    got restricted __be64 [usertype] fl_n_port_wwn
      drivers/s390/scsi/zfcp_fc.c:338:31: warning: restricted __be16 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:355:24: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fc.c:355:24:    expected restricted __be16 [usertype] ct_cmd
      drivers/s390/scsi/zfcp_fc.c:355:24:    got unsigned short [unsigned] [usertype] cmd
      drivers/s390/scsi/zfcp_fc.c:356:28: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fc.c:356:28:    expected restricted __be16 [usertype] ct_mr_size
      drivers/s390/scsi/zfcp_fc.c:356:28:    got int
      drivers/s390/scsi/zfcp_fc.c:379:36: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fc.c:379:36:    expected restricted __be64 [usertype] fn_wwpn
      drivers/s390/scsi/zfcp_fc.c:379:36:    got unsigned long long [unsigned] [usertype] wwpn
      drivers/s390/scsi/zfcp_fc.c:463:18: warning: restricted __be64 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:465:17: warning: cast from restricted __be64
      drivers/s390/scsi/zfcp_fc.c:473:20: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fc.c:473:20:    expected unsigned long long [unsigned] [usertype] wwnn
      drivers/s390/scsi/zfcp_fc.c:473:20:    got restricted __be64 [usertype] fl_wwnn
      drivers/s390/scsi/zfcp_fc.c:474:29: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fc.c:474:29:    expected unsigned int [unsigned] [usertype] maxframe_size
      drivers/s390/scsi/zfcp_fc.c:474:29:    got restricted __be16 [usertype] sp_bb_data
      drivers/s390/scsi/zfcp_fc.c:476:30: warning: restricted __be16 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:478:30: warning: restricted __be16 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:480:30: warning: restricted __be16 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:482:30: warning: restricted __be16 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:500:28: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fc.c:500:28:    expected unsigned long long [unsigned] [usertype] wwnn
      drivers/s390/scsi/zfcp_fc.c:500:28:    got restricted __be64 [usertype] adisc_wwnn
      drivers/s390/scsi/zfcp_fc.c:502:38: warning: restricted __be64 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:541:40: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fc.c:541:40:    expected restricted __be64 [usertype] adisc_wwpn
      drivers/s390/scsi/zfcp_fc.c:541:40:    got unsigned long long [unsigned] [usertype] port_name
      drivers/s390/scsi/zfcp_fc.c:542:40: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fc.c:542:40:    expected restricted __be64 [usertype] adisc_wwnn
      drivers/s390/scsi/zfcp_fc.c:542:40:    got unsigned long long [unsigned] [usertype] node_name
      drivers/s390/scsi/zfcp_fc.c:669:16: warning: restricted __be16 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:696:24: warning: restricted __be64 degrades to integer
      drivers/s390/scsi/zfcp_fc.c:699:54: warning: incorrect type in argument 2 (different base types)
      drivers/s390/scsi/zfcp_fc.c:699:54:    expected unsigned long long [unsigned] [usertype] <noident>
      drivers/s390/scsi/zfcp_fc.c:699:54:    got restricted __be64 [usertype] fp_wwpn
        CC      drivers/s390/scsi/zfcp_fc.o
        CHECK   drivers/s390/scsi/zfcp_fsf.c
      drivers/s390/scsi/zfcp_fsf.c:479:34: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fsf.c:479:34:    expected unsigned long long [unsigned] [usertype] port_name
      drivers/s390/scsi/zfcp_fsf.c:479:34:    got restricted __be64 [usertype] fl_wwpn
      drivers/s390/scsi/zfcp_fsf.c:480:34: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fsf.c:480:34:    expected unsigned long long [unsigned] [usertype] node_name
      drivers/s390/scsi/zfcp_fsf.c:480:34:    got restricted __be64 [usertype] fl_wwnn
      drivers/s390/scsi/zfcp_fsf.c:506:36: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fsf.c:506:36:    expected unsigned long long [unsigned] [usertype] peer_wwpn
      drivers/s390/scsi/zfcp_fsf.c:506:36:    got restricted __be64 [usertype] fl_wwpn
      drivers/s390/scsi/zfcp_fsf.c:507:36: warning: incorrect type in assignment (different base types)
      drivers/s390/scsi/zfcp_fsf.c:507:36:    expected unsigned long long [unsigned] [usertype] peer_wwnn
      drivers/s390/scsi/zfcp_fsf.c:507:36:    got restricted __be64 [usertype] fl_wwnn
      drivers/s390/scsi/zfcp_fc.h:269:46: warning: restricted __be32 degrades to integer
      drivers/s390/scsi/zfcp_fc.h:270:29: error: incompatible types in comparison expression (different base types)
      Signed-off-by: NSteffen Maier <maier@linux.vnet.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      9d464fc1
    • S
      scsi: zfcp: use common code fcp_cmnd and fcp_resp with union in fsf_qtcb_bottom_io · df00d7b8
      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 error-prone type casts.
      
      This change is possible since v2.6.33 commit 4318e08c
      ("[SCSI] zfcp: Update FCP protocol related code").
      Signed-off-by: NSteffen Maier <maier@linux.vnet.ibm.com>
      Reviewed-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Block <bblock@linux.vnet.ibm.com>
      Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
      df00d7b8