From: Hans Verkuil <hverkuil+cisco@kernel.org>
To: Jacopo Mondi <jacopo.mondi@ideasonboard.com>,
Andy Walls <awalls@md.metrocast.net>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Cc: Dan Carpenter <dan.carpenter@linaro.org>,
stable@vger.kernel.org, linux-media@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 0/2] media: pci: Fix invalid access to file *
Date: Tue, 14 Oct 2025 09:05:20 +0200 [thread overview]
Message-ID: <0627cfba-798a-482b-b335-cc78a609c150@kernel.org> (raw)
In-Reply-To: <20250819-cx18-v4l2-fh-v4-0-9db1635d6787@ideasonboard.com>
Hi Jacopo,
On 19/08/2025 09:07, Jacopo Mondi wrote:
> Since commits
> 7b9eb53e8591 ("media: cx18: Access v4l2_fh from file")
> 9ba9d11544f9 ("media: ivtv: Access v4l2_fh from file")
>
> All the ioctl handlers access their private data structures
> from file *
>
> The ivtv and cx18 drivers call the ioctl handlers from their
> DVB layer without a valid file *, causing invalid memory access.
>
> The issue has been reported by smatch in
> "[bug report] media: cx18: Access v4l2_fh from file"
>
> Fix this by providing wrappers for the ioctl handlers to be
> used by the DVB layer that do not require a valid file *.
This series should go to the fixes branch for v6.18, right?
This looks like a pure regression, so I think that makes sense.
BTW, why is there a Link: tag in the cx18 patch? It just links to
the v1 of the patch and that doesn't add meaningful information.
Linus likes Link:, but only if it really adds useful information.
Regards,
Hans
>
> Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
> ---
> Changes in v4:
> - Slightly adjust commit messages
> - Link to v3: https://lore.kernel.org/r/20250818-cx18-v4l2-fh-v3-0-5e2f08f3cadc@ideasonboard.com
>
> Changes in v3:
> - Change helpers to accept the type they're going to operate on instead
> of using the open_id wrapper type as suggested by Laurent
> - Link to v2: https://lore.kernel.org/r/20250818-cx18-v4l2-fh-v2-0-3f53ce423663@ideasonboard.com
>
> Changes in v2:
> - Add Cc: stable@vger.kernel.org per-patch
>
> ---
> Jacopo Mondi (2):
> media: cx18: Fix invalid access to file *
> media: ivtv: Fix invalid access to file *
>
> drivers/media/pci/cx18/cx18-driver.c | 9 +++------
> drivers/media/pci/cx18/cx18-ioctl.c | 30 +++++++++++++++++++-----------
> drivers/media/pci/cx18/cx18-ioctl.h | 8 +++++---
> drivers/media/pci/ivtv/ivtv-driver.c | 11 ++++-------
> drivers/media/pci/ivtv/ivtv-ioctl.c | 22 +++++++++++++++++-----
> drivers/media/pci/ivtv/ivtv-ioctl.h | 6 ++++--
> 6 files changed, 52 insertions(+), 34 deletions(-)
> ---
> base-commit: a75b8d198c55e9eb5feb6f6e155496305caba2dc
> change-id: 20250818-cx18-v4l2-fh-7eaa6199fdde
>
> Best regards,
next prev parent reply other threads:[~2025-10-14 7:05 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-19 7:07 [PATCH v4 0/2] media: pci: Fix invalid access to file * Jacopo Mondi
2025-08-19 7:07 ` [PATCH v4 1/2] media: cx18: " Jacopo Mondi
2025-10-14 12:53 ` Hans Verkuil
2025-08-19 7:07 ` [PATCH v4 2/2] media: ivtv: " Jacopo Mondi
2025-10-14 12:34 ` Hans Verkuil
2025-10-14 7:05 ` Hans Verkuil [this message]
2025-10-14 11:52 ` [PATCH v4 0/2] media: pci: " Jacopo Mondi
2025-10-14 11:57 ` Hans Verkuil
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=0627cfba-798a-482b-b335-cc78a609c150@kernel.org \
--to=hverkuil+cisco@kernel.org \
--cc=awalls@md.metrocast.net \
--cc=dan.carpenter@linaro.org \
--cc=jacopo.mondi@ideasonboard.com \
--cc=laurent.pinchart+renesas@ideasonboard.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=stable@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox