lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Sat, 3 Jun 2017 12:38:01 -0700
From:   Steve Longerbeam <slongerbeam@...il.com>
To:     Sakari Ailus <sakari.ailus@....fi>, Pavel Machek <pavel@....cz>
Cc:     robh+dt@...nel.org, mark.rutland@....com, shawnguo@...nel.org,
        kernel@...gutronix.de, fabio.estevam@....com,
        linux@...linux.org.uk, mchehab@...nel.org, hverkuil@...all.nl,
        nick@...anahar.org, markus.heiser@...marIT.de,
        p.zabel@...gutronix.de, laurent.pinchart+renesas@...asonboard.com,
        bparrot@...com, geert@...ux-m68k.org, arnd@...db.de,
        sudipm.mukherjee@...il.com, minghsiu.tsai@...iatek.com,
        tiffany.lin@...iatek.com, jean-christophe.trotin@...com,
        horms+renesas@...ge.net.au, niklas.soderlund+renesas@...natech.se,
        robert.jarzmik@...e.fr, songjun.wu@...rochip.com,
        andrew-ct.chen@...iatek.com, gregkh@...uxfoundation.org,
        shuah@...nel.org, sakari.ailus@...ux.intel.com,
        devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org, linux-media@...r.kernel.org,
        devel@...verdev.osuosl.org,
        Steve Longerbeam <steve_longerbeam@...tor.com>
Subject: Re: [PATCH v7 16/34] [media] add Omnivision OV5640 sensor driver



On 06/01/2017 01:26 AM, Sakari Ailus wrote:
> Hi Pavel,
> 
> On Wed, May 31, 2017 at 09:58:21PM +0200, Pavel Machek wrote:
>> Hi!
>>
>>> +/* min/typical/max system clock (xclk) frequencies */
>>> +#define OV5640_XCLK_MIN  6000000
>>> +#define OV5640_XCLK_MAX 24000000
>>> +
>>> +/*
>>> + * FIXME: there is no subdev API to set the MIPI CSI-2
>>> + * virtual channel yet, so this is hardcoded for now.
>>> + */
>>> +#define OV5640_MIPI_VC	1
>>
>> Can the FIXME be fixed?
> 
> Yes, but it's quite a bit of work. It makes sense to use a static virtual
> channel for now. A patchset which is however incomplete can be found here:
> 
> <URL:https://git.linuxtv.org/sailus/media_tree.git/log/?h=vc>
> 
> For what it's worth, all other devices use virtual channel zero for image
> data and so should this one.


Actually no. The CSI2IPU gasket in i.MX6 quad sends virtual channel 0
streams to IPU1-CSI0. But input to IPU1-CSI0 is also muxed with parallel
bus cameras. So if vc0 were chosen instead, platforms that support
parallel cameras to IPU1-CSI0 (SabreLite, SabreSD) would not be able
to use them concurrently with a MIPI CSI-2 source to IPU1-CSI1. So I
prefer to use static channel 1 to support those platforms.

I could convert this to a module parameter however, until a virtual
channel selection subdev API becomes available, at which point that
would have to be stripped.


> 
>>
>>> +/*
>>> + * image size under 1280 * 960 are SUBSAMPLING
>>
>> -> Image
>>
>>> + * image size upper 1280 * 960 are SCALING
>>
>> above?
>>


done.

>>> +/*
>>> + * FIXME: all of these register tables are likely filled with
>>> + * entries that set the register to their power-on default values,
>>> + * and which are otherwise not touched by this driver. Those entries
>>> + * should be identified and removed to speed register load time
>>> + * over i2c.
>>> + */
>>
>> load->loading? Can the FIXME be fixed?

That's a lot of work, and risky work at that. If someone could take
this on (strip out power-on default values from the tables), I'd
be grateful, but I don't have the time. For now at least, these
registers sets work fine.


>>
>>> +	/* Auto/manual exposure */
>>> +	ctrls->auto_exp = v4l2_ctrl_new_std_menu(hdl, ops,
>>> +						 V4L2_CID_EXPOSURE_AUTO,
>>> +						 V4L2_EXPOSURE_MANUAL, 0,
>>> +						 V4L2_EXPOSURE_AUTO);
>>> +	ctrls->exposure = v4l2_ctrl_new_std(hdl, ops,
>>> +					    V4L2_CID_EXPOSURE_ABSOLUTE,
>>> +					    0, 65535, 1, 0);
>>
>> Is exposure_absolute supposed to be in microseconds...?
> 
> Yes.

According to the docs V4L2_CID_EXPOSURE_ABSOLUTE is in 100 usec units.

  OTOH V4L2_CID_EXPOSURE has no defined unit, so it's a better fit IMO.
> Way more drivers appear to be using EXPOSURE than EXPOSURE_ABSOLUTE, too.

Done, switched to V4L2_CID_EXPOSURE. It's true, this control is not
taking 100 usec units, so unit-less is better.


Steve

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ