Re: [PATCH v2] iio: dac: Add support for the AD5592R/AD5593R ADCs/DACs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Mar 21, 2016 at 3:07 PM, Michael Hennerich
<michael.hennerich@xxxxxxxxxx> wrote:
> On 03/11/2016 05:28 PM, Linus Walleij wrote:

>>>> +             mutex_lock(&iio_dev->mlock);
>>>> +             st->ops->reg_write(st, AD5592R_REG_RESET, 0xdac);
>>>> +             mutex_unlock(&iio_dev->mlock);
>>
>> What's that? (0xdac)? Clever magic?
>
> Clever magic - to avoid accidental resets.

I see. Put in a small comment like:

/* Writing this magic value resets the device */

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-gpio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux