Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp2610839img; Sun, 24 Mar 2019 13:41:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqxcTdap35sAuNADZgn6UuWLktCCoEdutNf4swbLHrngDOmQzqS88xIpj9JedFRF+RvsRpdD X-Received: by 2002:a63:5321:: with SMTP id h33mr19911185pgb.168.1553460105252; Sun, 24 Mar 2019 13:41:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553460105; cv=none; d=google.com; s=arc-20160816; b=o5YpjzZnQJfXjPNWpnisyIMQE5FEv8yrs3QaP5sp4fO+TZ+Ino+4IGhL9b5c43xXOA UbfKDwe/uWFKkXVdoQNnRuMcj/CWfrCsbkCf9q/EHqN9UGDymX5Cbfkv5wY6AJFqeSlE +pX8l9j0vlLb4HVxHQUbnbfLohq91GK9RG1PXBC98O7BRCNzy6iUSGq9XxFn9g3JcHWh WbqQUMbKJbyA2zfUh0VqKE6o0gUDV7PATJEmT4Or6b5yBxaNu5HeEgJdP07VaRGhFSlF tgmxS6mG0BrA665BKARId6wRvwIY2AOlAA8aiN5lwTmqyaK8hex4xydNoFttKWhfIBYX wDCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=Zag3mS16/ocWpIVeVVV7YLnfoYtX1qKbn1MjQNJ0iGE=; b=yPKxKc3wo0/WreztHR4ja87v39Z9XTSTazq1bvkRiISjI3zoh9IDVa7qJBrZ0Byh/U f8Dg4vNWdtRu+KNxOp5Li/5hAUFunYh+U6HF6q37KzCS6GRYWrGqPhgTiGrCoNgX0iAr uLRNf2bHr7a7h0h1vq9qtipk5+rEyOMZJnI2Tx8VKqHqsOg0yQh88h2s+q1XSXb/q9EW hWjlRPDfn7L/znqQ12uSV+9CeoPFhzoj37OrvQ+PUN9YH283A9T0zQUKl1GR7dVYNRvM ydlanJIJlPa/WlLV5uNZpSi0hfoHkW7P63ZrZCRAQSlinmzn/Y7u9JwAtboA7Pz6DFwm KuPg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="gPT/L0tz"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h127si11672309pgc.407.2019.03.24.13.41.30; Sun, 24 Mar 2019 13:41:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="gPT/L0tz"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728949AbfCXUkj (ORCPT + 99 others); Sun, 24 Mar 2019 16:40:39 -0400 Received: from mail-lf1-f68.google.com ([209.85.167.68]:40998 "EHLO mail-lf1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726317AbfCXUkj (ORCPT ); Sun, 24 Mar 2019 16:40:39 -0400 Received: by mail-lf1-f68.google.com with SMTP id 10so4573743lfr.8; Sun, 24 Mar 2019 13:40:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Zag3mS16/ocWpIVeVVV7YLnfoYtX1qKbn1MjQNJ0iGE=; b=gPT/L0tzX/vifYTUsA5MPNJD/Y4KG7q8tZijBuFJQfi0Jv6xIteIvXtfthZCZSMIl5 y4wtmNQFyF72Jm6UKocE1/54kP+th90xkaqZ8rOCT4soTummmQ6LqAIplPZHHg/e9AHN 2eyKwF96i1qRT5mu2Rssz12t3GDtJaxe2cEIiHJBL3zEw8TScVUdOrct2uFAZ4sV9rK8 ZTM057pchI9qokWhXYE1ikb1phfVo771mINfdiav4cAV+egPuXZdazb8CGLnn9Tt3N4e 5l2mLNTxqo80q4OKOuOSKwI4+pvj6vNY1GTqmd88fb298iGciwiPCv3bqaI4VkpNuEyk tAKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Zag3mS16/ocWpIVeVVV7YLnfoYtX1qKbn1MjQNJ0iGE=; b=jeqF/6cj7cqGV4sLwyRFGluknd4YBEB5sTAackctP1lXHwBgXgBm7LSYZdNppDQ5Nz wH6xPUNkFmKxNUNddBJhE7FNoSeXcqD3H6ohtWX+asUdShbYHsMGfY4HqJdD8VYw9x67 71BjwRxg9CMJpYgdkLK1iQm7Y4VEQ0Uy1n0qoZWipL1Na6tP66kOxzTFOIyf9IpGUJgm cXtG6UQcQA/KiT2LVn8+td6Rynjy5NQvV8p140rvJZE1cwTxvEgnXpVCoXWbNaebqfIZ yvubd/qsWYuoEV8kMBwSPlOReixhuiTgciYz0csQunsf+tBMyNlT7ErBRbnaPcLQc9yi AWPA== X-Gm-Message-State: APjAAAX6a39TYqLr63p6s5QKr3rC9fNj/fbVg6F5Hpngiclaj5f4hRXr yDPUeTA0kNB3gLifS3dm7Go= X-Received: by 2002:ac2:5921:: with SMTP id v1mr10775321lfi.135.1553460037040; Sun, 24 Mar 2019 13:40:37 -0700 (PDT) Received: from z50.localnet (109241207190.gdansk.vectranet.pl. [109.241.207.190]) by smtp.gmail.com with ESMTPSA id 77sm1079933ljc.69.2019.03.24.13.40.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 24 Mar 2019 13:40:36 -0700 (PDT) From: Janusz Krzysztofik To: "H. Nikolaus Schaller" Cc: Aaro Koskinen , Boris Brezillon , Miquel Raynal , Richard Weinberger , David Woodhouse , Brian Norris , Marek Vasut , Tony Lindgren , linux-mtd@lists.infradead.org, linux-omap , linux-arm-kernel , LKML , Janusz Krzysztofik Subject: Re: [PATCH] mtd: rawnand: ams-delta: Drop board specific partition info Date: Sun, 24 Mar 2019 21:40:34 +0100 Message-ID: <1944041.gYv7fxL5Uc@z50> In-Reply-To: <454BF5C9-478A-4E2A-BF00-D2A2AFE25C45@goldelico.com> References: <20190319223718.26131-1-jmkrzyszt@gmail.com> <20190324185932.GA24594@darkstar.musicnaut.iki.fi> <454BF5C9-478A-4E2A-BF00-D2A2AFE25C45@goldelico.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On Sunday, March 24, 2019 8:24:48 PM CET H. Nikolaus Schaller wrote: > Hi, > > > Am 24.03.2019 um 19:59 schrieb Aaro Koskinen : > > > > Hi, > > > > On Sun, Mar 24, 2019 at 05:48:22PM +0100, Janusz Krzysztofik wrote: > >> Hi Aaro, > >> > >> Thanks for your review. > >> > >> On Wednesday, March 20, 2019 2:16:30 AM CET Aaro Koskinen wrote: > >>> On Tue, Mar 19, 2019 at 11:37:18PM +0100, Janusz Krzysztofik wrote: > >>>> After recent modifications, only a hardcoded partition info makes > >>>> the driver device specific. Other than that, the driver uses GPIO > >>>> exclusively and can be used on any hardware. > >>>> > >>>> Drop the partition info and use MTD partition parser with default > >>>> list of partition types instead. > >>>> > >>>> Amstrad Delta users should append the followig partition info to their > >>> ^^^^^^^^ > >>> Should be "following". > >>> > >>>> kernel command line, possibly by embedding it in CONFIG_CMDLINE: > >>>> mtdparts=ams-delta-nand:3584k(Kernel),256k(u-boot),256k(u-boot_params), \ > >>>> 256k(Amstrad_LDR),27m(File_system),768k(PBL_reserved). For their > >>>> convenience, select CONFIG_MTD_CMDLINE_PARTS symbol from that board > >>>> Kconfig automatically if this NAND driver is also selected. > >>>> > >>>> Signed-off-by: Janusz Krzysztofik > >>>> Cc: Tony Lindgren > >>> > >>> Could we move the fixed partition setup to the board file > >>> instead? Otherwise this kind of change is not really nice for the users, > >>> as it will likely break existing setups. The default partition layout > >>> should remain the same. > >> > >> I'm wondering if it would be acceptable to pass partition info from a .dts > >> file. I think that would be a better, more modern approach than adding a new > >> header under include/linux/platform_data. > > > > Hmm, I thought there was some generic way to define partitions without > > adding any new headers. But if that is not possible, then I guess your > > CMDLINE proposal is the preferred one.. > > I am not sure what you exactly need, but partitions can be defined in > the DTS as children of some NAND drivers. Example: > arch/arm/boot/dts/omap3-beagle.dts > So this design pattern could be copied instead of using CMDLINE. The problem is, OMAP1 has no device tree support. Other than that, your proposed approach already works for me locally with some basic support for device tree added to the board file. Thanks, Janusz