Re: [PATCH v2 2/7] iio: adc: ad7791: claim direct mode when writing frequency

2016-06-03 Thread Jonathan Cameron
On 01/06/16 20:10, Lars-Peter Clausen wrote: > On 06/01/2016 06:35 AM, Alison Schofield wrote: >> Driver was checking for direct mode and trying to lock it, but >> left a gap where mode could change before the desired operation. >> Use iio_device_claim_direct_mode() to guarantee device stays in >>

Re: [PATCH v2 2/7] iio: adc: ad7791: claim direct mode when writing frequency

2016-06-03 Thread Jonathan Cameron
On 01/06/16 20:10, Lars-Peter Clausen wrote: > On 06/01/2016 06:35 AM, Alison Schofield wrote: >> Driver was checking for direct mode and trying to lock it, but >> left a gap where mode could change before the desired operation. >> Use iio_device_claim_direct_mode() to guarantee device stays in >>

Re: [PATCH v2 2/7] iio: adc: ad7791: claim direct mode when writing frequency

2016-06-01 Thread Lars-Peter Clausen
On 06/01/2016 06:35 AM, Alison Schofield wrote: > Driver was checking for direct mode and trying to lock it, but > left a gap where mode could change before the desired operation. > Use iio_device_claim_direct_mode() to guarantee device stays in > direct mode. > > Refactor function to clarify

Re: [PATCH v2 2/7] iio: adc: ad7791: claim direct mode when writing frequency

2016-06-01 Thread Lars-Peter Clausen
On 06/01/2016 06:35 AM, Alison Schofield wrote: > Driver was checking for direct mode and trying to lock it, but > left a gap where mode could change before the desired operation. > Use iio_device_claim_direct_mode() to guarantee device stays in > direct mode. > > Refactor function to clarify

[PATCH v2 2/7] iio: adc: ad7791: claim direct mode when writing frequency

2016-05-31 Thread Alison Schofield
Driver was checking for direct mode and trying to lock it, but left a gap where mode could change before the desired operation. Use iio_device_claim_direct_mode() to guarantee device stays in direct mode. Refactor function to clarify look-up followed by lock sequence. Signed-off-by: Alison

[PATCH v2 2/7] iio: adc: ad7791: claim direct mode when writing frequency

2016-05-31 Thread Alison Schofield
Driver was checking for direct mode and trying to lock it, but left a gap where mode could change before the desired operation. Use iio_device_claim_direct_mode() to guarantee device stays in direct mode. Refactor function to clarify look-up followed by lock sequence. Signed-off-by: Alison