Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp1344696imm; Fri, 28 Sep 2018 16:54:13 -0700 (PDT) X-Google-Smtp-Source: ACcGV638b4cUH/TxCZrLjF1AfdY+3d4ITS6fFmgfv1LfoTg4PA4byqhMmcnZSVLW1ufx149bXrjc X-Received: by 2002:a62:6c48:: with SMTP id h69-v6mr820013pfc.61.1538178853101; Fri, 28 Sep 2018 16:54:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538178853; cv=none; d=google.com; s=arc-20160816; b=0EZRI9QU+EH8ABwi7PfWjTPLFDDbTqzO0hbVMOHrOjSLQnFUr6qnQOnOmXG5tOAP1s HD+Wx1riloJLKU15c/qdAjaWyM63qemX4ihOYz7D3azDvrk2HM8mnx2w6GtL/a76oTk2 R5+Ug5iSRxsau2MQcHhI4BsGf0xC2kk2AMcoLZ4eMzRo3aNB2eR4YcFbw7jo0lOKdUG9 0covPxLH3zF2Z++YD1xyj+MWiWSxxJ8gDAqFcn4lhcLn4mH9OQPQHH7J1liCdqx13ETA cKKmv6DwRnu4XeYk1uEeQQWw0Rv77NSrM3io5ty7ko+2CJzfhzTwFOH5RH0u7IaolJR3 GTtA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=wFeDhWrzkHz2wn7alGZtUZHTIDC4pWNe1PJTeUpaJWA=; b=PhXnm9kl/nl60LgsI4k3tsy8gA3mRmNQUOz7i04ttv1euw7kOlw86W4Y3knKBughY5 ySn01Cu/KhxDwH4Xf+1HRBvG+eYJnVPwD2QCcHsCRDSNkFCdM+h2afyUvX8u1uHZ0kB1 hfNgiYehOtlQpRl6vku//SVsvdJjmRBjjftVj9bIPcJfXY3vnYjfnOU5kdSTjJWS3BIz gQR/xdaO2//k0DegFtfSlWjNAd9sDXwDPXXy4VSIT4ieX/t+8sX0FfiPdADZcEx/GPyW 8Q8E7mMZxuYGx8OSJ2zOlQi68+8M3jpE7RyvCP8W2uLB+zDNmrYJZthkiFbCcJZVxhaY Dz5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=BgdN6oFp; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e127-v6si6650635pfe.8.2018.09.28.16.53.58; Fri, 28 Sep 2018 16:54:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=BgdN6oFp; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727379AbeI2GSe (ORCPT + 99 others); Sat, 29 Sep 2018 02:18:34 -0400 Received: from mail.kernel.org ([198.145.29.99]:56906 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726804AbeI2GSe (ORCPT ); Sat, 29 Sep 2018 02:18:34 -0400 Received: from mail-qt1-f179.google.com (mail-qt1-f179.google.com [209.85.160.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D1817206B6; Fri, 28 Sep 2018 23:52:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1538178746; bh=NNcSMbNweO7EpssOcZLVZT/m+fF9WWksGyYkkEvn98A=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=BgdN6oFpW3xvIgeraIGo13ygm3KLOkF1Ue6E/r75Aqubn0C9Fwutar+cMXtS/LepM p0U9Y6fQ7HZ9q/UG2AfX7We0d1npAWT3MDJ/IugLjd8EcknUOFZi9vD3Z8pmB6yR/w Pj4+uS0xe/OfJsar2ZmwTeyhcPsDCuSRybuAmM/w= Received: by mail-qt1-f179.google.com with SMTP id z13-v6so8538014qts.5; Fri, 28 Sep 2018 16:52:25 -0700 (PDT) X-Gm-Message-State: ABuFfoiVKYNdif5A7QIOOaz2LjfC+oVxMu5jok8ixes51zLYE2T2F+R1 mL5FQtgooxCLJR3gbc9aactdmOFI71zvCYvAag== X-Received: by 2002:ac8:190e:: with SMTP id t14-v6mr702816qtj.327.1538178745050; Fri, 28 Sep 2018 16:52:25 -0700 (PDT) MIME-Version: 1.0 References: <20180918082422.13050-1-songqiang1304521@gmail.com> <20180918082422.13050-2-songqiang1304521@gmail.com> <20180922160523.16b399fc@archlinux> <20180926224618.GA32126@bogus> <20180928093618.GA24536@Eros> In-Reply-To: <20180928093618.GA24536@Eros> From: Rob Herring Date: Fri, 28 Sep 2018 18:52:13 -0500 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v6 2/2] iio: proximity: vl53l0x: add interrupt support To: Song Qiang Cc: Jonathan Cameron , Hartmut Knaack , Lars-Peter Clausen , Peter Meerwald , Mark Rutland , Andy Shevchenko , Matt Ranostay , Thomas Gleixner , Andreas Klinger , linux-iio@vger.kernel.org, "linux-kernel@vger.kernel.org" , devicetree@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 28, 2018 at 4:36 AM Song Qiang wrote: > > On Wed, Sep 26, 2018 at 05:46:18PM -0500, Rob Herring wrote: > > On Sat, Sep 22, 2018 at 04:05:23PM +0100, Jonathan Cameron wrote: > > > On Tue, 18 Sep 2018 16:24:22 +0800 > > > Song Qiang wrote: > > > > > > > The first version of this driver issues a measuring request and polling > > > > for a status register in the device for measuring completes. > > > > vl53l0x support configuring GPIO1 on it to generate interrupt to > > > > indicate that new measurement is ready. This patch adds support for > > > > using this mechanisim to reduce cpu cost. > > > > > > > > Signed-off-by: Song Qiang > > > Hi Song. > > > > > > Looks correct in principal but a few things to tidy up before > > > this is ready to apply. > > > > > > Also we have an unrelated change in here to check the devices ID. > > > That should be in it's own patch. > > > > > > Thanks, > > > > > > Jonathan > > > > --- > > > > .../bindings/iio/proximity/vl53l0x.txt | 14 +- > > > > This should have been split with the complete binding in one patch > > rather than piecemeal driver feature by feature. > > > > Hi Rob, > > A few days ago when I was submitting this driver, I didn't do it very > well, the function of this driver is limited. I added interrupt support > the next day after you acked my first patch. I thought it's not polite > to add something after someone acked that patch, so I send the interrupt > support as a second patch. The first patch is merged to togreg now, but > this doesn't. I don't know when can I add new functions to the code that > just merged to togreg branch, could you offer some suggestions? You just needed to state why you didn't add a ack. But really, just don't send things except as RFC until they are "done". What to do next depends on Jonathan and whether he wants a follow-up patch or he will drop the first one. > > > > drivers/iio/proximity/vl53l0x-i2c.c | 135 +++++++++++++++--- > > > > 2 files changed, 129 insertions(+), 20 deletions(-) > > > > > > > > diff --git a/Documentation/devicetree/bindings/iio/proximity/vl53l0x.txt b/Documentation/devicetree/bindings/iio/proximity/vl53l0x.txt > > > > index ab9a9539fec4..40290f8dd70f 100644 > > > > --- a/Documentation/devicetree/bindings/iio/proximity/vl53l0x.txt > > > > +++ b/Documentation/devicetree/bindings/iio/proximity/vl53l0x.txt > > > > @@ -4,9 +4,21 @@ Required properties: > > > > - compatible: must be "st,vl53l0x-i2c" > > > > Is there more than one interface on this device, such as SPI? If not, > > then '-i2c' should be dropped. > > > > Yes, there is a CCI(Camera Control Interface) for communication. Isn't CCI just a subset of I2C? I should clarify my question is whether there's more than 1 mutually exclusive control interface (as many devices have control and data interfaces) where you could have 2 different drivers. A common example are devices with I2C and SPI interfaces. Rob