An error occurred fetching the project authors.
- 02 Aug, 2024 1 commit
-
-
Damien Le Moal authored
The function ata_noop_qc_prep(), as its name implies, does nothing and simply returns AC_ERR_OK. For drivers that do not need any special preparations of queued commands, we can avoid having to define struct ata_port qc_prep operation by simply testing if that operation is defined or not in ata_qc_issue(). Make this change and remove ata_noop_qc_prep(). Signed-off-by:
Damien Le Moal <dlemoal@kernel.org> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Sergey Shtylyov <s.shtylyov@omp.ru>
-
- 04 Jul, 2024 2 commits
-
-
Niklas Cassel authored
The ata_sas_port_alloc() wrapper mainly exists in order to export the internal libata function which it wraps. The secondary reason is that it initializes some ata_port struct members. However, ata_sas_port_alloc() is only used in a single location, sas_ata_init(), which already performs some ata_port struct member initialization, so it does not make sense to spread this initialization out over two separate locations. Thus, remove the wrapper and instead export the libata function directly, and move the libsas specific ata_port initialization to sas_ata_init(), which already does some ata_port initialization. Reviewed-by:
Hannes Reinecke <hare@suse.de> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Martin K. Petersen <martin.petersen@oracle.com> Link: https://lore.kernel.org/r/20240703184418.723066-19-cassel@kernel.orgSigned-off-by:
Niklas Cassel <cassel@kernel.org>
-
Niklas Cassel authored
The ata_sas_tport_add() and ata_sas_tport_delete() wrappers only exist in order to export the internal libata functions which they wrap. Remove the wrappers and instead export the libata functions directly. Reviewed-by:
Hannes Reinecke <hare@suse.de> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Martin K. Petersen <martin.petersen@oracle.com> Link: https://lore.kernel.org/r/20240703184418.723066-12-cassel@kernel.orgSigned-off-by:
Niklas Cassel <cassel@kernel.org>
-
- 30 Jun, 2024 1 commit
-
-
Niklas Cassel authored
libsas is currently not freeing all the struct ata_port struct members, e.g. ncq_sense_buf for a driver supporting Command Duration Limits (CDL). Add a function, ata_port_free(), that is used to free a ata_port, including its struct members. It makes sense to keep the code related to freeing a ata_port in its own function, which will also free all the struct members of struct ata_port. Fixes: 18bd7718 ("scsi: ata: libata: Handle completion of CDL commands using policy 0xD") Reviewed-by:
John Garry <john.g.garry@oracle.com> Link: https://lore.kernel.org/r/20240629124210.181537-8-cassel@kernel.orgSigned-off-by:
Niklas Cassel <cassel@kernel.org>
-
- 28 Mar, 2024 1 commit
-
-
Damien Le Moal authored
Commit b4d3ddd2 ("scsi: libsas: Define NCQ Priority sysfs attributes for SATA devices") introduced support for ATA NCQ priority control for ATA devices managed by libsas. This commit introduces the ncq_prio_supported and ncq_prio_enable sysfs device attributes to discover and control the use of this features, similarly to libata. However, libata publicly declares these device attributes and export them for use in ATA low level drivers. This leads to a compilation error when libsas and libata are built-in due to the double definition: ld: drivers/ata/libata-sata.o:/home/Linux/scsi/drivers/ata/libata-sata.c:900: multiple definition of `dev_attr_ncq_prio_supported'; drivers/scsi/libsas/sas_ata.o:/home/Linux/scsi/drivers/scsi/libsas/sas_ata.c:984: first defined here ld: drivers/ata/libata-sata.o:/home/Linux/scsi/drivers/ata/libata-sata.c:1026: multiple definition of `dev_attr_ncq_prio_enable'; drivers/scsi/libsas/sas_ata.o:/home/Linux/scsi/drivers/scsi/libsas/sas_ata.c:1022: first defined here Resolve this problem by directly declaring the libsas attributes instead of using the DEVICE_ATTR() macro. And for good measure, the device attribute variables are also renamed. Reported-by:
Geert Uytterhoeven <geert@linux-m68k.org> Fixes: b4d3ddd2 ("scsi: libsas: Define NCQ Priority sysfs attributes for SATA devices") Signed-off-by:
Damien Le Moal <dlemoal@kernel.org> Link: https://lore.kernel.org/r/20240327020122.439424-1-dlemoal@kernel.orgReviewed-by:
John Garry <john.g.garry@oracle.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 25 Mar, 2024 1 commit
-
-
Igor Pylypiv authored
libata sysfs attributes cannot be used for libsas-managed SATA devices because the ata_port location is different for libsas. Defined sysfs attributes (visible for SATA devices only): - /sys/block/sda/device/ncq_prio_enable - /sys/block/sda/device/ncq_prio_supported The newly defined attributes will pass the correct ata_port to libata helper functions. Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Damien Le Moal <dlemoal@kernel.org> Reviewed-by:
Jason Yan <yanaijie@huawei.com> Signed-off-by:
Igor Pylypiv <ipylypiv@google.com> Link: https://lore.kernel.org/r/20240307214418.3812290-3-ipylypiv@google.comReviewed-by:
Niklas Cassel <cassel@kernel.org> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 21 Aug, 2023 3 commits
-
-
John Garry authored
Since libsas was introduced in commit 2908d778 ("[SCSI] aic94xx: new driver"), sas_ssp_task.retry_count is only ever set, so delete it. The aic94xx driver also had its own retry_count definition in struct scb sub-structs, which may have caused a mix-up. Signed-off-by:
John Garry <john.g.garry@oracle.com> Link: https://lore.kernel.org/r/20230815115156.343535-6-john.g.garry@oracle.comReviewed-by:
Jason Yan <yanaijie@huawei.com> Reviewed-by:
Damien Le Moal <dlemoal@kernel.org> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
John Garry authored
Since commit 79855d17 ("libsas: remove task_collector mode"), struct scsi_core only contains a reference to the shost. struct scsi_core is only used in sas_ha_struct.core, so delete scsi_core and replace with a reference to the shost there. Signed-off-by:
John Garry <john.g.garry@oracle.com> Link: https://lore.kernel.org/r/20230815115156.343535-5-john.g.garry@oracle.comReviewed-by:
Jason Yan <yanaijie@huawei.com> Reviewed-by:
Damien Le Moal <dlemoal@kernel.org> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
Igor Pylypiv authored
Set return_fis_on_success when libata requests result taskfile. For Command Duration Limits policy 0xD (command completes without an error) libata needs FIS in order to detect the ATA_SENSE bit and read the Sense Data for Successful NCQ Commands log (0Fh). Signed-off-by:
Igor Pylypiv <ipylypiv@google.com> Link: https://lore.kernel.org/r/20230819213040.1101044-2-ipylypiv@google.comReviewed-by:
Niklas Cassel <niklas.cassel@wdc.com> Reviewed-by:
Damien Le Moal <dlemoal@kernel.org> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 02 Aug, 2023 4 commits
-
-
Niklas Cassel authored
ata_sas_port_init() now only contains a single initialization. Move this single initialization to ata_sas_port_alloc(), since: 1) ata_sas_port_alloc() already initializes some of the struct members. 2) ata_sas_port_alloc() is only used by libsas. Suggested-by:
John Garry <john.g.garry@oracle.com> Signed-off-by:
Niklas Cassel <niklas.cassel@wdc.com> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by:
Damien Le Moal <dlemoal@kernel.org>
-
Hannes Reinecke authored
Rename __ata_port_probe() to ata_port_probe() and drop the wrapper ata_sas_async_probe(). Signed-off-by:
Hannes Reinecke <hare@suse.de> Signed-off-by:
Niklas Cassel <niklas.cassel@wdc.com> Reviewed-by:
Jason Yan <yanaijie@huawei.com> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by:
Damien Le Moal <dlemoal@kernel.org>
-
Hannes Reinecke authored
Is now a wrapper around kfree(), so call it directly. Signed-off-by:
Hannes Reinecke <hare@suse.de> Signed-off-by:
Niklas Cassel <niklas.cassel@wdc.com> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Jason Yan <yanaijie@huawei.com> Reviewed-by:
Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by:
Damien Le Moal <dlemoal@kernel.org>
-
Hannes Reinecke authored
Callbacks are empty now, so remove them. Also, remove the call to ap->ops->port_start() in ata_sas_port_init(), as this would otherwise cause a NULL pointer dereference, now when the callback is gone. Signed-off-by:
Hannes Reinecke <hare@suse.de> [niklas: remove the call to ap->ops->port_start() in ata_sas_port_init()] Signed-off-by:
Niklas Cassel <niklas.cassel@wdc.com> Reviewed-by:
Jason Yan <yanaijie@huawei.com> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by:
Damien Le Moal <dlemoal@kernel.org>
-
- 12 Jan, 2023 1 commit
-
-
Dan Carpenter authored
This code accidentally returns success instead of -ENOMEM. Fixes: 7cc7646b ("scsi: libsas: Factor out sas_ata_add_dev()") Link: https://lore.kernel.org/r/Y7asLxzVwQ56G+ya@kiliSigned-off-by:
Dan Carpenter <error27@gmail.com> Reviewed-by:
Jason Yan <yanaijie@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 07 Jan, 2023 1 commit
-
-
Xingui Yang authored
Grab the ATA port lock in sas_ata_device_link_abort() before calling ata_link_abort() as outlined in this function's locking requirements. Fixes: 44112922 ("scsi: libsas: Add sas_ata_device_link_abort()") Signed-off-by:
Xingui Yang <yangxingui@huawei.com> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Jason Yan <yanaijie@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 04 Jan, 2023 2 commits
-
-
Damien Le Moal authored
The boolean return value of the qc_fill_rtf operation is used nowhere. Simplify this operation interface by making it a void function. All drivers defining this operation are also updated. Signed-off-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com> Signed-off-by:
Niklas Cassel <niklas.cassel@wdc.com> Reviewed-by:
John Garry <john.g.garry@oracle.com>
-
Niklas Cassel authored
The name ATA_QCFLAG_FAILED is misleading since it does not mean that a QC completed in error, or that it didn't complete at all. It means that libata decided to schedule EH for the QC, so the QC is now owned by the libata error handler (EH). The normal execution path is responsible for not accessing a QC owned by EH. libata core enforces the rule by returning NULL from ata_qc_from_tag() for QCs owned by EH. It is quite easy to mistake that a QC marked with ATA_QCFLAG_FAILED was an error. However, a QC that was actually an error is instead indicated by having qc->err_mask set. E.g. when we have a NCQ error, we abort all QCs, which currently will mark all QCs as ATA_QCFLAG_FAILED. However, it will only be a single QC that is an error (i.e. has qc->err_mask set). Rename ATA_QCFLAG_FAILED to ATA_QCFLAG_EH to more clearly highlight that this flag simply means that a QC is now owned by EH. This new name will not mislead to think that the QC was an error (which is instead indicated by having qc->err_mask set). This also makes it more obvious that the EH code skips all QCs that do not have ATA_QCFLAG_EH set (rather than ATA_QCFLAG_FAILED), since the EH code should simply only care about QCs that are owned by EH itself. Signed-off-by:
Niklas Cassel <niklas.cassel@wdc.com> Reviewed-by:
John Garry <john.g.garry@oracle.com> Signed-off-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com>
-
- 30 Dec, 2022 2 commits
-
-
Jason Yan authored
Factor out sas_ata_add_dev() and put it in sas_ata.c since it is a SATA related interface. Also follow the standard coding style to define an inline empty function when CONFIG_SCSI_SAS_ATA is not enabled. Cc: John Garry <john.g.garry@oracle.com> Signed-off-by:
Jason Yan <yanaijie@huawei.com> Reviewed-by:
John Garry <john.g.garry@oracle.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
Jason Yan authored
There is a sas_get_ata_command_set() declaration above sas_get_ata_info() to make it compile. However, this function is defined in the same file. Move it up to save the forward declaration. Also remove the variable 'fis' which is not needed in this function. Cc: John Garry <john.g.garry@oracle.com> Signed-off-by:
Jason Yan <yanaijie@huawei.com> Reviewed-by:
John Garry <john.g.garry@oracle.com> Reviewed-by:
Jack Wang <jinpu.wang@ionos.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 26 Nov, 2022 2 commits
-
-
Jie Zhan authored
sas_ata_wait_after_reset() does not need to be exported since it is no longer referenced outside libsas. Signed-off-by:
Jie Zhan <zhanjie9@hisilicon.com> Link: https://lore.kernel.org/r/20221118083714.4034612-6-zhanjie9@hisilicon.comReviewed-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
Jie Zhan authored
Create function smp_ata_check_ready_type() for LLDDs to wait for SATA devices to come up after a link reset. Signed-off-by:
Jie Zhan <zhanjie9@hisilicon.com> Link: https://lore.kernel.org/r/20221118083714.4034612-4-zhanjie9@hisilicon.comSigned-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 19 Oct, 2022 1 commit
-
-
Niklas Cassel authored
Clean up the code by making use of the newly introduced ata_port_is_frozen() helper function. Signed-off-by:
Niklas Cassel <niklas.cassel@wdc.com> Reviewed-by:
John Garry <john.garry@huawei.com> Acked-by:
Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com>
-
- 18 Oct, 2022 2 commits
-
-
John Garry authored
In sas_ata_task_done(), for commands which complete with error we set the SATA dev FIS status field with ATA_ERR. In ata_eh_analyze_tf() this would be interpreted as a HSM error. Set ATA_DRDY, which will lead libata to judge as a device error, which is a safer bet. Signed-off-by:
John Garry <john.garry@huawei.com> Link: https://lore.kernel.org/r/1665998435-199946-9-git-send-email-john.garry@huawei.comReviewed-by:
Niklas Cassel <niklas.cassel@wdc.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
John Garry authored
Similar to how AHCI handles NCQ errors in ahci_error_intr() -> ata_port_abort() -> ata_do_link_abort(), add an NCQ error handler for LLDDs to call to initiate a link abort. This will mark all outstanding QCs as failed and kick-off EH. Note: A "force reset" argument is added for drivers which require the ATA error handling to always reset the device. A driver may require this feature for when SATA device per-SCSI cmnd resources are only released during reset for ATA EH. As such, we need an option to force reset to be done, regardless of what any EH autopsy decides. The SATA device FIS fields are set to indicate a device error from ata_eh_analyze_tf(). Suggested-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com> Suggested-by:
Niklas Cassel <niklas.cassel@wdc.com> Signed-off-by:
John Garry <john.garry@huawei.com> Link: https://lore.kernel.org/r/1665998435-199946-2-git-send-email-john.garry@huawei.comTested-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com> Tested-by: Niklas Cassel <niklas.cassel@wdc.com> # pm80xx Reviewed-by:
Jason Yan <yanaijie@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 20 May, 2022 1 commit
-
-
John Garry authored
Create function sas_ata_wait_after_reset() from sas_ata_hard_reset() as some LLDDs may want to check for a remote ATA phy is up after reset. Link: https://lore.kernel.org/r/1652354134-171343-2-git-send-email-john.garry@huawei.comTested-by:
Yihang Li <liyihang6@hisilicon.com> Reviewed-by:
Xiang Chen <chenxiang66@hisilicon.com> Signed-off-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 23 Feb, 2022 3 commits
-
-
Damien Le Moal authored
To detect if a command is NCQ, there is no need to test all possible NCQ command codes. Instead, use ata_is_ncq() to test the command protocol. Link: https://lore.kernel.org/r/20220220031810.738362-24-damien.lemoal@opensource.wdc.comReviewed-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
Damien Le Moal authored
To detect for the DMA_NONE (no data transfer) DMA direction, sas_ata_qc_issue() tests if the command protocol is ATA_PROT_NODATA. This test does not include the ATA_CMD_NCQ_NON_DATA command as this command protocol is defined as ATA_PROT_NCQ_NODATA (equal to ATA_PROT_FLAG_NCQ) and not as ATA_PROT_NODATA. To include both NCQ and non-NCQ commands when testing for the DMA_NONE DMA direction, use "!ata_is_data()". Link: https://lore.kernel.org/r/20220220031810.738362-2-damien.lemoal@opensource.wdc.com Fixes: 176ddd89 ("scsi: libsas: Reset num_scatter if libata marks qc as NODATA") Cc: stable@vger.kernel.org Reviewed-by:
John Garry <john.garry@huawei.com> Reviewed-by:
Jack Wang <jinpu.wang@ionos.com> Signed-off-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
John Garry authored
Add a function to execute an ATA command using the TMF code, and use in the hisi_sas driver. That driver needs to be able to issue the command on a specific phy, so add an interface for that. With that, hisi_sas_exec_internal_tmf_task() may be deleted. Link: https://lore.kernel.org/r/1645534259-27068-19-git-send-email-john.garry@huawei.comTested-by:
Yihang Li <liyihang6@hisilicon.com> Tested-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com> Reviewed-by:
Christoph Hellwig <hch@lst.de> Signed-off-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 19 Feb, 2022 1 commit
-
-
John Garry authored
No LLDD sets exec status as SAS_SG_ERR, so remove support. Link: https://lore.kernel.org/r/1645112566-115804-5-git-send-email-john.garry@huawei.comTested-by:
Damien Le Moal <damien.lemoal@opensource.wdc.com> Signed-off-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 11 Feb, 2022 2 commits
-
-
Xiang Chen authored
Input parameter work_q is not unused in function sas_ata_eh(), so remove it. Link: https://lore.kernel.org/r/1644561778-183074-4-git-send-email-chenxiang66@hisilicon.comReviewed-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Xiang Chen <chenxiang66@hisilicon.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
Xiang Chen authored
Task->task_state_flags is already set in function sas_alloc_task(), so remove duplicated setting. Link: https://lore.kernel.org/r/1644561778-183074-3-git-send-email-chenxiang66@hisilicon.comReviewed-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Xiang Chen <chenxiang66@hisilicon.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 12 Aug, 2021 1 commit
-
-
Bart Van Assche authored
Prepare for removal of the request pointer by using scsi_cmd_to_rq() instead. This patch does not change any functionality. Link: https://lore.kernel.org/r/20210809230355.8186-27-bvanassche@acm.orgReviewed-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Bart Van Assche <bvanassche@acm.org> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 21 Jul, 2021 1 commit
-
-
Jason Yan authored
libsas needs to include some header files in the scsi directory. However these are currently hardcoded with the path "../" in the C files. Do this in the Makefile to avoid hardcoding the path. Link: https://lore.kernel.org/r/20210716074551.771312-1-yanaijie@huawei.com Cc: John Garry <john.garry@huawei.com> Reviewed-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Jason Yan <yanaijie@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 02 Jun, 2021 1 commit
-
-
Bart Van Assche authored
This patch prepares for converting SAM status codes into an enum. Without this patch converting SAM status codes into an enumeration type would trigger complaints about enum type mismatches for the SAS code. Link: https://lore.kernel.org/r/20210524025457.11299-2-bvanassche@acm.org Cc: Hannes Reinecke <hare@suse.com> Cc: Artur Paszkiewicz <artur.paszkiewicz@intel.com> Cc: Jason Yan <yanaijie@huawei.com> Reviewed-by:
John Garry <john.garry@huawei.com> Reviewed-by:
Himanshu Madhani <himanshu.madhani@oracle.com> Acked-by:
Jack Wang <jinpu.wang@ionos.com> Signed-off-by:
Bart Van Assche <bvanassche@acm.org> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 08 Apr, 2021 1 commit
-
-
Jolly Shah authored
When the cache_type for the SCSI device is changed, the SCSI layer issues a MODE_SELECT command. The caching mode details are communicated via a request buffer associated with the SCSI command with data direction set as DMA_TO_DEVICE (scsi_mode_select()). When this command reaches the libata layer, as a part of generic initial setup, libata layer sets up the scatterlist for the command using the SCSI command (ata_scsi_qc_new()). This command is then translated by the libata layer into ATA_CMD_SET_FEATURES (ata_scsi_mode_select_xlat()). The libata layer treats this as a non-data command (ata_mselect_caching()), since it only needs an ATA taskfile to pass the caching on/off information to the device. It does not need the scatterlist that has been setup, so it does not perform dma_map_sg() on the scatterlist (ata_qc_issue()). Unfortunately, when this command reaches the libsas layer (sas_ata_qc_issue()), libsas layer sees it as a non-data command with a scatterlist. It cannot extract the correct DMA length since the scatterlist has not been mapped with dma_map_sg() for a DMA operation. When this partially constructed SAS task reaches pm80xx LLDD, it results in the following warning: "pm80xx_chip_sata_req 6058: The sg list address start_addr=0x0000000000000000 data_len=0x0end_addr_high=0xffffffff end_addr_low=0xffffffff has crossed 4G boundary" Update libsas to handle ATA non-data commands separately so num_scatter and total_xfer_len remain 0. Link: https://lore.kernel.org/r/20210318225632.2481291-1-jollys@google.com Fixes: 53de092f ("scsi: libsas: Set data_dir as DMA_NONE if libata marks qc as NODATA") Tested-by:
Luo Jiaxing <luojiaxing@huawei.com> Reviewed-by:
John Garry <john.garry@huawei.com> Signed-off-by:
Jolly Shah <jollys@google.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 06 Apr, 2021 1 commit
-
-
Luo Jiaxing authored
checkpatch reported an error in sas_to_ata_err(). switch and case statements are incorrectly indented. Link: https://lore.kernel.org/r/1616675396-6108-2-git-send-email-luojiaxing@huawei.comSigned-off-by:
Luo Jiaxing <luojiaxing@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 23 Sep, 2020 1 commit
-
-
Liu Shixin authored
Simplify the return expression. Link: https://lore.kernel.org/r/20200921134558.3478922-1-liushixin2@huawei.comReviewed-by:
Jason Yan <yanaijie@huawei.com> Signed-off-by:
Liu Shixin <liushixin2@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 02 Sep, 2020 1 commit
-
-
Luo Jiaxing authored
It was discovered that sdparm will fail when attempting to disable write cache on a SATA disk connected via libsas. In the ATA command set the write cache state is controlled through the SET FEATURES operation. This is roughly corresponds to MODE SELECT in SCSI and the latter command is what is used in the SCSI-ATA translation layer. A subtle difference is that a MODE SELECT carries data whereas SET FEATURES is defined as a non-data command in ATA. Set the DMA data direction to DMA_NONE if the requested ATA command is identified as non-data. [mkp: commit desc] Fixes: fa1c1e8f ("[SCSI] Add SATA support to libsas") Link: https://lore.kernel.org/r/1598426666-54544-1-git-send-email-luojiaxing@huawei.comReviewed-by:
John Garry <john.garry@huawei.com> Reviewed-by:
Jason Yan <yanaijie@huawei.com> Signed-off-by:
Luo Jiaxing <luojiaxing@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-
- 23 Aug, 2020 1 commit
-
-
Gustavo A. R. Silva authored
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. Also, remove unnecessary fall-through markings when it is the case. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-throughSigned-off-by:
Gustavo A. R. Silva <gustavoars@kernel.org>
-
- 25 Jul, 2020 1 commit
-
-
Luo Jiaxing authored
libata currently attempts to reset even if the SATA disk is unplugged. To avoid the meaningless reset of a missing disk, libsas should report offline status to libata. libata already provides a .prereset callback for this purpose. This is called by ata_eh_reset() and can be used to influence whether a reset attempt should be made. Add sas_ata_preset callback to check status of phy and disk. If the disk is already offline or phy is disabled, we return -ENOENT to libata to avoid the reset. Link: https://lore.kernel.org/r/1595408643-63011-3-git-send-email-luojiaxing@huawei.comReviewed-by:
John Garry <john.garry@huawei.com> Reviewed-by:
Jason Yan <yanaijie@huawei.com> Signed-off-by:
Luo Jiaxing <luojiaxing@huawei.com> Signed-off-by:
Martin K. Petersen <martin.petersen@oracle.com>
-