Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp411031ybl; Wed, 4 Dec 2019 04:57:37 -0800 (PST) X-Google-Smtp-Source: APXvYqzu7HwZynzC2VV+ix967D6tjC1jnQFdPJhgBZlhr39DeYHubramAf2d/E5NNBcrgdr30qlN X-Received: by 2002:a05:6830:60f:: with SMTP id w15mr2348124oti.225.1575464257475; Wed, 04 Dec 2019 04:57:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575464257; cv=none; d=google.com; s=arc-20160816; b=awaCg8r+t8Wgigp9LPQZDx3WS91H7FVNEpQknWucCZ4ZAboUih5IFs+w/QCdWaukxx B7FsRVm/v7C77OF76wCqjCO/dsNheBapfDw5UfjWdWlGLnHEI9LL2VAzk7VtLRAtf1sp 6C9LVmxWseBK/Pmz3zqWRUvX0e4DrwydrIBLHnztpNDOd80k/0sXfHgRqXi53c4vJWwp 6TdFow61DP0Sg3x3CcYo+ZV5UBou0xFyHkcMjqTnsxHdacuXqPbck+4ecxJypHNrShlI ov5GDXOILFzkHuVA/SbQn/J6npurDqFtlEuOl7zBDB2MyHYSVGgvMb7ZEowlSmHx6o+G xbnA== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=75OBmJFI3hpuZ4Q6xPCszXW82HOFGTHmHSHourpUJo0=; b=GzOS1ShWVWgGdqVvSDkSflor7uiKRqgPgdIIHBIiY23Fdu79fDOA2naFgy7lVxdRIg Hh7I5M7vP8MQ0cDWVhmPXz844O6i+RZeWVyjw+gkNuySyBQEdoedUi/ZxAVlFWigfsSz vDqTvwMw+6qBW1y2tpq1u8g4BliaDte6PCLx3hNstXl1kz6uzNt77ptO+LzrpcaBQNoV 76RW3sA7v5RTMexePB0aMwAkc0HdXjewidQxPX0oXL65n9qMbW70RGgXmcZFfPlUhh8z yy9VQz2ABDCy2DP/A5wrLcgZeDHxXXBgMSX4L3IIeei0d+BP9K83s9GiStIcmGWnOV5C Czsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=e6TfccCf; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 34si2964784otu.34.2019.12.04.04.57.24; Wed, 04 Dec 2019 04:57:37 -0800 (PST) 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=@ti.com header.s=ti-com-17Q1 header.b=e6TfccCf; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727820AbfLDMzs (ORCPT + 99 others); Wed, 4 Dec 2019 07:55:48 -0500 Received: from lelv0143.ext.ti.com ([198.47.23.248]:44210 "EHLO lelv0143.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726010AbfLDMzs (ORCPT ); Wed, 4 Dec 2019 07:55:48 -0500 Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id xB4CtLla021288; Wed, 4 Dec 2019 06:55:21 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1575464121; bh=75OBmJFI3hpuZ4Q6xPCszXW82HOFGTHmHSHourpUJo0=; h=Subject:To:CC:References:From:Date:In-Reply-To; b=e6TfccCfOlRHdE4aRiwj/c6mLAfsJvVI9jtvB241LwZYg12Kb3nKITmZXXAim2ENg mW4d9tz8/BHbqG9JyHgltecYvf8lGeGhYvn9gFVZQc8708HiuZU95x8HqXVPQd0Czd vr1tYpTKdDAeilTspVpALfyteFa87pBEN0Os9fPI= Received: from DLEE102.ent.ti.com (dlee102.ent.ti.com [157.170.170.32]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTP id xB4CtLqc057283; Wed, 4 Dec 2019 06:55:21 -0600 Received: from DLEE105.ent.ti.com (157.170.170.35) by DLEE102.ent.ti.com (157.170.170.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1847.3; Wed, 4 Dec 2019 06:55:21 -0600 Received: from lelv0326.itg.ti.com (10.180.67.84) by DLEE105.ent.ti.com (157.170.170.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1847.3 via Frontend Transport; Wed, 4 Dec 2019 06:55:21 -0600 Received: from [172.24.145.136] (ileax41-snat.itg.ti.com [10.172.224.153]) by lelv0326.itg.ti.com (8.15.2/8.15.2) with ESMTP id xB4CtHYT006688; Wed, 4 Dec 2019 06:55:18 -0600 Subject: Re: [PATCH v5 4/4] mtd: Add driver for concatenating devices To: Miquel Raynal CC: Richard Weinberger , Tudor Ambarus , Rob Herring , Mark Rutland , , Thomas Petazzoni , , , Mark Brown , Boris Brezillon , Paul Kocialkowski , Bernhard Frauendienst References: <20191127105522.31445-1-miquel.raynal@bootlin.com> <20191127105522.31445-5-miquel.raynal@bootlin.com> <690065a2-619d-3f97-30c6-5dea76896d78@ti.com> <20191204111751.5383b426@xps13> From: Vignesh Raghavendra Message-ID: <431e7345-ee60-6d79-7a0c-9396da93029c@ti.com> Date: Wed, 4 Dec 2019 18:25:48 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.1 MIME-Version: 1.0 In-Reply-To: <20191204111751.5383b426@xps13> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/12/19 3:47 pm, Miquel Raynal wrote: > Hi Vignesh, > > Vignesh Raghavendra wrote on Wed, 4 Dec 2019 15:28:46 > +0530: > [...] >> IIUC flash0 and flash1 are subnodes of a SPI master node? >> And I believe flash0 node's compatible is "jedec,spi-nor"? > > Indeed this is one possibility (probably the most common) but in theory > this should work for any kind of MTD device, hence I voluntarily > dropped the hardware-specific properties to focus on the partitions > description here. > Ah, make sense... >> >> >>> >>> flash1 { >>> partitions { >>> compatible = "fixed-partitions"; >>> >>> flash0_part1: part1@0 { >> >> s/flash0_part1/flash1_part0? > > Right! > >> >>> label = "part1_0"; >>> reg = <0x0 0x800000>; >>> }; >>> >>> part0@800000 { >>> label = "part1_1"; >>> reg = <0x800000 0x800000>; >>> }; >>> }; >>> }; >>> >> >> For my understanding, how many /dev/mtdX entries would this create? > > If the master is retained (Kconfig option) and thanks to the common > partitioning scheme, we would have: > * flash0 (mtd0) > * part0_0 (mtd1) > * part0_1 (mtd2) > * flash1 (mtd3) > * part1_0 (mtd4) > * part1_1 (mtd5) > > If we enable this driver, we would also get an additional device: > * mtd2-mtd4-concat (or part0_1-part1_0-concat, I don't recall the exact > name) being mtd6. Ok, thanks for the clarification! -- Regards Vignesh