aboutsummaryrefslogtreecommitdiff
path: root/include/nand.h
diff options
context:
space:
mode:
authorSean Anderson2023-11-04 16:37:49 -0400
committerTom Rini2023-11-16 12:43:49 -0500
commitc2034821772898b54d745e79fc96586cebaae12c (patch)
treebcb42b5b9843a8ba00437d55d2c0e4836626cc26 /include/nand.h
parentb37a9208a2ed36b67303e8169539c1a0c42ea0e1 (diff)
nand: Add function to unregister NAND devices
This performs the opposite of nand_register, allowing drivers to unregister nand devices. This is probably unnecessary for most regular drivers, but we expect sandbox drivers to get repeatedly bound/unbound, so this will help avoid dangling pointers. Signed-off-by: Sean Anderson <seanga2@gmail.com> Reviewed-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Diffstat (limited to 'include/nand.h')
-rw-r--r--include/nand.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/nand.h b/include/nand.h
index c1d7533aaac..fc584f5ef7a 100644
--- a/include/nand.h
+++ b/include/nand.h
@@ -22,6 +22,7 @@ int nand_mtd_to_devnum(struct mtd_info *mtd);
#if CONFIG_IS_ENABLED(SYS_NAND_SELF_INIT)
void board_nand_init(void);
int nand_register(int devnum, struct mtd_info *mtd);
+void nand_unregister(struct mtd_info *mtd);
#else
struct nand_chip;