- Apr 03, 2023
-
-
Phil Elwell authored
The kernel's time unit of jiffies should be stored as an unsigned long value. Storing it as an unsigned int, as gpio-fsm did, leads to truncation and malfunction when the kernel is built for a 64-bit platform. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
-
- Apr 01, 2023
-
-
Dave Stevenson authored
media_pipeline_start and media_pipeline_stop now validate that the pipeline is being started and stopped with the same pipe and pad handles. When running with embedded metadata (eg imx477 and imx708), the start typically happens from the metadata pad, whilst stop is always from the image pad. Always pass the image pad to media_pipeline_start to ensure that the calls are balanced. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
-
- Mar 31, 2023
-
-
Naushir Patuck authored
Create a cluster for the HVLIP and VFLIP controls so they are treated as a single composite control. Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Switch the system clock name from "xclk" to "inclk". Use lower case lables for all regulator names. Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Switch the system clock name from "xclk" to "inclk". Use lower case lables for all regulator names. Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Replace the existing imx708.yaml file with sony,imx708.yaml that follows the latest devicetree conventions for camera sensors. Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
This commit addresses vaious tidy-ups requesed for upstreaming the IMX708 driver. Notably: - Remove #define IMX708_NUM_SUPPLIES and use ARRAY_SIZE() directly - Use dev_err_probe where possible in imx708_probe() - Fix error handling paths in imx708_probe() Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Remove unused and redundant control fields from the state structure. Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Add a parameter to change the sensor device CSI-2 link frequency to one of the following values: 450Mhz (default), 447Mhz, or 453Mhz. Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
-
Naushir Patuck authored
Add support for three different usable link frequencies (default 450Mhz, 447Mhz, and 453MHz) for the IMX708 camera sensor. The choice of frequency is handled thorugh the "link-frequency" overlay parameter. Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
-
- Mar 30, 2023
-
-
Jonathan Bell authored
Setting both the Drop and Add bits on the input context prevents the corruption of split transactions seen with the BCM2711 XHCI controller, which is a dwc3 variant. This is a downstream feature that allows usbhid to restrict polling intervals on mice and keyboards, and was only tested on a VL805 which didn't complain about the fact the endpoint got added twice. Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
-
Dom Cobley authored
We seem to be getting increased OOM failures with MGLRU enabled on 32-bit kernels. Let's disable it by default (it can still be manually enabled at runtime). See: https://github.com/raspberrypi/linux/issues/5395 Signed-off-by: Dom Cobley <popcornmix@gmail.com>
-
Phil Elwell authored
Upstream change [1] has deleted the NET_CLS_TCINDEX Kconfig symbol. Regenerate our defconfigs without it. Signed-off-by: Phil Elwell <phil@raspberrypi.com> [1] 3abebc50 ("net/sched: Retire tcindex classifier")
-
- Mar 29, 2023
-
-
Phil Elwell authored
Since [1], the fbdev deferred IO framework is careful to cancel pending updates on close to prevent dirty pages being accessed after they may have been reused. However, this is not necessary in the case that the pagelist is empty, and drivers that don't make use of the pagelist may have wanted updates cancelled for no good reason. Avoid penalising fbdev drivers that don't make use of the pagelist by making the cancelling of deferred IO on close conditional on there being a non-empty pagelist. See: https://github.com/raspberrypi/linux/issues/5398 Signed-off-by: Phil Elwell <phil@raspberrypi.com> [1] 3efc61d9 ("fbdev: Fix invalid page access after closing deferred I/O devices")
-
Phil Elwell authored
This reverts commit b70f2a88 . Signed-off-by: Phil Elwell <phil@raspberrypi.com>
-
- Mar 28, 2023
-
-
Dave Stevenson authored
Now upstream have accepted patches adding a mono version of IMX290, and IMX327, update the compatible strings in the overlays to match. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
-
Alexander Stein authored
Should be upstream commit 3c3f66b8125a Both sensors are quite similar. Their specs only differ regarding LVDS and parallel output but are identical regarding MIPI-CSI-2 interface. But they use a different init setting of hard-coded values, taken from the datasheet. Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 5fcaecd6b5aa imx290_start_streaming logs what failed, but not the error code from that function. Add it into the log message. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 42765b80f8c6 The sensor supports H & V flips, so add the relevant hooks for V4L2_CID_HFLIP and V4L2_CID_VFLIP to configure them. Note that the Bayer order is maintained as the readout area shifts by 1 pixel in the appropriate direction (note the comment about the top margin being 8 pixels whilst the bottom margin is 9). The V4L2_SEL_TGT_CROP region is therefore adjusted appropriately. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit b8b86dfe1aee The sensor supports either a 37.125 or 74.25MHz external, but the driver only supported 37.125MHz. Add the relevant register configuration for either clock frequency option. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 454ce4c6d77b IMX290_CTRL_07 was written from both imx290_global_init_settings and imx290_1080p_settings and imx290_720p_settings. Remove it from imx290_global_init_settings as the setting varies based on the mode. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit b3aa351ea88a The default VMAX for 60fps in 720p mode is 750 according to the datasheet, however the driver always left it at 1125 thereby stopping 60fps being achieved. Make VMAX (and therefore V4L2_CID_VBLANK) mode dependent so that 720p60 can be achieved. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 97792a11021b The driver exposed V4L2_CID_VBLANK as a read only control to allow for exposure calculations and determination of the frame rate. Convert to a read/write control so that the frame rate can be controlled. V4L2_CID_VBLANK also sets the limits for the exposure control, therefore exposure ranges have to be updated when vblank changes (either via s_ctrl, or via changing mode). Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 8cab2bd86307 The driver exposed V4L2_CID_HBLANK as a read only control to allow for exposure calculations and determination of the frame rate. Convert to a read/write control so that the frame rate can be controlled. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 34819ba0b450 Commit "98e0500e media: i2c: imx290: Add configurable link frequency and pixel rate" added support for the increased link frequencies on 2 data lanes, but didn't update the CSI timing registers in accordance with the datasheet. Use the specified settings. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 7d4f22ba99cc Commit "97589ad6 media: i2c: imx290: Add support for 2 data lanes" added support for running in two lane mode (instead of 4), but without changing the link frequency that resulted in a max of 30fps. Commit "98e0500e media: i2c: imx290: Add configurable link frequency and pixel rate" then doubled the link frequency when in 2 lane mode, but didn't undo the correction for running at only 30fps, just extending horizontal blanking instead. Remove the 30fps limit on 2 lane by correcting the register config in accordance with the datasheet for 60fps operation over 2 lanes. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 4381df0c756f The datasheet lists the link frequency changes between 1080p and 720p modes. This is correct that the link frequency changes as measured on an oscilloscope. Link frequency is not necessarily the same as pixel rate. The datasheet gives standard configurations for 1080p and 720p modes at a number of frame rates. Looking at the 1080p mode it gives: HMAX = 0x898 = 2200 VMAX = 0x465 = 1125 2200 * 1125 * 60fps = 148.5MPix/s Looking at the 720p mode it gives: HMAX = 0xce4 = 3300 VMAX = 0x2ee = 750 3300 * 750 * 60fps = 148.5Mpix/s This driver currently scales the pixel rate proportionally to the link frequency, however the above shows that this is not the correct thing to do, and currently all frame rate and exposure calculations give incorrect results. Correctly report the pixel rate as being 148.5MPix/s under any mode. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 5f9dee39ab55 Any V4L2 subdevice that implements controls and declares V4L2_SUBDEV_FL_HAS_DEVNODE should also declare V4L2_SUBDEV_FL_HAS_EVENTS and implement subscribe_event and unsubscribe_event hooks. This driver didn't and would therefore fail v4l2-compliance testing. Add the relevant hooks. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 7843b2eb081b The colorspace fields were left untouched in imx290_set_fmt which lead to a v4l2-compliance failure. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 76d1bd4f0f45 Fix up a couple of coding style issues regarding missing blank lines after declarations, double blank lines, and incorrect indentation. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit 9bf52c7136d1 The IMX290 module is available as either mono or colour (Bayer). Update the driver so that it can advertise the correct mono formats instead of the colour ones. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Tested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Andy Shevchenko authored
Should be upstream commit 971458482809 No need to call fwnode_property_read_u32(dev_fwnode()), when we have already existing helper. So use it. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Andy Shevchenko authored
Should be upstream commit 5d129c4539c3 Since we have a proper endianness converters for LE 24-bit data use them. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Alexander Stein authored
Should be upstream commit 783ecfe5556a The imx290 driver can be used for both imx290 and imx327 as they have a similar register set and configuration. imx327 lacks 8 lanes LVDS and 120 FPS support. Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com> Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Should be upstream commit f0c720ff2d21 The IMX290 module is available as either monochrome or colour and the variant is not detectable at runtime. Add a new compatible string for the monochrome version, based on the full device name IMX290LLR. For consistency, add a new compatible string for the colour version based on the IMX290LQR full device name, and deprecate the current ambiguous compatible string. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com> Acked-by: Rob Herring <robh@kernel.org> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Tested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Laurent Pinchart authored
Upstream commit a96dfea1 Convert the Sony IMX290 DT binding from text to YAML. Add Manivannan as a maintainer given that he is listed in MAINTAINERS for the file, as volunteering myself. The name of the input clock, "xclk", is wrong as the hardware manual names it INCK. As the device has a single clock, the name could be omitted, but that would require a corresponding change to the driver and is thus a candidate for further patches. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
-
Dave Stevenson authored
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
-
Laurent Pinchart authored
Upstream commit 05ef7ec4 Check the error status returned by imx290_set_data_lanes() in its caller and propagate it. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
-
Laurent Pinchart authored
Upstream commit 76c00128 There's no need to check for an incorrect number of data lanes in imx290_set_data_lanes() as the value is validated at probe() time. Drop the check. The PHY_LANE_NUM and CSI_LANE_MODE registers are programmed with a value equal to the number of lanes minus one. Compute it instead of handling it in the switch/case. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
-
Laurent Pinchart authored
Upstream commit 7d399658 There's no need to configure the data lanes in the runtime PM resume handler. Do so in imx290_start_streaming() instead. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
-