- Jun 18, 2020
-
-
Dave Stevenson authored
"87f3ab94 media: ov5647: Add basic support for multiple sensor modes." added a return path ov5647_set_fmt that didn't release the device mutex that it had claimed. Release the mutex. Signed-off-by:
Dave Stevenson <dave.stevenson@raspberrypi.com>
-
Dave Stevenson authored
In order to apply lens shading correctly the client needs to know how each mode crops or scales the image compared to the full sensor array. Implement this (based on the imx219 equivalent). Signed-off-by:
Dave Stevenson <dave.stevenson@raspberrypi.com>
-
David Plowman authored
Specifically: * AWB is now off by default. * AEC/AGC is also off by default. * The default mode is changed to the 10-bit 2x2 binned mode. AWB and AEC/AGC can be re-enabled using the usual V4L2 controls. The original 8-bit mode will be respected if an application requests the 8-bit format. Signed-off-by:
David Plowman <david.plowman@raspberrypi.com> Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
David Plowman authored
The 8-bit VGA mode remains, we add the following 10-bit modes: Mode 0: 2592x1944 full resolution. Mode 1: 1920x1080 full resolution, but centre-cropped. (This mode achieves 30fps, mode 0 does not.) Mode 2: 1296x972 full field-of-view 2x2 binned mode. Mode 3: VGA full field of view mode. Signed-off-by:
David Plowman <david.plowman@raspberrypi.com> Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
David Plowman authored
Added basic v4l2_ctrl_handler infrastructure (there was none previously). Added controls to let AWB/AEC/AGC run in the sensor's auto mode or manually. Also controls to set exposure (in lines) and analogue gain (as a register code) from user code. Also delete registers (just the one) from the VGA mode register set that are now controlled by the new V4L2 controls. Signed-off-by:
David Plowman <david.plowman@raspberrypi.com> Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
David Plowman authored
Specifically: Added a structure ov5647_mode and a list of supported_modes (though no actual new modes as yet). The state object points to the "current mode". ov5647_enum_mbus_code, ov5647_enum_frame_size, ov5647_set_fmt and ov5647_get_fmt all needed upgrading to cope with multiple modes. __sensor_init (which writes all the registers) is now called by ov5647_stream_on (once the mode is known) rather than by ov5647_sensor_power. Signed-off-by:
David Plowman <david.plowman@raspberrypi.com> Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
David Plowman authored
Previously they were returning positive non-zero codes for success, which were getting passed up the call stack. Since release 4.19, do_dentry_open (fs/open.c) has been catching these and flagging an error. (So this driver has been broken since that date.) Fixes: 3c2472a3 [media] media: i2c: Add support for OV5647 sensor Signed-off-by:
David Plowman <david.plowman@raspberrypi.org> Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Dave Stevenson authored
The flag V4L2_SUBDEV_FL_HAS_EVENTS is required if the subdev can generate events. It can create events from the ctrl handler, therefore this is required. Signed-off-by:
Dave Stevenson <dave.stevenson@raspberrypi.com>
-
Jacopo Mondi authored
Implement the get_selection pad operation for the IMX219 sensor driver. The supported targets report the sensor's native size, the crop default rectangle and the crop rectangle. Reviewed-by:
Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by:
Jacopo Mondi <jacopo@jmondi.org>
-
Phil Elwell authored
Like many overlays, the i2c-gpio overlay goes to efforts to avoid generating warnings about #address-cells and #size-cells not being defined, which it does by defining them. Unfortunately this is fatal if they don't match what the system requires, and the recent switch to #size-cells = 2 on 2711 made i2c-gpio very dangerous. In the absence of the knowledge of a clean way to fix this, just delete the declarations and suffer the warnings. Signed-off-by:
Phil Elwell <phil@raspberrypi.com>
-
Phil Elwell authored
Add the spi_dma4 DT parameter to enable use of the 40-bit DMA channels to drive SPI. Note that there are only 3-4 40-bit channels available, and using this parameter claims 2 of them. Usage: dtparam=spi_dma4 Signed-off-by:
Phil Elwell <phil@raspberrypi.com>
-
Phil Elwell authored
BCM2711 has 4 DMA channels with a 40-bit address range, allowing them to access the full 4GB of memory on a Pi 4. Signed-off-by:
Phil Elwell <phil@raspberrypi.org>
-
Phil Elwell authored
This warning is unavoidable from a client's perspective and doesn't indicate anything wrong (just surprising). SQUASH with "spi: use_gpio_descriptor fixup moved to spi_setup" Signed-off-by:
Phil Elwell <phil@raspberrypi.com>
-
popcornmix authored
Signed-off-by:
popcornmix <popcornmix@gmail.com>
-
popcornmix authored
Signed-off-by:
popcornmix <popcornmix@gmail.com>
-
popcornmix authored
This isn't required on Pi3, so don't treat as an error Signed-off-by:
popcornmix <popcornmix@gmail.com>
-
Naushir Patuck authored
This commit enables the bcm2835-isp driver in the following defconfigs: bcm2709_defconfig bcm2711_defconfig bcmrpi_defconfig bcmrpi3_defconfig Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
bcmn2835_isp is a platform driver dependent on vchiq, therefore add the load/unload functions for it to vchiq. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Driver for the BCM2835 ISP hardware block. This driver uses the MMAL component to program the ISP hardware through the VC firmware. The ISP component can produce two video stream outputs, and Bayer image statistics. This can't be encompassed in a simple V4L2 M2M device, so create a new device that registers 4 video nodes. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
No functional changes in this commit. - Remove erroneous whitespace. - Remove _t postfix label on structs and enums. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
We are reserving controls for the new bcm2835-isp driver. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Add V4L2_META_FMT_BCM2835_ISP_STATS V4L2 format type. This new format will be used by the BCM2835 ISP device to return out ISP statistics for 3A. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
This file defines the userland interface to the bcm2835-isp driver that will follow in a separate commit. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
The sensor subdevice may change the Bayer order if a H/V flip is requested after a s_fmt call. Unicam g_fmt must call the subdev get_fmt in case this has happened and return out the correct format 4cc. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
This commit updates the imx219 driver to adverise support for embedded data streams. This can then be used by the bcm2835-unicam driver, which has recently been updated to expose the embedded data stream to userland. The imx219 sensor subdevice overloads the media pad to differentiate between image stream (pad 0) and embedded data stream (pad 1) when performing the v4l2_subdev_pad_ops functions. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Phil Elwell authored
This reverts commit 91f2cf4a. Revert this because the clock driver won't probe without a DT node, and creating it as a platform device won't give it one. Doing so avoids the following error message: raspberrypi-clk raspberrypi-clk: Missing firmware node Signed-off-by:
Phil Elwell <phil@raspberrypi.com>
-
popcornmix authored
We actually use the 64-bit 2711 kernel on Pi3 too. It still uses the downstream cpufreq driver in DT. See: https://www.raspberrypi.org/forums/viewtopic.php?f=29&t=269769&start=100#p1644752 Signed-off-by:
popcornmix <popcornmix@gmail.com>
-
Laurent Pinchart authored
The FRAME_SYNC event is useful for userspace image processing algorithms to program the camera sensor as early as possible after frame start. Support it. Signed-off-by:
Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by:
Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by:
Jacopo Mondi <jacopo@jmondi.org> Reviewed-by:
Naushir Patuck <naush@raspberrypi.com>
-
Laurent Pinchart authored
The unicam driver supports both the SOURCE_CHANGE and CTRL events. Both events are only generated on the image video node, so the event-related ioctls are useless on the medatada node. Disable them. Signed-off-by:
Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by:
Jacopo Mondi <jacopo@jmondi.org> Reviewed-by:
Naushir Patuck <naush@raspberrypi.com>
-
Dafna Hirschfeld authored
https://patchwork.linuxtv.org/patch/62740/ When enumerating the frame sizes, the value sent to imx219_get_format_code should be fse->code (the code from the ioctl) and not imx219->fmt.code which is the code set currently in the driver. Fixes: 22da1d56 ("media: i2c: imx219: Add support for RAW8 bit bayer format") Signed-off-by:
Dafna Hirschfeld <dafna.hirschfeld@collabora.com> Reviewed-by:
Helen Koike <helen.koike@collabora.com> Reviewed-by:
Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by:
Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
-
Lad Prabhakar authored
Commit 25130b8a upstream. This patch adds mode table entry for capturing cropped 640x480 resolution Signed-off-by:
Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> Acked-by:
Dave Stevenson <dave.stevenson@raspberrypi.com> Signed-off-by:
Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
-
Lad Prabhakar authored
Commit 22da1d56 upstream. IMX219 sensor is capable for RAW8/RAW10 modes. This commit adds support for RAW8 bayer format. Signed-off-by:
Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> Signed-off-by:
Dave Stevenson <dave.stevenson@raspberrypi.com> Signed-off-by:
Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
-
Lad Prabhakar authored
Commit ca45448a upstream. When supporting Rpi Camera v2 Module on the RZ/G2E, found the driver had some issues with rcar mipi-csi driver. The sensor never entered into LP-11 state. The powerup sequence in the datasheet[1] shows the sensor entering into LP-11 in streaming mode, so to fix this issue transitions are performed from "streaming -> standby" in the probe() after power up. With this commit the sensor is able to enter LP-11 mode during power up, as expected by some CSI-2 controllers. [1] https://publiclab.org/system/images/photos/000/023/294/original/ RASPBERRY_PI_CAMERA_V2_DATASHEET_IMX219PQH5_7.0.0_Datasheet_XXX.PDF Signed-off-by:
Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> Acked-by:
Dave Stevenson <dave.stevenson@raspberrypi.com> Signed-off-by:
Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
-
Dave Stevenson authored
Commit 1283b3b8 upstream. (Currently on linux-media/master, queued for 5.7) Adds a driver for the 8MPix Sony IMX219 CSI2 sensor. Whilst the sensor supports 2 or 4 CSI2 data lanes, this driver currently only supports 2 lanes. 8MPix @ 15fps, 1080P @ 30fps (cropped FOV), and 1640x1232 (2x2 binned) @ 30fps are currently supported. [Sakari Ailus: make imx219_check_hwcfg static] Signed-off-by:
Dave Stevenson <dave.stevenson@raspberrypi.com> Signed-off-by:
Andrey Konovalov <andrey.konovalov@linaro.org> Signed-off-by:
Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
-
Phil Elwell authored
This reverts commit 334c2448fb0aa5fb21c275619cec3ceb65dfc81d.
-
Naushir Patuck authored
If no buffer has been queued by a userland application, we use an internal dummy buffer for the hardware to spin in. This will allow the driver to release the existing userland buffer back to the application for processing. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
This patch adds a new node in the bcm2835-unicam driver to support CSI-2 embedded data streams. The subdevice is queried to see if embedded data is available from the sensor. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Move device node specific state out of the device state structure and into a new node structure. This separation will be needed for future changes where we will add an embedded data node to the driver to work alongside the existing image data node. Currently only use a single image node, so this commit does not add any functional changes. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
This patch adds MEDIA_BUS_FMT_SENSOR_DATA used by the bcm2835-unicam driver to support CSI-2 embedded data streams from camera sensors. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Add V4L2_META_FMT_SENSOR_DATA format 4CC. This new format will be used by the BCM2835 Unicam device to return out camera sensor embedded data. Signed-off-by:
Naushir Patuck <naush@raspberrypi.com>
-