From: Greg Kroah-Hartman Date: Mon, 12 Aug 2024 14:04:34 +0000 (+0200) Subject: 6.6-stable patches X-Git-Tag: v6.1.105~50 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4e2101e3f9588fd2de3456377e4d34730a0e4df8;p=thirdparty%2Fkernel%2Fstable-queue.git 6.6-stable patches added patches: block-use-the-right-type-for-stub-rq_integrity_vec.patch mptcp-pm-deny-endp-with-signal-subflow-port.patch --- diff --git a/queue-6.6/block-use-the-right-type-for-stub-rq_integrity_vec.patch b/queue-6.6/block-use-the-right-type-for-stub-rq_integrity_vec.patch new file mode 100644 index 00000000000..9fe721d3d57 --- /dev/null +++ b/queue-6.6/block-use-the-right-type-for-stub-rq_integrity_vec.patch @@ -0,0 +1,31 @@ +From 69b6517687a4b1fb250bd8c9c193a0a304c8ba17 Mon Sep 17 00:00:00 2001 +From: Jens Axboe +Date: Wed, 26 Jun 2024 19:01:58 -0600 +Subject: block: use the right type for stub rq_integrity_vec() + +From: Jens Axboe + +commit 69b6517687a4b1fb250bd8c9c193a0a304c8ba17 upstream. + +For !CONFIG_BLK_DEV_INTEGRITY, rq_integrity_vec() wasn't updated +properly. Fix it up. + +Fixes: cf546dd289e0 ("block: change rq_integrity_vec to respect the iterator") +Signed-off-by: Jens Axboe +Cc: Matthieu Baerts +Signed-off-by: Greg Kroah-Hartman +--- + include/linux/blk-integrity.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/include/linux/blk-integrity.h ++++ b/include/linux/blk-integrity.h +@@ -175,7 +175,7 @@ static inline int blk_integrity_rq(struc + return 0; + } + +-static inline struct bio_vec *rq_integrity_vec(struct request *rq) ++static inline struct bio_vec rq_integrity_vec(struct request *rq) + { + /* the optimizer will remove all calls to this function */ + return (struct bio_vec){ }; diff --git a/queue-6.6/mptcp-pm-deny-endp-with-signal-subflow-port.patch b/queue-6.6/mptcp-pm-deny-endp-with-signal-subflow-port.patch new file mode 100644 index 00000000000..87a0da32da4 --- /dev/null +++ b/queue-6.6/mptcp-pm-deny-endp-with-signal-subflow-port.patch @@ -0,0 +1,43 @@ +From 8af1f11865f259c882cce71d32f85ee9004e2660 Mon Sep 17 00:00:00 2001 +From: "Matthieu Baerts (NGI0)" +Date: Wed, 31 Jul 2024 13:05:54 +0200 +Subject: mptcp: pm: deny endp with signal + subflow + port + +From: Matthieu Baerts (NGI0) + +commit 8af1f11865f259c882cce71d32f85ee9004e2660 upstream. + +As mentioned in the 'Fixes' commit, the port flag is only supported by +the 'signal' flag, and not by the 'subflow' one. Then if both the +'signal' and 'subflow' flags are set, the problem is the same: the +feature cannot work with the 'subflow' flag. + +Technically, if both the 'signal' and 'subflow' flags are set, it will +be possible to create the listening socket, but not to establish a +subflow using this source port. So better to explicitly deny it, not to +create some confusions because the expected behaviour is not possible. + +Fixes: 09f12c3ab7a5 ("mptcp: allow to use port and non-signal in set_flags") +Cc: stable@vger.kernel.org +Reviewed-by: Mat Martineau +Signed-off-by: Matthieu Baerts (NGI0) +Link: https://patch.msgid.link/20240731-upstream-net-20240731-mptcp-endp-subflow-signal-v1-2-c8a9b036493b@kernel.org +Signed-off-by: Jakub Kicinski +Signed-off-by: Greg Kroah-Hartman +--- + net/mptcp/pm_netlink.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +--- a/net/mptcp/pm_netlink.c ++++ b/net/mptcp/pm_netlink.c +@@ -1359,8 +1359,8 @@ static int mptcp_nl_cmd_add_addr(struct + if (ret < 0) + return ret; + +- if (addr.addr.port && !(addr.flags & MPTCP_PM_ADDR_FLAG_SIGNAL)) { +- GENL_SET_ERR_MSG(info, "flags must have signal when using port"); ++ if (addr.addr.port && !address_use_port(&addr)) { ++ GENL_SET_ERR_MSG(info, "flags must have signal and not subflow when using port"); + return -EINVAL; + } + diff --git a/queue-6.6/series b/queue-6.6/series index 8b10a5965ea..097c3ddd3d9 100644 --- a/queue-6.6/series +++ b/queue-6.6/series @@ -167,3 +167,5 @@ drm-radeon-remove-__counted_by-from-statearray.states.patch mptcp-fully-established-after-add_addr-echo-on-mpj.patch mptcp-pm-fix-backup-support-in-signal-endpoints.patch selftests-mptcp-fix-error-path.patch +mptcp-pm-deny-endp-with-signal-subflow-port.patch +block-use-the-right-type-for-stub-rq_integrity_vec.patch