diff options
author | Scott Wood <oss@buserror.net> | 2016-09-01 17:31:31 -0500 |
---|---|---|
committer | Scott Wood <oss@buserror.net> | 2016-09-01 20:08:48 -0500 |
commit | 8b7d51249eca113c4965a7c417f33d7eb569434b (patch) | |
tree | 749d7b0e00f101c2873ef1c0ba00a2384537c59a /drivers/mtd | |
parent | 4004a81828c72311f9c310c38d903b3f6638465d (diff) | |
download | u-boot-imx-8b7d51249eca113c4965a7c417f33d7eb569434b.zip u-boot-imx-8b7d51249eca113c4965a7c417f33d7eb569434b.tar.gz u-boot-imx-8b7d51249eca113c4965a7c417f33d7eb569434b.tar.bz2 |
nand: Fix some more NULL name tests
Now that nand_info[] is an array of pointers we need to test the
pointer itself rather than using name as a proxy for NULLness.
Fixes: b616d9b0a708eb9 ("nand: Embed mtd_info in struct nand_chip")
Signed-off-by: Scott Wood <oss@buserror.net>
Cc: Lukasz Majewski <l.majewski@samsung.com>
Cc: Tony Lindgren <tony@atomide.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/nand/omap_gpmc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/nand/omap_gpmc.c b/drivers/mtd/nand/omap_gpmc.c index 6e201d6..af618fc 100644 --- a/drivers/mtd/nand/omap_gpmc.c +++ b/drivers/mtd/nand/omap_gpmc.c @@ -899,7 +899,7 @@ int __maybe_unused omap_nand_switch_ecc(uint32_t hardware, uint32_t eccstrength) if (nand_curr_device < 0 || nand_curr_device >= CONFIG_SYS_MAX_NAND_DEVICE || - !nand_info[nand_curr_device]->name) { + !nand_info[nand_curr_device]) { printf("nand: error: no NAND devices found\n"); return -ENODEV; } |