Skip to content

Conversation

6by9
Copy link
Contributor

@6by9 6by9 commented Jul 7, 2020

Adds a couple of controls and fixups for imx290 to make compliance and libcamera happy.

A couple of minor fixes for bcm2835_unicam for compliance failures.

NB If you wish to run v4l2-compliance with the current latest version, you need to disable the failure on not getting cache hints in setupMmap

		if (cache_hints) {
			fail_on_test(!(flags & V4L2_BUF_FLAG_NO_CACHE_INVALIDATE));
			fail_on_test(!(flags & V4L2_BUF_FLAG_NO_CACHE_CLEAN));
		} else {
			// Disable these two failure cases.
			//fail_on_test(flags & V4L2_BUF_FLAG_NO_CACHE_INVALIDATE);
			//fail_on_test(flags & V4L2_BUF_FLAG_NO_CACHE_CLEAN);
		}

I've just raised this on linux-media and they expect v4l2-compliance to be run against https://git.linuxtv.org/media_tree.git/ master branch only, and that has introduced some cache flushing flags that these two test the results of.

6by9 added 5 commits July 7, 2020 15:11
__v4l2_ctrl_modify_range only updates the current value should
it be invalid within the new range. That can leave modes producing
odd frame rates.

Explicitly update the HBLANK and VBLANK values so that on mode
change we revert to the default frame rate for the mode.

Signed-off-by: Dave Stevenson <[email protected]>
Userspace needs to know the cropping arrangements for each mode,
so expose this through g_selection.

Signed-off-by: Dave Stevenson <[email protected]>
The colorspace fields were left untouched in imx290_set_fmt
which lead to a v4l2-compliance failure.

Signed-off-by: Dave Stevenson <[email protected]>
v4l2-compliance throws a failure if the device doesn't advertise
V4L2_CAP_READWRITE but allows read or write operations.
We do support read, so reinstate the flag.

Signed-off-by: Dave Stevenson <[email protected]>
[g|s]_selection pass in a buffer type that needs to be validated
before passing on to the sensor subdev.

Signed-off-by: Dave Stevenson <[email protected]>
@6by9
Copy link
Contributor Author

6by9 commented Jul 7, 2020

@naushir More reviewing please.

@pelwell pelwell merged commit 006c056 into raspberrypi:rpi-5.4.y Jul 8, 2020
@6by9
Copy link
Contributor Author

6by9 commented Jul 10, 2020

NB If you wish to run v4l2-compliance with the current latest version, you need to disable the failure on not getting cache hints in setupMmap

Fixed in v4l2-compliance. It now does a kernel version check as the caching caps will only appear in 5.9.

@naushir
Copy link
Contributor

naushir commented Jul 10, 2020

This review fell off my radar, sorry about that. I know it's already merged, but changes all look good to me.

popcornmix added a commit to raspberrypi/firmware that referenced this pull request Jul 13, 2020
kernel: vc4_hdmi: Support HBR audio
See: raspberrypi/linux#3717

kernel: OV7251 overlay and defconfig
See: raspberrypi/linux#3714

kernel: Imx290 & unicam v4l2-compliance fixes
See: raspberrypi/linux#3712

kernel: Enhances the DAC+ driver to control the optional headphone amplifier
See: raspberrypi/linux#3711

kernel: OV9281 driver and overlay
See: raspberrypi/linux#3709

kernel: dtoverlays: Fixup imx219 and imx477 overlays due to parsing failures
See: raspberrypi/linux#3706

kernel: FKMS: max refresh rate and blocking 1366x768
See: raspberrypi/linux#3704

kernel: Fix lockups and IRQ jitter on multicore RasPis
See: raspberrypi/linux#3703

kernel: dts: Further simplify firmware clocks
See: raspberrypi/linux#3609

kernel: configs: Add CAN_EMS_USB=m
See: raspberrypi/linux#3716

kernel: configs: Enable CONFIG_BLK_DEV_NVME=m

kernel: ARM: dts: Make bcm2711 dts more like 5.7

firmware: arm_loader: Don't enable the ARM USB IRQ
See: raspberrypi/linux#3703

firmware: hdmi: Remove M2MC/BVB min turbo clock request
popcornmix added a commit to Hexxeh/rpi-firmware that referenced this pull request Jul 13, 2020
kernel: vc4_hdmi: Support HBR audio
See: raspberrypi/linux#3717

kernel: OV7251 overlay and defconfig
See: raspberrypi/linux#3714

kernel: Imx290 & unicam v4l2-compliance fixes
See: raspberrypi/linux#3712

kernel: Enhances the DAC+ driver to control the optional headphone amplifier
See: raspberrypi/linux#3711

kernel: OV9281 driver and overlay
See: raspberrypi/linux#3709

kernel: dtoverlays: Fixup imx219 and imx477 overlays due to parsing failures
See: raspberrypi/linux#3706

kernel: FKMS: max refresh rate and blocking 1366x768
See: raspberrypi/linux#3704

kernel: Fix lockups and IRQ jitter on multicore RasPis
See: raspberrypi/linux#3703

kernel: dts: Further simplify firmware clocks
See: raspberrypi/linux#3609

kernel: configs: Add CAN_EMS_USB=m
See: raspberrypi/linux#3716

kernel: configs: Enable CONFIG_BLK_DEV_NVME=m

kernel: ARM: dts: Make bcm2711 dts more like 5.7

firmware: arm_loader: Don't enable the ARM USB IRQ
See: raspberrypi/linux#3703

firmware: hdmi: Remove M2MC/BVB min turbo clock request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants