Commit d1cfeee916fe86eddd944f7363f9d2884bdd9814

Authored by Andrew Ruder
Committed by Heiko Schocher
1 parent 65e5cb54d0

ubi: enable error reporting in initialization

The UBI layer will disable much of its error reporting when it is
compiled into the linux kernel to avoid stopping boot.  We want this
error reporting in U-Boot since we don't initialize the UBI layer until
it is used and want the error reporting.

We force this by telling the UBI layer we are building as a module.

Signed-off-by: Andrew Ruder <andrew.ruder@elecsyscorp.com>
Cc: Wolfgang Denk <wd@denx.de>
Cc: Heiko Schocher <hs@denx.de>
Cc: Kyungmin Park <kmpark@infradead.org>

Showing 1 changed file with 8 additions and 0 deletions Side-by-side Diff

... ... @@ -51,6 +51,14 @@
51 51  
52 52 #undef CONFIG_MTD_UBI_BLOCK
53 53  
  54 +/* ubi_init() disables returning error codes when built into the Linux
  55 + * kernel so that it doesn't hang the Linux kernel boot process. Since
  56 + * the U-Boot driver code depends on getting valid error codes from this
  57 + * function we just tell the UBI layer that we are building as a module
  58 + * (which only enables the additional error reporting).
  59 + */
  60 +#define CONFIG_MTD_UBI_MODULE
  61 +
54 62 #if !defined(CONFIG_MTD_UBI_BEB_LIMIT)
55 63 #define CONFIG_MTD_UBI_BEB_LIMIT 20
56 64 #endif