From: Val Packett <val@packett.cool>
Cc: Val Packett <val@packett.cool>,
Miquel Raynal <miquel.raynal@bootlin.com>,
Richard Weinberger <richard@nod.at>,
Vignesh Raghavendra <vigneshr@ti.com>,
Heiko Stuebner <heiko@sntech.de>,
Stephen Rothwell <sfr@canb.auug.org.au>,
linux-mtd@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH] mtd: rawnand: rockchip: reject NVDDR timings when checked
Date: Sat, 18 May 2024 00:31:13 -0300 [thread overview]
Message-ID: <20240518033923.5577-2-val@packett.cool> (raw)
.setup_interface first gets called with a negative "target" value
NAND_DATA_IFACE_CHECK_ONLY, in which case an error is expected
if the controller driver does not support the timing mode (NVDDR).
Signed-off-by: Val Packett <val@packett.cool>
---
Hello everyone, first Linux patch from a long time FreeBSD person :)
This was required to get the NAND controller to attach on the random
old RK3066 tablet I'm bringing up mainline on.
---
drivers/mtd/nand/raw/rockchip-nand-controller.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mtd/nand/raw/rockchip-nand-controller.c b/drivers/mtd/nand/raw/rockchip-nand-controller.c
index 7baaef69d..555804476 100644
--- a/drivers/mtd/nand/raw/rockchip-nand-controller.c
+++ b/drivers/mtd/nand/raw/rockchip-nand-controller.c
@@ -420,13 +420,13 @@ static int rk_nfc_setup_interface(struct nand_chip *chip, int target,
u32 rate, tc2rw, trwpw, trw2c;
u32 temp;
- if (target < 0)
- return 0;
-
timings = nand_get_sdr_timings(conf);
if (IS_ERR(timings))
return -EOPNOTSUPP;
+ if (target < 0)
+ return 0;
+
if (IS_ERR(nfc->nfc_clk))
rate = clk_get_rate(nfc->ahb_clk);
else
--
2.45.0
______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
WARNING: multiple messages have this Message-ID (diff)
From: Val Packett <val@packett.cool>
Cc: Val Packett <val@packett.cool>,
Miquel Raynal <miquel.raynal@bootlin.com>,
Richard Weinberger <richard@nod.at>,
Vignesh Raghavendra <vigneshr@ti.com>,
Heiko Stuebner <heiko@sntech.de>,
Stephen Rothwell <sfr@canb.auug.org.au>,
linux-mtd@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH] mtd: rawnand: rockchip: reject NVDDR timings when checked
Date: Sat, 18 May 2024 00:31:13 -0300 [thread overview]
Message-ID: <20240518033923.5577-2-val@packett.cool> (raw)
.setup_interface first gets called with a negative "target" value
NAND_DATA_IFACE_CHECK_ONLY, in which case an error is expected
if the controller driver does not support the timing mode (NVDDR).
Signed-off-by: Val Packett <val@packett.cool>
---
Hello everyone, first Linux patch from a long time FreeBSD person :)
This was required to get the NAND controller to attach on the random
old RK3066 tablet I'm bringing up mainline on.
---
drivers/mtd/nand/raw/rockchip-nand-controller.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mtd/nand/raw/rockchip-nand-controller.c b/drivers/mtd/nand/raw/rockchip-nand-controller.c
index 7baaef69d..555804476 100644
--- a/drivers/mtd/nand/raw/rockchip-nand-controller.c
+++ b/drivers/mtd/nand/raw/rockchip-nand-controller.c
@@ -420,13 +420,13 @@ static int rk_nfc_setup_interface(struct nand_chip *chip, int target,
u32 rate, tc2rw, trwpw, trw2c;
u32 temp;
- if (target < 0)
- return 0;
-
timings = nand_get_sdr_timings(conf);
if (IS_ERR(timings))
return -EOPNOTSUPP;
+ if (target < 0)
+ return 0;
+
if (IS_ERR(nfc->nfc_clk))
rate = clk_get_rate(nfc->ahb_clk);
else
--
2.45.0
_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip
WARNING: multiple messages have this Message-ID (diff)
From: Val Packett <val@packett.cool>
Cc: Val Packett <val@packett.cool>,
Miquel Raynal <miquel.raynal@bootlin.com>,
Richard Weinberger <richard@nod.at>,
Vignesh Raghavendra <vigneshr@ti.com>,
Heiko Stuebner <heiko@sntech.de>,
Stephen Rothwell <sfr@canb.auug.org.au>,
linux-mtd@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH] mtd: rawnand: rockchip: reject NVDDR timings when checked
Date: Sat, 18 May 2024 00:31:13 -0300 [thread overview]
Message-ID: <20240518033923.5577-2-val@packett.cool> (raw)
.setup_interface first gets called with a negative "target" value
NAND_DATA_IFACE_CHECK_ONLY, in which case an error is expected
if the controller driver does not support the timing mode (NVDDR).
Signed-off-by: Val Packett <val@packett.cool>
---
Hello everyone, first Linux patch from a long time FreeBSD person :)
This was required to get the NAND controller to attach on the random
old RK3066 tablet I'm bringing up mainline on.
---
drivers/mtd/nand/raw/rockchip-nand-controller.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mtd/nand/raw/rockchip-nand-controller.c b/drivers/mtd/nand/raw/rockchip-nand-controller.c
index 7baaef69d..555804476 100644
--- a/drivers/mtd/nand/raw/rockchip-nand-controller.c
+++ b/drivers/mtd/nand/raw/rockchip-nand-controller.c
@@ -420,13 +420,13 @@ static int rk_nfc_setup_interface(struct nand_chip *chip, int target,
u32 rate, tc2rw, trwpw, trw2c;
u32 temp;
- if (target < 0)
- return 0;
-
timings = nand_get_sdr_timings(conf);
if (IS_ERR(timings))
return -EOPNOTSUPP;
+ if (target < 0)
+ return 0;
+
if (IS_ERR(nfc->nfc_clk))
rate = clk_get_rate(nfc->ahb_clk);
else
--
2.45.0
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
WARNING: multiple messages have this Message-ID (diff)
From: Val Packett <val@packett.cool>
Cc: Val Packett <val@packett.cool>,
Miquel Raynal <miquel.raynal@bootlin.com>,
Richard Weinberger <richard@nod.at>,
Vignesh Raghavendra <vigneshr@ti.com>,
Heiko Stuebner <heiko@sntech.de>,
Stephen Rothwell <sfr@canb.auug.org.au>,
linux-mtd@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH] mtd: rawnand: rockchip: reject NVDDR timings when checked
Date: Sat, 18 May 2024 00:31:13 -0300 [thread overview]
Message-ID: <20240518033923.5577-2-val@packett.cool> (raw)
.setup_interface first gets called with a negative "target" value
NAND_DATA_IFACE_CHECK_ONLY, in which case an error is expected
if the controller driver does not support the timing mode (NVDDR).
Signed-off-by: Val Packett <val@packett.cool>
---
Hello everyone, first Linux patch from a long time FreeBSD person :)
This was required to get the NAND controller to attach on the random
old RK3066 tablet I'm bringing up mainline on.
---
drivers/mtd/nand/raw/rockchip-nand-controller.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mtd/nand/raw/rockchip-nand-controller.c b/drivers/mtd/nand/raw/rockchip-nand-controller.c
index 7baaef69d..555804476 100644
--- a/drivers/mtd/nand/raw/rockchip-nand-controller.c
+++ b/drivers/mtd/nand/raw/rockchip-nand-controller.c
@@ -420,13 +420,13 @@ static int rk_nfc_setup_interface(struct nand_chip *chip, int target,
u32 rate, tc2rw, trwpw, trw2c;
u32 temp;
- if (target < 0)
- return 0;
-
timings = nand_get_sdr_timings(conf);
if (IS_ERR(timings))
return -EOPNOTSUPP;
+ if (target < 0)
+ return 0;
+
if (IS_ERR(nfc->nfc_clk))
rate = clk_get_rate(nfc->ahb_clk);
else
--
2.45.0
next reply other threads:[~2024-05-18 3:41 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-18 3:31 Val Packett [this message]
2024-05-18 3:31 ` [PATCH] mtd: rawnand: rockchip: reject NVDDR timings when checked Val Packett
2024-05-18 3:31 ` Val Packett
2024-05-18 3:31 ` Val Packett
2024-05-18 10:44 ` Miquel Raynal
2024-05-18 10:44 ` Miquel Raynal
2024-05-18 10:44 ` Miquel Raynal
2024-05-18 10:44 ` Miquel Raynal
2024-05-19 3:13 ` [PATCH v2] mtd: rawnand: rockchip: ensure NVDDR timings are rejected Val Packett
2024-05-19 3:13 ` Val Packett
2024-05-19 3:13 ` Val Packett
2024-05-19 3:13 ` Val Packett
2024-05-27 12:14 ` Miquel Raynal
2024-05-27 12:14 ` Miquel Raynal
2024-05-27 12:14 ` Miquel Raynal
2024-05-27 12:14 ` Miquel Raynal
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=20240518033923.5577-2-val@packett.cool \
--to=val@packett.cool \
--cc=heiko@sntech.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=miquel.raynal@bootlin.com \
--cc=richard@nod.at \
--cc=sfr@canb.auug.org.au \
--cc=vigneshr@ti.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.