ata: libata-core: fix parameter types of ata_wait_register()
authorSergey Shtylyov <s.shtylyov@omp.ru>
Sat, 29 Jul 2023 20:17:47 +0000 (23:17 +0300)
committerDamien Le Moal <dlemoal@kernel.org>
Wed, 2 Aug 2023 08:37:06 +0000 (17:37 +0900)
ata_wait_register() passes its 'unsigned long {interval|timeout}' params
verbatim to ata_{msleep|deadline}() that just take 'unsigned int' param
for the time intervals in ms -- eliminate unneeded implicit casts...

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

index 04db0f2c683a72d6779aafa8ced3dea777917fd5..54cc342c0b4f4f5b6022e3c45fd36b359269da71 100644 (file)
@@ -6684,7 +6684,7 @@ EXPORT_SYMBOL_GPL(ata_msleep);
  *     The final register value.
  */
 u32 ata_wait_register(struct ata_port *ap, void __iomem *reg, u32 mask, u32 val,
-                     unsigned long interval, unsigned long timeout)
+                     unsigned int interval, unsigned int timeout)
 {
        unsigned long deadline;
        u32 tmp;
index d9edb3d62a423dc0837f365f50f971518f1c89d4..4772f64af734bded27b5f98535adcbd33b7d88f3 100644 (file)
@@ -1116,7 +1116,7 @@ static inline void ata_sas_port_resume(struct ata_port *ap)
 extern int ata_ratelimit(void);
 extern void ata_msleep(struct ata_port *ap, unsigned int msecs);
 extern u32 ata_wait_register(struct ata_port *ap, void __iomem *reg, u32 mask,
-                       u32 val, unsigned long interval, unsigned long timeout);
+                            u32 val, unsigned int interval, unsigned int timeout);
 extern int atapi_cmd_type(u8 opcode);
 extern unsigned int ata_pack_xfermask(unsigned int pio_mask,
                                      unsigned int mwdma_mask,