Unknown command 'nand' - try 'help'

2019-08-22 02:39发布

问题:

I'm trying build a linux system on beaglebone black and following to mastering embedded linux programming book, however when I boot my u-boot on beaglebone black, I have received a error: unknown command 'nand' - try 'help'.

Does anybody have any idea of what did I do wrong or did I miss something?

回答1:

If you are in Chapter 3: All About Bootloaders → U-Boot → Using U-Boot:

  • This is NOT an example meant to be executed on a BeagleBoneBlack.
  • It is a generic example of a U-Boot command that possibly could work on hardware that actually has NAND flash. The BBB does not have raw NAND flash, it has an eMMC and a micro-SD card slot.

If that's not where you are in the book, please provide chapter information and what you are trying to achieve.

BTW: please also note that there are errata for this book, especially around U-Boot and the NAND commands. You might want to verify if they apply to your reprint.



回答2:

The command nand is only available in U-Boot if CONFIG_CMD_NAND=y is configured.

Use make menuconfig for configuration.