Received: by 2002:a05:6a10:6006:0:0:0:0 with SMTP id w6csp1982311pxa; Sat, 29 Aug 2020 09:52:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwWrcwBqnAQRlpa9Cc/8k5rk3KiR7oZa2PIU8LZ/QXNwpjeTV6a7NLndMWEnGgbaY277lOV X-Received: by 2002:a05:6402:b72:: with SMTP id cb18mr3950747edb.299.1598719939911; Sat, 29 Aug 2020 09:52:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598719939; cv=none; d=google.com; s=arc-20160816; b=D9EFGwyAOG6nX7Pe3mZ029SuT2vFe7E1k+z7pbRso5eRbCxN696qnkLmFHZtPeL2E/ fr+y6PjqpcvZhD3muba24H706hHHCTu8Np8Sj8WmbkDGm9tiaGG7wN/JN22GhhgJVdqQ gjzHfl9OMgDsLgfddYik9b48hx94py6VEto1/66D2K/r91ewq0vLrxRf9GSqw0OzTQ2O 9vEPwo9bM8B/oqXUpxSE351oYwnW1oxR8vDP1d7pOh/FUvncjkuxoXwMKRAADha1ALOM yuu2K7fmQhdae4eECVeh93p4hKKyMdJO0odp2ZZwS0vSMMbkBiFfTYihGoFsZCdkhaq9 O+yA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=drnMWn5J7uFf/unNGu/tbKTOCklphVYdaI09sHRBxuc=; b=YCqnrYIBxjJ2+UAxaFi4LVUdp3Xcx2hNeULuoRhVpxBCRFj6Ok9qI173FSGg71AgAv Pd8hlf4Qyyw0gMhb40HmLU2qc+Vcs4IrocQP628wm0oj4sn7XLJqw3XpMBVs0rDsmhUd PIfLGQP9wyB8r2LzA7EyOLFMXqSMmi245wqxWYSVkbq+vvVAJNhlofWbqMAVPGQ+EJiB h6Z1tGlJsTjetouJwTPYZm8wDj0IhfL8PuJz5E1eqSdtCoMTv0vfswoLpeHrz7Ququ0z fvgny/FonUWiOFYhwfAQ+7Owt4uniZpjEOwgPVu0HaafR2Brcv00B+D54Y88u4nLRVkM B1MQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=N8eo6hWl; 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 k3si1817397edr.476.2020.08.29.09.51.56; Sat, 29 Aug 2020 09:52:19 -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=default header.b=N8eo6hWl; 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 S1728470AbgH2Qsx (ORCPT + 99 others); Sat, 29 Aug 2020 12:48:53 -0400 Received: from mail.kernel.org ([198.145.29.99]:47608 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726562AbgH2Qsu (ORCPT ); Sat, 29 Aug 2020 12:48:50 -0400 Received: from archlinux (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 8780320791; Sat, 29 Aug 2020 16:48:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1598719729; bh=oStdbXzIEINY68GBdcZq2e4qRczvBTpiM+H0TZy4H8c=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=N8eo6hWlyndWhlkSpFhr0xRXj51Z2n9sFYXzJcHGk4l+XYV99lQ4no85bQi1Hmbsh gmJQCENTlbFXO+iyt3On6VWPak1wUXI6+jrSGg3/gJnMUVtrguOL77Sik8mgm8LrFE NRbrYkTjeJb0cDP/bIQgci8BdRtV6av8VRAOC1xI= Date: Sat, 29 Aug 2020 17:48:45 +0100 From: Jonathan Cameron To: Nishant Malpani Cc: robh+dt@kernel.org, dragos.bogdan@analog.com, darius.berghe@analog.com, linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org, devicetree@vger.kernel.org Subject: Re: [PATCH 2/3] dt-bindings: iio: gyro: adxrs290: Add required interrupts property Message-ID: <20200829174845.7fae971d@archlinux> In-Reply-To: <20200825124711.11455-3-nish.malpani25@gmail.com> References: <20200825124711.11455-1-nish.malpani25@gmail.com> <20200825124711.11455-3-nish.malpani25@gmail.com> X-Mailer: Claws Mail 3.17.6 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 25 Aug 2020 18:17:10 +0530 Nishant Malpani wrote: > Append 'interrupts' as a required property and provide a suitable example > for using a GPIO interrupt line. > > Signed-off-by: Nishant Malpani Hi Nishant, I don't understand why the interrupt is 'required'. Also note you should never be adding required properties to an existing binding. It's possible someone already used the binding as it stands and shipped a board with it burnt in a firmware. (bit unlikely but you never know!) Jonathan > --- > .../devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml | 8 ++++++++ > 1 file changed, 8 insertions(+) > > diff --git a/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml b/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml > index 61adb2c2454b..cae593dd1ba7 100644 > --- a/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml > +++ b/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml > @@ -28,17 +28,23 @@ properties: > > spi-cpha: true > > + interrupts: > + maxItems: 1 > + > required: > - compatible > - reg > - spi-max-frequency > - spi-cpol > - spi-cpha > + - interrupts Why? Device works fine without one being supplied. It's not uncommon on embedded boards to not wire up interrupts due to a lack of pins and just rely on polling. > > additionalProperties: false > > examples: > - | > + #include > + #include > spi { > #address-cells = <1>; > #size-cells = <0>; > @@ -48,6 +54,8 @@ examples: > spi-max-frequency = <5000000>; > spi-cpol; > spi-cpha; > + interrupt-parent = <&gpio>; > + interrupts = <25 IRQ_TYPE_EDGE_RISING>; > }; > }; > ...