From: Tudor Ambarus <tudor.ambarus@linaro.org>
To: Mark Brown <broonie@kernel.org>,
"linux-spi@vger.kernel.org" <linux-spi@vger.kernel.org>
Cc: AlvinZhou <alvinzhou.tw@gmail.com>,
Pratyush Yadav <pratyush@kernel.org>,
mwalle@kernel.org, Miquel Raynal <miquel.raynal@bootlin.com>,
richard@nod.at,
"open list:SPI NOR SUBSYSTEM" <linux-mtd@lists.infradead.org>,
open list <linux-kernel@vger.kernel.org>,
chengminglin@mxic.com.tw, leoyu@mxic.com.tw
Subject: [GIT PULL] spi-mem/swap16 changes for v6.13
Date: Fri, 4 Oct 2024 11:08:51 +0300 [thread overview]
Message-ID: <5b2bcd4d-faae-40f6-908a-63f4dbb02adc@linaro.org> (raw)
Hi, Mark,
I've made an immutable tag for the spi-mem swap16 changes. I let the
0day bot run on them, I got no complains. Pull if you need them.
Thanks,
ta
The following changes since commit 9852d85ec9d492ebef56dc5f229416c925758edc:
Linux 6.12-rc1 (2024-09-29 15:06:19 -0700)
are available in the Git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git
tags/mtd/spi-mem-swap16-for-6.13
for you to fetch changes up to 50cb86f21ec2ede08d0ec0479fbd8697a8a25616:
spi: mxic: Add support for swapping byte (2024-10-02 09:44:57 +0300)
----------------------------------------------------------------
This allows specifying the byte order in Octal DTR mode.
There are NOR flashes (Macronix) that swap the bytes on a 16-bit
boundary when configured in Octal DTR mode. The byte order of
16-bit words is swapped when read or written in Octal Double
Transfer Rate (DTR) mode compared to Single Transfer Rate (STR)
modes. If one writes D0 D1 D2 D3 bytes using 1-1-1 mode, and uses
8D-8D-8D SPI mode for reading, it will read back D1 D0 D3 D2.
Swapping the bytes may introduce some endianness problems. It can
affect the boot sequence if the entire boot sequence is not handled
in either 8D-8D-8D mode or 1-1-1 mode. Therefore, it is necessary
to swap the bytes back to ensure the same byte order as in STR modes.
Fortunately there are controllers that could swap the bytes back at
runtime, addressing the flash's endianness requirements. Provide a
way for the upper layers to specify the byte order in Octal DTR mode.
----------------------------------------------------------------
AlvinZhou (1):
spi: mxic: Add support for swapping byte
Tudor Ambarus (1):
spi: spi-mem: Allow specifying the byte order in Octal DTR mode
drivers/spi/spi-mem.c | 3 +++
drivers/spi/spi-mxic.c | 17 +++++++++++++----
include/linux/spi/spi-mem.h | 8 +++++++-
3 files changed, 23 insertions(+), 5 deletions(-)
reply other threads:[~2024-10-04 8:08 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=5b2bcd4d-faae-40f6-908a-63f4dbb02adc@linaro.org \
--to=tudor.ambarus@linaro.org \
--cc=alvinzhou.tw@gmail.com \
--cc=broonie@kernel.org \
--cc=chengminglin@mxic.com.tw \
--cc=leoyu@mxic.com.tw \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=linux-spi@vger.kernel.org \
--cc=miquel.raynal@bootlin.com \
--cc=mwalle@kernel.org \
--cc=pratyush@kernel.org \
--cc=richard@nod.at \
/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
all inboxes | Powered by JetHome®