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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 9 Feb 2017 12:02:55 +0200
From:   Sakari Ailus <sakari.ailus@....fi>
To:     Ramiro Oliveira <Ramiro.Oliveira@...opsys.com>
Cc:     Sakari Ailus <sakari.ailus@...ux.intel.com>,
        linux-media@...r.kernel.org, linux-kernel@...r.kernel.org,
        devicetree@...r.kernel.org, CARLOS.PALMINHA@...opsys.com,
        "David S. Miller" <davem@...emloft.net>,
        Geert Uytterhoeven <geert+renesas@...der.be>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Guenter Roeck <linux@...ck-us.net>,
        Hans Verkuil <hans.verkuil@...co.com>,
        Mark Rutland <mark.rutland@....com>,
        Mauro Carvalho Chehab <mchehab@...nel.org>,
        Pavel Machek <pavel@....cz>,
        Robert Jarzmik <robert.jarzmik@...e.fr>,
        Rob Herring <robh+dt@...nel.org>,
        Steve Longerbeam <slongerbeam@...il.com>
Subject: Re: [PATCH RESEND v7 2/2] Add support for OV5647 sensor.

Hi Ramiro,

On Wed, Feb 08, 2017 at 09:56:12AM +0000, Ramiro Oliveira wrote:
> Hi Sakari
> 
> On 2/7/2017 5:31 PM, Sakari Ailus wrote:
> > Hi Ramiro,
> > 
> > On Mon, Feb 06, 2017 at 11:38:28AM +0000, Ramiro Oliveira wrote:
> > ...
> >>>> +	ret = ov5647_write_array(sd, ov5647_640x480,
> >>>> +					ARRAY_SIZE(ov5647_640x480));
> >>>> +	if (ret < 0) {
> >>>> +		dev_err(&client->dev, "write sensor_default_regs error\n");
> >>>> +		return ret;
> >>>> +	}
> >>>> +
> >>>> +	ov5647_set_virtual_channel(sd, 0);
> >>>> +
> >>>> +	ov5647_read(sd, 0x0100, &resetval);
> >>>> +	if (!(resetval & 0x01)) {
> >>>
> >>> Can this ever happen? Streaming start is at the end of the register list.
> >>>
> >>
> >> I'm not sure it can happen. It was just a safeguard, but I can remove it if you
> >> think it's not necessary
> > 
> > You're not reading back the other registers either, albeit I'd check that
> > the I2C accesses actually succeed. Generally the return values are ignored.
> > 
> 
> So you're recommending I perform a random I2C access after power on to check the
> system, and discard the read value? Or just drop this piece of code entirely?
> 

I'm not. What I'm saying that you're mostly not checking whether I2C
accesses succeed or not.

-- 
Regards,

Sakari Ailus
e-mail: sakari.ailus@....fi	XMPP: sailus@...iisi.org.uk

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ