]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
cmd: nand: remove direct access to struct mtd_info->priv
authorGrygorii Strashko <grygorii.strashko@ti.com>
Tue, 27 Jun 2017 00:12:58 +0000 (19:12 -0500)
committerTom Rini <trini@konsulko.com>
Wed, 12 Jul 2017 02:41:47 +0000 (22:41 -0400)
Replace direct access to struct mtd_info->priv with proper
accessor mtd_to_nand().

Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
cmd/nand.c

index d6542e50f2e916c95cdfa41702d568f07b6fe9c9..a2152ec8260e0546a5a19dbfd9bec8d0201ac7a3 100644 (file)
@@ -128,7 +128,7 @@ static int set_dev(int dev)
        nand_curr_device = dev;
 
 #ifdef CONFIG_SYS_NAND_SELECT_DEVICE
-       board_nand_select_device(mtd->priv, dev);
+       board_nand_select_device(mtd_to_nand(mtd), dev);
 #endif
 
        return 0;