]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
ata: libata-core: Make ata_dev_cleanup_cdl_resources() static
authorDamien Le Moal <dlemoal@kernel.org>
Thu, 3 Jul 2025 10:36:20 +0000 (19:36 +0900)
committerNiklas Cassel <cassel@kernel.org>
Fri, 4 Jul 2025 08:36:00 +0000 (10:36 +0200)
The function ata_dev_cleanup_cdl_resources() is called only from
ata_dev_init_cdl_resources() and ata_dev_free_resources() which are
both defined in drivers/ata/libata-core.c. So there is no need for
ata_dev_cleanup_cdl_resources() to be visible from outside of this
file. Change this function definition to be a static function.

No functional changes.

Signed-off-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Niklas Cassel <cassel@kernel.org>
Link: https://lore.kernel.org/r/20250703103622.291272-3-dlemoal@kernel.org
Signed-off-by: Niklas Cassel <cassel@kernel.org>
drivers/ata/libata-core.c
drivers/ata/libata.h

index 30913bc6fe2162ff39b190989994cbb4c564939b..72abd2996e9c89872abae9135b7e897cd04984dd 100644 (file)
@@ -2516,7 +2516,7 @@ static void ata_dev_config_trusted(struct ata_device *dev)
                dev->flags |= ATA_DFLAG_TRUSTED;
 }
 
-void ata_dev_cleanup_cdl_resources(struct ata_device *dev)
+static void ata_dev_cleanup_cdl_resources(struct ata_device *dev)
 {
        kfree(dev->cdl);
        dev->cdl = NULL;
index 8e68f4556962cf0da5675613e88e08190ceb67d4..767a61f8ff899db5170d5e461d40ca248f92ca0d 100644 (file)
@@ -97,7 +97,6 @@ extern int ata_cmd_ioctl(struct scsi_device *scsidev, void __user *arg);
 extern const char *sata_spd_string(unsigned int spd);
 extern unsigned int ata_read_log_page(struct ata_device *dev, u8 log,
                                      u8 page, void *buf, unsigned int sectors);
-void ata_dev_cleanup_cdl_resources(struct ata_device *dev);
 
 #define to_ata_port(d) container_of(d, struct ata_port, tdev)