mtd: mtd-abi: add a helper to detect the nand type
The helper is for user applications, and it is just a copy of the kernel helper: mtd_type_is_nand(); Signed-off-by: Huang Shijie <b32955@freescale.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
This commit is contained in:
Родитель
818b973929
Коммит
4f8a3ba700
|
@ -275,4 +275,9 @@ enum mtd_file_modes {
|
|||
MTD_FILE_MODE_RAW,
|
||||
};
|
||||
|
||||
static inline int mtd_type_is_nand_user(const struct mtd_info_user *mtd)
|
||||
{
|
||||
return mtd->type == MTD_NANDFLASH || mtd->type == MTD_MLCNANDFLASH;
|
||||
}
|
||||
|
||||
#endif /* __MTD_ABI_H__ */
|
||||
|
|
Загрузка…
Ссылка в новой задаче