[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Ymp98LBQySvpz8/j@aptenodytes>
Date: Thu, 28 Apr 2022 13:43:44 +0200
From: Paul Kocialkowski <paul.kocialkowski@...tlin.com>
To: Maxime Ripard <maxime@...no.tech>
Cc: Jernej Škrabec <jernej.skrabec@...il.com>,
linux-kernel@...r.kernel.org, linux-media@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, linux-sunxi@...ts.linux.dev,
Yong Deng <yong.deng@...ewell.com>,
Mauro Carvalho Chehab <mchehab@...nel.org>,
Chen-Yu Tsai <wens@...e.org>,
Samuel Holland <samuel@...lland.org>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>,
Thomas Petazzoni <thomas.petazzoni@...tlin.com>
Subject: Re: [PATCH v4 43/45] media: sun6i-csi: Detect the availability of
the ISP
Hi Maxime,
On Thu 28 Apr 22, 10:11, Maxime Ripard wrote:
> On Thu, Apr 28, 2022 at 09:55:56AM +0200, Paul Kocialkowski wrote:
> > Hi Jernej,
> >
> > Thanks a lot for all your reviews!
> >
> > On Wed 27 Apr 22, 22:07, Jernej Škrabec wrote:
> > > Dne petek, 15. april 2022 ob 17:28:09 CEST je Paul Kocialkowski napisal(a):
> > > > Add a helper to detect whether the ISP is available and connected
> > > > and store the indication in a driver-wide variable.
> > > >
> > > > Signed-off-by: Paul Kocialkowski <paul.kocialkowski@...tlin.com>
> > > > ---
> > > > .../platform/sunxi/sun6i-csi/sun6i_csi.c | 33 +++++++++++++++++++
> > > > .../platform/sunxi/sun6i-csi/sun6i_csi.h | 3 ++
> > > > 2 files changed, 36 insertions(+)
> > > >
> > > > diff --git a/drivers/media/platform/sunxi/sun6i-csi/sun6i_csi.c
> > > > b/drivers/media/platform/sunxi/sun6i-csi/sun6i_csi.c index
> > > > a88deb8ba1e7..f185cbd113c7 100644
> > > > --- a/drivers/media/platform/sunxi/sun6i-csi/sun6i_csi.c
> > > > +++ b/drivers/media/platform/sunxi/sun6i-csi/sun6i_csi.c
> > > > @@ -25,6 +25,35 @@
> > > > #include "sun6i_csi_capture.h"
> > > > #include "sun6i_csi_reg.h"
> > > >
> > > > +/* ISP */
> > > > +
> > > > +static bool sun6i_csi_isp_detect(struct sun6i_csi_device *csi_dev)
> > > > +{
> > > > + struct device *dev = csi_dev->dev;
> > > > + struct fwnode_handle *handle = NULL;
> > > > +
> > > > + /* ISP is not available if disabled in kernel config. */
> > > > + if (!IS_ENABLED(CONFIG_VIDEO_SUN6I_ISP))
> > >
> > > Where is this symbol defined?
> >
> > That is defined through Kconfig's auto-generated header, from the associated
> > option for the ISP driver. It is defined in the ISP support series so this
> > will effectively always be false for now.
>
> Can the ISP be compiled as a module, but the CSI driver built-in?
I think so yes, I don't see any reason why not.
> If so,
> that would create a dependency from the kernel image to a module, which
> won't compile.
I think this would introduce a run-time dependency (sun6i-csi needing sun6i-isp
in order to register) but I don't understand why it wouldn't compile though.
Could you ellaborate a bit?
Thanks!
Paul
--
Paul Kocialkowski, Bootlin
Embedded Linux and kernel engineering
https://bootlin.com
Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)
Powered by blists - more mailing lists