diff options
author | Colin Ian King <colin.king@canonical.com> | 2018-07-02 03:30:22 -0400 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2018-07-02 10:47:06 -0400 |
commit | 8740fa6f5c834a881b9b0d560e62c6fe3c1e60ef (patch) | |
tree | 25a922a64d7f903d0fbedfddcf7eb3404dc12d5d | |
parent | eb36333de4bfba57fa6f8f88052e53180d54708e (diff) |
sata_nv: remove redundant pointers sdev0 and sdev1
Pointers sdev0 and sdev1 are being assigned but are never used hence they
are redundant and can be removed.
Cleans up clang warnings:
warning: variable 'sdev0' set but not used [-Wunused-but-set-variable]
warning: variable 'sdev1' set but not used [-Wunused-but-set-variable]
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
-rw-r--r-- | drivers/ata/sata_nv.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/ata/sata_nv.c b/drivers/ata/sata_nv.c index 10ae11aa1926..72c9b922a77b 100644 --- a/drivers/ata/sata_nv.c +++ b/drivers/ata/sata_nv.c | |||
@@ -675,7 +675,6 @@ static int nv_adma_slave_config(struct scsi_device *sdev) | |||
675 | struct ata_port *ap = ata_shost_to_port(sdev->host); | 675 | struct ata_port *ap = ata_shost_to_port(sdev->host); |
676 | struct nv_adma_port_priv *pp = ap->private_data; | 676 | struct nv_adma_port_priv *pp = ap->private_data; |
677 | struct nv_adma_port_priv *port0, *port1; | 677 | struct nv_adma_port_priv *port0, *port1; |
678 | struct scsi_device *sdev0, *sdev1; | ||
679 | struct pci_dev *pdev = to_pci_dev(ap->host->dev); | 678 | struct pci_dev *pdev = to_pci_dev(ap->host->dev); |
680 | unsigned long segment_boundary, flags; | 679 | unsigned long segment_boundary, flags; |
681 | unsigned short sg_tablesize; | 680 | unsigned short sg_tablesize; |
@@ -736,8 +735,6 @@ static int nv_adma_slave_config(struct scsi_device *sdev) | |||
736 | 735 | ||
737 | port0 = ap->host->ports[0]->private_data; | 736 | port0 = ap->host->ports[0]->private_data; |
738 | port1 = ap->host->ports[1]->private_data; | 737 | port1 = ap->host->ports[1]->private_data; |
739 | sdev0 = ap->host->ports[0]->link.device[0].sdev; | ||
740 | sdev1 = ap->host->ports[1]->link.device[0].sdev; | ||
741 | if ((port0->flags & NV_ADMA_ATAPI_SETUP_COMPLETE) || | 738 | if ((port0->flags & NV_ADMA_ATAPI_SETUP_COMPLETE) || |
742 | (port1->flags & NV_ADMA_ATAPI_SETUP_COMPLETE)) { | 739 | (port1->flags & NV_ADMA_ATAPI_SETUP_COMPLETE)) { |
743 | /* | 740 | /* |