Received: by 2002:ab2:6857:0:b0:1ef:ffd0:ce49 with SMTP id l23csp719689lqp; Thu, 21 Mar 2024 13:26:45 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWqorNGlYoYC9iJXIlNEJjcqn6CBgvp2Ne6hMMe1KrEWCJRAkNsW+Z2xf56bXNKKF/YGCIctAJihlwmYw2YpptZ6EOm3/nbTb07aQzLDA== X-Google-Smtp-Source: AGHT+IErZK+s/uSpwPlKKFH5Y79qSUaZlIxsD/VpLmCRzeaL4m2qWtyH50FQr4LCanJw5qb/DaAG X-Received: by 2002:a05:6a20:12cf:b0:1a3:57f8:7aee with SMTP id v15-20020a056a2012cf00b001a357f87aeemr780003pzg.46.1711052805082; Thu, 21 Mar 2024 13:26:45 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711052805; cv=pass; d=google.com; s=arc-20160816; b=iYzuyo9if25yp6YZqkidaXQRq33ElD9eEUC7eCO58Kqg8C5UYRLYsUKb8Cqs4FRIUZ Qwo6ON1Gm+aHOCtu0515BQ4lhj7e7w3fRcuCGffKb9MooQnltrtcKAZElC/QNp1vOUKg L8m6hSywSeWOgCFiUSOT4gf6Hb/PGpb+5aUfam5f2jSsZGs2SWQ2p9d7g2Hq3KgNkzCl YnvZbCG0wjowSSlCyAUF1odBGSDwq14t4C8aYH0uvqyhtZ/59uO4ZIDdf4j2QV+ILryF BGMus3lnbDsho2KVo6ebj051/JJOeiLvIHQcIOog6UgNu55fnVYEJnN4+I7aa/So4cA1 vaLQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date; bh=xtr2wOMipl67dtQ9OBXFqmd2d5oHeD3oT8GlsubQMJk=; fh=4L2f+/6l+KWbqDOAQvrgBkPYw7HmnsyObzFPI1/hw9Y=; b=05HU0ZhcwlJIucND3ssVYm93q/mKaGCIDOjL/hAX+72rXjeAoTBRt01bTDwpk4YxXX 8afZH2so/b/EoRK838nzQLJw/EObUyDr7ZypReonkljNfChYi0BE8casN9dtG+F6jXFO cyaR9jqraf651fcHTwsaYEwXvZ3regOfjCVWxZXW7hrU5jClFHXvluNXnQFVqv9kz9o/ QFdfABbAhaTo54t1KNrCUZVVhrEnf/s9LeWknA3TcOnvsAeHDLcaB5tb9icd+Mbi0aSP tpE8hE+YkMR5s4RAmx6sM+/XJla90EGNm40DmNMa5Pnbj+tbP5JJQNaEHwbh04A25hit EbTQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=makrotopia.org); spf=pass (google.com: domain of linux-kernel+bounces-110639-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-110639-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id u35-20020a056a0009a300b006e5d8de0368si432059pfg.284.2024.03.21.13.26.44 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 Mar 2024 13:26:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-110639-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=makrotopia.org); spf=pass (google.com: domain of linux-kernel+bounces-110639-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-110639-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 893BA28457B for ; Thu, 21 Mar 2024 20:26:44 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B6723134CF2; Thu, 21 Mar 2024 20:26:35 +0000 (UTC) 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 8C96F134CC6; Thu, 21 Mar 2024 20:26:33 +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=1711052795; cv=none; b=imXAEXKiuIKwXFPPpttxVBdHH1VTez4vu1wRkN87xs0UlETV8ggI99u1osOHOWe6SvyfQ2wPyxUHYZfgaLtd8p7HIp2rTDsEHgryW5hiN+A04dWJ3rIQPeSegigQeMh67iBhzhusRnocGmqJUIiyCBJ9nf6Nag36rmsf8nIKEBg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711052795; c=relaxed/simple; bh=N64rGhvs2KBoM27OkS7eZxDXNsg40ICyXB3VDM12Icc=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=loM5sa3WVA4pZLdqePuXSP2AiYTQ5seG+NHB0hrmneq/4cCzZxjR/J/LULYKHs7PcdYyUwLgGDXghQ1Cp3Df+KsOJ7Udgb97I18vmLrisa3ouzwACDfjx275gMNZhFQSv/a0AVbREa+jasUw3AYfQZgjPWMMfE0CUc62Zk1fGcs= 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 1rnOzL-0000Zb-2X; Thu, 21 Mar 2024 20:26:11 +0000 Date: Thu, 21 Mar 2024 20:26:07 +0000 From: Daniel Golle To: Bart Van Assche Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Ulf Hansson , Jens Axboe , Dave Chinner , Jan Kara , Thomas =?iso-8859-1?Q?Wei=DFschuh?= , Damien Le Moal , Li Lingfeng , Christian Brauner , Christian Heusel , Min Li , Adrian Hunter , Avri Altman , Hannes Reinecke , Christian Loehle , Bean Huo , Yeqi Fu , Victor Shih , Christophe JAILLET , Dominique Martinet , "Ricardo B. Marliere" , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org, linux-block@vger.kernel.org Subject: Re: [PATCH 1/8] dt-bindings: block: add basic bindings for block devices Message-ID: References: <28dcc69ecf9d55e95991d8f2a8e19f71bbd32af0.1711048433.git.daniel@makrotopia.org> <38efd4e4-0421-4318-8b2d-ca2603d482f5@acm.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <38efd4e4-0421-4318-8b2d-ca2603d482f5@acm.org> On Thu, Mar 21, 2024 at 12:39:33PM -0700, Bart Van Assche wrote: > On 3/21/24 12:32, Daniel Golle wrote: > > +$id: http://devicetree.org/schemas/block/partition.yaml# > > +$schema: http://devicetree.org/meta-schemas/core.yaml# > > + > > +title: Partition on a block device > > + > > +description: | > > + This binding describes a partition on a block device. > > + Partitions may be matched by a combination of partition number, name, > > + and UUID. > > + > > +maintainers: > > + - Daniel Golle > > + > > +properties: > > + $nodename: > > + pattern: '^block-partition-.+$' > > + > > + partnum: > > + $ref: /schemas/types.yaml#/definitions/uint32 > > + description: > > + Matches partition by number if present. > > + > > + partname: > > + $ref: /schemas/types.yaml#/definitions/string > > + description: > > + Matches partition by PARTNAME if present. > > + > > + partuuid: > > + $ref: /schemas/types.yaml#/definitions/string > > + description: > > + Matches partition by PARTUUID if present. > > + > > + nvmem-layout: > > + $ref: /schemas/nvmem/layouts/nvmem-layout.yaml# > > + description: > > + This container may reference an NVMEM layout parser. > > Does the above imply that only systems with a single block device are > supported? Absolutely not. Of course also such devices often have multiple block devices, typically eMMC, NVMe and SD card are supported, some also come with SATA ports. The block device(s) relevant as NVMEM providers has/have to be referenced and the 'partitions' node is a child node of a specific block device, of course. > > Supporting partition numbers seems unfortunate to me. Partition numbers > will change if the partition scheme changes. I fully argee with that, and using partnum as an identifier is not very smart. However, this is what some vendors are doing (in custom downstream drivers or scripts running in early userland) and hence the kernel implementation should allow to identify the relevant location in exactly the same way to be sure we are always compatible.