Message ID | 1452219400-32478-6-git-send-email-xuejiancheng@huawei.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Fri, Jan 08, 2016 at 10:16:39AM +0800, Jiancheng Xue wrote: > Add device tree bindings for Hi3519 system controller. > > Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> > --- > Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ > 1 file changed, 14 insertions(+) > create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt This seems like it could be combined with other HiSi system controller bindings if the compatible string is the only difference. But it is fine like this: Acked-by: Rob Herring <robh@kernel.org> Rob
On Fri, 08 Jan 2016, Jiancheng Xue wrote: > Add device tree bindings for Hi3519 system controller. > > Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> > --- > Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ > 1 file changed, 14 insertions(+) > create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt I have this patch, but none of the others in the set, thus I am lacking context. > diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt > new file mode 100644 > index 0000000..115c5be > --- /dev/null > +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt > @@ -0,0 +1,14 @@ > +* Hisilicon Hi3519 System Controller Block > + > +This bindings use the following binding: > +Documentation/devicetree/bindings/mfd/syscon.txt > + > +Required properties: > +- compatible: "hisilicon,hi3519-sysctrl". > +- reg: the register region of this block > + > +Examples: > +sysctrl: system-controller@12010000 { > + compatible = "hisilicon,hi3519-sysctrl", "syscon"; > + reg = <0x12010000 0x1000>; > +}; There is no requirement (nor want) for binding documents where the given device is simply using highly generic bindings. This just amounts to churn.
Hi Lee Jones, Thanks for your comments. On 2016/1/11 13:48, Lee Jones wrote: > On Fri, 08 Jan 2016, Jiancheng Xue wrote: > >> Add device tree bindings for Hi3519 system controller. >> >> Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> >> --- >> Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ >> 1 file changed, 14 insertions(+) >> create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt > > I have this patch, but none of the others in the set, thus I am > lacking context. > I can forward other patches in the set to you. Thank you. >> diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt >> new file mode 100644 >> index 0000000..115c5be >> --- /dev/null >> +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt >> @@ -0,0 +1,14 @@ >> +* Hisilicon Hi3519 System Controller Block >> + >> +This bindings use the following binding: >> +Documentation/devicetree/bindings/mfd/syscon.txt >> + >> +Required properties: >> +- compatible: "hisilicon,hi3519-sysctrl". >> +- reg: the register region of this block >> + >> +Examples: >> +sysctrl: system-controller@12010000 { >> + compatible = "hisilicon,hi3519-sysctrl", "syscon"; >> + reg = <0x12010000 0x1000>; >> +}; > > There is no requirement (nor want) for binding documents where the > given device is simply using highly generic bindings. This just > amounts to churn. > This block is specific for Hi3519 SOC, and may has its own driver. So I think it's better to keep this binding. Jiancheng
On Mon, 11 Jan 2016, xuejiancheng wrote: > On 2016/1/11 13:48, Lee Jones wrote: > > On Fri, 08 Jan 2016, Jiancheng Xue wrote: > > > >> Add device tree bindings for Hi3519 system controller. > >> > >> Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> > >> --- > >> Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ > >> 1 file changed, 14 insertions(+) > >> create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt > > > > I have this patch, but none of the others in the set, thus I am > > lacking context. > > > I can forward other patches in the set to you. Thank you. > > >> diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt > >> new file mode 100644 > >> index 0000000..115c5be > >> --- /dev/null > >> +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt > >> @@ -0,0 +1,14 @@ > >> +* Hisilicon Hi3519 System Controller Block > >> + > >> +This bindings use the following binding: > >> +Documentation/devicetree/bindings/mfd/syscon.txt > >> + > >> +Required properties: > >> +- compatible: "hisilicon,hi3519-sysctrl". > >> +- reg: the register region of this block > >> + > >> +Examples: > >> +sysctrl: system-controller@12010000 { > >> + compatible = "hisilicon,hi3519-sysctrl", "syscon"; > >> + reg = <0x12010000 0x1000>; > >> +}; > > > > There is no requirement (nor want) for binding documents where the > > given device is simply using highly generic bindings. This just > > amounts to churn. > > > This block is specific for Hi3519 SOC, and may has its own driver. Does it have its own driver currently? > So I think it's better to keep this binding.
On 2016/1/11 16:55, Lee Jones wrote: > On Mon, 11 Jan 2016, xuejiancheng wrote: >> On 2016/1/11 13:48, Lee Jones wrote: >>> On Fri, 08 Jan 2016, Jiancheng Xue wrote: >>> >>>> Add device tree bindings for Hi3519 system controller. >>>> >>>> Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> >>>> --- >>>> Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ >>>> 1 file changed, 14 insertions(+) >>>> create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt >>> >>> I have this patch, but none of the others in the set, thus I am >>> lacking context. >>> >> I can forward other patches in the set to you. Thank you. >> >>>> diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt >>>> new file mode 100644 >>>> index 0000000..115c5be >>>> --- /dev/null >>>> +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt >>>> @@ -0,0 +1,14 @@ >>>> +* Hisilicon Hi3519 System Controller Block >>>> + >>>> +This bindings use the following binding: >>>> +Documentation/devicetree/bindings/mfd/syscon.txt >>>> + >>>> +Required properties: >>>> +- compatible: "hisilicon,hi3519-sysctrl". >>>> +- reg: the register region of this block >>>> + >>>> +Examples: >>>> +sysctrl: system-controller@12010000 { >>>> + compatible = "hisilicon,hi3519-sysctrl", "syscon"; >>>> + reg = <0x12010000 0x1000>; >>>> +}; >>> >>> There is no requirement (nor want) for binding documents where the >>> given device is simply using highly generic bindings. This just >>> amounts to churn. >>> >> This block is specific for Hi3519 SOC, and may has its own driver. > > Does it have its own driver currently? > Not yet. Arnd Bergmann and Rob Herring all suggested adding a specific compatible string with the SOC name. This binding is just used for describing the compatible string now. When more functions on hi3519 SOC are added later, the specific driver will be also needed. >> So I think it's better to keep this binding. >
On Tue, 12 Jan 2016, xuejiancheng wrote: > > > On 2016/1/11 16:55, Lee Jones wrote: > > On Mon, 11 Jan 2016, xuejiancheng wrote: > >> On 2016/1/11 13:48, Lee Jones wrote: > >>> On Fri, 08 Jan 2016, Jiancheng Xue wrote: > >>> > >>>> Add device tree bindings for Hi3519 system controller. > >>>> > >>>> Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> > >>>> --- > >>>> Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ > >>>> 1 file changed, 14 insertions(+) > >>>> create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt > >>> > >>> I have this patch, but none of the others in the set, thus I am > >>> lacking context. > >>> > >> I can forward other patches in the set to you. Thank you. > >> > >>>> diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt > >>>> new file mode 100644 > >>>> index 0000000..115c5be > >>>> --- /dev/null > >>>> +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt > >>>> @@ -0,0 +1,14 @@ > >>>> +* Hisilicon Hi3519 System Controller Block > >>>> + > >>>> +This bindings use the following binding: > >>>> +Documentation/devicetree/bindings/mfd/syscon.txt > >>>> + > >>>> +Required properties: > >>>> +- compatible: "hisilicon,hi3519-sysctrl". > >>>> +- reg: the register region of this block > >>>> + > >>>> +Examples: > >>>> +sysctrl: system-controller@12010000 { > >>>> + compatible = "hisilicon,hi3519-sysctrl", "syscon"; > >>>> + reg = <0x12010000 0x1000>; > >>>> +}; > >>> > >>> There is no requirement (nor want) for binding documents where the > >>> given device is simply using highly generic bindings. This just > >>> amounts to churn. > >>> > >> This block is specific for Hi3519 SOC, and may has its own driver. > > > > Does it have its own driver currently? > > > Not yet. > Arnd Bergmann and Rob Herring all suggested adding a specific compatible string > with the SOC name. This binding is just used for describing the compatible string now. > When more functions on hi3519 SOC are added later, the specific driver will be also > needed. Save this binding until it has more functionality. We here "I'll add to this later" all too often. > >> So I think it's better to keep this binding. > > >
Hello Lee, On 2016/1/12 15:41, Lee Jones wrote: > On Tue, 12 Jan 2016, xuejiancheng wrote: > >> >> >> On 2016/1/11 16:55, Lee Jones wrote: >>> On Mon, 11 Jan 2016, xuejiancheng wrote: >>>> On 2016/1/11 13:48, Lee Jones wrote: >>>>> On Fri, 08 Jan 2016, Jiancheng Xue wrote: >>>>> >>>>>> Add device tree bindings for Hi3519 system controller. >>>>>> >>>>>> Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> >>>>>> --- >>>>>> Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ >>>>>> 1 file changed, 14 insertions(+) >>>>>> create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt >>>>> >>>>> I have this patch, but none of the others in the set, thus I am >>>>> lacking context. >>>>> >>>> I can forward other patches in the set to you. Thank you. >>>> >>>>>> diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt >>>>>> new file mode 100644 >>>>>> index 0000000..115c5be >>>>>> --- /dev/null >>>>>> +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt >>>>>> @@ -0,0 +1,14 @@ >>>>>> +* Hisilicon Hi3519 System Controller Block >>>>>> + >>>>>> +This bindings use the following binding: >>>>>> +Documentation/devicetree/bindings/mfd/syscon.txt >>>>>> + >>>>>> +Required properties: >>>>>> +- compatible: "hisilicon,hi3519-sysctrl". >>>>>> +- reg: the register region of this block >>>>>> + >>>>>> +Examples: >>>>>> +sysctrl: system-controller@12010000 { >>>>>> + compatible = "hisilicon,hi3519-sysctrl", "syscon"; >>>>>> + reg = <0x12010000 0x1000>; >>>>>> +}; >>>>> >>>>> There is no requirement (nor want) for binding documents where the >>>>> given device is simply using highly generic bindings. This just >>>>> amounts to churn. >>>>> >>>> This block is specific for Hi3519 SOC, and may has its own driver. >>> >>> Does it have its own driver currently? >>> >> Not yet. >> Arnd Bergmann and Rob Herring all suggested adding a specific compatible string >> with the SOC name. This binding is just used for describing the compatible string now. >> When more functions on hi3519 SOC are added later, the specific driver will be also >> needed. > > Save this binding until it has more functionality. We here "I'll add > to this later" all too often. > In the hi3519.dtsi file, there is a system-controller device node described like below: sysctrl: system-controller@12010000 { compatible = "hisilicon,hi3519-sysctrl", "syscon"; reg = <0x12010000 0x1000>; }; Do you mean that I should remove "hisilicon,hi3519-sysctrl" and just use "syscon" as the compatible string?? If I want to add "hisilicon,hi3519-sysctrl" for hi3519. where should I put this binding? Could you give some suggestions? Thank you very much! >>>> So I think it's better to keep this binding. >>> >> >
On Tue, 12 Jan 2016, xuejiancheng wrote: > Hello Lee, > > On 2016/1/12 15:41, Lee Jones wrote: > > On Tue, 12 Jan 2016, xuejiancheng wrote: > > > >> > >> > >> On 2016/1/11 16:55, Lee Jones wrote: > >>> On Mon, 11 Jan 2016, xuejiancheng wrote: > >>>> On 2016/1/11 13:48, Lee Jones wrote: > >>>>> On Fri, 08 Jan 2016, Jiancheng Xue wrote: > >>>>> > >>>>>> Add device tree bindings for Hi3519 system controller. > >>>>>> > >>>>>> Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> > >>>>>> --- > >>>>>> Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ > >>>>>> 1 file changed, 14 insertions(+) > >>>>>> create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt > >>>>> > >>>>> I have this patch, but none of the others in the set, thus I am > >>>>> lacking context. > >>>>> > >>>> I can forward other patches in the set to you. Thank you. > >>>> > >>>>>> diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt > >>>>>> new file mode 100644 > >>>>>> index 0000000..115c5be > >>>>>> --- /dev/null > >>>>>> +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt > >>>>>> @@ -0,0 +1,14 @@ > >>>>>> +* Hisilicon Hi3519 System Controller Block > >>>>>> + > >>>>>> +This bindings use the following binding: > >>>>>> +Documentation/devicetree/bindings/mfd/syscon.txt > >>>>>> + > >>>>>> +Required properties: > >>>>>> +- compatible: "hisilicon,hi3519-sysctrl". > >>>>>> +- reg: the register region of this block > >>>>>> + > >>>>>> +Examples: > >>>>>> +sysctrl: system-controller@12010000 { > >>>>>> + compatible = "hisilicon,hi3519-sysctrl", "syscon"; > >>>>>> + reg = <0x12010000 0x1000>; > >>>>>> +}; > >>>>> > >>>>> There is no requirement (nor want) for binding documents where the > >>>>> given device is simply using highly generic bindings. This just > >>>>> amounts to churn. > >>>>> > >>>> This block is specific for Hi3519 SOC, and may has its own driver. > >>> > >>> Does it have its own driver currently? > >>> > >> Not yet. > >> Arnd Bergmann and Rob Herring all suggested adding a specific compatible string > >> with the SOC name. This binding is just used for describing the compatible string now. > >> When more functions on hi3519 SOC are added later, the specific driver will be also > >> needed. > > > > Save this binding until it has more functionality. We here "I'll add > > to this later" all too often. > > > > In the hi3519.dtsi file, there is a system-controller device node described like below: > sysctrl: system-controller@12010000 { > compatible = "hisilicon,hi3519-sysctrl", "syscon"; > reg = <0x12010000 0x1000>; > }; > Do you mean that I should remove "hisilicon,hi3519-sysctrl" and just use "syscon" as the > compatible string?? Where is this compatible string _used_? > If I want to add "hisilicon,hi3519-sysctrl" for hi3519. where should I put this binding? > Could you give some suggestions? Thank you very much! If you're not using the compatible i.e. the device doesn't have its own driver yet, then there is no need to supply the binding at all, is there? > >>>> So I think it's better to keep this binding. > >>> > >> > > >
On 2016/1/12 16:39, Lee Jones wrote: > On Tue, 12 Jan 2016, xuejiancheng wrote: > >> Hello Lee, >> >> On 2016/1/12 15:41, Lee Jones wrote: >>> On Tue, 12 Jan 2016, xuejiancheng wrote: >>> >>>> >>>> >>>> On 2016/1/11 16:55, Lee Jones wrote: >>>>> On Mon, 11 Jan 2016, xuejiancheng wrote: >>>>>> On 2016/1/11 13:48, Lee Jones wrote: >>>>>>> On Fri, 08 Jan 2016, Jiancheng Xue wrote: >>>>>>> >>>>>>>> Add device tree bindings for Hi3519 system controller. >>>>>>>> >>>>>>>> Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> >>>>>>>> --- >>>>>>>> Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ >>>>>>>> 1 file changed, 14 insertions(+) >>>>>>>> create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt >>>>>>> >>>>>>> I have this patch, but none of the others in the set, thus I am >>>>>>> lacking context. >>>>>>> >>>>>> I can forward other patches in the set to you. Thank you. >>>>>> >>>>>>>> diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt >>>>>>>> new file mode 100644 >>>>>>>> index 0000000..115c5be >>>>>>>> --- /dev/null >>>>>>>> +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt >>>>>>>> @@ -0,0 +1,14 @@ >>>>>>>> +* Hisilicon Hi3519 System Controller Block >>>>>>>> + >>>>>>>> +This bindings use the following binding: >>>>>>>> +Documentation/devicetree/bindings/mfd/syscon.txt >>>>>>>> + >>>>>>>> +Required properties: >>>>>>>> +- compatible: "hisilicon,hi3519-sysctrl". >>>>>>>> +- reg: the register region of this block >>>>>>>> + >>>>>>>> +Examples: >>>>>>>> +sysctrl: system-controller@12010000 { >>>>>>>> + compatible = "hisilicon,hi3519-sysctrl", "syscon"; >>>>>>>> + reg = <0x12010000 0x1000>; >>>>>>>> +}; >>>>>>> >>>>>>> There is no requirement (nor want) for binding documents where the >>>>>>> given device is simply using highly generic bindings. This just >>>>>>> amounts to churn. >>>>>>> >>>>>> This block is specific for Hi3519 SOC, and may has its own driver. >>>>> >>>>> Does it have its own driver currently? >>>>> >>>> Not yet. >>>> Arnd Bergmann and Rob Herring all suggested adding a specific compatible string >>>> with the SOC name. This binding is just used for describing the compatible string now. >>>> When more functions on hi3519 SOC are added later, the specific driver will be also >>>> needed. >>> >>> Save this binding until it has more functionality. We here "I'll add >>> to this later" all too often. >>> >> >> In the hi3519.dtsi file, there is a system-controller device node described like below: >> sysctrl: system-controller@12010000 { >> compatible = "hisilicon,hi3519-sysctrl", "syscon"; >> reg = <0x12010000 0x1000>; >> }; >> Do you mean that I should remove "hisilicon,hi3519-sysctrl" and just use "syscon" as the >> compatible string?? > > Where is this compatible string _used_? > >> If I want to add "hisilicon,hi3519-sysctrl" for hi3519. where should I put this binding? >> Could you give some suggestions? Thank you very much! > > If you're not using the compatible i.e. the device doesn't have its > own driver yet, then there is no need to supply the binding at all, is > there? > OK. Thank you. >>>>>> So I think it's better to keep this binding. >>>>> >>>> >>> >> >
On Tuesday 12 January 2016 17:28:05 xuejiancheng wrote: > >>>>> > >>>> Not yet. > >>>> Arnd Bergmann and Rob Herring all suggested adding a specific compatible string > >>>> with the SOC name. This binding is just used for describing the compatible string now. > >>>> When more functions on hi3519 SOC are added later, the specific driver will be also > >>>> needed. > >>> > >>> Save this binding until it has more functionality. We here "I'll add > >>> to this later" all too often. > >>> > >> > >> In the hi3519.dtsi file, there is a system-controller device node described like below: > >> sysctrl: system-controller@12010000 { > >> compatible = "hisilicon,hi3519-sysctrl", "syscon"; > >> reg = <0x12010000 0x1000>; > >> }; > >> Do you mean that I should remove "hisilicon,hi3519-sysctrl" and just use "syscon" as the > >> compatible string?? > > > > Where is this compatible string _used_? > > > >> If I want to add "hisilicon,hi3519-sysctrl" for hi3519. where should I put this binding? > >> Could you give some suggestions? Thank you very much! > > > > If you're not using the compatible i.e. the device doesn't have its > > own driver yet, then there is no need to supply the binding at all, is > > there? > > > > OK. Thank you. > Sorry for stepping in late here. I still think that every syscon device should come with a specific compatible string, so we have the option of creating a driver later on, and I'd like to see a binding document that lists those strings (which I believe exists here). It's really hard to add compatible strings later on, anything else we can work around by keying off that string and adding a workaround in the kernel. Arnd
Hi Arnd, On 2016/1/13 6:51, Arnd Bergmann wrote: > On Tuesday 12 January 2016 17:28:05 xuejiancheng wrote: >>>>>>> >>>>>> Not yet. >>>>>> Arnd Bergmann and Rob Herring all suggested adding a specific compatible string >>>>>> with the SOC name. This binding is just used for describing the compatible string now. >>>>>> When more functions on hi3519 SOC are added later, the specific driver will be also >>>>>> needed. >>>>> >>>>> Save this binding until it has more functionality. We here "I'll add >>>>> to this later" all too often. >>>>> >>>> >>>> In the hi3519.dtsi file, there is a system-controller device node described like below: >>>> sysctrl: system-controller@12010000 { >>>> compatible = "hisilicon,hi3519-sysctrl", "syscon"; >>>> reg = <0x12010000 0x1000>; >>>> }; >>>> Do you mean that I should remove "hisilicon,hi3519-sysctrl" and just use "syscon" as the >>>> compatible string?? >>> >>> Where is this compatible string _used_? >>> >>>> If I want to add "hisilicon,hi3519-sysctrl" for hi3519. where should I put this binding? >>>> Could you give some suggestions? Thank you very much! >>> >>> If you're not using the compatible i.e. the device doesn't have its >>> own driver yet, then there is no need to supply the binding at all, is >>> there? >>> >> >> OK. Thank you. >> > > Sorry for stepping in late here. I still think that every syscon device should > come with a specific compatible string, so we have the option of creating a > driver later on, and I'd like to see a binding document that lists those strings > (which I believe exists here). > > It's really hard to add compatible strings later on, anything else we can > work around by keying off that string and adding a workaround in the kernel. > Is it OK if I put this binding document into the directory "Documentation/devicetree/bindings/arm/hisilicon"? Thank you. > Arnd > > . >
On Wednesday 13 January 2016 17:08:20 xuejiancheng wrote: > > > > Is it OK if I put this binding document into the directory "Documentation/devicetree/bindings/arm/hisilicon"? > Yes, sounds good. Arnd
On Tue, 12 Jan 2016, Arnd Bergmann wrote: > On Tuesday 12 January 2016 17:28:05 xuejiancheng wrote: > > >>>>> > > >>>> Not yet. > > >>>> Arnd Bergmann and Rob Herring all suggested adding a specific compatible string > > >>>> with the SOC name. This binding is just used for describing the compatible string now. > > >>>> When more functions on hi3519 SOC are added later, the specific driver will be also > > >>>> needed. > > >>> > > >>> Save this binding until it has more functionality. We here "I'll add > > >>> to this later" all too often. > > >>> > > >> > > >> In the hi3519.dtsi file, there is a system-controller device node described like below: > > >> sysctrl: system-controller@12010000 { > > >> compatible = "hisilicon,hi3519-sysctrl", "syscon"; > > >> reg = <0x12010000 0x1000>; > > >> }; > > >> Do you mean that I should remove "hisilicon,hi3519-sysctrl" and just use "syscon" as the > > >> compatible string?? > > > > > > Where is this compatible string _used_? > > > > > >> If I want to add "hisilicon,hi3519-sysctrl" for hi3519. where should I put this binding? > > >> Could you give some suggestions? Thank you very much! > > > > > > If you're not using the compatible i.e. the device doesn't have its > > > own driver yet, then there is no need to supply the binding at all, is > > > there? > > > > > > > OK. Thank you. > > > > Sorry for stepping in late here. I still think that every syscon device should > come with a specific compatible string, so we have the option of creating a > driver later on, and I'd like to see a binding document that lists those strings > (which I believe exists here). > > It's really hard to add compatible strings later on, anything else we can > work around by keying off that string and adding a workaround in the kernel. Why is it more difficult (or any different) to add a compatible string later (when it is used) over now (when it is not used)?
On Monday 25 January 2016 14:26:09 Lee Jones wrote: > On Tue, 12 Jan 2016, Arnd Bergmann wrote: > > > On Tuesday 12 January 2016 17:28:05 xuejiancheng wrote: > > > >>>>> > > > >>>> Not yet. > > > >>>> Arnd Bergmann and Rob Herring all suggested adding a specific compatible string > > > >>>> with the SOC name. This binding is just used for describing the compatible string now. > > > >>>> When more functions on hi3519 SOC are added later, the specific driver will be also > > > >>>> needed. > > > >>> > > > >>> Save this binding until it has more functionality. We here "I'll add > > > >>> to this later" all too often. > > > >>> > > > >> > > > >> In the hi3519.dtsi file, there is a system-controller device node described like below: > > > >> sysctrl: system-controller@12010000 { > > > >> compatible = "hisilicon,hi3519-sysctrl", "syscon"; > > > >> reg = <0x12010000 0x1000>; > > > >> }; > > > >> Do you mean that I should remove "hisilicon,hi3519-sysctrl" and just use "syscon" as the > > > >> compatible string?? > > > > > > > > Where is this compatible string _used_? > > > > > > > >> If I want to add "hisilicon,hi3519-sysctrl" for hi3519. where should I put this binding? > > > >> Could you give some suggestions? Thank you very much! > > > > > > > > If you're not using the compatible i.e. the device doesn't have its > > > > own driver yet, then there is no need to supply the binding at all, is > > > > there? > > > > > > > > > > OK. Thank you. > > > > > > > Sorry for stepping in late here. I still think that every syscon device should > > come with a specific compatible string, so we have the option of creating a > > driver later on, and I'd like to see a binding document that lists those strings > > (which I believe exists here). > > > > It's really hard to add compatible strings later on, anything else we can > > work around by keying off that string and adding a workaround in the kernel. > > Why is it more difficult (or any different) to add a compatible string > later (when it is used) over now (when it is not used)? There are many reasons why it can be hard to change a DT binary or source file later on. Sometimes the dtb is shipped with the firmware, sometimes someone has a slightly different platform that is not yet upstreamed, and they need to know about the change when forward-porting to a newer kernel. Either way, you always want to be able to run a newer kernel on an older dtb file without loss of functionality, so all "compatible" strings should generally be as specific as possible (with fallbacks to more generic strings). We do this even for devices that we think are identical, e.g. when multiple SoC vendors integrate the same IP block, but in this case, we already *know* that they are incompatible, so we should never have the same string as the most specific ID. Arnd
diff --git a/Documentation/devicetree/bindings/mfd/hi3519.txt b/Documentation/devicetree/bindings/mfd/hi3519.txt new file mode 100644 index 0000000..115c5be --- /dev/null +++ b/Documentation/devicetree/bindings/mfd/hi3519.txt @@ -0,0 +1,14 @@ +* Hisilicon Hi3519 System Controller Block + +This bindings use the following binding: +Documentation/devicetree/bindings/mfd/syscon.txt + +Required properties: +- compatible: "hisilicon,hi3519-sysctrl". +- reg: the register region of this block + +Examples: +sysctrl: system-controller@12010000 { + compatible = "hisilicon,hi3519-sysctrl", "syscon"; + reg = <0x12010000 0x1000>; +};
Add device tree bindings for Hi3519 system controller. Signed-off-by: Jiancheng Xue <xuejiancheng@huawei.com> --- Documentation/devicetree/bindings/mfd/hi3519.txt | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 Documentation/devicetree/bindings/mfd/hi3519.txt