From patchwork Tue Mar 5 20:23:44 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Golle X-Patchwork-Id: 778186 Received: from pidgin.makrotopia.org (pidgin.makrotopia.org [185.142.180.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4665112BE8C; Tue, 5 Mar 2024 20:24:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.142.180.65 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709670248; cv=none; b=LD/qTgf/E8iwv+E+ZLHFRD4ZxL7lQjYL93JkdqcyJ2o31s3yKOEiw044S+QSHNaEhpBHOSnNUGBghCpyeL6qFbTtzahn5KB6NMCNwze4tBNKos21eXnyh6ZURijPKBuv4HD8zySAiz1OF8gDtljX7hxjzZl4I/I6j/X6y4nsXAY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709670248; c=relaxed/simple; bh=2Quus8bwOAvZ26pD2KZKwCchqWnTAr6TMdGV+yLI5KI=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=kz7IKQ1C/5iRjfqkaFF9CZhF1Ha+kvySQ+qha55NDIMVxvMBSwr4/VaEMxchLhX6x+nqgze/kL6fDjqYF/Kkr2nQWZxKM8+y1uSRXK4SH1KSWvv/OgxSxHwYBCV7S82ZD2slVP/qFbXjNVhGrpozMLHrKHD3N+vOrsEf4jM2x5Q= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=makrotopia.org; spf=pass smtp.mailfrom=makrotopia.org; arc=none smtp.client-ip=185.142.180.65 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=makrotopia.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=makrotopia.org Received: from local by pidgin.makrotopia.org with esmtpsa (TLS1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.96.2) (envelope-from ) id 1rhbKG-0001ND-2V; Tue, 05 Mar 2024 20:23:48 +0000 Date: Tue, 5 Mar 2024 20:23:44 +0000 From: Daniel Golle To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Ulf Hansson , Jens Axboe , Daniel Golle , Dave Chinner , Jan Kara , Thomas =?iso-8859-1?q?Wei=DFschuh?= , Christian Brauner , Li Lingfeng , Damien Le Moal , Min Li , Adrian Hunter , Hannes Reinecke , Christian Loehle , Avri Altman , Bean Huo , Yeqi Fu , Victor Shih , Christophe JAILLET , "Ricardo B. Marliere" , Greg Kroah-Hartman , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org, linux-block@vger.kernel.org Cc: Diping Zhang , Jianhui Zhao , Jieying Zeng , Chad Monroe , Adam Fox , John Crispin Subject: [RFC PATCH v2 3/8] block: add new genhd flag GENHD_FL_NVMEM Message-ID: References: Precedence: bulk X-Mailing-List: linux-mmc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: 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(+) diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index 715c9201008a6..03e4b1fd5060d 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -81,11 +81,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 {