From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1765598AbdAKQZ1 (ORCPT ); Wed, 11 Jan 2017 11:25:27 -0500 Received: from vern.gendns.com ([206.190.152.46]:38212 "EHLO vern.gendns.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1765581AbdAKQZZ (ORCPT ); Wed, 11 Jan 2017 11:25:25 -0500 Subject: Re: [PATCH v2 5/5] ARM: dts: Add LEGO MINDSTORMS EV3 dts To: Sekhar Nori References: <1483677228-2325-1-git-send-email-david@lechnology.com> <1483677228-2325-6-git-send-email-david@lechnology.com> Cc: Kevin Hilman , Rob Herring , Mark Rutland , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org From: David Lechner Message-ID: <1dd57ac3-554f-7d66-97b0-b76c3ddc7854@lechnology.com> Date: Wed, 11 Jan 2017 10:25:18 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - vern.gendns.com X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lechnology.com X-Get-Message-Sender-Via: vern.gendns.com: authenticated_id: davidmain+lechnology.com/only user confirmed/virtual account not confirmed X-Authenticated-Sender: vern.gendns.com: davidmain@lechnology.com X-Source: X-Source-Args: X-Source-Dir: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/11/2017 04:42 AM, Sekhar Nori wrote: > On Friday 06 January 2017 10:03 AM, David Lechner wrote: > >> + beeper { >> + compatible = "pwm-beeper"; >> + pinctrl-names = "default"; >> + pinctrl-0 = <&ehrpwm0b_pins>, <&_pins>; >> + pwms = <&ehrpwm0 1 0 0>; >> + enable-gpios = <&gpio 111 GPIO_ACTIVE_HIGH>; > > Since the enable-gpios binding for pwm beeper is still not accepted, can > you drop the property or the node itself (if that makes more sense)? No sound will come out of the speaker without enabling this gpio. So, I guess I will just drop this node for now. > >> +&spi0 { >> + status = "okay"; >> + pinctrl-names = "default"; >> + pinctrl-0 = <&spi0_pins>, <&spi0_cs0_pin>, <&spi0_cs3_pin>; >> + >> + flash@0 { >> + compatible = "n25q128a13", "jedec,spi-nor"; >> + reg = <0>; >> + spi-max-frequency = <50000000>; >> + ti,spi-wdelay = <8>; >> + >> + /* Partitions are based on the official firmware from LEGO */ >> + partitions { >> + #address-cells = <1>; >> + #size-cells = <1>; >> + partition@0 { >> + label = "U-Boot"; >> + reg = <0 0x40000>; >> + }; >> + >> + partition@40000 { >> + label = "U-Boot Env"; >> + reg = <0x40000 0x10000>; >> + }; >> + >> + partition@50000 { >> + label = "Kernel"; >> + reg = <0x50000 0x200000>; >> + }; >> + >> + partition@250000 { >> + label = "Filesystem"; >> + reg = <0x250000 0xa50000>; >> + }; >> + >> + partition@cb0000 { >> + label = "Storage"; >> + reg = <0xcb0000 0x2f0000>; >> + }; >> + }; >> + }; >> + >> + adc@3 { >> + compatible = "ti-ads7957"; > > So looks like this works because of_register_spi_device() sets up > modalias of spi device from compatible string. I am fine with it, just > highlighting it here to make sure this is acceptable practice. I did not > really find any precedence for using SPI device name as compatible > property in existing DTS files. Indeed. It looks like this sort of "trivial" device binding is just used for i2c devices. I will submit some patches to add proper device tree bindings and change this to "ti,ads7957". > >> + reg = <3>; >> + spi-max-frequency = <10000000>; >> + refin-supply = <&adc_ref>; >> + }; > > Rest of the patch looks good to me. > > Thanks, > Sekhar >