From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.aswsp.com ([193.34.35.150]:54575 "EHLO mail.aswsp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754265AbcIGI3K (ORCPT ); Wed, 7 Sep 2016 04:29:10 -0400 Message-ID: <57CFD0CB.2070508@parrot.com> Date: Wed, 7 Sep 2016 10:33:15 +0200 From: Gregor Boirie MIME-Version: 1.0 To: Linus Walleij , Jonathan Cameron CC: "linux-iio@vger.kernel.org" , Hartmut Knaack , Lars-Peter Clausen , Peter Meerwald-Stadler , Rob Herring , Mark Rutland , Jonathan Corbet , Laxman Dewangan , Alexander Kurz , Tejun Heo , Stephen Boyd , Akinobu Mita , Daniel Baluta , Ludovic Tancerel , Vlad Dogaru , Marek Vasut , Crestez Dan Leonard , Neil Armstrong , Masahiro Yamada , Arnd Bergmann Subject: Re: [PATCH v3 3/3] iio:pressure: initial zpa2326 barometer support References: <53b4bcc7b2d5de2ed61a0aeebf0898fd7b5aa2cb.1472841954.git.gregor.boirie@parrot.com> In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Sender: linux-iio-owner@vger.kernel.org List-Id: linux-iio@vger.kernel.org On 09/07/2016 09:54 AM, Linus Walleij wrote: > On Sun, Sep 4, 2016 at 6:22 PM, Jonathan Cameron wrote: > >> The nasty here is that we need to validate that the trigger is associate >> with this device 'before' allowing others to associate. Could be done I >> think in a slightly more than average complexity validate call. >> >> * If another trigger is used then pollfunc would have to initialize a oneshot >> read as you already have it doing. > I guess the new function iio_trigger_using_own() would be pretty helpful > for this driver too. Yes! I was just looking at your patch :) It would allow me to get rid of pointer to own trigger stored in iio device's private state. Good point. > > Do you think we can merge patch 1+2 of that series (adding the function > and using it with the ST sensors) and I will squash patch > 3 into my pending MPU-3050 driver and then this driver can rely on it > as well? > > The way I see it is that when handling triggers we should always handle > our own as well as any external trigger (e.g. HRTimer, or even a trigger > from a different sensor...) > > Yours, > Linus Walleij