From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gw2.atmark-techno.com (gw2.atmark-techno.com [35.74.137.57]) (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 29959417D87 for ; Tue, 11 Aug 2026 23:23:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=35.74.137.57 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786490635; cv=none; b=jyIjw/X+f5eIBI7KPPuiC7WEuwq6R7m1Q2u/fF0fSGELJxsFtasVCG+F0+49drm5XQv+XDmhZYvikGLkAAzOngPGCzh1Ef0liuxduoT1lzf77oSFs4eA+augYEji/Vg8UwCWvkxlZCo62ThtekbvDe5UCt51pEv3Fp6Tl3IAc4Y= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786490635; c=relaxed/simple; bh=Tr64g3ul3E1GEx9P8FK/XkvnAWtWNkJ25lKpXc2D0Jc=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=U0e02YxXW7Z26SE65+wlxVUz69St60lVw/zOl3AF5rl8iS6+WToPQR1ycPdZvVHDJczHoPx+kkvbbxyczyVepoNksB/S6pqzP0qbh26pz5jy8vh3E9V4+Q9gmgYWLGdACU/W5yHApEG5lh0s45ECau676IlJNZGhXZIJPThvIww= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=atmark-techno.com; spf=pass smtp.mailfrom=atmark-techno.com; dkim=pass (2048-bit key) header.d=atmark-techno.com header.i=@atmark-techno.com header.b=QUrVlLBc; arc=none smtp.client-ip=35.74.137.57 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=atmark-techno.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=atmark-techno.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=atmark-techno.com header.i=@atmark-techno.com header.b="QUrVlLBc" Authentication-Results: gw2.atmark-techno.com; dkim=pass (2048-bit key; unprotected) header.d=atmark-techno.com header.i=@atmark-techno.com header.a=rsa-sha256 header.s=google header.b=QUrVlLBc; dkim-atps=neutral Received: from mail-pl1-f199.google.com (mail-pl1-f199.google.com [209.85.214.199]) by gw2.atmark-techno.com (Postfix) with ESMTPS id 83FFC444 for ; Wed, 12 Aug 2026 08:23:47 +0900 (JST) Received: by mail-pl1-f199.google.com with SMTP id d9443c01a7336-2ce7dff6253so13892995ad.1 for ; Tue, 11 Aug 2026 16:23:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=atmark-techno.com; s=google; t=1786490626; x=1787095426; darn=vger.kernel.org; h=in-reply-to:content-transfer-encoding:content-disposition :content-type:mime-version:references:message-id:subject:cc:to:from :date:from:to:cc:subject:date:message-id:reply-to:content-type; bh=poCJy7EhTAZaAcqpQDKZJc01iAhjKgRkc0yZroaBdLs=; b=QUrVlLBcbs4U0ReF2t1RjjOxHZlHPTy7gK6eWNyPtL/LBeU9VrDwtRjg1Cb8hap9ZJ FMm0B4s4CjxpIaDaOYUPwtf1DW9pw49nMJg9pIthZ9mDRimEeQMBjLbLyfN6VXR556L/ iTVUAVLJNh1xddPteT9OPI1l9cqEMsiLjYmOIfGhnUnXLbihdv+2LaC7qG2rIOluvpOQ /1ZCB5gWgIDyppy66eKVKEkLB/P5m0iNQe6Se7h/DOmGaEb+liWsAdce0TZaPxMjg4tS 4zuUEzfnGdwO9fsMGedidYP2o1d021YdkDKuTBNzdoxlHEnQXNJJFRfTq9Fpbj9QQ8ci MnrQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786490626; x=1787095426; h=in-reply-to:content-transfer-encoding:content-disposition :content-type:mime-version:references:message-id:subject:cc:to:from :date:x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to:content-type; bh=poCJy7EhTAZaAcqpQDKZJc01iAhjKgRkc0yZroaBdLs=; b=BRiQwoJtmvEml+GqIzN6f3KPSb+lgi5WshRhqk3mvMqpdl/z41FHG8A6aU31u3sFes XvbOOeVQvxLaImogxcGiOue2Hrcp1ki544Z3TQuQw2FaRjHSp4UnsKUNjrZF8gbvhdFg zVpi+hjCI7zrfjBG09BHJNAsobmv7Xt8+ANVa52ivfLKED2HN0lCKTu0Cvi/5lDa6/+0 k4yxtmpTfyvID1WqdCE1aE04H/t7lNpcYEBjYHXBjj8zMe1Pps0+Mp/11eDSPAUj9jKl vkDdiZRzFhzhRh73yT1XLmj+B4XaSOnPSDAL9kW5JdzkUdp5Pq6kvjXzpWi2HFAlRiVJ XDIw== X-Forwarded-Encrypted: i=1; AHgh+RpkfTfd1Lt5zTsD61mWFt1XCmjjD2khpWC1ZLEYvqnHPTkPdpSb6bsDtTmkKUO9I515GIqZlWI0t6gC1x4=@vger.kernel.org X-Gm-Message-State: AOJu0YyL+IN24lTmCEbNhI/BfdC5l4pVD61AmCPewIbgFf6iGm7kzEnP 6HUlAf53HiKsxuRYNNHyQR8FxJb+iFR9pjSVcjo1VHHW1BlueMWspLNmjJFvoiH3qh8t04InC4A JRLiVmqKxd3a2PM0g8z4nHFVQz+0Q3Z+8tbfFNzH20t0mUQMYCEk6hyBc7NAD4h+LfLY= X-Gm-Gg: AR+sD133RdyoRn++3mmR9PZv52SXZSdphhste9BSNWoADTynfqsmFQYi62h1rVsbsk4 Kp9X5TY/mZV4EeS2AExBClUnOmeCbSaWdKfndeqKm7lTptqLVEzPAi2aq/ARGKJLlMWqLaN4xfK 3uwJ3hAgMo0mv80AcPtV46sTF8k+jNIXyCevCmT5u+9ITIQLyKK9c1deCqoyLoqGRBgXDbNpsdC I5uhaU1OH3N/N0pqewykmXLYyuEd2vuZZOzPOM0+IQlIKpNX5DkV2eUxf+ZwEp6sW27kb0/PAM7 ZFA1a3cSpZWC3wIygJ4dlL+gkw340x6DwDekuNmyoz+ZRkRqGShnljlh+0cMweQvHX/PrOVpB7r QwPa/8A1pYOcb0I2fzyzGbJSkhUSDiQY8gW6cEVW/Vj8tiPfp X-Received: by 2002:a17:90b:6cd:b0:390:b3c5:e2c9 with SMTP id 98e67ed59e1d1-39302bce9e4mr159111a91.17.1786490626367; Tue, 11 Aug 2026 16:23:46 -0700 (PDT) X-Received: by 2002:a17:90b:6cd:b0:390:b3c5:e2c9 with SMTP id 98e67ed59e1d1-39302bce9e4mr159077a91.17.1786490625706; Tue, 11 Aug 2026 16:23:45 -0700 (PDT) Received: from localhost (sodcd-04p2-40.ppp11.odn.ad.jp. [203.139.65.40]) by smtp.gmail.com with UTF8SMTPSA id 98e67ed59e1d1-392fe4a8c05sm260990a91.2.2026.08.11.16.23.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Aug 2026 16:23:44 -0700 (PDT) Date: Wed, 12 Aug 2026 08:23:33 +0900 From: Dominique Martinet To: Md Sadre Alam Cc: miquel.raynal@bootlin.com, richard@nod.at, vigneshr@ti.com, tudor.ambarus@linaro.org, s-k6@ti.com, linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, varadarajan.narayanan@oss.qualcomm.com Subject: Re: [PATCH 1/2] mtd: spinand: winbond: add support for W25N04LW Message-ID: References: <20260807064339.1632249-1-md.alam@oss.qualcomm.com> <20260807064339.1632249-2-md.alam@oss.qualcomm.com> 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=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Md Sadre Alam wrote on Tue, Aug 11, 2026 at 06:10:50PM +0530: > > I agree with Miquèl that your patch looks odd, you wrote > > > + NAND_MEMORG(1, 4096, 128, 64, 2048, 40, 1, 1, 1), > > but the erase blocks are 256K long so it should be > > + NAND_MEMORG(1, 4096, 256, 64, 2048, 40, 1, 1, 1), (I misremembered NAND_MEMORG() fields, the 256 is indeed the OOB area size as you pointed out; the erase blocks were already correct at 64 pages = 256KB so while the settings were wrong this might actually not be visible at all in quick testing; sorry) > > FWIW, I've confirmed it works with the following diff (at least up to > > the point of creating an ubi volume and booting from it); happy to send > > this as a patch if this has indeed not been tested > > This device was supported in our downstream tree and was tested there. I > picked that patch and posted it upstream assuming the configuration was > already correct. > The `128` in: > NAND_MEMORG(1, 4096, 128, 64, 2048, 40, 1, 1, 1) > was my mistake. It should indeed be `256`, matching the 4096 + 256 page > layout in the W25N04LW datasheet. > Please go ahead and post your tested patch. I do not currently have this > device available to retest the upstream version. Ok, let me do some slightly more thorough checks and clean up a bit and I'll send a v2 later this week/early next week The continuous read feature also definitely is interesting to me and I'll be testing it later, but it's "just" a performance improvement so I'll be taking a bit longer; I'll come back with either a patch or questions hopefully by next month ish Thanks, -- Dominique