From patchwork Fri Oct 23 09:17:54 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 55467 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lf0-f71.google.com (mail-lf0-f71.google.com [209.85.215.71]) by patches.linaro.org (Postfix) with ESMTPS id 8871420581 for ; Fri, 23 Oct 2015 09:18:05 +0000 (UTC) Received: by lfu67 with SMTP id 67sf19543306lfu.2 for ; Fri, 23 Oct 2015 02:18:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:mime-version:in-reply-to:references :date:message-id:subject:from:to:cc:content-type:sender:precedence :list-id:x-original-sender:x-original-authentication-results :mailing-list:list-post:list-help:list-archive:list-unsubscribe; bh=n9U9CPnKHnVmFPrXPik+IueTgsuUsdAmj4+Kb1j5kSo=; b=F/nhvE8l2ANCBnUyQ2DRDjageF/B+ILGUO9TzqTkpzbNrtDD9Up393h511wN/+069n 1xJmI4QByxCBjMeLXGF0eGW8jyI9pV1mNpQAJu4RznYdBV9U6Lgn6g913RfazHKZIPLh Z+cpsHriBijlGcUw6IWBDenC+GYdWZUaiVdg5zRt81IpVUJDvP38OjJFgHwPGKAM4NHD W2Z8d8QnQl0nidNoWN1FevkPUOObtKKBqW1VgaytPma2pgGfWv+YF23/Nuw9/x36P11x nqkAThFNfmmdBmB9YijqLVVopO4edR9OggGYEqcRV5wV3ELNeNCK5ft8RzzDfK3MBzbH 3EBg== X-Gm-Message-State: ALoCoQkX3MM2oS6JYYuGbnlPCdFA6/z31l1Phy6cu7Pwc0lJfUiZU6RyO3eeWoc1gOQ+dg5AJJbP X-Received: by 10.180.216.105 with SMTP id op9mr637493wic.0.1445591884462; Fri, 23 Oct 2015 02:18:04 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.25.79.6 with SMTP id d6ls373939lfb.47.gmail; Fri, 23 Oct 2015 02:18:04 -0700 (PDT) X-Received: by 10.25.78.80 with SMTP id c77mr7063715lfb.18.1445591884313; Fri, 23 Oct 2015 02:18:04 -0700 (PDT) Received: from mail-lf0-f49.google.com (mail-lf0-f49.google.com. [209.85.215.49]) by mx.google.com with ESMTPS id h139si12127982lfb.126.2015.10.23.02.18.04 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 23 Oct 2015 02:18:04 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.49 as permitted sender) client-ip=209.85.215.49; Received: by lfaz124 with SMTP id z124so76632402lfa.1 for ; Fri, 23 Oct 2015 02:18:04 -0700 (PDT) X-Received: by 10.112.168.228 with SMTP id zz4mr10807751lbb.73.1445591884176; Fri, 23 Oct 2015 02:18:04 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.59.35 with SMTP id w3csp1092763lbq; Fri, 23 Oct 2015 02:18:02 -0700 (PDT) X-Received: by 10.66.90.198 with SMTP id by6mr3727854pab.78.1445591882613; Fri, 23 Oct 2015 02:18:02 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id it8si28150387pbc.103.2015.10.23.02.18.02; Fri, 23 Oct 2015 02:18:02 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752780AbbJWJR7 (ORCPT + 6 others); Fri, 23 Oct 2015 05:17:59 -0400 Received: from mail-ob0-f169.google.com ([209.85.214.169]:34381 "EHLO mail-ob0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751113AbbJWJRz (ORCPT ); Fri, 23 Oct 2015 05:17:55 -0400 Received: by obbda8 with SMTP id da8so88162173obb.1 for ; Fri, 23 Oct 2015 02:17:54 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.60.123.2 with SMTP id lw2mr14957115oeb.2.1445591874558; Fri, 23 Oct 2015 02:17:54 -0700 (PDT) Received: by 10.182.214.104 with HTTP; Fri, 23 Oct 2015 02:17:54 -0700 (PDT) In-Reply-To: <20151015162210.GA4545@localhost> References: <1444915191-28350-1-git-send-email-linus.walleij@linaro.org> <20151015162210.GA4545@localhost> Date: Fri, 23 Oct 2015 11:17:54 +0200 Message-ID: Subject: Re: [PATCH] mtd: document linux-specific partition parser DT binding From: Linus Walleij To: Brian Norris Cc: David Woodhouse , "linux-mtd@lists.infradead.org" , "linux-arm-kernel@lists.infradead.org" , "devicetree@vger.kernel.org" , Jason Gunthorpe , Liviu Dudau , "Rafa?? Mi??ecki" , Hauke Mehrtens , Jonas Gorski Sender: devicetree-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: devicetree@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: linus.walleij@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.49 as permitted sender) smtp.mailfrom=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , On Thu, Oct 15, 2015 at 6:22 PM, Brian Norris wrote: > Are you trying to use this binding, or is this just purely a mechanical > documentation issue? I ask, because it seems that binding never really > got reviewed at all, and others have recently tried to extend support > for it generically [1], but a few objections came up [2][3]. I am using it in this devicetree patch: http://marc.info/?l=linux-arm-kernel&m=144492610417605&w=2 And this devicetree patch: http://marc.info/?l=linux-arm-kernel&m=144490455308758&w=2 Otherwise the AFS partition type will not be scanned. The other option is to add "afs" to this list in drivers/mtd/maps/physmap_of.c: > Unfortunately I/we dropped the ball a bit on that thread, but we'd > ideally like to address those concerns in a new binding that is > supported for all MTDs, and deprecate the old one. The new one would > probably not directly use the parser name as used by Linux, but define > some list of compatible strings that fit DT conventions better. Also, I > don't want people including things like "cmdlinepart" in DT, but it > should be available as an override if necessary. IOW, DT shouldn't > supersede the kernel command line. This is not for cmdlinepart, as AFS is an actual on-flash format. > That's not to say we can't document the old one, but I'm curious if > there are real users. I'd also like to encourage new users to avoid the > old one if we can make that feasible. I'm happy to do either patch, or define a new binding if you prefer, like simply: partition-type = ; and then we define this as "arm,arm-flash-structure" or something, and parse that to "afs" internally in physmap_of.c. >> + - linux,part-probe: a flash partition type to look for, using the >> + Linux-internal partition naming scheme, e.g. "afs" for the ARM >> + Flash footers. > > IIUC, this property actually supports a list of parsers, not just a > single partition type. Ah it does. If we wanna go with this patch I'll fix it. > Also, if we're really going to support this, we should list exactly what > strings we support. And that's one of the problems with the existing > binding; it supports any old string Linux supports, which doesn't match > how we typically want to add bindings (i.e., via proposal + review). OK that sounds like a case for "arm,arm-flash-structure" for this specific binding. Yours, Linus Walleij --- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/mtd/maps/physmap_of.c b/drivers/mtd/maps/physmap_of.c index 3e614e9119d5..6233473a55d6 100644 --- a/drivers/mtd/maps/physmap_of.c +++ b/drivers/mtd/maps/physmap_of.c @@ -110,7 +110,7 @@ static struct mtd_info *obsolete_probe(struct platform_device *dev, default is use. These take precedence over other device tree information. */ static const char * const part_probe_types_def[] = { - "cmdlinepart", "RedBoot", "ofpart", "ofoldpart", NULL }; + "cmdlinepart", "RedBoot", "ofpart", "ofoldpart", "afs", NULL }; I can send a patch like this if you prefer?