ata: libata-scsi: fix timeout type in ata_scsi_park_store()
authorSergey Shtylyov <s.shtylyov@omp.ru>
Sat, 29 Jul 2023 20:17:50 +0000 (23:17 +0300)
committerDamien Le Moal <dlemoal@kernel.org>
Wed, 2 Aug 2023 08:37:06 +0000 (17:37 +0900)
ata_scsi_park_store() passes its 'long input' variable (if it's >= 0) to
ata_deadline() that now takes 'unsigned int' -- eliminate unneeded implicit
cast...

Signed-off-by: Sergey Shtylyov <s.shtylyov@omp.ru>
Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
drivers/ata/libata-scsi.c

index 370d18aca71e87653339e53002a7326812693665..f39d603f05bc32d0b55064786db93c6e2903b9ec 100644 (file)
@@ -135,11 +135,11 @@ static ssize_t ata_scsi_park_store(struct device *device,
        struct scsi_device *sdev = to_scsi_device(device);
        struct ata_port *ap;
        struct ata_device *dev;
-       long int input;
+       int input;
        unsigned long flags;
        int rc;
 
-       rc = kstrtol(buf, 10, &input);
+       rc = kstrtoint(buf, 10, &input);
        if (rc)
                return rc;
        if (input < -2)