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 362043126B2 for ; Sun, 29 Mar 2026 13:18:49 +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=1774790330; cv=none; b=FAULSoNOt/wT6kb4OjOlTP5kWl/xWFbFb1RiuqcRaO76tfBiJWka03Xm/hJDmDEKL1kjnT6qqlikUKcUn2nAkMyZSFtScI6bu0Ht8vSbiuR0t8mJVQO3XkearH5zu2UmTk/Hj5vqxJSIXWMH4RcTw6AJzSW6v3H+N/1d+jddT0E= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774790330; c=relaxed/simple; bh=IgaaAYFjyAHiExrBs/4lOPoUrjMr2+EtBBo9h8K11CQ=; h=Subject:To:From:Date:Message-ID:MIME-Version:Content-Type; b=OjKzTjKACVA70wVBVl/47koCxUH5CoDLXIq+NPFtQJpRNe7yo4EPxbeNDPZPeFpoEOQNWgQMkBIlnHL311GbD+tOBViaDVWrKCErdub1eLaw9IWPTPbXna1bIv4eZjnpIOhoIv5XJV7VvqobhicdBm8mFO7EgQ7BdyNQkr6s1oY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=ncnKUrwF; 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="ncnKUrwF" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 584E5C116C6; Sun, 29 Mar 2026 13:18:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1774790329; bh=IgaaAYFjyAHiExrBs/4lOPoUrjMr2+EtBBo9h8K11CQ=; h=Subject:To:From:Date:From; b=ncnKUrwFd+XY3MxJ3Pn08VCtL7bVqCRPUsMX1A9u3HPEKDP1zkyZhJDOmlOhrvhe0 0C/ypirG2Gzz+YSnFjEHbMCRLfBDdG6xhTe3xmT3vJp9129umla+O+AD4OCUiqEkdO mmBX+hG+H2si0TZpV4FtW4DwC7gsVlrTkp0cWE60= Subject: patch "iio: gyro: mpu3050: Fix out-of-sequence free_irq()" added to char-misc-linus To: ethantidmore06@gmail.com,Jonathan.Cameron@huawei.com,Stable@vger.kernel.org,andriy.shevchenko@intel.com,jic23@kernel.org,linusw@kernel.org From: Date: Sun, 29 Mar 2026 14:50:12 +0200 Message-ID: <2026032912-unscented-gusto-7c46@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 This is a note to let you know that I've just added the patch titled iio: gyro: mpu3050: Fix out-of-sequence free_irq() to my char-misc git tree which can be found at git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc.git in the char-misc-linus branch. The patch will show up in the next release of the linux-next tree (usually sometime within the next 24 hours during the week.) The patch will hopefully also be merged in Linus's tree for the next -rc kernel release. If you have any questions about this process, please let me know. From d14116f6529fa085b1a1b1f224dc9604e4d2a29c Mon Sep 17 00:00:00 2001 From: Ethan Tidmore Date: Tue, 24 Feb 2026 16:48:18 -0600 Subject: iio: gyro: mpu3050: Fix out-of-sequence free_irq() The triggered buffer is initialized before the IRQ is requested. The removal path currently calls iio_triggered_buffer_cleanup() before free_irq(). This violates the expected LIFO. Place free_irq() in the correct location relative to iio_triggered_buffer_cleanup(). Fixes: 3904b28efb2c7 ("iio: gyro: Add driver for the MPU-3050 gyroscope") Suggested-by: Jonathan Cameron Reviewed-by: Linus Walleij Signed-off-by: Ethan Tidmore Reviewed-by: Andy Shevchenko Cc: Signed-off-by: Jonathan Cameron --- drivers/iio/gyro/mpu3050-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/gyro/mpu3050-core.c b/drivers/iio/gyro/mpu3050-core.c index 2e92daf047bd..d84e04e4b431 100644 --- a/drivers/iio/gyro/mpu3050-core.c +++ b/drivers/iio/gyro/mpu3050-core.c @@ -1278,9 +1278,9 @@ void mpu3050_common_remove(struct device *dev) pm_runtime_get_sync(dev); pm_runtime_put_noidle(dev); pm_runtime_disable(dev); - iio_triggered_buffer_cleanup(indio_dev); if (mpu3050->irq) free_irq(mpu3050->irq, mpu3050->trig); + iio_triggered_buffer_cleanup(indio_dev); mpu3050_power_down(mpu3050); } -- 2.53.0