On Wed, Nov 21, 2012 at 07:21:02PM +0100, Guennadi Liakhovetski wrote:

> +     regmap_read(as3711->regmap, AS3711_ASIC_ID_1, &id1);
> +     regmap_read(as3711->regmap, AS3711_ASIC_ID_2, &id2);
> +     dev_info(as3711->dev, "AS3711 detected: %x:%x\n", id1, id2);
> +     if (id1 != 0x8b)
> +             return -ENODEV;

This looks odd - you're printing the "AS3711 detected" message prior to
checking the device ID which will be a bit confusing if there's a
problem.  Should probably do this after the ID check (and ideally also
check the return value of regmap_read(), it's especially important
during device identification where someone might've typoed the address).

Otherwise this looks good.

Attachment: signature.asc
Description: Digital signature

Reply via email to