<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/drivers/scsi/libsas, branch v4.11</title>
<subtitle>Linux kernel source tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/'/>
<entry>
<title>scsi: libsas: fix ata xfer length</title>
<updated>2017-03-20T13:45:08+00:00</updated>
<author>
<name>John Garry</name>
<email>john.garry@huawei.com</email>
</author>
<published>2017-03-16T15:07:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=9702c67c6066f583b629cf037d2056245bb7a8e6'/>
<id>9702c67c6066f583b629cf037d2056245bb7a8e6</id>
<content type='text'>
The total ata xfer length may not be calculated properly, in that we do
not use the proper method to get an sg element dma length.

According to the code comment, sg_dma_len() should be used after
dma_map_sg() is called.

This issue was found by turning on the SMMUv3 in front of the hisi_sas
controller in hip07. Multiple sg elements were being combined into a
single element, but the original first element length was being use as
the total xfer length.

Cc: &lt;stable@vger.kernel.org&gt;
Fixes: ff2aeb1eb64c8a4770a6 ("libata: convert to chained sg")
Signed-off-by: John Garry &lt;john.garry@huawei.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The total ata xfer length may not be calculated properly, in that we do
not use the proper method to get an sg element dma length.

According to the code comment, sg_dma_len() should be used after
dma_map_sg() is called.

This issue was found by turning on the SMMUv3 in front of the hisi_sas
controller in hip07. Multiple sg elements were being combined into a
single element, but the original first element length was being use as
the total xfer length.

Cc: &lt;stable@vger.kernel.org&gt;
Fixes: ff2aeb1eb64c8a4770a6 ("libata: convert to chained sg")
Signed-off-by: John Garry &lt;john.garry@huawei.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi</title>
<updated>2017-02-21T19:51:42+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2017-02-21T19:51:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=cdc194705d26fdd7fc5446b5d830f2bbe2b22c30'/>
<id>cdc194705d26fdd7fc5446b5d830f2bbe2b22c30</id>
<content type='text'>
Pull SCSI updates from James Bottomley:
 "This update includes the usual round of major driver updates (ncr5380,
  ufs, lpfc, be2iscsi, hisi_sas, storvsc, cxlflash, aacraid,
  megaraid_sas, ...).

  There's also an assortment of minor fixes and the major update of
  switching a bunch of drivers to pci_alloc_irq_vectors from Christoph"

* tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (188 commits)
  scsi: megaraid_sas: handle dma_addr_t right on 32-bit
  scsi: megaraid_sas: array overflow in megasas_dump_frame()
  scsi: snic: switch to pci_irq_alloc_vectors
  scsi: megaraid_sas: driver version upgrade
  scsi: megaraid_sas: Change RAID_1_10_RMW_CMDS to RAID_1_PEER_CMDS and set value to 2
  scsi: megaraid_sas: Indentation and smatch warning fixes
  scsi: megaraid_sas: Cleanup VD_EXT_DEBUG and SPAN_DEBUG related debug prints
  scsi: megaraid_sas: Increase internal command pool
  scsi: megaraid_sas: Use synchronize_irq to wait for IRQs to complete
  scsi: megaraid_sas: Bail out the driver load if ld_list_query fails
  scsi: megaraid_sas: Change build_mpt_mfi_pass_thru to return void
  scsi: megaraid_sas: During OCR, if get_ctrl_info fails do not continue with OCR
  scsi: megaraid_sas: Do not set fp_possible if TM capable for non-RW syspdIO, change fp_possible to bool
  scsi: megaraid_sas: Remove unused pd_index from megasas_build_ld_nonrw_fusion
  scsi: megaraid_sas: megasas_return_cmd does not memset IO frame to zero
  scsi: megaraid_sas: max_fw_cmds are decremented twice, remove duplicate
  scsi: megaraid_sas: update can_queue only if the new value is less
  scsi: megaraid_sas: Change max_cmd from u32 to u16 in all functions
  scsi: megaraid_sas: set pd_after_lb from MR_BuildRaidContext and initialize pDevHandle to MR_DEVHANDLE_INVALID
  scsi: megaraid_sas: latest controller OCR capability from FW before sending shutdown DCMD
  ...
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull SCSI updates from James Bottomley:
 "This update includes the usual round of major driver updates (ncr5380,
  ufs, lpfc, be2iscsi, hisi_sas, storvsc, cxlflash, aacraid,
  megaraid_sas, ...).

  There's also an assortment of minor fixes and the major update of
  switching a bunch of drivers to pci_alloc_irq_vectors from Christoph"

* tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (188 commits)
  scsi: megaraid_sas: handle dma_addr_t right on 32-bit
  scsi: megaraid_sas: array overflow in megasas_dump_frame()
  scsi: snic: switch to pci_irq_alloc_vectors
  scsi: megaraid_sas: driver version upgrade
  scsi: megaraid_sas: Change RAID_1_10_RMW_CMDS to RAID_1_PEER_CMDS and set value to 2
  scsi: megaraid_sas: Indentation and smatch warning fixes
  scsi: megaraid_sas: Cleanup VD_EXT_DEBUG and SPAN_DEBUG related debug prints
  scsi: megaraid_sas: Increase internal command pool
  scsi: megaraid_sas: Use synchronize_irq to wait for IRQs to complete
  scsi: megaraid_sas: Bail out the driver load if ld_list_query fails
  scsi: megaraid_sas: Change build_mpt_mfi_pass_thru to return void
  scsi: megaraid_sas: During OCR, if get_ctrl_info fails do not continue with OCR
  scsi: megaraid_sas: Do not set fp_possible if TM capable for non-RW syspdIO, change fp_possible to bool
  scsi: megaraid_sas: Remove unused pd_index from megasas_build_ld_nonrw_fusion
  scsi: megaraid_sas: megasas_return_cmd does not memset IO frame to zero
  scsi: megaraid_sas: max_fw_cmds are decremented twice, remove duplicate
  scsi: megaraid_sas: update can_queue only if the new value is less
  scsi: megaraid_sas: Change max_cmd from u32 to u16 in all functions
  scsi: megaraid_sas: set pd_after_lb from MR_BuildRaidContext and initialize pDevHandle to MR_DEVHANDLE_INVALID
  scsi: megaraid_sas: latest controller OCR capability from FW before sending shutdown DCMD
  ...
</pre>
</div>
</content>
</entry>
<entry>
<title>scsi: libsas: remove sas_scsi_timed_out</title>
<updated>2017-02-07T00:09:12+00:00</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2017-01-30T12:18:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=28917d40e63a65c3923d45ed190c748e45b90ac7'/>
<id>28917d40e63a65c3923d45ed190c748e45b90ac7</id>
<content type='text'>
EH_NOT_HANDLED is the default case if no eh_timed_out method is
provided, so there is no need to supply it.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Hannes Reinecke &lt;hare@suse.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
EH_NOT_HANDLED is the default case if no eh_timed_out method is
provided, so there is no need to supply it.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Hannes Reinecke &lt;hare@suse.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>block: split scsi_request out of struct request</title>
<updated>2017-01-27T22:08:35+00:00</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2017-01-27T08:46:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=82ed4db499b8598f16f8871261bff088d6b0597f'/>
<id>82ed4db499b8598f16f8871261bff088d6b0597f</id>
<content type='text'>
And require all drivers that want to support BLOCK_PC to allocate it
as the first thing of their private data.  To support this the legacy
IDE and BSG code is switched to set cmd_size on their queues to let
the block layer allocate the additional space.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Jens Axboe &lt;axboe@fb.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
And require all drivers that want to support BLOCK_PC to allocate it
as the first thing of their private data.  To support this the legacy
IDE and BSG code is switched to set cmd_size on their queues to let
the block layer allocate the additional space.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Jens Axboe &lt;axboe@fb.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi</title>
<updated>2016-07-27T21:48:37+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2016-07-27T21:48:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=6a492b0f23d28e1f946cdf08e54617484400dafb'/>
<id>6a492b0f23d28e1f946cdf08e54617484400dafb</id>
<content type='text'>
Pull SCSI updates from James Bottomley:
 "This update includes the usual round of driver updates (fcoe, lpfc,
  ufs, qla2xxx, hisi_sas).  The most important other change is removing
  the flag to allow non-blk_mq on a per host basis (it's unused); there
  is still a global module parameter for all of SCSI just in case.

  The rest are an assortment of minor fixes and typo updates"

* tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (101 commits)
  scsi:libsas: fix oops caused by assigning a freed task to -&gt;lldd_task
  fnic: pci_dma_mapping_error() doesn't return an error code
  scsi: lpfc: avoid harmless comparison warning
  fcoe: implement FIP VLAN responder
  fcoe: Rename 'fip_frame' to 'fip_vn2vn_notify_frame'
  lpfc: call lpfc_sli_validate_fcp_iocb() with the hbalock held
  scsi: ufs: remove unnecessary goto label
  hpsa: change hpsa_passthru_ioctl timeout
  hpsa: correct skipping masked peripherals
  qla2xxx: Update driver version to 8.07.00.38-k
  qla2xxx: Fix BBCR offset
  qla2xxx: Fix duplicate message id.
  qla2xxx: Disable the adapter and skip error recovery in case of register disconnect.
  qla2xxx: Separate ISP type bits out from device type.
  qla2xxx: Correction to function qla26xx_dport_diagnostics().
  qla2xxx: Add support to handle Loop Init error Asynchronus event.
  qla2xxx: Let DPORT be enabled purely by nvram.
  qla2xxx: Add bsg interface to support statistics counter reset.
  qla2xxx: Add bsg interface to support D_Port Diagnostics.
  qla2xxx: Check for device state before unloading the driver.
  ...
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull SCSI updates from James Bottomley:
 "This update includes the usual round of driver updates (fcoe, lpfc,
  ufs, qla2xxx, hisi_sas).  The most important other change is removing
  the flag to allow non-blk_mq on a per host basis (it's unused); there
  is still a global module parameter for all of SCSI just in case.

  The rest are an assortment of minor fixes and typo updates"

* tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (101 commits)
  scsi:libsas: fix oops caused by assigning a freed task to -&gt;lldd_task
  fnic: pci_dma_mapping_error() doesn't return an error code
  scsi: lpfc: avoid harmless comparison warning
  fcoe: implement FIP VLAN responder
  fcoe: Rename 'fip_frame' to 'fip_vn2vn_notify_frame'
  lpfc: call lpfc_sli_validate_fcp_iocb() with the hbalock held
  scsi: ufs: remove unnecessary goto label
  hpsa: change hpsa_passthru_ioctl timeout
  hpsa: correct skipping masked peripherals
  qla2xxx: Update driver version to 8.07.00.38-k
  qla2xxx: Fix BBCR offset
  qla2xxx: Fix duplicate message id.
  qla2xxx: Disable the adapter and skip error recovery in case of register disconnect.
  qla2xxx: Separate ISP type bits out from device type.
  qla2xxx: Correction to function qla26xx_dport_diagnostics().
  qla2xxx: Add support to handle Loop Init error Asynchronus event.
  qla2xxx: Let DPORT be enabled purely by nvram.
  qla2xxx: Add bsg interface to support statistics counter reset.
  qla2xxx: Add bsg interface to support D_Port Diagnostics.
  qla2xxx: Check for device state before unloading the driver.
  ...
</pre>
</div>
</content>
</entry>
<entry>
<title>scsi:libsas: fix oops caused by assigning a freed task to -&gt;lldd_task</title>
<updated>2016-07-21T00:53:35+00:00</updated>
<author>
<name>Wei Fang</name>
<email>fangwei1@huawei.com</email>
</author>
<published>2016-07-06T09:00:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=354a086d9369cb7471790fa047665884f2bc6d79'/>
<id>354a086d9369cb7471790fa047665884f2bc6d79</id>
<content type='text'>
A freed task has been assigned to -&gt;lldd_task when lldd_execute_task()
failed in sas_ata_qc_issue(), and access of -&gt;lldd_task will cause an
oops:

Call trace:
[&lt;ffffffc000641f64&gt;] sas_ata_post_internal+0x6c/0x150
[&lt;ffffffc0006c0d64&gt;] ata_exec_internal_sg+0x32c/0x588
[&lt;ffffffc0006c1048&gt;] ata_exec_internal+0x88/0xe8
[&lt;ffffffc0006c13b4&gt;] ata_dev_read_id+0x204/0x5e0
[&lt;ffffffc0006c17f0&gt;] ata_dev_reread_id+0x60/0xc8
[&lt;ffffffc0006c3098&gt;] ata_dev_revalidate+0x88/0x1e0
[&lt;ffffffc0006cf828&gt;] ata_eh_recover+0xcf8/0x13a8
[&lt;ffffffc0006d075c&gt;] ata_do_eh+0x5c/0xe0
[&lt;ffffffc0006d0828&gt;] ata_std_error_handler+0x48/0x98
[&lt;ffffffc0006d042c&gt;] ata_scsi_port_error_handler+0x474/0x658
[&lt;ffffffc000641b78&gt;] async_sas_ata_eh+0x50/0x80
[&lt;ffffffc0000ca664&gt;] async_run_entry_fn+0x64/0x180
[&lt;ffffffc0000c085c&gt;] process_one_work+0x164/0x438
[&lt;ffffffc0000c0c74&gt;] worker_thread+0x144/0x4b0
[&lt;ffffffc0000c70fc&gt;] kthread+0xfc/0x110

Fix this by reassigning NULL to -&gt;lldd_task in error path.

Signed-off-by: Wei Fang &lt;fangwei1@huawei.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A freed task has been assigned to -&gt;lldd_task when lldd_execute_task()
failed in sas_ata_qc_issue(), and access of -&gt;lldd_task will cause an
oops:

Call trace:
[&lt;ffffffc000641f64&gt;] sas_ata_post_internal+0x6c/0x150
[&lt;ffffffc0006c0d64&gt;] ata_exec_internal_sg+0x32c/0x588
[&lt;ffffffc0006c1048&gt;] ata_exec_internal+0x88/0xe8
[&lt;ffffffc0006c13b4&gt;] ata_dev_read_id+0x204/0x5e0
[&lt;ffffffc0006c17f0&gt;] ata_dev_reread_id+0x60/0xc8
[&lt;ffffffc0006c3098&gt;] ata_dev_revalidate+0x88/0x1e0
[&lt;ffffffc0006cf828&gt;] ata_eh_recover+0xcf8/0x13a8
[&lt;ffffffc0006d075c&gt;] ata_do_eh+0x5c/0xe0
[&lt;ffffffc0006d0828&gt;] ata_std_error_handler+0x48/0x98
[&lt;ffffffc0006d042c&gt;] ata_scsi_port_error_handler+0x474/0x658
[&lt;ffffffc000641b78&gt;] async_sas_ata_eh+0x50/0x80
[&lt;ffffffc0000ca664&gt;] async_run_entry_fn+0x64/0x180
[&lt;ffffffc0000c085c&gt;] process_one_work+0x164/0x438
[&lt;ffffffc0000c0c74&gt;] worker_thread+0x144/0x4b0
[&lt;ffffffc0000c70fc&gt;] kthread+0xfc/0x110

Fix this by reassigning NULL to -&gt;lldd_task in error path.

Signed-off-by: Wei Fang &lt;fangwei1@huawei.com&gt;
Signed-off-by: Martin K. Petersen &lt;martin.petersen@oracle.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>libsas: use ata_is_ncq() and ata_has_dma() accessors</title>
<updated>2016-07-14T14:45:02+00:00</updated>
<author>
<name>Hannes Reinecke</name>
<email>hare@suse.de</email>
</author>
<published>2016-07-14T00:05:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=b38d4d85b89c68b2748a5e225185073424510486'/>
<id>b38d4d85b89c68b2748a5e225185073424510486</id>
<content type='text'>
Use accessors instead of the raw protocol value.

Signed-off-by: Hannes Reinecke &lt;hare@suse.com&gt;
[hch: trivial cleanup of the ata_task assignments]
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use accessors instead of the raw protocol value.

Signed-off-by: Hannes Reinecke &lt;hare@suse.com&gt;
[hch: trivial cleanup of the ata_task assignments]
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>libata/libsas: Define ATA_CMD_NCQ_NON_DATA</title>
<updated>2016-05-09T16:36:44+00:00</updated>
<author>
<name>Hannes Reinecke</name>
<email>hare@suse.de</email>
</author>
<published>2016-04-25T10:45:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=661ce1f0c4a69f92ad781d8d2c205c90dd9c5833'/>
<id>661ce1f0c4a69f92ad781d8d2c205c90dd9c5833</id>
<content type='text'>
Define the NCQ NON DATA command and update libsas to handle it
correctly.

Signed-off-by: Hannes Reinecke &lt;hare@suse.com&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Define the NCQ NON DATA command and update libsas to handle it
correctly.

Signed-off-by: Hannes Reinecke &lt;hare@suse.com&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>libsas: enable FPDMA SEND/RECEIVE</title>
<updated>2016-05-09T16:36:44+00:00</updated>
<author>
<name>Hannes Reinecke</name>
<email>hare@suse.de</email>
</author>
<published>2016-04-25T10:45:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=ef026b18bb8260e21b4a61685eac46ecdc490d00'/>
<id>ef026b18bb8260e21b4a61685eac46ecdc490d00</id>
<content type='text'>
Update libsas and dependent drivers to handle FPDMA
SEND/RECEIVE correctly.

Signed-off-by: Hannes Reinecke &lt;hare@suse.com&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Update libsas and dependent drivers to handle FPDMA
SEND/RECEIVE correctly.

Signed-off-by: Hannes Reinecke &lt;hare@suse.com&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'for-4.0-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata</title>
<updated>2015-03-25T00:08:29+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2015-03-25T00:08:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=1401b7c3ec5a8521e53a56c0da27f743b4765d26'/>
<id>1401b7c3ec5a8521e53a56c0da27f743b4765d26</id>
<content type='text'>
Pull libata fix from Tejun Heo:
 "One patch to fix a regression from the recent switch to blk-mq tag
  allocation which can cause oops on SAS-attached SATA drives"

* 'for-4.0-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata:
  ata: Add a new flag to destinguish sas controller
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull libata fix from Tejun Heo:
 "One patch to fix a regression from the recent switch to blk-mq tag
  allocation which can cause oops on SAS-attached SATA drives"

* 'for-4.0-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata:
  ata: Add a new flag to destinguish sas controller
</pre>
</div>
</content>
</entry>
</feed>
