Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1434136
| Path | csiph.com!news.freedyn.net!aioe.org!gothmog.csi.it!bofh.it!news.nic.it!robomod |
|---|---|
| From | Stephen Boyd <stephen.boyd@linaro.org> |
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware |
| Date | Thu, 30 Jun 2016 03:10:01 +0200 |
| Message-ID | <rPyEp-32M-3@gated-at.bofh.it> (permalink) |
| References | <rObgS-7hv-5@gated-at.bofh.it> <rOgqe-2jQ-13@gated-at.bofh.it> <rP002-6Rk-23@gated-at.bofh.it> <rP002-6Rk-21@gated-at.bofh.it> <rPhax-GR-13@gated-at.bofh.it> <rPhax-GR-15@gated-at.bofh.it> <rPhax-GR-11@gated-at.bofh.it> <rPsIG-7IY-19@gated-at.bofh.it> <rPybo-2DK-13@gated-at.bofh.it> |
| X-Original-To | Chanwoo Choi <cw00.choi@samsung.com>, Rob Herring <robh+dt@kernel.org> |
| Dkim-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=JzP4oF0IAOICVYGDc6nyc7oDXHvdsb+neqfZ4dg+P0E=; b=D/lAt9LR8lfF2YvO7ljAAF5rbBXN/qDqdvVSuyHAKWtXwnxu6y0pSFcLXj4oVLKBdo 9T16+Zm0/Fap89KDuAsiDS3xGYSPX4vhcrFlIuw8j+6GosBZL2BtkMGdRwcpvlcUtjwA Tb3sadERahcrZCwuP7u9+YC25dqElqcNfYBYw= |
| X-Google-Dkim-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=JzP4oF0IAOICVYGDc6nyc7oDXHvdsb+neqfZ4dg+P0E=; b=S+ROz6+rikIIEEFqmIO5eWsvaXOBOVyBXSbiBpzime91ziE10oYq8NwYrsObqrdMwF /7GoecS+JdCQ5dlgmvr/IztQOLHjxIM6JiPZlUbP6xgRSRyoIv6MKpZQ6vdZzRTdef73 PPvB5t39NSvQehi6qzSaggBsGsjLcX9wp1jLLxjCj0qankUkzEO2rf70KpYsH1yljVnP jPNMvCSDWf2f/+s7vQQfSogjYOM1jw3IHpXM66UfIRpqwOQGV4EH7rWJ2QHiaS8ccg43 gZeh1c+j5FfW0tmnMLYVqibbDirT8MQupFSVcIhXMz2BmuvqeXeP2YzANz3supOYcg6P Qi/g== |
| X-Gm-Message-State | ALyK8tJrHD6QyDzkFD8YMpFMN4Ji7py9ryCaolXOJdufEEszLe0vA929UERL/YgxqK8csIuAjHZfRSTIZzc0yDN1 |
| X-Received | by 10.176.64.37 with SMTP id h34mr5561226uad.112.1467248695351; Wed, 29 Jun 2016 18:04:55 -0700 (PDT) |
| MIME-Version | 1.0 |
| Content-Type | text/plain; charset=UTF-8 |
| Content-Transfer-Encoding | 8BIT |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 77 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | Chanwoo Choi <cwchoi00@gmail.com>, linux-arm-msm@vger.kernel.org, linux-kernel <linux-kernel@vger.kernel.org>, linux-arm-kernel <linux-arm-kernel@lists.infradead.org>, Roger Quadros <rogerq@ti.com> |
| X-Original-Date | Wed, 29 Jun 2016 18:04:54 -0700 |
| X-Original-Message-ID | <CAJOFmgwBWUL9wYmzNgXqidGQbEPNYj-qYZGdNjidJ2Utswm3Gw@mail.gmail.com> |
| X-Original-References | <20160626055647.18898-1-stephen.boyd@linaro.org> <CAGTfZH3ireJWo5-Jd5SEiSy-WMTsw43pweruOqwSesAZqagvtg@mail.gmail.com> <146705470025.30684.13257433085055355379@sboyd-linaro> <CAGTfZH3ZhZ2gQcOSuAByZWD59E3Bro1aayr2JsM2W+mYa2LQTQ@mail.gmail.com> <CGME20160628215923epcas1p3f7942aca724bf2746c20319750184584@epcas1p3.samsung.com> <146715115921.31418.2315766296233007937@sboyd-linaro> <577369F5.8040907@samsung.com> <146722608622.16253.4347418438203284037@sboyd-linaro> <57746935.4030107@samsung.com> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | csiph.com linux.kernel:1434136 |
Show key headers only | View raw
On 29 June 2016 at 17:35, Chanwoo Choi <cw00.choi@samsung.com> wrote: > On 2016년 06월 30일 03:48, Stephen Boyd wrote: >> Quoting Chanwoo Choi (2016-06-28 23:25:57) >>> On 2016년 06월 29일 06:59, Stephen Boyd wrote: >>>> Quoting Chanwoo Choi (2016-06-28 05:06:48) >>>>> 2016-06-28 4:11 GMT+09:00 Stephen Boyd <stephen.boyd@linaro.org>: >>>>>> Quoting Chanwoo Choi (2016-06-26 04:20:43) >>>>>>> 2016-06-26 14:56 GMT+09:00 Stephen Boyd <stephen.boyd@linaro.org>: >>>>>>>> +PROPERTIES >>>>>>>> + >>>>>>>> +- compatible: >>>>>>>> + Usage: required >>>>>>>> + Value type: <string> >>>>>>>> + Definition: Should contain "qcom,pm8941-misc"; >>>>>>>> + >>>>>>>> +- reg: >>>>>>>> + Usage: required >>>>>>>> + Value type: <u32> >>>>>>>> + Definition: Should contain the offset to the misc address space >>>>>>> >>>>>>> 'reg' property is used on extcon-qcom-spmi-misc.c? >>>>>>> I think that you don't need to include this property. >>>>>> >>>>>> No it isn't used in the driver right now, but there is a register offset >>>>>> for this module and there are registers that can be read/written in this >>>>>> module. I'd like to keep it as required so we can easily read the >>>>>> registers in the future if needed. >>>>> >>>>> OK. >>>>> But, If you want to remain the reg property, you should add the code to get >>>>> the register offset by using OF functions. This patch don't include the OF >>>>> function to handle it. >>>>> >>>> >>>> Sorry I don't follow the argument. I've put the reg property here for >>>> future proofing so that the binding doesn't have to change in backwards >>>> incompatible ways in the future if we do need to get the property later. >>> >>> I don't mention that 'reg' property should be removed. >> >> Ok good. We need to keep reg property as this device is on a bus that >> uses reg property for addressing. >> >>> Just if you want to remain it, you should add some codes as following: >>> For exmaple, >>> - of_get_address() to get the address information from device-tree. >>> >>> If documentation include the some properties, you should add the handling code >>> in device driver. When you add the code to get the offset from device-tree, >>> it doesn't influence the some behavior in the future. >> >> Sorry I don't understand that argument. We can put properties into >> bindings and not use them in drivers if there isn't any immediate need >> to use them. >> >> From what I can tell you're suggesting we call of_get_address() in the >> driver and then do nothing with the value of the property? Is that just >> to check that the node is compliant with the binding and actually has a >> reg property? We don't add code in the kernel to check dts compliance, >> so I'm not inclined to do anything more here. > > I don't agree. > > When he DT binding document include the 'reg' property. > But, the device driver don't include any code to handle the 'reg' property > (just to get the offset). It is obviously wrong. > > It is just basic principle to write the Device-tree binding document. > > Other developer who don' know the history about 'reg' property > would be embarrassed. Why don't extcon driver include the code to > handle the 'reg' property? There is no method to explain it. > Perhaps Rob can explain why having a reg property is required for a bus that has #address-cells=<1> even though the device driver isn't using the reg property.
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Stephen Boyd <stephen.boyd@linaro.org> - 2016-06-26 08:00 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Chanwoo Choi <cwchoi00@gmail.com> - 2016-06-26 13:30 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Chanwoo Choi <cwchoi00@gmail.com> - 2016-06-26 13:30 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Chanwoo Choi <cwchoi00@gmail.com> - 2016-06-28 14:10 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Chanwoo Choi <cw00.choi@samsung.com> - 2016-06-29 08:30 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Stephen Boyd <stephen.boyd@linaro.org> - 2016-06-29 20:50 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Chanwoo Choi <cw00.choi@samsung.com> - 2016-06-30 02:40 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Stephen Boyd <stephen.boyd@linaro.org> - 2016-06-30 03:10 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Roger Quadros <rogerq@ti.com> - 2016-06-27 09:50 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Stephen Boyd <stephen.boyd@linaro.org> - 2016-06-27 21:40 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Roger Quadros <rogerq@ti.com> - 2016-06-28 08:40 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Stephen Boyd <stephen.boyd@linaro.org> - 2016-06-28 10:50 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Roger Quadros <rogerq@ti.com> - 2016-06-28 11:20 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Stephen Boyd <stephen.boyd@linaro.org> - 2016-06-29 00:10 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Roger Quadros <rogerq@ti.com> - 2016-06-29 08:20 +0200
Re: [PATCH] extcon: Add support for qcom SPMI PMIC USB id detection hardware Stephen Boyd <stephen.boyd@linaro.org> - 2016-06-29 21:00 +0200
csiph-web