linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 00/15] media: vimc: Add support for multiplanar formats
@ 2019-03-27 15:17 André Almeida
  2019-03-27 15:17 ` [PATCH v2 01/15] media: Move sp2mp functions to v4l2-common André Almeida
                   ` (14 more replies)
  0 siblings, 15 replies; 27+ messages in thread
From: André Almeida @ 2019-03-27 15:17 UTC (permalink / raw)
  To: linux-media
  Cc: mchehab, hverkuil, helen.koike, lucmaga, linux-kernel, kernel, lkcamp

Hello,

This series implements support for multiplane pixel formats at Vimc.
A lot of changes were required since vimc support for singleplane
was "hardcoded". The code has been adapted in order to support both
formats. When was possible, the functions were written generically,
avoiding functions for just one type of pixel format.

The debayer subdevice is the only one that currently doesn't supports
multiplanar formats. Documentation to each device will be made in a
future patch. In hardcoded topology, the exposed capture device
`RGB/YUV Capture` have a debayer in the pipeline, so it will fail when
tested with multiplanar formats.

The last commit of this series was tested using Hans' virtme.sh[1]
script here are the summary of results:

Grand Total for vivid device /dev/media0: 631, Succeeded: 631, Failed: 0, Warnings: 6
Grand Total for vivid device /dev/media1: 631, Succeeded: 631, Failed: 0, Warnings: 6
Grand Total for vim2m device /dev/media3: 61, Succeeded: 61, Failed: 0, Warnings: 0
Grand Total for vimc device /dev/media3: 478, Succeeded: 478, Failed: 0, Warnings: 0
Final Summary: 1801, Succeeded: 1801, Failed: 0, Warnings: 12

This patch depends on this one:

"[PATCH] media: vimc: propagate pixel format in the stream"

Thanks,
	André

[1] https://hverkuil.home.xs4all.nl/virtme/virtme.sh

Changes in v2:
- Fix typos
- Fix indentations
- Enhance v4l2_fmt_* documentation
- Change the order of commits, now the multiplanar parameter is the last
one with the commit to set the device capabilities
- Squash "unnecessary checks" commits together
- In v1, the whole media device was in singleplanar or in multiplanar
format. Now, each stream/pipeline can be in a format
- Check the capture capabilities to get if the stream is in
singleplanar/multiplanar mode, instead of checking the module parameter.
- Change `if (multiplanar)` to `if (IS_MULTIPLANAR(vcap))`
- Add a new commit to propagate in the stream if the capture device is
in multiplanar or singleplanar mode


André Almeida (15):
  media: Move sp2mp functions to v4l2-common
  media: vimc: Remove unnecessary stream checks
  media: vimc: cap: Change vimc_cap_device.format type
  media: vimc: cap: Dynamically define stream pixelformat
  media: vimc: cap: Add handler for singleplanar fmt ioctls
  media: vimc: cap: Add handler for multiplanar fmt ioctls
  media: vimc: cap: Add multiplanar formats
  media: vimc: cap: Add multiplanar default format
  media: vimc: cap: Allocate and verify mplanar buffers
  media: vimc: Propagate multiplanar state in the stream
  media: vimc: Add and use new struct vimc_frame
  media: vimc: sen: Add support for multiplanar formats
  media: vimc: sca: Add support for multiplanar formats
  media: vimc: cap: Add support for multiplanar formats
  media: vimc: Create multiplanar parameter

 drivers/media/platform/vimc/vimc-capture.c    | 351 +++++++++++++++---
 drivers/media/platform/vimc/vimc-common.c     |  36 ++
 drivers/media/platform/vimc/vimc-common.h     |  49 ++-
 drivers/media/platform/vimc/vimc-debayer.c    |  39 +-
 drivers/media/platform/vimc/vimc-scaler.c     | 128 ++++---
 drivers/media/platform/vimc/vimc-sensor.c     |  65 ++--
 drivers/media/platform/vimc/vimc-streamer.c   |   2 +-
 drivers/media/platform/vimc/vimc-streamer.h   |   3 +
 drivers/media/platform/vivid/vivid-vid-cap.c  |   6 +-
 .../media/platform/vivid/vivid-vid-common.c   |  59 ---
 .../media/platform/vivid/vivid-vid-common.h   |   9 -
 drivers/media/platform/vivid/vivid-vid-out.c  |   6 +-
 drivers/media/v4l2-core/v4l2-common.c         |  62 ++++
 include/media/v4l2-common.h                   |  37 ++
 14 files changed, 618 insertions(+), 234 deletions(-)

--
2.21.0


^ permalink raw reply	[flat|nested] 27+ messages in thread

end of thread, other threads:[~2019-04-16 15:17 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-27 15:17 [PATCH v2 00/15] media: vimc: Add support for multiplanar formats André Almeida
2019-03-27 15:17 ` [PATCH v2 01/15] media: Move sp2mp functions to v4l2-common André Almeida
2019-04-12 22:48   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 02/15] media: vimc: Remove unnecessary stream checks André Almeida
2019-04-12 22:48   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 03/15] media: vimc: cap: Change vimc_cap_device.format type André Almeida
2019-04-12 22:48   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 04/15] media: vimc: cap: Dynamically define stream pixelformat André Almeida
2019-04-12 22:48   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 05/15] media: vimc: cap: Add handler for singleplanar fmt ioctls André Almeida
2019-04-12 22:48   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 06/15] media: vimc: cap: Add handler for multiplanar " André Almeida
2019-03-27 15:17 ` [PATCH v2 07/15] media: vimc: cap: Add multiplanar formats André Almeida
2019-04-12 22:49   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 08/15] media: vimc: cap: Add multiplanar default format André Almeida
2019-04-12 22:49   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 09/15] media: vimc: cap: Allocate and verify mplanar buffers André Almeida
2019-04-12 22:49   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 10/15] media: vimc: Propagate multiplanar state in the stream André Almeida
2019-04-12 22:50   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 11/15] media: vimc: Add and use new struct vimc_frame André Almeida
2019-04-16 15:17   ` Helen Koike
2019-03-27 15:17 ` [PATCH v2 12/15] media: vimc: sen: Add support for multiplanar formats André Almeida
2019-03-27 15:17 ` [PATCH v2 13/15] media: vimc: sca: " André Almeida
2019-03-27 15:17 ` [PATCH v2 14/15] media: vimc: cap: " André Almeida
2019-03-27 15:17 ` [PATCH v2 15/15] media: vimc: Create multiplanar parameter André Almeida
2019-04-12 22:50   ` Helen Koike

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).