From patchwork Tue Sep 25 03:17:23 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Song Qiang X-Patchwork-Id: 10613277 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 7BF6A112B for ; Tue, 25 Sep 2018 03:17:37 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6521F29AEE for ; Tue, 25 Sep 2018 03:17:37 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5867429AF9; Tue, 25 Sep 2018 03:17:37 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E9C3829AEE for ; Tue, 25 Sep 2018 03:17:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728073AbeIYJWz (ORCPT ); Tue, 25 Sep 2018 05:22:55 -0400 Received: from mail-pf1-f194.google.com ([209.85.210.194]:41130 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727503AbeIYJWy (ORCPT ); Tue, 25 Sep 2018 05:22:54 -0400 Received: by mail-pf1-f194.google.com with SMTP id m77-v6so1484743pfi.8; Mon, 24 Sep 2018 20:17:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=i27eoIRURIs0+vIDJ8A6Lr6wvThnfMnF5bV0qpvXErI=; b=fY+PuYzr0QVkslJvK9SYzQKulSX+6lx1U2NJtedypp7Ty/aNDlHoPWXNN8Mfk1TCtf 49NO0R2uOTS5fyLJjXZaio6nMqg6KlRkCDFUnq1fgaAoVr8UFt0MaRNy5YltVPvB0uY4 DT5qdzDuc5xhKpTSfDXtbiZSWTPvFFBpSh8P/FlfrEOlXf/PgmvH8FFNl7v+kCUTN2Di YCL6cXYsXUjMAJq3UNj/2sQ9ETcFmgCv8SvPFiybIVtrhfAGCpY7eQHLi7lPplzKIYYz Ql/wGcrvwC+sNn4wBVVfMSpeUsrcGtO4vDKGY+0YoZIKq9Ciz39u48bZt8V5btKtglwH m6UQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=i27eoIRURIs0+vIDJ8A6Lr6wvThnfMnF5bV0qpvXErI=; b=VI/0c4k0mwAJl9t01eM6IY68E/3jO+u97d34JQC/LdWbufMoVTg9glmXGW8WaeXxM9 P1YUg/YypWWzdn/Fo7+GIsX22lJa2J+6xHPGQ6G2LZtiAhqcxg2nByl3Q51HEW3nFrGR rKsabENPOh4dAKzAbfi0wUx6PLLyjZYqQzRlDXOE17DyWgIUPOOFu361hBU2C4ak5/lk 8DHeoghFUWqnJnktJ7q/Nv3VzApaBM0csXQZrjZarkbH4iYShQdNhl9f/Eeml6lim1dG ansAt74MHCjuMBHyn2ABSlstmFYHN3hCG1vRDxhdidnPrMz6GTD3b2kjcpc3r4G2hL5K w1cQ== X-Gm-Message-State: ABuFfogMEaWACafxf5ZGoP9zBRidNVOp4uhJCQsrVXR2Ks3uomem2o7i jxzXOwmsKTMK/akGT1nF7Z4= X-Google-Smtp-Source: ACcGV62V/bRYJY+ng0QWONg2ezi8+yFWLAF18IpECnXYHu1PSGQ1XcJ+yp5U1zzZtVj0OU6gNNViuQ== X-Received: by 2002:a17:902:7887:: with SMTP id q7-v6mr1425638pll.111.1537845451584; Mon, 24 Sep 2018 20:17:31 -0700 (PDT) Received: from localhost (104.176.229.35.bc.googleusercontent.com. [35.229.176.104]) by smtp.gmail.com with ESMTPSA id n9-v6sm967993pfg.21.2018.09.24.20.17.30 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 24 Sep 2018 20:17:31 -0700 (PDT) From: Song Qiang To: jic23@kernel.org, knaack.h@gmx.de, lars@metafoo.de, pmeerw@pmeerw.net, robh+dt@kernel.org, mark.rutland@arm.com Cc: preid@electromag.com.au, rtresidd@electromag.com.au, linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Song Qiang Subject: [PATCH 1/2] iio: magnetometer: Add DT support for PNI RM3100 Date: Tue, 25 Sep 2018 11:17:23 +0800 Message-Id: <20180925031724.21399-1-songqiang1304521@gmail.com> X-Mailer: git-send-email 2.17.1 Sender: linux-iio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP PNI RM3100 is a high resolution, large signal immunity magnetometer, composed of 3 single sensors and a processing chip with MagI2C Interface. PNI is not in the vendors' list, so this patch is also adding it. Signed-off-by: Song Qiang --- Changes in v2: - Remove bus specific part in compatible string. .../bindings/iio/magnetometer/pni,rm3100.txt | 20 +++++++++++++++++++ .../devicetree/bindings/vendor-prefixes.txt | 1 + 2 files changed, 21 insertions(+) create mode 100644 Documentation/devicetree/bindings/iio/magnetometer/pni,rm3100.txt diff --git a/Documentation/devicetree/bindings/iio/magnetometer/pni,rm3100.txt b/Documentation/devicetree/bindings/iio/magnetometer/pni,rm3100.txt new file mode 100644 index 000000000000..4677690fc5d0 --- /dev/null +++ b/Documentation/devicetree/bindings/iio/magnetometer/pni,rm3100.txt @@ -0,0 +1,20 @@ +* PNI RM3100 3-axis magnetometer sensor + +Required properties: + +- compatible : should be "pni,rm3100" +- reg : the I2C address or SPI chip select number of the sensor. + +Optional properties: + +- interrupts: data ready (DRDY) from the chip. + The interrupts can be triggered on rising edges. + +Example: + +rm3100: rm3100@20 { + compatible = "pni,rm3100"; + reg = <0x20>; + interrupt-parent = <&gpio0>; + interrupts = <4 IRQ_TYPE_EDGE_RISING>; +}; diff --git a/Documentation/devicetree/bindings/vendor-prefixes.txt b/Documentation/devicetree/bindings/vendor-prefixes.txt index 41f0b97eb933..5bf3395fe9ae 100644 --- a/Documentation/devicetree/bindings/vendor-prefixes.txt +++ b/Documentation/devicetree/bindings/vendor-prefixes.txt @@ -288,6 +288,7 @@ pine64 Pine64 pixcir PIXCIR MICROELECTRONICS Co., Ltd plathome Plat'Home Co., Ltd. plda PLDA +pni PNI portwell Portwell Inc. poslab Poslab Technology Co., Ltd. powervr PowerVR (deprecated, use img)