diff options
author | Ezequiel Garcia <elezegarcia@gmail.com> | 2012-11-28 13:18:29 +0100 |
---|---|---|
committer | Artem Bityutskiy <artem.bityutskiy@linux.intel.com> | 2012-12-10 12:38:59 +0100 |
commit | 64575574f26d7969713ede9bde750c979da4037e (patch) | |
tree | 37877fedba9902b5717f030682f76b9367ba92c6 /drivers/mtd/ubi/debug.h | |
parent | UBI: replace memcpy with struct assignment (diff) | |
download | linux-64575574f26d7969713ede9bde750c979da4037e.tar.xz linux-64575574f26d7969713ede9bde750c979da4037e.zip |
UBI: introduce helpers dbg_chk_{io, gen}
With this patch code is a bit more readable and there's no
generated code or functionality impact.
Furthermore, this abstracts implementation details and
will allow to change ubi_debug_info in a less invasive way.
Signed-off-by: Ezequiel Garcia <elezegarcia@gmail.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Diffstat (limited to 'drivers/mtd/ubi/debug.h')
-rw-r--r-- | drivers/mtd/ubi/debug.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/mtd/ubi/debug.h b/drivers/mtd/ubi/debug.h index 3dbc877d9663..0add8d8a1672 100644 --- a/drivers/mtd/ubi/debug.h +++ b/drivers/mtd/ubi/debug.h @@ -158,4 +158,13 @@ static inline int ubi_dbg_is_erase_failure(const struct ubi_device *ubi) return 0; } +static inline int ubi_dbg_chk_io(const struct ubi_device *ubi) +{ + return ubi->dbg->chk_io; +} + +static inline int ubi_dbg_chk_gen(const struct ubi_device *ubi) +{ + return ubi->dbg->chk_gen; +} #endif /* !__UBI_DEBUG_H__ */ |