]> git.ipfire.org Git - people/ms/u-boot.git/commitdiff
sf: Remove spi_flash_remove
authorJagan Teki <jteki@openedev.com>
Mon, 14 Dec 2015 03:32:06 +0000 (09:02 +0530)
committerJagan Teki <jteki@openedev.com>
Wed, 13 Jan 2016 13:17:26 +0000 (18:47 +0530)
Use direct call to device_remove instead of exctra
spi_flash_remove defination.

Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Jagan Teki <jteki@openedev.com>
drivers/mtd/spi/sf-uclass.c
include/spi_flash.h

index 72e0f6b3fb1e591124ae2bfc879ac3685d6405b5..95ffad476d76c1bf0127802da1d7b7490b094f3e 100644 (file)
@@ -46,7 +46,7 @@ struct spi_flash *spi_flash_probe(unsigned int bus, unsigned int cs,
 
 void spi_flash_free(struct spi_flash *flash)
 {
-       spi_flash_remove(flash->spi->dev);
+       device_remove(flash->spi->dev);
 }
 
 int spi_flash_probe_bus_cs(unsigned int busnum, unsigned int cs,
@@ -69,11 +69,6 @@ int spi_flash_probe_bus_cs(unsigned int busnum, unsigned int cs,
        return 0;
 }
 
-int spi_flash_remove(struct udevice *dev)
-{
-       return device_remove(dev);
-}
-
 static int spi_flash_post_bind(struct udevice *dev)
 {
 #if defined(CONFIG_NEEDS_MANUAL_RELOC)
index f25b3e7819c641b6a7f1f6231d01b1fea95e35c8..0d26b8a5aa0f5c8b5846afc650fe9dc89ff1bcc2 100644 (file)
@@ -170,8 +170,6 @@ struct spi_flash *spi_flash_probe(unsigned int bus, unsigned int cs,
 /* Compatibility function - this is the old U-Boot API */
 void spi_flash_free(struct spi_flash *flash);
 
-int spi_flash_remove(struct udevice *flash);
-
 static inline int spi_flash_read(struct spi_flash *flash, u32 offset,
                                 size_t len, void *buf)
 {