mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Jules Maselbas <jmaselbas@zdiv.net>
To: barebox@lists.infradead.org
Cc: Jules Maselbas <jmaselbas@kalray.eu>
Subject: [PATCH v2 4/5] mtd: spi-nor: move SPI_NOR_MAX_ADDR_WIDTH define to spi-nor.h
Date: Sat, 12 Aug 2023 09:48:23 +0200	[thread overview]
Message-ID: <20230812074859.1755-4-jmaselbas@zdiv.net> (raw)
In-Reply-To: <20230812074859.1755-1-jmaselbas@zdiv.net>

From: Jules Maselbas <jmaselbas@kalray.eu>

Move the SPI_NOR_MAX_ADDR_WIDTH define into spi-nor.h to be used by
drivers.

Signed-off-by: Jules Maselbas <jmaselbas@kalray.eu>
---
 drivers/mtd/spi-nor/spi-nor.c | 1 -
 include/linux/mtd/spi-nor.h   | 2 ++
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/mtd/spi-nor/spi-nor.c b/drivers/mtd/spi-nor/spi-nor.c
index 968fd3ea7a..ab61e7824c 100644
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
@@ -21,7 +21,6 @@
 #include <of.h>
 
 #define SPI_NOR_MAX_ID_LEN	6
-#define SPI_NOR_MAX_ADDR_WIDTH	4
 
 /*
  * For everything but full-chip erase; probably could be much smaller, but kept
diff --git a/include/linux/mtd/spi-nor.h b/include/linux/mtd/spi-nor.h
index fc7cefb55e..720b4888d4 100644
--- a/include/linux/mtd/spi-nor.h
+++ b/include/linux/mtd/spi-nor.h
@@ -142,6 +142,8 @@
         SNOR_PROTO_ADDR(_addr_nbits) |                         \
         SNOR_PROTO_DATA(_data_nbits))
 
+#define SPI_NOR_MAX_ADDR_WIDTH	4
+
 enum spi_nor_protocol {
        SNOR_PROTO_1_1_1 = SNOR_PROTO_STR(1, 1, 1),
        SNOR_PROTO_1_1_2 = SNOR_PROTO_STR(1, 1, 2),
-- 
2.41.0




  parent reply	other threads:[~2023-08-12  7:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-12  7:48 [PATCH v2 1/5] mtd: spi-nor: Add SPI_NOR_QUAD_WRITE hwcap Jules Maselbas
2023-08-12  7:48 ` [PATCH v2 2/5] mtd: spi-nor: enable {dual,quad}-read and quad-write for w25q256 Jules Maselbas
2023-08-12  7:48 ` [PATCH v2 3/5] mtd: spi-nor: enable quad-write for is25lp01g Jules Maselbas
2023-08-12  7:48 ` Jules Maselbas [this message]
2023-08-12  7:48 ` [PATCH v2 5/5] mtd: spi-nor: Add Synopsys DesignWare Octal SPI driver Jules Maselbas
2023-08-14 12:57 ` [PATCH v2 1/5] mtd: spi-nor: Add SPI_NOR_QUAD_WRITE hwcap Sascha Hauer

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=20230812074859.1755-4-jmaselbas@zdiv.net \
    --to=jmaselbas@zdiv.net \
    --cc=barebox@lists.infradead.org \
    --cc=jmaselbas@kalray.eu \
    /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