Skip to content
Commit 93af53b8 authored by Ezequiel García's avatar Ezequiel García Committed by Brian Norris
Browse files

nand: omap2: Remove horrible ifdefs to fix module probe



The current code abuses ifdefs to determine if the selected ECC scheme
is supported by the running kernel. As a result the code is hard to read,
and it also fails to load as a module.

This commit removes all the ifdefs and instead introduces a function
omap2_nand_ecc_check() to check if the ECC is supported by using
IS_ENABLED(CONFIG_xxx).

Since IS_ENABLED() is true when a config is =y or =m, this change fixes the
module so it can be loaded with no issues.

Acked-by: default avatarRoger Quadros <rogerq@ti.com>
Signed-off-by: default avatarEzequiel Garcia <ezequiel@vanguardiasur.com.ar>
Signed-off-by: default avatarBrian Norris <computersforpeace@gmail.com>
parent 2a960cce
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment