From: Sakari Ailus <sakari.ailus@iki.fi>
To: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
Linux Media Mailing List <linux-media@vger.kernel.org>,
David Plowman <david.plowman@raspberrypi.com>,
Naushir Patuck <naush@raspberrypi.com>,
Nick Hollinghurst <nick.hollinghurst@raspberrypi.org>,
Dave Stevenson <dave.stevenson@raspberrypi.com>,
Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>,
Kieran Bingham <kieran.bingham@ideasonboard.com>,
Hans Verkuil <hverkuil-cisco@xs4all.nl>,
Mauro Carvalho Chehab <mchehab@kernel.org>
Subject: Re: [PATCH v7 7/8] media: raspberrypi: Add support for PiSP BE
Date: Mon, 27 May 2024 12:43:37 +0000 [thread overview]
Message-ID: <ZlR_-VL7hy5_Hhe4@valkosipuli.retiisi.eu> (raw)
In-Reply-To: <6oiill244e4bb4zsdd5x7kzrw62x4pq6vfmps6offh5qvfniyr@4u4xi4fparbk>
Hi Jacopo,
On Mon, May 27, 2024 at 12:18:54PM +0200, Jacopo Mondi wrote:
> Hi Sakari, Laurent
>
> On Mon, May 27, 2024 at 06:44:25AM GMT, Sakari Ailus wrote:
> > Hi Laurent,
> >
> > On Mon, May 27, 2024 at 04:19:11AM +0300, Laurent Pinchart wrote:
> > > > One API-based solution could be moving the IOCTL interface to MC device
> > > > node only. This wouldn't be a small change so I'm not proposing doing that
> > > > now.
> > >
> > > I think we could also use the request API. It is a bit more cumbersome
> > > to use from a userspace point of view, but this driver is meant to be
> > > used from libcamera, so we can isolate applications from the extra
> > > burden.
> > >
> > > We will need to add support for formats in the request API (or rather
> > > for requests in the format ioctls).
> > >
> > > From a kernel point of view, the helpers used by the codec drivers may
> > > not be suitable for ISP drivers, but I don't think it would be very
> > > difficult to implement other helpers is needed, isolating the ISP driver
> > > from the complexity of the request API.
> > >
> > > This doesn't preclude developing a better userspace API with ioctls on
> > > the MC device node only at a later point. If the above-mentioned kernel
> > > helpers are done right, transitioning to a new userspace API will have
> > > minimal impact on drivers.
> >
> > This is indeed the third feasible option. I agree. The work on the
> > framework side might not be that much either.
> >
>
> For the time being, I would like to move forward and merge the version
> of the driver with a single enabled context.
>
> As you can see the driver multiples the contexts by creating two
> groups
>
> The number of groups is defined by
>
> /*
> * We want to support 2 independent instances allowing 2 simultaneous users
> * of the ISP-BE (of course they share hardware, platform resources and mutex).
> * Each such instance comprises a group of device nodes representing input
> * and output queues, and a media controller device node to describe them.
> */
> #define PISPBE_NUM_NODE_GROUPS 2
>
> Can I simply set this to 1 or should the driver be reworked to remove
> the group concept completely (it will be quite some rework).
>
> You can guess what my preference is, and considering we want to
> experiment with a different API the group part will possibily need to
> be reintroduced.
I believe you can also guess what my preference is. :-)
I don't expect we'll need the number of groups in the upstream driver.
Before deciding what to do here I'd like to arrive to a conclusion on how
this gets addressed so the desired functionality is available in the
upstream driver.
Maybe the Request API is indeed something to consider here.
I wonder what Laurent thinks.
>
> Also if we simply set PISPBE_NUM_NODE_GROUPS=1, the downstream RPi
> kernel will solely need to have 1 patch that restores the value to 2
> to be able to use the mainline kernel driver instead of keeping their
> multi-context downstream version in use until multi-context is
> finalized in mainline.
--
Kind regards,
Sakari Ailus
next prev parent reply other threads:[~2024-05-27 12:46 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-24 14:00 [PATCH v7 0/8] media: raspberrypi: Add support for PiSP Back End Jacopo Mondi
2024-05-24 14:00 ` [PATCH v7 1/8] media: uapi: pixfmt-luma: Document MIPI CSI-2 packing Jacopo Mondi
2024-05-24 14:00 ` [PATCH v7 2/8] media: uapi: Add a pixel format for BGR48 and RGB48 Jacopo Mondi
2024-05-24 14:00 ` [PATCH v7 3/8] media: uapi: Add Raspberry Pi PiSP Back End uAPI Jacopo Mondi
2024-05-24 14:00 ` [PATCH v7 4/8] media: uapi: Add meta pixel format for PiSP BE config Jacopo Mondi
2024-05-24 14:00 ` [PATCH v7 5/8] media: uapi: Add PiSP Compressed RAW Bayer formats Jacopo Mondi
2024-05-24 14:00 ` [PATCH v7 6/8] media: dt-bindings: Add bindings for Raspberry Pi PiSP Back End Jacopo Mondi
2024-05-24 14:00 ` [PATCH v7 7/8] media: raspberrypi: Add support for PiSP BE Jacopo Mondi
2024-05-26 20:59 ` Sakari Ailus
2024-05-27 1:19 ` Laurent Pinchart
2024-05-27 6:44 ` Sakari Ailus
2024-05-27 10:18 ` Jacopo Mondi
2024-05-27 12:43 ` Sakari Ailus [this message]
2024-05-27 15:39 ` Laurent Pinchart
2024-05-28 7:44 ` Jacopo Mondi
2024-05-27 7:56 ` Jacopo Mondi
2024-05-27 8:14 ` Sakari Ailus
2024-05-27 8:31 ` Laurent Pinchart
2024-05-27 8:45 ` Sakari Ailus
2024-05-27 10:55 ` Laurent Pinchart
2024-05-27 9:46 ` Jacopo Mondi
2024-05-24 14:00 ` [PATCH v7 8/8] media: admin-guide: Document the Raspberry Pi " Jacopo Mondi
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=ZlR_-VL7hy5_Hhe4@valkosipuli.retiisi.eu \
--to=sakari.ailus@iki.fi \
--cc=dave.stevenson@raspberrypi.com \
--cc=david.plowman@raspberrypi.com \
--cc=hverkuil-cisco@xs4all.nl \
--cc=jacopo.mondi@ideasonboard.com \
--cc=kieran.bingham@ideasonboard.com \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=naush@raspberrypi.com \
--cc=nick.hollinghurst@raspberrypi.org \
--cc=tomi.valkeinen@ideasonboard.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.