summaryrefslogtreecommitdiff
path: root/include/linux/mtd/mtd.h
diff options
context:
space:
mode:
authorZhuohao Lee <zhuohao@chromium.org>2019-07-01 00:07:10 +0800
committerTudor Ambarus <tudor.ambarus@microchip.com>2019-08-29 10:36:47 +0300
commit1018c94be6ea073115f6bcf993d6492138d2b8e3 (patch)
tree95f2fc85c3b5bd0bdb8088d9be61edad62b68d0f /include/linux/mtd/mtd.h
parent7ae2227b1c1928cfc8220ca6383c757b185fcf32 (diff)
mtd: mtdcore: add debugfs nodes for querying the flash name and id
Currently, we don't have vfs nodes for querying the underlying flash name and flash id. This information is important especially when we want to know the flash detail of the defective system. In order to support the query, we add mtd_debugfs_populate() to create two debugfs nodes (ie. partname and partid). The upper driver can assign the pointer to partname and partid before calling mtd_device_register(). Signed-off-by: Zhuohao Lee <zhuohao@chromium.org> Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com> Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Diffstat (limited to 'include/linux/mtd/mtd.h')
-rw-r--r--include/linux/mtd/mtd.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
index 4ca8c1c845fb..249e8d9bfbcd 100644
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -189,6 +189,9 @@ struct module; /* only needed for owner field in mtd_info */
*/
struct mtd_debug_info {
struct dentry *dfs_dir;
+
+ const char *partname;
+ const char *partid;
};
struct mtd_info {