From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752843AbcEJPtK (ORCPT ); Tue, 10 May 2016 11:49:10 -0400 Received: from mail-pf0-f176.google.com ([209.85.192.176]:33588 "EHLO mail-pf0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751036AbcEJPtI (ORCPT ); Tue, 10 May 2016 11:49:08 -0400 Date: Tue, 10 May 2016 08:49:04 -0700 From: Bjorn Andersson To: Andrew Duggan Cc: Dmitry Torokhov , Rob Herring , Pawel Moll , Mark Rutland , Ian Campbell , Christopher Heiny , linux-input@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Benjamin Tissoires Subject: Re: [PATCH v2 0/3] input: rmi4: Regulator supply support Message-ID: <20160510154904.GI1256@tuxbot> References: <1462596008-21381-1-git-send-email-bjorn.andersson@linaro.org> <57312CFB.2040304@synaptics.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <57312CFB.2040304@synaptics.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon 09 May 17:36 PDT 2016, Andrew Duggan wrote: > Hi Bjorn, > > On 05/06/2016 09:40 PM, Bjorn Andersson wrote: > >The first version of the regulator support patch suffered from being > >implemented in the transport driver, as a work around for resource availability > >racing (EPROBE_DEFER of the core driver) with the interrupt handler. > > > >After reconsidering the solutions discussed following that I concluded that the > >interrupt management is not really part of the transport, neither conceptually > >or electrically. I therefor here suggest (patch 1/3) to move the interrupt > >registration and handling to the core rmi driver. > > My concern with moving interrupt processing to the core is that not all > transports report attn to the rmi core using an irq. The HID and SMBus > transports which are currently in development, reside a little higher in the > stack and attention is reported using different mechanisms. We moved > interrupt handling to the transport drivers so that they could handle the > differences in how attn is reported. > I suspected that to be the case. > This message has some of the previous discussion regarding interrupt > processing: > https://lkml.org/lkml/2015/11/28/123 > > Similarly, not all transports will need support for regulators. Implementing > both in the transport drivers avoids the EPROBE_DEFER racing and avoids > adding checks in the core to see if it needs to handle interrupts and manage > regulators. > So either we duplicate the regulator support in spi/i2c or we make them optional in the core driver. Sounds like you prefer the prior, i.e. v1 of my patch. Regards, Bjorn