diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/mtd/nand.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/mtd/nand.h b/include/linux/mtd/nand.h index 7f17767c69..762f9c4f2a 100644 --- a/include/linux/mtd/nand.h +++ b/include/linux/mtd/nand.h @@ -543,6 +543,8 @@ struct nand_chip { void *priv; unsigned int bbt_type; + + struct mtd_info mtd; }; /* @@ -799,4 +801,9 @@ struct nand_sdr_timings { /* get timing characteristics from ONFI timing mode. */ const struct nand_sdr_timings *onfi_async_timing_mode_to_sdr_timings(int mode); +static inline struct nand_chip *mtd_to_nand(struct mtd_info *mtd) +{ + return mtd->priv; +} + #endif /* __LINUX_MTD_NAND_H */ |