From: Greg Kroah-Hartman Date: Fri, 11 Aug 2023 15:30:38 +0000 (+0200) Subject: 5.4-stable patches X-Git-Tag: v4.14.323~76 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=cb0389131cd49f69cf72d20f3e4b6cb2e845fef4;p=thirdparty%2Fkernel%2Fstable-queue.git 5.4-stable patches added patches: ipv6-adjust-ndisc_is_useropt-to-also-return-true-for-pio.patch mmc-moxart-read-scr-register-without-changing-byte-order.patch series --- diff --git a/queue-5.4/ipv6-adjust-ndisc_is_useropt-to-also-return-true-for-pio.patch b/queue-5.4/ipv6-adjust-ndisc_is_useropt-to-also-return-true-for-pio.patch new file mode 100644 index 00000000000..cf5f393fff9 --- /dev/null +++ b/queue-5.4/ipv6-adjust-ndisc_is_useropt-to-also-return-true-for-pio.patch @@ -0,0 +1,57 @@ +From 048c796beb6eb4fa3a5a647ee1c81f5c6f0f6a2a Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Maciej=20=C5=BBenczykowski?= +Date: Mon, 7 Aug 2023 03:25:32 -0700 +Subject: ipv6: adjust ndisc_is_useropt() to also return true for PIO +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: Maciej Żenczykowski + +commit 048c796beb6eb4fa3a5a647ee1c81f5c6f0f6a2a upstream. + +The upcoming (and nearly finalized): + https://datatracker.ietf.org/doc/draft-collink-6man-pio-pflag/ +will update the IPv6 RA to include a new flag in the PIO field, +which will serve as a hint to perform DHCPv6-PD. + +As we don't want DHCPv6 related logic inside the kernel, this piece of +information needs to be exposed to userspace. The simplest option is to +simply expose the entire PIO through the already existing mechanism. + +Even without this new flag, the already existing PIO R (router address) +flag (from RFC6275) cannot AFAICT be handled entirely in kernel, +and provides useful information that should be exposed to userspace +(the router's global address, for use by Mobile IPv6). + +Also cc'ing stable@ for inclusion in LTS, as while technically this is +not quite a bugfix, and instead more of a feature, it is absolutely +trivial and the alternative is manually cherrypicking into all Android +Common Kernel trees - and I know Greg will ask for it to be sent in via +LTS instead... + +Cc: Jen Linkova +Cc: Lorenzo Colitti +Cc: David Ahern +Cc: YOSHIFUJI Hideaki / 吉藤英明 +Cc: stable@vger.kernel.org +Signed-off-by: Maciej Żenczykowski +Link: https://lore.kernel.org/r/20230807102533.1147559-1-maze@google.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Greg Kroah-Hartman +--- + net/ipv6/ndisc.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +--- a/net/ipv6/ndisc.c ++++ b/net/ipv6/ndisc.c +@@ -196,7 +196,8 @@ static struct nd_opt_hdr *ndisc_next_opt + static inline int ndisc_is_useropt(const struct net_device *dev, + struct nd_opt_hdr *opt) + { +- return opt->nd_opt_type == ND_OPT_RDNSS || ++ return opt->nd_opt_type == ND_OPT_PREFIX_INFO || ++ opt->nd_opt_type == ND_OPT_RDNSS || + opt->nd_opt_type == ND_OPT_DNSSL || + opt->nd_opt_type == ND_OPT_CAPTIVE_PORTAL || + ndisc_ops_is_useropt(dev, opt->nd_opt_type); diff --git a/queue-5.4/mmc-moxart-read-scr-register-without-changing-byte-order.patch b/queue-5.4/mmc-moxart-read-scr-register-without-changing-byte-order.patch new file mode 100644 index 00000000000..569295664d0 --- /dev/null +++ b/queue-5.4/mmc-moxart-read-scr-register-without-changing-byte-order.patch @@ -0,0 +1,44 @@ +From d44263222134b5635932974c6177a5cba65a07e8 Mon Sep 17 00:00:00 2001 +From: Sergei Antonov +Date: Tue, 27 Jun 2023 15:05:49 +0300 +Subject: mmc: moxart: read scr register without changing byte order + +From: Sergei Antonov + +commit d44263222134b5635932974c6177a5cba65a07e8 upstream. + +Conversion from big-endian to native is done in a common function +mmc_app_send_scr(). Converting in moxart_transfer_pio() is extra. +Double conversion on a LE system returns an incorrect SCR value, +leads to errors: + +mmc0: unrecognised SCR structure version 8 + +Fixes: 1b66e94e6b99 ("mmc: moxart: Add MOXA ART SD/MMC driver") +Signed-off-by: Sergei Antonov +Cc: Jonas Jensen +Cc: stable@vger.kernel.org +Link: https://lore.kernel.org/r/20230627120549.2400325-1-saproj@gmail.com +Signed-off-by: Ulf Hansson +Signed-off-by: Greg Kroah-Hartman +--- + drivers/mmc/host/moxart-mmc.c | 8 +------- + 1 file changed, 1 insertion(+), 7 deletions(-) + +--- a/drivers/mmc/host/moxart-mmc.c ++++ b/drivers/mmc/host/moxart-mmc.c +@@ -339,13 +339,7 @@ static void moxart_transfer_pio(struct m + return; + } + for (len = 0; len < remain && len < host->fifo_width;) { +- /* SCR data must be read in big endian. */ +- if (data->mrq->cmd->opcode == SD_APP_SEND_SCR) +- *sgp = ioread32be(host->base + +- REG_DATA_WINDOW); +- else +- *sgp = ioread32(host->base + +- REG_DATA_WINDOW); ++ *sgp = ioread32(host->base + REG_DATA_WINDOW); + sgp++; + len += 4; + } diff --git a/queue-5.4/series b/queue-5.4/series new file mode 100644 index 00000000000..f65cf6ae0cb --- /dev/null +++ b/queue-5.4/series @@ -0,0 +1,2 @@ +mmc-moxart-read-scr-register-without-changing-byte-order.patch +ipv6-adjust-ndisc_is_useropt-to-also-return-true-for-pio.patch