From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8C2EA2E8DEF for ; Mon, 4 May 2026 08:46:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777884373; cv=none; b=Cwi9lI0EVdT4ks91zqXEh1MTSZeD67lorpIA2QdnHCC+zFrUDFe8s/N5BgSuZQ2xfOiu7NSoemiqGi50I7Pm/a4eug/iIUvRa546ivUE4MPGhZaQ7+0V/5+TO+sGjqyJCFfcTRl+07Sj41rLqSxYtzBl9vkRGnos+wtYcuLuZYU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1777884373; c=relaxed/simple; bh=6EcDAu4wV6uuKvoFm8q5194ELme8scE+u8O/Goq79Z0=; h=Subject:To:Cc:From:Date:Message-ID:MIME-Version:Content-Type; b=GMo5XBzIvp0FijjwBZ8eeCEN/8RDyvkBx3xxn3V4kQIpr4UinJnBuj78y/nZk14rFwQc90bhaQKyXMRnMs5VkzvVw/vM7BPC2blE8yDoNz8ZxyqPi8c7cXqlQxrZJYk+vnDHTDKTMHDM6D4GvX+1V0Xf2azAdWcbbG7cvVfBQXc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=PFNX4RPU; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="PFNX4RPU" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 24981C2BCB8; Mon, 4 May 2026 08:46:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1777884373; bh=6EcDAu4wV6uuKvoFm8q5194ELme8scE+u8O/Goq79Z0=; h=Subject:To:Cc:From:Date:From; b=PFNX4RPUrLUcm09MUU+SHFdqw2LZEBSccp8oWxdxpsqOQ9eIyAonPngV3WJXqJOfk BYmW/rY9jC/yRRAmEwPNkIaLMVz56Kf+nqsDENg76Hxd5o4r4Wz0NHZ/g5bbshnFU5 OTxqbyI78X1+8q0QzsGJ+7FFzONkEYxkFR7P3Ljc= Subject: FAILED: patch "[PATCH] can: ucan: fix devres lifetime" failed to apply to 5.15-stable tree To: johan@kernel.org,jakob.unterwurzacher@theobroma-systems.com,mkl@pengutronix.de Cc: From: Date: Mon, 04 May 2026 10:46:11 +0200 Message-ID: <2026050411-monsoon-twitch-7df9@gregkh> Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit The patch below does not apply to the 5.15-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . To reproduce the conflict and resubmit, you may use the following commands: git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-5.15.y git checkout FETCH_HEAD git cherry-pick -x fed4626501c871890da287bec62a96e52da1af89 # git commit -s git send-email --to '' --in-reply-to '2026050411-monsoon-twitch-7df9@gregkh' --subject-prefix 'PATCH 5.15.y' HEAD^.. Possible dependencies: thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From fed4626501c871890da287bec62a96e52da1af89 Mon Sep 17 00:00:00 2001 From: Johan Hovold Date: Fri, 27 Mar 2026 11:45:20 +0100 Subject: [PATCH] can: ucan: fix devres lifetime USB drivers bind to USB interfaces and any device managed resources should have their lifetime tied to the interface rather than parent USB device. This avoids issues like memory leaks when drivers are unbound without their devices being physically disconnected (e.g. on probe deferral or configuration changes). Fix the control message buffer lifetime so that it is released on driver unbind. Fixes: 9f2d3eae88d2 ("can: ucan: add driver for Theobroma Systems UCAN devices") Cc: stable@vger.kernel.org # 4.19 Cc: Jakob Unterwurzacher Signed-off-by: Johan Hovold Link: https://patch.msgid.link/20260327104520.1310158-1-johan@kernel.org Signed-off-by: Marc Kleine-Budde diff --git a/drivers/net/can/usb/ucan.c b/drivers/net/can/usb/ucan.c index 0ea0ac75e42f..ee3c1abbd063 100644 --- a/drivers/net/can/usb/ucan.c +++ b/drivers/net/can/usb/ucan.c @@ -1397,7 +1397,7 @@ static int ucan_probe(struct usb_interface *intf, */ /* Prepare Memory for control transfers */ - ctl_msg_buffer = devm_kzalloc(&udev->dev, + ctl_msg_buffer = devm_kzalloc(&intf->dev, sizeof(union ucan_ctl_payload), GFP_KERNEL); if (!ctl_msg_buffer) {