-
Notifications
You must be signed in to change notification settings - Fork 5.2k
drivers: bcm2835_unicam: Disable trigger mode operation #4834
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@6by9, this does seem to be a valid fix for the pink frames (fingers crossed)! |
Only question is do we disable this selectively based on a dt config? Ideally I would hope we can disable this globally. |
@@ -983,11 +983,6 @@ static irqreturn_t unicam_isr(int irq, void *dev) | |||
} | |||
} | |||
|
|||
if (reg_read(unicam, UNICAM_ICTL) & UNICAM_FCM) { | |||
/* Switch out of trigger mode if selected */ | |||
reg_write_field(unicam, UNICAM_ICTL, 1, UNICAM_TFC); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To someone who knows nothing about the subject matter, the 1
here is unexpected.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's hitting the trigger bit in the ICTL register. It's using UNICAM_TFC as the bitmask.
I see little reason not to disable it globally. Typo in commit message "firmeare", but otherwise I'm happy. Possibly worth pinging Laurent et al about this patch as they are upstreaming Unicam. |
On a Pi3 B/B+ platform the imx219 sensor frequently generates a single corrupt frame when the sensor first starts. This can either be a missing line, or invalid samples within the line. This only occurrs using the Unicam kernel driver. Disabling trigger mode elimiates this corruption. Since trigger mode is a legacy feature copied from the firmware driver and not expected to be needed, remove it. Tested on the Raspberry Pi cameras and shows no ill effects. Signed-off-by: Naushir Patuck <[email protected]>
Yes, I will ping Laurent and co. about this commit. |
See: raspberrypi/linux#4845 kernel: drm/vc4_hdmi: Add Broadcast RGB property to allow override of RGB range See: raspberrypi/linux#4850 kernel: Update rpi-display overlay See: raspberrypi/linux#4841 kernel: ARM: dts: BCM2711 AON_INTR2 generates IRQ edges See: raspberrypi/linux#4838 kernel: drivers: bcm2835_unicam: Disable trigger mode operation See: raspberrypi/linux#4834 kernel: random: fix crash on multiple early calls to add_bootloader_randomness See: raspberrypi/linux#4829
See: raspberrypi/linux#4845 kernel: drm/vc4_hdmi: Add Broadcast RGB property to allow override of RGB range See: raspberrypi/linux#4850 kernel: Update rpi-display overlay See: raspberrypi/linux#4841 kernel: ARM: dts: BCM2711 AON_INTR2 generates IRQ edges See: raspberrypi/linux#4838 kernel: drivers: bcm2835_unicam: Disable trigger mode operation See: raspberrypi/linux#4834 kernel: random: fix crash on multiple early calls to add_bootloader_randomness See: raspberrypi/linux#4829
On a Pi3 B/B+ platform the imx219 sensor frequently generates a single corrupt
frame when the sensor first starts. This can either be a missing line, or
invalid samples within the line. This only occurrs using the Unicam kernel
driver.
Disabling trigger mode elimiates this corruption. Since trigger mode is a
legacy feature copied from the firmeare driver and not expected to be needed,
remove it. Tested on the Raspberry Pi cameras and shows no ill effects.
Signed-off-by: Naushir Patuck [email protected]