linux-mtd.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Sudip Mukherjee <sudip.mukherjee@sifive.com>
To: Tudor Ambarus <tudor.ambarus@microchip.com>,
	Pratyush Yadav <p.yadav@ti.com>, Michael Walle <michael@walle.cc>,
	Miquel Raynal <miquel.raynal@bootlin.com>,
	Richard Weinberger <richard@nod.at>,
	Vignesh Raghavendra <vigneshr@ti.com>
Cc: greentime.hu@sifive.com, jude.onyenegecha@sifive.com,
	william.salmon@sifive.com, adnan.chowdhury@sifive.com,
	ben.dooks@sifive.com, linux-mtd@lists.infradead.org,
	linux-kernel@vger.kernel.org,
	Sudip Mukherjee <sudip.mukherjee@sifive.com>
Subject: [PATCH 1/3] mtd: spi-nor: extend no_sfdp_flags to use u16
Date: Tue, 12 Jul 2022 17:38:21 +0100	[thread overview]
Message-ID: <20220712163823.428126-2-sudip.mukherjee@sifive.com> (raw)
In-Reply-To: <20220712163823.428126-1-sudip.mukherjee@sifive.com>

Currently no_sfdp_flags is u8 and all the bits have been used. Extend
it to use u16 so that we can add more support.

Signed-off-by: Sudip Mukherjee <sudip.mukherjee@sifive.com>
---
 drivers/mtd/spi-nor/core.c | 2 +-
 drivers/mtd/spi-nor/core.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/spi-nor/core.c b/drivers/mtd/spi-nor/core.c
index ce5d69317d46c..e5f7691c5bd40 100644
--- a/drivers/mtd/spi-nor/core.c
+++ b/drivers/mtd/spi-nor/core.c
@@ -2335,7 +2335,7 @@ static void spi_nor_no_sfdp_init_params(struct spi_nor *nor)
 {
 	struct spi_nor_flash_parameter *params = nor->params;
 	struct spi_nor_erase_map *map = &params->erase_map;
-	const u8 no_sfdp_flags = nor->info->no_sfdp_flags;
+	const u16 no_sfdp_flags = nor->info->no_sfdp_flags;
 	u8 i, erase_mask;
 
 	if (no_sfdp_flags & SPI_NOR_DUAL_READ) {
diff --git a/drivers/mtd/spi-nor/core.h b/drivers/mtd/spi-nor/core.h
index 61886868cd022..58fbedc94080f 100644
--- a/drivers/mtd/spi-nor/core.h
+++ b/drivers/mtd/spi-nor/core.h
@@ -501,7 +501,7 @@ struct flash_info {
 #define NO_CHIP_ERASE			BIT(7)
 #define SPI_NOR_NO_FR			BIT(8)
 
-	u8 no_sfdp_flags;
+	u16 no_sfdp_flags;
 #define SPI_NOR_SKIP_SFDP		BIT(0)
 #define SECT_4K				BIT(1)
 #define SPI_NOR_DUAL_READ		BIT(3)
-- 
2.30.2


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

  reply	other threads:[~2022-07-12 16:40 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-12 16:38 [PATCH 0/3] Add Quad Input Page Program to chips with no SFDP table Sudip Mukherjee
2022-07-12 16:38 ` Sudip Mukherjee [this message]
2022-07-18 16:58   ` [PATCH 1/3] mtd: spi-nor: extend no_sfdp_flags to use u16 Tudor.Ambarus
2022-07-12 16:38 ` [PATCH 2/3] mtd: spi-nor: add support for Quad Page Program to no_sfdp_flags Sudip Mukherjee
2022-07-18 17:02   ` Tudor.Ambarus
2022-07-18 18:49     ` Sudip Mukherjee
2022-07-22 10:24       ` Sudip Mukherjee
2022-07-29  7:48         ` Tudor.Ambarus
2022-07-29  8:10           ` Ben Dooks
2022-07-29 10:07             ` Tudor.Ambarus
2022-07-29  7:35       ` Tudor.Ambarus
2022-07-12 16:38 ` [PATCH 3/3] mtd: spi-nor: issi: is25wp256: Enable Quad Input Page Program Sudip Mukherjee
2022-07-18  7:39   ` Michael Walle
2022-07-18 14:56     ` Sudip Mukherjee

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220712163823.428126-2-sudip.mukherjee@sifive.com \
    --to=sudip.mukherjee@sifive.com \
    --cc=adnan.chowdhury@sifive.com \
    --cc=ben.dooks@sifive.com \
    --cc=greentime.hu@sifive.com \
    --cc=jude.onyenegecha@sifive.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=michael@walle.cc \
    --cc=miquel.raynal@bootlin.com \
    --cc=p.yadav@ti.com \
    --cc=richard@nod.at \
    --cc=tudor.ambarus@microchip.com \
    --cc=vigneshr@ti.com \
    --cc=william.salmon@sifive.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).