From nobody Tue Feb 10 20:07:36 2026 Received: from relay1-d.mail.gandi.net (relay1-d.mail.gandi.net [217.70.183.193]) (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 AC01C21CC4A for ; Fri, 7 Mar 2025 15:08:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.193 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1741360121; cv=none; b=IzEeFRToD/Sevuu9OQcBt/eX0SycgQgQJLJ/H7GJfSxPZuhLYciq8+gdXFrsdQf/DdECsRegn7Q5ZXoVChFxueaOqdw8ZRtVzCGa02dNHnE3rrAvHduLsHOz86BxGEhByRVwr/fWPFaooy3fiRM+If8Ks1UTqJ3CR6+VS9ZQSsc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1741360121; c=relaxed/simple; bh=+PqrpRYVhEyed5L1M66HKptxDOJlamL5VAZR+Jav/TM=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=psyGf8ir27ScBB/elF95BOG05z5ju09e6xnvejSbHlZUjzTI/fSuD8X/KrArEc1+CKZduihAq8343oySXSxcKdEz9TzJePsLz3x8r9Aux8NBAwEMQW+uBSLAdkbueTD7Yzc1ItSPbbowJdozhd9JUHDCTrvn6DrTys08nTuroPY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=inGjFDLK; arc=none smtp.client-ip=217.70.183.193 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="inGjFDLK" Received: by mail.gandi.net (Postfix) with ESMTPSA id 0FDD04430E; Fri, 7 Mar 2025 15:08:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1741360118; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=spqqaejQJ2OnLLz9FBx+nDsiHzoIe3FZo+XQEdP1SxM=; b=inGjFDLKyV17QCOObWIjjbjvUnt1X2eJfh1t407GQI0qV9LnpzMM9eK536uObi8Yv+Ss7i X7Bf1ZX4o2qpg11CPq4GeGdde0vTYE7NfLuwy1PWllfxeosFtkrCZiAS9+9gS43uioGB6/ ceDtAJ8fbF+o2LAk51mNWd3qZUu+CwubHz+F9Z8DfDm+FB9MutzaeyflcWgQh3103aQi5E gvpZP51ov5D60L3Z2OxICbj5AqO700HNWvMjXWTPzkSiVbmDKnnWri2t2gwuWMm2W5Ph18 RpiO4e3idFGrxv8JsR6Q72p126QbKE2sWro2mdv1eWMWdP3RQXRH39HDQdelZw== From: Miquel Raynal Date: Fri, 07 Mar 2025 16:08:24 +0100 Subject: [PATCH 05/21] mtd: spinand: Use more specific naming for the erase op 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-Transfer-Encoding: quoted-printable Message-Id: <20250307-winbond-6-14-rc1-octal-v1-5-45c1e074ad74@bootlin.com> References: <20250307-winbond-6-14-rc1-octal-v1-0-45c1e074ad74@bootlin.com> In-Reply-To: <20250307-winbond-6-14-rc1-octal-v1-0-45c1e074ad74@bootlin.com> To: Richard Weinberger , Vignesh Raghavendra , Santhosh Kumar K Cc: Tudor Ambarus , Pratyush Yadav , Michael Walle , Thomas Petazzoni , Steam Lin , linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, Miquel Raynal X-Mailer: b4 0.15-dev X-GND-State: clean X-GND-Score: -100 X-GND-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgdduuddtleekucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuifetpfffkfdpucggtfgfnhhsuhgsshgtrhhisggvnecuuegrihhlohhuthemuceftddunecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhfffugggtgffkfhgjvfevofesthejredtredtjeenucfhrhhomhepofhiqhhuvghlucftrgihnhgrlhcuoehmihhquhgvlhdrrhgrhihnrghlsegsohhothhlihhnrdgtohhmqeenucggtffrrghtthgvrhhnpeelgfehvdduieefieeikeffgffggfdttdeugeffieetheeuleelfeehffdtffetveenucfkphepledvrddukeegrddutdekrddujeeinecuvehluhhsthgvrhfuihiivgepudenucfrrghrrghmpehinhgvthepledvrddukeegrddutdekrddujeeipdhhvghloheplgduledvrdduieekrddurddutdeingdpmhgrihhlfhhrohhmpehmihhquhgvlhdrrhgrhihnrghlsegsohhothhlihhnrdgtohhmpdhnsggprhgtphhtthhopeduuddprhgtphhtthhopehtuhguohhrrdgrmhgsrghruhhssehlihhnrghrohdrohhrghdprhgtphhtthhopehmihgthhgrvghlseifrghllhgvrdgttgdprhgtphhtthhopehthhhomhgrshdrphgvthgriiiiohhnihessghoohhtlhhinhdrtghomhdprhgtphhtthhopehlihhnuhigqdhkvghrnhgvlhesvhhgvghrrdhkvghrnhgvlhdrohhrghdprhgtphhtthhopehsthhlihhnv desfihinhgsohhnugdrtghomhdprhgtphhtthhopehmihhquhgvlhdrrhgrhihnrghlsegsohhothhlihhnrdgtohhmpdhrtghpthhtohepphhrrghthihushhhsehkvghrnhgvlhdrohhrghdprhgtphhtthhopehvihhgnhgvshhhrhesthhirdgtohhm X-GND-Sasl: miquel.raynal@bootlin.com SPI operations have been initially described through macros implicitly implying the use of a single SPI SDR bus. Macros for supporting dual and quad I/O transfers have been added on top, generally inspired by vendor naming, followed by DTR operations. Soon we might see octal and even octal DTR operations as well (including the opcode byte). Let's clarify what the macro really means by describing the expected bus topology in the erase macro name. Signed-off-by: Miquel Raynal Reviewed-by: Tudor Ambarus --- drivers/mtd/nand/spi/core.c | 2 +- include/linux/mtd/spinand.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c index b6c0993206ebab1dcee715ea6de33efe7d5af3a2..1959e8d9c64be004c71a0d6ac64= 54fde08e708fa 100644 --- a/drivers/mtd/nand/spi/core.c +++ b/drivers/mtd/nand/spi/core.c @@ -529,7 +529,7 @@ static int spinand_erase_op(struct spinand_device *spin= and, { struct nand_device *nand =3D spinand_to_nand(spinand); unsigned int row =3D nanddev_pos_to_row(nand, pos); - struct spi_mem_op op =3D SPINAND_BLK_ERASE_OP(row); + struct spi_mem_op op =3D SPINAND_BLK_ERASE_1S_1S_0_OP(row); =20 return spi_mem_exec_op(spinand->spimem, &op); } diff --git a/include/linux/mtd/spinand.h b/include/linux/mtd/spinand.h index d041b1cc18de6add45800eaa7605bda1c64ca257..545531afe2dac593d112065483a= fd180226cc533 100644 --- a/include/linux/mtd/spinand.h +++ b/include/linux/mtd/spinand.h @@ -50,7 +50,7 @@ SPI_MEM_OP_NO_DUMMY, \ SPI_MEM_OP_DATA_IN(1, valptr, 1)) =20 -#define SPINAND_BLK_ERASE_OP(addr) \ +#define SPINAND_BLK_ERASE_1S_1S_0_OP(addr) \ SPI_MEM_OP(SPI_MEM_OP_CMD(0xd8, 1), \ SPI_MEM_OP_ADDR(3, addr, 1), \ SPI_MEM_OP_NO_DUMMY, \ --=20 2.48.1