Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp3774141pxb; Wed, 13 Oct 2021 12:40:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzffdSsUlrXc+1pta68h7YBywGxYyPJOxhOms7FyyZRoQz4gMe0P/lJHxVdk52ViFaVQRdf X-Received: by 2002:aa7:9f8f:0:b0:44c:cf63:ec7c with SMTP id z15-20020aa79f8f000000b0044ccf63ec7cmr1229158pfr.77.1634154001109; Wed, 13 Oct 2021 12:40:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634154001; cv=none; d=google.com; s=arc-20160816; b=MpOaiDmSaj3fLNQEhpqDiLLOhNxeOsoIFoavF5SxtlqrUflq5P4Jf5oHqrNh0R8iUh kFMTog9fObDLgj0mgb7ZdLyQg4OFxDAQACamCBXgnari1X80rbD7ohaQi68sNWeFHnba eAw9bD83elAF/dtNupQ6YzIQHNl6zy11GYYVZ0AaZEoE9IsEj8XRAa32Be/Q/1G5QbUg bZeqQp+H0lv6dUi7F4MU/CgYDWSzhuMYeNyPAWGJnMSCxkWlvfzad1EQ3/yz/WUiYzNP gfQ6SncPumXlt/Tb2FV6m8Mz4PI/mWIg8vZaU09oDVvzJFwqYhRrH4htCHAkiUuvhkQ3 LQWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:message-id:date:to:cc:from:subject :references:in-reply-to:content-transfer-encoding:mime-version :dkim-signature; bh=GZGjrnN3BqfyRpfJCMWRqnXrkKKBED6h68WfCB8Ej/A=; b=dVfsIERjGuwykV7V2Ud3wLNVbMqCOABvNV4RPY8vmnRIazYzsfNqD7VbkZqOUxGwGx 3JvkglHhoeadVN/BqX2jjczSBcLGHBWRYOvYIJd6Ev1lWo807rtUKuD3DyRMKHxZRyxd Y8mbclpWj5lCJihWw0q9FYdByywoHBLRKloIbWIlWluqHLi6pHp2BdatReFdEFVR5x8y givl7l2vbsukUxRPQkgcUHJlEk+G28PhTVIzh3vx/k/mH+HFYFiSK3a8Yr4Fxr/iFA7+ 3T1impnQUXSwIBTzgfb9LOC1OdMxtfCHj2kityhGra2ymWO1E729DqrA6LrSvHQj6GiP p9FA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="EPK/Y0ly"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id 8si559818pgp.636.2021.10.13.12.39.45; Wed, 13 Oct 2021 12:40:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="EPK/Y0ly"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S238259AbhJMTke (ORCPT + 99 others); Wed, 13 Oct 2021 15:40:34 -0400 Received: from mail.kernel.org ([198.145.29.99]:34102 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229989AbhJMTke (ORCPT ); Wed, 13 Oct 2021 15:40:34 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 80E156117A; Wed, 13 Oct 2021 19:38:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1634153910; bh=1/hjFW2ygJ0uYLiaRIcfmB5JWSBU8zq3TcAb9ayy3pE=; h=In-Reply-To:References:Subject:From:Cc:To:Date:From; b=EPK/Y0lyoOFy/Y/W96uc/dmmP03Rk8lGpdYx3KbuSMz5zXgV40tuI2OtIag2+d6ON Vh2wkCncLUDyXrtmcxY7GvOLfEp0rGNiE9d48u1C3vlfD8ZFAhuMQfRajOLCid1plB 2qvOJnNzl+j3kzke+qsLG2WIg64XX9/znfVk5+bOpS+UgEmQVsKtnu/cGjFgFLYZYH OugFhXrapAQDLIIDbpqJvAMw7yQyXUwHJHCxq2JJNz0W6rxwXWAD7cErb+ObGHGAu0 Cv0k2XS/VmklHbVN07uU95kVqMcba8fu9qOwsNi2EinyI9VX2qPQFt9Brybx0eRzsJ ENiHLA1WOtjSQ== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable In-Reply-To: <3bf1fbf3-e741-ef08-a4e4-b348b877d02a@quicinc.com> References: <1631860384-26608-1-git-send-email-quic_fenglinw@quicinc.com> <1631860384-26608-9-git-send-email-quic_fenglinw@quicinc.com> <163406051353.936959.12718174954614897750@swboyd.mtv.corp.google.com> <3bf1fbf3-e741-ef08-a4e4-b348b877d02a@quicinc.com> Subject: Re: [RESEND PATCH v1 8/9] spmi: pmic-arb: make interrupt support optional From: Stephen Boyd Cc: collinsd@codeaurora.org, subbaram@codeaurora.org To: Fenglin Wu , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Date: Wed, 13 Oct 2021 12:38:29 -0700 Message-ID: <163415390922.936959.12352892206436080955@swboyd.mtv.corp.google.com> User-Agent: alot/0.9.1 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Quoting Fenglin Wu (2021-10-13 01:36:54) >=20 > On 10/13/2021 1:41 AM, Stephen Boyd wrote: > > Quoting Fenglin Wu (2021-09-16 23:33:03) > >> From: David Collins > >> > >> Make the support of PMIC peripheral interrupts optional for > >> spmi-pmic-arb devices. This is useful in situations where > >> SPMI address mapping is required without the need for IRQ > >> support. > >> > >> Signed-off-by: David Collins > >> Signed-off-by: Fenglin Wu > >> --- > >> drivers/spmi/spmi-pmic-arb.c | 45 +++++++++++++++++++++++++++-------= ---------- > > Is there a binding update? Can the binding be converted to YAML as well? > This change doesn't add/update any dtsi properties but just checking if an > existing property is present to decide if IRQ support is required, so no > binding change is needed. The property is now optional in the binding. Please update the binding. > > > >> 1 file changed, 28 insertions(+), 17 deletions(-) > >> > >> diff --git a/drivers/spmi/spmi-pmic-arb.c b/drivers/spmi/spmi-pmic-arb= .c > >> index 988204c..55fa981 100644 > >> --- a/drivers/spmi/spmi-pmic-arb.c > >> +++ b/drivers/spmi/spmi-pmic-arb.c > >> @@ -1280,10 +1280,12 @@ static int spmi_pmic_arb_probe(struct platform= _device *pdev) > >> goto err_put_ctrl; > >> } > >> =20 > >> - pmic_arb->irq =3D platform_get_irq_byname(pdev, "periph_irq"); > >> - if (pmic_arb->irq < 0) { > >> - err =3D pmic_arb->irq; > >> - goto err_put_ctrl; > >> + if (of_find_property(pdev->dev.of_node, "interrupt-names", NUL= L)) { > > I don't think we should be keying off of interrupt-names. Instead we > > should be checking for something else. Maybe interrupt-controller > > property? > Sure, I can update it to check the presence of "interrupt-controller"=20 > property. Ok.