From: Hidenori Kobayashi <hidenorik@chromium.org>
To: Dan Carpenter <dan.carpenter@linaro.org>
Cc: Sakari Ailus <sakari.ailus@linux.intel.com>,
Bingbu Cao <bingbu.cao@intel.com>,
Tianshu Qiu <tian.shu.qiu@intel.com>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-media@vger.kernel.org, linux-staging@lists.linux.dev,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] media: staging: ipu3-imgu: Set fields before media_entity_pads_init()
Date: Fri, 5 Jan 2024 11:19:23 +0900 [thread overview]
Message-ID: <20240105021856.wpzmwtyzxzqfznrp@google.com> (raw)
In-Reply-To: <27f1c487-78cc-4e56-ba79-1434aba131fd@moroto.mountain>
On Thu, Jan 04, 2024 at 01:04:27PM +0300, Dan Carpenter wrote:
> On Thu, Dec 28, 2023 at 06:39:25PM +0900, Hidenori Kobayashi wrote:
> > The pad's flags is checked in media_entity_pads_init(), so it has to be
> > initialized beforehand. The ops initialization is also moved together
> > for readability.
> >
>
> How does this bug look like to a user? What is the Fixes tag? Does
> this need to be backported to stable?
I suppose I should have included those in the commit message.
1) To a user, the imgu driver fails to probe with the following message:
[ 14.596315] ipu3-imgu 0000:00:05.0: failed initialize subdev media entity (-22)
[ 14.596322] ipu3-imgu 0000:00:05.0: failed to register subdev0 ret (-22)
[ 14.596327] ipu3-imgu 0000:00:05.0: failed to register pipes (-22)
[ 14.596331] ipu3-imgu 0000:00:05.0: failed to create V4L2 devices (-22)
2) Re Fixes tag, I see that the first commit of imgu driver already
initializes the flags after media_entity_pads_init(). The documentation
of this API ( "Drivers must set the direction of every pad ... before
calling media_entity_pads_init") predates the first commit. So, I guess
Fixes: a0ca1627b450 ("media: staging/intel-ipu3: Add v4l2 driver based on media framework")
3) Re stable, I was not sure. The probe failure only appears after a
check was added by Commit deb866f9e3a45ae058b21765feeffae6aea6a193. That
check is not in linux-6.6.y branch. So I was not sure if this counts as
"a real bug that bothers people" mentioned in the document.
With the above, how does the following sounds to you?
The imgu driver fails to probe because it does not set the pad's flags
before calling media_entity_pads_init(). Fix the initialization order so
that the driver probe succeeds. The ops initialization is also moved
together for readability.
Fixes: a0ca1627b450 ("media: staging/intel-ipu3: Add v4l2 driver based on media framework")
Thanks for the guidance,
Hidenori
next prev parent reply other threads:[~2024-01-05 2:19 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-28 9:39 [PATCH] media: staging: ipu3-imgu: Set fields before media_entity_pads_init() Hidenori Kobayashi
2024-01-04 10:04 ` Dan Carpenter
2024-01-05 2:19 ` Hidenori Kobayashi [this message]
2024-01-05 7:34 ` Dan Carpenter
2024-01-08 8:59 ` Sakari Ailus
2024-01-09 3:27 ` Hidenori Kobayashi
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=20240105021856.wpzmwtyzxzqfznrp@google.com \
--to=hidenorik@chromium.org \
--cc=bingbu.cao@intel.com \
--cc=dan.carpenter@linaro.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=mchehab@kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=tian.shu.qiu@intel.com \
/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;
as well as URLs for NNTP newsgroup(s).