From 2b28bf485b283991eea9f00c5831c1c39c73991f Mon Sep 17 00:00:00 2001 From: Daniel Golle Date: Thu, 21 Mar 2024 19:33:49 +0000 Subject: [PATCH 6/8] block: add new genhd flag GENHD_FL_NVMEM Add new flag to destinguish block devices which may act as an NVMEM provider. Signed-off-by: Daniel Golle --- include/linux/blkdev.h | 2 ++ 1 file changed, 2 insertions(+) --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -82,11 +82,13 @@ struct partition_meta_info { * ``GENHD_FL_NO_PART``: partition support is disabled. The kernel will not * scan for partitions from add_disk, and users can't add partitions manually. * + * ``GENHD_FL_NVMEM``: the block device should be considered as NVMEM provider. */ enum { GENHD_FL_REMOVABLE = 1 << 0, GENHD_FL_HIDDEN = 1 << 1, GENHD_FL_NO_PART = 1 << 2, + GENHD_FL_NVMEM = 1 << 3, }; enum {