mtd: nand: rockchip: avoid initializing nand driver twice
Change-Id: Id643cbdaf3df1b57ef16a52004c2192944d1f289 Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
This commit is contained in:
parent
24c72b14cb
commit
6c65ad505d
|
|
@ -254,9 +254,15 @@ static void read_flash_id(struct rk_nand *rknand, uint8_t *id)
|
|||
void board_nand_init(void)
|
||||
{
|
||||
const void *blob = gd->fdt_blob;
|
||||
static int initialized;
|
||||
fdt_addr_t regs;
|
||||
int node;
|
||||
|
||||
if (initialized)
|
||||
return;
|
||||
|
||||
initialized = 1;
|
||||
|
||||
if (g_rk_nand)
|
||||
return;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue