mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-27 09:12:39 +00:00
89895937dd
Changelog: https://cdn.kernel.org/pub/linux/kernel/v5.x/ChangeLog-5.15.133 Removed upstreamed: bcm47xx/patches-5.15/101-v5.18-mtd-rawnand-brcmnand-Allow-SoC-to-provide-I-O-operations.patch[1] Cherry picked build fix.[2] All other patches automatically rebased. 1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.133&id=56cf9f446b331414a15ef0e8dedf23583ec2c427 2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/stable-queue.git/tree/queue-5.15/fix-up-backport-of-136191703038-interconnect-teach-l.patch Build system: x86_64 Build-tested: ramips/tplink_archer-a6-v3 Run-tested: ramips/tplink_archer-a6-v3 Signed-off-by: John Audia <therealgraysky@proton.me>
30 lines
989 B
Diff
30 lines
989 B
Diff
From: Florian Fainelli <f.fainelli@gmail.com>
|
|
Subject: [PATCH v3 8/9] mtd: rawnand: brcmnand: BCMA controller uses command shift of 0
|
|
Date: Fri, 07 Jan 2022 10:46:13 -0800
|
|
Content-Type: text/plain; charset="utf-8"
|
|
|
|
For some odd and unexplained reason the BCMA NAND controller, albeit
|
|
revision 3.4 uses a command shift of 0 instead of 24 as it should be,
|
|
quirk that.
|
|
|
|
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
|
|
---
|
|
drivers/mtd/nand/raw/brcmnand/brcmnand.c | 6 ++++++
|
|
1 file changed, 6 insertions(+)
|
|
|
|
--- a/drivers/mtd/nand/raw/brcmnand/brcmnand.c
|
|
+++ b/drivers/mtd/nand/raw/brcmnand/brcmnand.c
|
|
@@ -951,6 +951,12 @@ static void brcmnand_wr_corr_thresh(stru
|
|
|
|
static inline int brcmnand_cmd_shift(struct brcmnand_controller *ctrl)
|
|
{
|
|
+ /* Kludge for the BCMA-based NAND controller which does not actually
|
|
+ * shift the command
|
|
+ */
|
|
+ if (ctrl->nand_version == 0x0304 && brcmnand_non_mmio_ops(ctrl))
|
|
+ return 0;
|
|
+
|
|
if (ctrl->nand_version < 0x0602)
|
|
return 24;
|
|
return 0;
|