mtd: spi-nor: Rename method, s/spi_nor_match_id/spi_nor_match_name
authorTudor Ambarus <tudor.ambarus@microchip.com>
Wed, 20 Apr 2022 10:34:17 +0000 (13:34 +0300)
committerPratyush Yadav <p.yadav@ti.com>
Wed, 27 Apr 2022 09:27:35 +0000 (14:57 +0530)
The method is matching a flash_info entry by searching by name. Rename
the method for better clarity.

Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: Pratyush Yadav <p.yadav@ti.com>
Reviewed-by: Pratyush Yadav <p.yadav@ti.com>
Reviewed-by: Michael Walle <michael@walle.cc>
Link: https://lore.kernel.org/r/20220420103427.47867-2-tudor.ambarus@microchip.com
drivers/mtd/spi-nor/core.c

index c1630131c73424dbb95c32d435c6aad19243c948..8e293fcd1ecd6f4d14abb65ef50f7cb93c15c69a 100644 (file)
@@ -2885,8 +2885,8 @@ void spi_nor_restore(struct spi_nor *nor)
 }
 EXPORT_SYMBOL_GPL(spi_nor_restore);
 
-static const struct flash_info *spi_nor_match_id(struct spi_nor *nor,
-                                                const char *name)
+static const struct flash_info *spi_nor_match_name(struct spi_nor *nor,
+                                                  const char *name)
 {
        unsigned int i, j;
 
@@ -2908,7 +2908,7 @@ static const struct flash_info *spi_nor_get_flash_info(struct spi_nor *nor,
        const struct flash_info *info = NULL;
 
        if (name)
-               info = spi_nor_match_id(nor, name);
+               info = spi_nor_match_name(nor, name);
        /* Try to auto-detect if chip name wasn't specified or not found */
        if (!info)
                info = spi_nor_read_id(nor);