aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ata
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2017-09-14 19:54:18 +0100
committerTejun Heo <tj@kernel.org>2017-09-18 20:24:21 -0700
commit01bb12e49b85ee99fa8445cbbc450092cd34afc9 (patch)
tree54d504883d0b8f9522925539fc19f363eb0f3ef1 /drivers/ata
parentf4ac6476945ff62939420bcf8266e39f8d5d54bd (diff)
ata: pata_artop: remove redundant initialization of pio
pio is initialized and the data is never read, instead it is almost immediately being updated to a new value. Fix this by removing the initialization. Detected by scan-build: "warning: Value stored to 'pio' during its initialization is never read" Fixes: 669a5db411d8 ("[libata] Add a bunch of PATA drivers") Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'drivers/ata')
-rw-r--r--drivers/ata/pata_artop.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ata/pata_artop.c b/drivers/ata/pata_artop.c
index 96c05c9494fa..6b3355343542 100644
--- a/drivers/ata/pata_artop.c
+++ b/drivers/ata/pata_artop.c
@@ -242,7 +242,7 @@ static void artop6210_set_dmamode (struct ata_port *ap, struct ata_device *adev)
static void artop6260_set_dmamode (struct ata_port *ap, struct ata_device *adev)
{
- unsigned int pio = adev->pio_mode - XFER_PIO_0;
+ unsigned int pio;
struct pci_dev *pdev = to_pci_dev(ap->host->dev);
u8 ultra;

Privacy Policy