Hi,
I though of writing these two small patches to rename the dw9807 bindings
and driver to reflect what's apparent in the compatible string: this is
just the VCM part.
Sakari Ailus (2):
dt-bindings: dw9714, dw9807-vcm: Add files to MAINTAINERS, rename
files
dw9807-vcm: Recognise th
lopers shouldn't need to
read it. OTOH it might be that they're also not the primary audience for
this driver either. If there's a Wikipedia article you could refer to or
such that'd be fine IMO, too.
Up to you.
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
On Thu, Jul 19, 2018 at 02:13:50PM +0200, Hans Verkuil wrote:
> From: Hans Verkuil
>
> Add a new pixelformat for the vicodec software codec using the
> Fast Walsh Hadamard Transform.
>
> Signed-off-by: Hans Verkuil
Apart from the docs:
Acked-by: Sakari Ailus
--
S
On Thu, Jul 19, 2018 at 02:13:50PM +0200, Hans Verkuil wrote:
> From: Hans Verkuil
>
> Add a new pixelformat for the vicodec software codec using the
> Fast Walsh Hadamard Transform.
>
> Signed-off-by: Hans Verkuil
Could you add documentation for this format, please?
--
S
MEDIA_ENT_F_PROC_VIDEO_DECODER``
> + - Video (MPEG, HEVC, VPx, etc.) decoder. An entity capable of
> + decompressing a compressed video stream into uncompressed video
> + frames must have one sink pad and one source pad.
> +
It'd be nice to keep the
Add the DT binding documentation for dw9714 and dw9807-vcm to the
MAINTAINERS file. The dw9807-vcm binding documentation file is renamed to
match the dw9807's VCM bit's compatible string.
Signed-off-by: Sakari Ailus
---
.../bindings/media/i2c/{dongwoon,dw9807.txt => dongwoon,dw9807
t; +Converting the raw bayer image into YUV domain
> +--
> +
> +The processed images after the above step, can be converted to YUV domain
> +as below.
> +
> +Main output frames
> +~~
> +
> +raw2pnm -x2560 -y19
On Wed, Jul 18, 2018 at 11:29:01AM +0200, Hans Verkuil wrote:
> On 16/07/18 14:49, Sakari Ailus wrote:
> > Hi Hans,
> >
> > On Thu, Jul 05, 2018 at 10:25:19AM +0200, Hans Verkuil wrote:
> >> The vb2_core_qbuf() function didn't check if q->error was set. It
parse 'data-enable-active' prop
dt-bindings: media: rcar-vin: Add 'data-enable-active'
media: rcar-vin: Handle data-enable polarity
media: i2c: ov7670: Put ep fwnode after use
Luca Ceresoli (1):
media: smiapp: fix debug message
Sakari Ailus (2):
sm
208->sd.ctrl_handler = ctrl_hdlr;
> +
> + return 0;
> +
> +error:
> + v4l2_ctrl_handler_free(ctrl_hdlr);
> + mutex_destroy(&imx208->mutex);
> +
> + return ret;
> +}
> +
> +static void imx208_free_controls(struct imx208 *imx208)
> +{
> + v4l2_ctrl_handler_free(imx208->sd.ctrl_handler);
> + mutex_destroy(&imx208->mutex);
> +}
> +
> +static int imx208_probe(struct i2c_client *client)
> +{
> + struct imx208 *imx208;
> + int ret;
> + u32 val = 0;
> +
> + device_property_read_u32(&client->dev, "clock-frequency", &val);
> + if (val != 1920)
> + return -EINVAL;
> +
> + imx208 = devm_kzalloc(&client->dev, sizeof(*imx208), GFP_KERNEL);
> + if (!imx208)
> + return -ENOMEM;
> +
> + /* Initialize subdev */
> + v4l2_i2c_subdev_init(&imx208->sd, client, &imx208_subdev_ops);
> +
> + /* Check module identity */
> + ret = imx208_identify_module(imx208);
> + if (ret)
> + return ret;
> +
> + /* Set default mode to max resolution */
> + imx208->cur_mode = &supported_modes[0];
> +
> + ret = imx208_init_controls(imx208);
> + if (ret)
> + return ret;
> +
> + /* Initialize subdev */
> + imx208->sd.internal_ops = &imx208_internal_ops;
> + imx208->sd.flags |= V4L2_SUBDEV_FL_HAS_DEVNODE;
> + imx208->sd.entity.type = MEDIA_ENT_T_V4L2_SUBDEV_SENSOR;
We no longer have types, but functions. I.e. MEDIA_ENT_F_CAM_SENSOR . The
type field no longer exists. (See below.)
> +
> + /* Initialize source pad */
> + imx208->pad.flags = MEDIA_PAD_FL_SOURCE;
> + ret = media_entity_init(&imx208->sd.entity, 1, &imx208->pad, 0);
This function got renamed quite some time ago as media_entity_pads_init().
Have you compile tested this against the current media tree?
> + if (ret) {
> + dev_err(&client->dev, "%s failed:%d\n", __func__, ret);
> + goto error_handler_free;
> + }
> +
> + ret = v4l2_async_register_subdev_sensor_common(&imx208->sd);
> + if (ret < 0)
> + goto error_media_entity;
> +
> + pm_runtime_set_active(&client->dev);
> + pm_runtime_enable(&client->dev);
> + pm_runtime_idle(&client->dev);
> +
> + return 0;
> +
> +error_media_entity:
> + media_entity_cleanup(&imx208->sd.entity);
> +
> +error_handler_free:
> + imx208_free_controls(imx208);
> +
> + return ret;
> +}
> +
> +static int imx208_remove(struct i2c_client *client)
> +{
> + struct v4l2_subdev *sd = i2c_get_clientdata(client);
> + struct imx208 *imx208 = to_imx208(sd);
> +
> + v4l2_async_unregister_subdev(sd);
> + media_entity_cleanup(&sd->entity);
> + imx208_free_controls(imx208);
> +
> + pm_runtime_disable(&client->dev);
> + pm_runtime_set_suspended(&client->dev);
> +
> + return 0;
> +}
> +
> +static const struct dev_pm_ops imx208_pm_ops = {
> + SET_SYSTEM_SLEEP_PM_OPS(imx208_suspend, imx208_resume)
> +};
> +
> +#ifdef CONFIG_ACPI
> +static const struct acpi_device_id imx208_acpi_ids[] = {
> + { "INT3478" },
> + { /* sentinel */ }
> +};
> +
> +MODULE_DEVICE_TABLE(acpi, imx208_acpi_ids);
> +#endif
> +
> +static struct i2c_driver imx208_i2c_driver = {
> + .driver = {
> + .name = "imx208",
> + .pm = &imx208_pm_ops,
> + .acpi_match_table = ACPI_PTR(imx208_acpi_ids),
> + },
> + .probe_new = imx208_probe,
> + .remove = imx208_remove,
> +};
> +
> +module_i2c_driver(imx208_i2c_driver);
> +
> +MODULE_AUTHOR("Yeh, Andy ");
> +MODULE_AUTHOR("Chen, Ping-chung ");
> +MODULE_DESCRIPTION("Sony IMX208 sensor driver");
> +MODULE_LICENSE("GPL v2");
--
Kind regards,
Sakari Ailus
sakari.ai...@linux.intel.com
A lot of sensor drivers are labelled as "sensor-level" drivers. That's odd
and somewhat confusing as the term isn't used elsewhere: these are just
sensor drivers. Call them such.
Signed-off-by: Sakari Ailus
---
drivers/media/i2c/Kconfig | 62 +++---
(q->error) {
> + dprintk(1, "fatal error occurred on queue\n");
> + return -EIO;
> + }
> +
> vb = q->bufs[index];
>
> if ((req && q->uses_qbuf) ||
How long has this problem existed? It looks like something that should go
to the stable branches, too...
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
The smiapp driver is licensed under GNU GPL v2 only, as stated by the
header. Reflect this in the MODULE_LICENSE macro.
Signed-off-by: Sakari Ailus
---
drivers/media/i2c/smiapp/smiapp-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/media/i2c/smiapp/smiapp
On Mon, Jun 04, 2018 at 01:46:19PM +0200, Hans Verkuil wrote:
> From: Hans Verkuil
>
> Add a simple helper function that tests if the driver supports
> the request API.
>
> Signed-off-by: Hans Verkuil
Acked-by: Sakari Ailus
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
It might become possible that drivers can disable such links (if for some
> reason the device node cannot be used), so we might need to add a new link
> flag at some point to mark interface links that can be changed by the driver
> but not by userspace.
>
> Signed-off-by: Hans Ve
On Tue, Jun 26, 2018 at 01:47:45PM -0700, Steve Longerbeam wrote:
>
>
> On 06/26/2018 12:12 AM, Sakari Ailus wrote:
> > On Wed, May 09, 2018 at 04:06:32PM -0700, Steve Longerbeam wrote:
> > >
> > > On 05/08/2018 03:12 AM, Sakari Ailus wrote:
> > >
Hi Steve,
On Tue, May 08, 2018 at 08:55:04PM -0700, Steve Longerbeam wrote:
>
>
> On 05/08/2018 03:28 AM, Sakari Ailus wrote:
> > Hi Steve,
> >
> > Again, sorry about the delay. This thread got buried in my inbox. :-(
> > Please see my reply below.
> >
ER_MAX217X_BASE and
> V4L2_CID_USER_IMX_BASE taking on the same value. Fix by assigning imx
> CID base the next available range at 0x10b0.
>
> Signed-off-by: Steve Longerbeam
Acked-by: Sakari Ailus
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
On Thu, Jun 28, 2018 at 06:20:37PM +0200, Marco Felsch wrote:
> Add two helper functions to check if two rectangles have the same
> position (top/left) and if two rectangles equals (same size and
> same position).
>
> Signed-off-by: Marco Felsch
Acked-by: Sakari Ailus
-
etree/bindings/media/i2c/ak7375.txt
create mode 100644 drivers/media/i2c/ak7375.c
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
t this once that's done.
>
> Making G_TOPOLOGY useful is urgently needed since I think that will be
> very helpful for the work we want to do on library support for complex
> cameras.
For the set:
Acked-by: Sakari Ailus
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
ruct imx319 *imx319)
> +{
> + v4l2_ctrl_handler_free(imx319->sd.ctrl_handler);
> +}
Please use v4l2_ctrl_handler_free() directly instead, and remove this
function.
Both apply to the imx355 driver as well.
--
Kind regards,
Sakari Ailus
sakari.ai...@linux.intel.com
or !CONFIG_PM
Hugues Fruchet (1):
media: ov5640: fix frame interval enumeration
Javier Martinez Canillas (1):
media: omap3isp: zero-initialize the isp cam_xclk{a,b} initial data
Philipp Puschmann (1):
media: ov5640: adjust xclk_max
Sakari Ailus (1):
v4l
i2c/ov7251.c seems abour right,
for instance.
I think this would be relevant in addressing the compile issues without
subdev uAPI, too.
I've postponed the two patches, feel free to send either delta or v7 of
this.
--
Sakari Ailus
sakari.ai...@linux.intel.com
v5640: Add "rotation" property
media: ov5640: add support of module orientation
Sakari Ailus (3):
dt-bindings: media: Define "rotation" property for sensors
dt-bindings: smia: Add "rotation" property
smiapp: Support the "rotation" property
On Tue, May 08, 2018 at 08:55:04PM -0700, Steve Longerbeam wrote:
>
>
> On 05/08/2018 03:28 AM, Sakari Ailus wrote:
> > Hi Steve,
> >
> > Again, sorry about the delay. This thread got buried in my inbox. :-(
> > Please see my reply below.
> >
> > On
On Wed, May 09, 2018 at 04:06:32PM -0700, Steve Longerbeam wrote:
>
>
> On 05/08/2018 03:12 AM, Sakari Ailus wrote:
> > On Fri, Apr 20, 2018 at 10:12:33AM -0700, Steve Longerbeam wrote:
> > > Hi Sakari,
> > >
> > >
> > > On 04/20/
fic chips.
>
> Provide a flexible way to determine the addressing bits through
> address-width in this patch.
>
> Signed-off-by: Alan Chiang
> Signed-off-by: Andy Yeh
> Reviewed-by: Sakari Ailus
> Reviewed-by: Andy Shevchenko
> Reviewed-by: Rajmohan Mani
> ---
&
Chiang
> Signed-off-by: Andy Yeh
> Reviewed-by: Sakari Ailus
> Reviewed-by: Andy Shevchenko
> Reviewed-by: Rajmohan Mani
> ---
> drivers/misc/eeprom/at24.c | 16
> 1 file changed, 16 insertions(+)
>
> diff --git a/drivers/misc/eeprom/at24.c b/drivers/misc/e
or acked-by) tags from
reviewers explicitly. You can't just add them based on people commenting
on your patches.
- DT binding patches precede driver changes.
Please send v2 with these addressed.
--
Kind regards,
Sakari Ailus
sakari.ai...@linux.intel.com
;client->dev);
> + pm_runtime_idle(&client->dev);
> +
> + return 0;
> +
> +err_cleanup:
> + v4l2_ctrl_handler_free(&ak7375_dev->ctrls_vcm);
> + media_entity_cleanup(&ak7375_dev->sd.entity);
> + dev_err(&client->dev, "Probe failed: %d\n", val);
This line is redundant, too: the kernel already prints the error value.
> +
> + return val;
> +}
--
Sakari Ailus
sakari.ai...@linux.intel.com
+---+---+---+---+---+---+---+---+
> |D03|D02|D01|D00|---|---|---|---|
> +---+---+---+---+---+---+---+---+
>
> This driver support :
> - set ak7375 to standby mode once suspend and
> turn it back to active if resume
> - set the position via V4L2_CID_FOCUS_ABSOLUTE ctrl
>
>
8-06-21 12:22:49 +0300)
Arnd Bergmann (2):
media: v4l: cadence: include linux/slab.h
media: v4l: cadence: add VIDEO_V4L2 dependency
Sakari Ailus (1):
imx258: Check the rotation property has a value of 180
drivers
const *mode @@
drivers/media/i2c/ov5640.c:1394:14:expected struct ov5640_mode_info const
+*mode
drivers/media/i2c/ov5640.c:1394:14:got struct ov5640_mode_info const ( *<
+noident> )[9]
Signed-off-by: Sakari Ailus
---
include/media/v4l2-common.h | 2 +-
1 file changed, 1 ins
, mode->hact,
> - mode->vact, true);
> + mode = ov5640_find_mode(sensor, frame_rate, mode->hact,
> + mode->vact, true);
> + if (!mode) {
> + ret = -EINVAL;
> + goto out;
> + }
> +
> + sensor->current_mode = mode;
> sensor->pending_mode_change = true;
> out:
> mutex_unlock(&sensor->lock);
> --
> 1.9.1
>
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
uot;%s I2C failure: %d\n", __func__, ret);
> + return ret;
> + }
> +
> + for (val = ak7375_dev->focus->val % AK7375_CTRL_STEPS;
> + val <= ak7375_dev->focus->val;
> + val += AK7375_CTRL_STEPS) {
> + ret = ak7375_i2c_write(ak7375_dev, AK7375_REG_POSITION,
> +val << 4, 2);
> + if (ret)
> + dev_err_ratelimited(dev, "%s I2C failure: %d\n",
> + __func__, ret);
> + usleep_range(AK7375_CTRL_DELAY_US, AK7375_CTRL_DELAY_US + 10);
> + }
> +
> + ak7375_dev->active = true;
> +
> + return 0;
> +}
> +
> +static const struct of_device_id ak7375_of_table[] = {
> + { .compatible = "asahi-kasei,ak7375" },
> + { /* sentinel */ }
> +};
> +MODULE_DEVICE_TABLE(of, ak7375_of_table);
> +
> +static const struct dev_pm_ops ak7375_pm_ops = {
> + SET_SYSTEM_SLEEP_PM_OPS(ak7375_vcm_suspend, ak7375_vcm_resume)
> + SET_RUNTIME_PM_OPS(ak7375_vcm_suspend, ak7375_vcm_resume, NULL)
> +};
> +
> +static struct i2c_driver ak7375_i2c_driver = {
> + .driver = {
> + .name = "ak7375",
> + .pm = &ak7375_pm_ops,
> + .of_match_table = ak7375_of_table,
> + },
> + .probe_new = ak7375_probe,
> + .remove = ak7375_remove,
> +};
> +module_i2c_driver(ak7375_i2c_driver);
> +
> +MODULE_AUTHOR("Tianshu Qiu ");
> +MODULE_AUTHOR("Bingbu Cao ");
> +MODULE_DESCRIPTION("AK7375 VCM driver");
> +MODULE_LICENSE("GPL v2");
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
Hi folks,
This is an earlier patch "smiapp: Support the "upside-down" property"
split into two -- the DT binding change and a driver change.
The only change is in DT bindings --- an added reference to
video-interfaces.txt in rotation property documentation.
Sakari Ailus (2):
Use the "rotation" property to tell that the sensor is mounted upside
down. This reverses the behaviour of the VFLIP and HFLIP controls as well
as the pixel order.
Signed-off-by: Sakari Ailus
Reviewed-by: Sebastian Reichel
---
drivers/media/i2c/smiapp/smiapp-core.c | 16 +
Add the rotation property to list of optional properties for the smia
sensors.
Signed-off-by: Sakari Ailus
Reviewed-by: Sebastian Reichel
Acked-by: Rob Herring
---
Documentation/devicetree/bindings/media/i2c/nokia,smia.txt | 3 +++
1 file changed, 3 insertions(+)
diff --git a/Documentation
Hi Tomasz,
On Sat, May 19, 2018 at 12:37:34AM +0900, Tomasz Figa wrote:
> +Hu, Jerry W +Mani, Rajmohan +Sakari Ailus
>
> FYI
> On Fri, May 18, 2018 at 4:07 AM Mauro Carvalho Chehab <
> mchehab+sams...@kernel.org> wrote:
>
> > Hi all,
>
> > The goal of
On Wed, Jun 13, 2018 at 10:09:58AM +, Hugues FRUCHET wrote:
> Hi Sakari, Rob,
>
> Find a new proposal below:
>
> On 06/13/2018 10:24 AM, Sakari Ailus wrote:
> > On Wed, Jun 13, 2018 at 08:10:02AM +, Hugues FRUCHET wrote:
> >> Hi Rob, thanks for review,
&g
needs a common definition.
> >
>
> A common definition has been introduced by Sakari, I'm reusing it, see:
> https://www.mail-archive.com/linux-media@vger.kernel.org/msg132517.html
>
> I would so propose:
> >> +- rotation: as defined in
> >> + Documentati
to
Mauro.
I put the smiapp bindings to the same patch with the driver change as they
were pretty small both but we'll split these in the future.
I've marked the pull request as deferred for now; let me know whether
you're still ok with this going in as such.
Thanks.
--
Kind regards,
Sakari Ailus
e-mail: sakari.ai...@iki.fi
mode 100644 Documentation/devicetree/bindings/media/i2c/ov2680.txt
create mode 100644 drivers/media/i2c/dw9807.c
create mode 100644 drivers/media/i2c/ov2680.c
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
1 15:45:23 +0300)
Hugues Fruchet (2):
media: ov5640: add HFLIP/VFLIP controls support
media: ov5640: add support of module orientation
Sakari Ailus (2):
dt-bindings: media: Define "rotation" property for
Please remember to add acks you've received in the future.
--
Sakari Ailus
sakari.ai...@linux.intel.com
tion", &rotation);
> + if (!ret) {
> + switch (rotation) {
> + case 180:
> + sensor->upside_down = true;
> + /* fall through */
> + case 0:
> + break;
> + default:
> + dev_warn(dev, "%u degrees rotation is not supported,
> ignoring...\n",
> + rotation);
> + }
> + }
> +
> endpoint = fwnode_graph_get_next_endpoint(dev_fwnode(&client->dev),
> NULL);
> if (!endpoint) {
--
Kind regards,
Sakari Ailus
e-mail: sakari.ai...@iki.fi
make sense if just change the compatible string to
> "asahi-kasei,ak7375" and keep the file name unchanged?
Most binding files in the directory seem to use the chip name rather than
the full compatible string (including the vendor). I guess both are fine.
--
Sakari Ailus
sakari.ai...@linux.intel.com
);
I don't have a data datasheet for this thing, but it looks like buf[1] will
be undefined for writes the size of which is 1. And this what appears to be
written to the device as well...
> + if (ret < 0)
> + return ret;
> + if (ret != size + 1)
> + return -EIO;
> + return 0;
> +}
--
Sakari Ailus
sakari.ai...@linux.intel.com
ONFIG_VIDEO_AK7375) += ak7375.o
> obj-$(CONFIG_VIDEO_DW9714) += dw9714.o
> obj-$(CONFIG_VIDEO_ADV7170) += adv7170.o
> obj-$(CONFIG_VIDEO_ADV7175) += adv7175.o
> diff --git a/drivers/media/i2c/ak7375.c b/drivers/media/i2c/ak7375.c
> new file mode 100644
> index ..012e673e9ced
> --- /dev/null
> +++ b/drivers/media/i2c/ak7375.c
...
> +static const struct of_device_id ak7375_of_table[] = {
> + { .compatible = "akm,ak7375" },
"asahi-kasei,ak7375"
--
Sakari Ailus
sakari.ai...@linux.intel.com
Signed-off-by: Sakari Ailus
---
MAINTAINERS| 7 +
drivers/media/i2c/Kconfig | 10 ++
drivers/media/i2c/Makefile | 1 +
drivers/media/i2c/dw9807.c | 329 +
4 files changed, 347 insertions(+)
create mode 100644 drivers/media/i2c
From: Alan Chiang
Dongwoon DW9807 is a voice coil lens driver.
Signed-off-by: Alan Chiang
Signed-off-by: Andy Yeh
Reviewed-by: Rob Herring
Signed-off-by: Sakari Ailus
---
Documentation/devicetree/bindings/media/i2c/dongwoon,dw9807.txt | 9 +
1 file changed, 9 insertions(+)
create
Just posting this after squashing the vcm-only bit to the compatible string.
Alan Chiang (2):
media: dt-bindings: Add bindings for Dongwoon DW9807 voice coil
media: dw9807: Add dw9807 vcm driver
.../bindings/media/i2c/dongwoon,dw9807.txt | 9 +
MAINTAINERS
files changed, 250 insertions(+), 90 deletions(-)
--
Kind regards,
Sakari Ailus
e-mail: sakari.ai...@iki.fi
kiB page size.
Signed-off-by: Sakari Ailus
---
Hi Rob, others,
The original bindings were missing the EEPROM bit. This change recognises
it's there, and allows adding more elaborate support for it later on if
needed.
If this change is fine, I'll squash it to the original patches that a
gt; with the pxa_camera driver if the video device is opened by more than
> two users at the same time.
>
> Instead of propagating the boilerplate code for each subdevice driver
> that implement s_power, this introduces an trick that many V4L2 drivers
> are using with v4l2_fh_is_si
ariable]
> s64 exposure_max;
> ^~~~
>
> Signed-off-by: Mauro Carvalho Chehab
Acked-by: Sakari Ailus
--
Sakari Ailus
sakari.ai...@linux.intel.com
The driver only supports streaming images flipped horizontally and
vertically. In order to ensure that all current users will be fine if or
when support for upright streaming is added, require the presence of the
"rotation" control now.
Signed-off-by: Sakari Ailus
Tested-by:
On Fri, May 25, 2018 at 04:09:55PM +0200, Sebastian Reichel wrote:
> Hi,
>
> On Fri, May 25, 2018 at 04:52:35PM +0300, Sakari Ailus wrote:
> > Use the "rotation" property to tell that the sensor is mounted upside
> > down. This reverses the behaviour of the VFLIP an
queue you just capture the result of whatever the device delivers. I don't
> believe there is much if anything you can or want to control per-buffer.
May there be controls associated with the capture queue buffers?
--
Sakari Ailus
sakari.ai...@linux.intel.com
Use the "rotation" property to tell that the sensor is mounted upside
down. This reverses the behaviour of the VFLIP and HFLIP controls as well
as the pixel order.
Signed-off-by: Sakari Ailus
---
since v2.2:
- Fix property name in code.
.../devicetree/bindings/media/i2c/noki
On Fri, May 25, 2018 at 03:41:59PM +0200, Sebastian Reichel wrote:
> Hi,
>
> On Fri, May 25, 2018 at 03:27:26PM +0300, Sakari Ailus wrote:
> > Use the "upside-down" property to tell that the sensor is mounted upside
> > down. This reverses the behaviour of the V
Use the "rotation" property to tell that the sensor is mounted upside
down. This reverses the behaviour of the VFLIP and HFLIP controls as well
as the pixel order.
Signed-off-by: Sakari Ailus
---
since v2:
- Fix the property name in the commit message
.../devicetree/bindings/media
the "rotation" property for camera sensors, mirroring
what is defined for displays in
Documentation/devicetree/bindings/display/panel/panel.txt .
Signed-off-by: Sakari Ailus
---
Documentation/devicetree/bindings/media/video-interfaces.txt | 4
1 file changed, 4 insertions(+)
di
Use the "upside-down" property to tell that the sensor is mounted upside
down. This reverses the behaviour of the VFLIP and HFLIP controls as well
as the pixel order.
Signed-off-by: Sakari Ailus
---
.../devicetree/bindings/media/i2c/nokia,smia.txt | 2 ++
drivers/media/
Hi,
Here's an update on my previous patchset adding an "upside-down" property.
Instead of dropping the first patch entirely as I first thought, I decided
to add documentation for the rotation property for sensors as well. The
updates to the patches are related to that.
Sakari
, as all the formats you have are
> > > 10bpp). In OF world those parameters come from DT, what about ACPI?
> >
> > I presume the driver only supports a particular number of lanes (4). ACPI
> > supports _DSD properties, i.e. the same can be done on ACPI.
> >
&
On Fri, May 25, 2018 at 01:16:32AM +0900, Akinobu Mita wrote:
> 2018-05-22 22:59 GMT+09:00 Sakari Ailus :
> > Dear Mita-san,
> >
> > On Mon, May 21, 2018 at 12:40:38AM +0900, Akinobu Mita wrote:
> >> The open() operation for the pxa_camera driver always calls s_pow
On Thu, May 24, 2018 at 02:42:41PM +0200, Philipp Zabel wrote:
> Hi Sakari,
>
> thank you for the review comments.
>
> On Thu, 2018-05-24 at 14:38 +0300, Sakari Ailus wrote:
> > Hi Philipp,
> >
> > Thanks for the patch.
> >
> > On Wed, May 23,
truct video_mux *vmux = v4l2_subdev_to_video_mux(sd);
> + struct v4l2_mbus_framefmt *mbusformat;
> + int i;
unsigned int i
> +
> + mutex_lock(&vmux->lock);
> +
> + for (i = 0; i < sd->entity.num_pads; i++) {
> + mbusformat = v4
ipe_binarydesc.c | 3 ++-
> .../staging/media/atomisp/pci/atomisp2/css2400/sh_css.c| 7 +--
> 5 files changed, 7 insertions(+), 27 deletions(-)
>
I'm sorry to tell you that the atomisp driver was removed from the staging
tree some time ago.
--
Kind regards,
Sakari Ailus
sakari.ai...@linux.intel.com
ruct v4l2_subdev_pad_config *cfg,
> > + struct v4l2_subdev_format *fmt)
> > +{
> > + struct imx319 *imx319 = to_imx319(sd);
> > + int ret;
> > +
> > + mutex_lock(&imx319->mutex);
> > + ret = imx319_do_get_pad_format(imx319, cfg, fmt);
> > + mutex_unlock(&imx319->mutex);
> > +
> > + return ret;
> > +}
> > +
> > +static int
> > +imx319_set_pad_format(struct v4l2_subdev *sd,
> > + struct v4l2_subdev_pad_config *cfg,
> > + struct v4l2_subdev_format *fmt)
> > +{
> > + struct imx319 *imx319 = to_imx319(sd);
> > + const struct imx319_mode *mode;
> > + struct v4l2_mbus_framefmt *framefmt;
> > + s32 vblank_def;
> > + s32 vblank_min;
> > + s64 h_blank;
> > + s64 pixel_rate;
> > +
> > + mutex_lock(&imx319->mutex);
> > +
> > + /*
> > +* Only one bayer order is supported.
> > +* It depends on the flip settings.
> > +*/
> > + fmt->format.code = imx319_get_format_code(imx319);
> > +
> > + mode = v4l2_find_nearest_size(supported_modes,
> > + ARRAY_SIZE(supported_modes), width, height,
> > + fmt->format.width, fmt->format.height);
> > + imx319_update_pad_format(imx319, mode, fmt);
> > + if (fmt->which == V4L2_SUBDEV_FORMAT_TRY) {
> > + framefmt = v4l2_subdev_get_try_format(sd, cfg, fmt->pad);
> > + *framefmt = fmt->format;
> > + } else {
> > + imx319->cur_mode = mode;
> > + pixel_rate =
> > + (link_freq_menu_items[0] * 2 * 4) / 10;
>
> This assumes a fixed link frequency and a fixed number of data lanes,
> and a fixed bpp value (but this is ok, as all the formats you have are
> 10bpp). In OF world those parameters come from DT, what about ACPI?
I presume the driver only supports a particular number of lanes (4). ACPI
supports _DSD properties, i.e. the same can be done on ACPI.
If the driver only supports these, then it should check this matches with
what the firmware (ACPI) has. The fwnode API is the same.
--
Sakari Ailus
sakari.ai...@linux.intel.com
On Tue, May 22, 2018 at 02:19:21PM +0100, Rui Miguel Silva wrote:
> Hi Sakari,
> On Fri 18 May 2018 at 22:13, Sakari Ailus wrote:
> > On Fri, May 18, 2018 at 09:27:58AM +0100, Rui Miguel Silva wrote:
> > > > > +endpoint node
> > > > > +---
l2_fh_is_singular_file().
I'd rather like that the sub-device drivers would move to use runtime PM
instead of depending on the s_power() callback. It's much cleaner that way.
It's not a near-term solution though. The approach seems fine, please see
comments below though.
>
>
deletions(-)
create mode 100644 Documentation/devicetree/bindings/media/i2c/ov772x.txt
create mode 100644 drivers/media/i2c/imx258.c
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
gt;num_planes; ++plane)
> + call_void_memop(vb, finish, vb->planes[plane].mem_priv);
> + }
>
> spin_lock_irqsave(&q->done_lock, flags);
> if (state == VB2_BUF_STATE_QUEUED ||
How long do you think this problem has existed? Would thi
state is simply correct and optimal handling of requests.
Signed-off-by: Sakari Ailus
---
since v14.1:
- Add dummy variants of the update lock functions to be used if MC is
disabled.
drivers/media/media-request.c | 7 -
include/media/media-request.h | 65
state is simply correct and optimal handling of requests.
Signed-off-by: Sakari Ailus
---
since v14:
- Correctly initialise the refcount to zero, as well as check it's zero
when the request is cleaned
drivers/media/media-request.c | 7 +-
include/media/media-request.h
00644
Documentation/devicetree/bindings/media/renesas,rcar-csi2.txt
create mode 100644 drivers/media/platform/rcar-vin/rcar-csi2.c
--
Sakari Ailus
e-mail: sakari.ai...@iki.fi
Add kerneldoc documentation for v4l2_ctrl_request_setup and
v4l2_ctrl_request_complete functions.
Signed-off-by: Sakari Ailus
---
include/media/v4l2-ctrls.h | 26 ++
1 file changed, 26 insertions(+)
diff --git a/include/media/v4l2-ctrls.h b/include/media/v4l2-ctrls.h
From: Alexandre Courbot
If 'which' is V4L2_CTRL_WHICH_REQUEST_VAL, then the 'request_fd' field
can be used to specify a request for the G/S/TRY_EXT_CTRLS ioctls.
Signed-off-by: Alexandre Courbot
Signed-off-by: Hans Verkuil
---
drivers/media/v4l2-core/v4l2-compat-ioctl32.c | 5 -
drivers/m
From: Hans Verkuil
Add a 'bool from_other_dev' argument: set to true if the two
handlers refer to different devices (e.g. it is true when
inheriting controls from a subdev into a main v4l2 bridge
driver).
This will be used later when implementing support for the
request API since we need to skip
From: Hans Verkuil
Integrate the request support. This adds the v4l2_ctrl_request_complete
and v4l2_ctrl_request_setup functions to complete a request and (as a
helper function) to apply a request to the hardware.
It takes care of queuing requests and correctly chaining control values
in the req
From: Hans Verkuil
Buffers can now be prepared or queued for a request.
A buffer is unbound from the request at vb2_buffer_done time or
when the queue is cancelled.
Signed-off-by: Hans Verkuil
---
drivers/media/common/videobuf2/videobuf2-core.c | 124 ++--
drivers/media/co
From: Hans Verkuil
Make vb2_buffer a request object.
Signed-off-by: Hans Verkuil
---
include/media/videobuf2-core.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/include/media/videobuf2-core.h b/include/media/videobuf2-core.h
index 224c4820a0443..3d54654c3cd48 100644
--- a/include/med
Instead of checking the media request state is idle at one point, lock the
request for updating during the S_EXT_CTRLS call. As a by-product, finding
the request has been moved out of the v4l2_ctrls_find_req_obj() in order
to keep request object lookups to the minimum.
Signed-off-by: Sakari Ailus
From: Hans Verkuil
To store request data the handler_new_ref() allocates memory
for it if needed.
Signed-off-by: Hans Verkuil
---
drivers/media/v4l2-core/v4l2-ctrls.c | 20
1 file changed, 16 insertions(+), 4 deletions(-)
diff --git a/drivers/media/v4l2-core/v4l2-ctrls.c
From: Hans Verkuil
The next patch needs the reference to a control instead of the
control itself, so change struct v4l2_ctrl_helper accordingly.
Signed-off-by: Hans Verkuil
---
drivers/media/v4l2-core/v4l2-ctrls.c | 18 +-
1 file changed, 9 insertions(+), 9 deletions(-)
diff -
From: Hans Verkuil
Embed and initialize a media_request_object in struct v4l2_ctrl_handler.
Add a p_req field to struct v4l2_ctrl_ref that will store the
request value.
Signed-off-by: Hans Verkuil
Signed-off-by: Alexandre Courbot
---
drivers/media/v4l2-core/v4l2-ctrls.c | 1 +
include/media/
From: Hans Verkuil
The userspace-provided plane data needs to be stored in
vb2_v4l2_buffer. Currently this information is applied by
__fill_vb2_buffer() which is called by the core prepare_buf
and qbuf functions, but when using requests these functions
aren't called yet since the buffer won't be
state is simply correct and optimal handling of requests.
Signed-off-by: Sakari Ailus
---
drivers/media/media-request.c | 3 ++-
include/media/media-request.h | 53 +++
2 files changed, 55 insertions(+), 1 deletion(-)
diff --git a/drivers/media/media
cancellation of a streaming operation.
We take the req_queue_mutex here before any other locks since
it is a very high-level lock.
[Sakari Ailus: No longer acquire req_queue_mutex for controls]
Signed-off-by: Hans Verkuil
Signed-off-by: Sakari Ailus
---
drivers/media/v4l2-core/v4l2-dev.c | 36
From: Hans Verkuil
Add media_request_object_find to find a request object inside a
request based on ops and/or priv values.
Objects of the same type (vb2 buffer, control handler) will have
the same ops value. And objects that refer to the same 'parent'
object (e.g. the v4l2_ctrl_handler that has
Grab the request spinlock to access media request state
Signed-off-by: Sakari Ailus
---
drivers/media/common/videobuf2/videobuf2-core.c | 16
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/drivers/media/common/videobuf2/videobuf2-core.c
b/drivers/media/common
2: add vb2_request_queue/validate helpers
v4l2-mem2mem: add vb2_m2m_request_queue
media: vim2m: add media device
vim2m: use workqueue
vim2m: support requests
vivid: add mc
vivid: add request support
RFC: media-requests: add debugfs node
Sakari Ailus (9):
media-request: Make request state an e
From: Hans Verkuil
Request API requires a media node. Add one to the vim2m driver so we can
use requests with it.
This probably needs a bit more work to correctly represent m2m
hardware in the media topology.
Signed-off-by: Hans Verkuil
---
drivers/media/platform/vim2m.c | 42
From: Hans Verkuil
Define the public request API.
This adds the new MEDIA_IOC_REQUEST_ALLOC ioctl to allocate a request
and two ioctls that operate on a request in order to queue the
contents of the request to the driver and to re-initialize the
request.
Signed-off-by: Hans Verkuil
---
includ
From: Hans Verkuil
This implements the V4L2 part of the request support. The main
change is that vb2_qbuf and vb2_prepare_buf now have a new
media_device pointer. This required changes to several drivers
that did not use the vb2_ioctl_qbuf/prepare_buf helper functions.
Signed-off-by: Hans Verkui
-by: Sakari Ailus
---
drivers/media/media-request.c | 57 ++-
include/media/media-request.h | 2 +-
2 files changed, 30 insertions(+), 29 deletions(-)
diff --git a/drivers/media/media-request.c b/drivers/media/media-request.c
index c7e11e816e272
From: Hans Verkuil
Add support for requests to vivid.
Signed-off-by: Hans Verkuil
---
drivers/media/platform/vivid/vivid-core.c| 8
drivers/media/platform/vivid/vivid-kthread-cap.c | 12
drivers/media/platform/vivid/vivid-kthread-out.c | 12
drivers/
901 - 1000 of 6671 matches
Mail list logo