public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format
@ 2018-02-01 11:15 Ard Biesheuvel
  2018-02-01 15:53 ` Laszlo Ersek
  0 siblings, 1 reply; 5+ messages in thread
From: Ard Biesheuvel @ 2018-02-01 11:15 UTC (permalink / raw)
  To: edk2-devel; +Cc: liming.gao, lersek, yonghong.zhu, Ard Biesheuvel

By default, the device tree compiler emits phandle properties twice:
one called 'phandle' and another called 'linux,phandle'. Given that
Linux was updated in early 2010 [0] to accept the former (which is
what is specified in the ePAPR and device tree specifications), there
is no point in emitting both when compiling device trees for UEFI
platforms.

[0] 04b954a673dd02f585a2769c4945a43880faa989
"of/flattree: Make the kernel accept ePAPR style phandle information"

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
---
 BaseTools/Conf/build_rule.template | 2 +-
 BaseTools/Conf/tools_def.template  | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/BaseTools/Conf/build_rule.template b/BaseTools/Conf/build_rule.template
index 3e6aa8ff0f34..a5e471eb3c10 100755
--- a/BaseTools/Conf/build_rule.template
+++ b/BaseTools/Conf/build_rule.template
@@ -250,7 +250,7 @@
 
     <Command.GCC>
         "$(PP)" $(DTCPP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
-        "$(DTC)" -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
+        "$(DTC)" $(DTC_FLAGS) -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
 
 [Visual-Form-Representation-File]
     <InputFile>
diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template
index 482ef263c274..99ad271471d9 100755
--- a/BaseTools/Conf/tools_def.template
+++ b/BaseTools/Conf/tools_def.template
@@ -4467,6 +4467,7 @@ NOOPT_DDK3790xASL_IPF_DLINK_FLAGS    = /NOLOGO /NODEFAULTLIB /LTCG /DLL /OPT:REF
 DEBUG_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
 RELEASE_*_*_OBJCOPY_ADDDEBUGFLAG   =
 NOOPT_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
+*_*_*_DTC_FLAGS                    = -H epapr
 
 DEFINE GCC_ALL_CC_FLAGS            = -g -Os -fshort-wchar -fno-builtin -fno-strict-aliasing -Wall -Werror -Wno-array-bounds -include AutoGen.h -fno-common
 DEFINE GCC_IA32_CC_FLAGS           = DEF(GCC_ALL_CC_FLAGS) -m32 -malign-double -freorder-blocks -freorder-blocks-and-partition -O2 -mno-stack-arg-probe
-- 
2.11.0



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format
  2018-02-01 11:15 [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format Ard Biesheuvel
@ 2018-02-01 15:53 ` Laszlo Ersek
  2018-02-05 13:58   ` Ard Biesheuvel
  0 siblings, 1 reply; 5+ messages in thread
From: Laszlo Ersek @ 2018-02-01 15:53 UTC (permalink / raw)
  To: Ard Biesheuvel, edk2-devel; +Cc: liming.gao, yonghong.zhu

On 02/01/18 12:15, Ard Biesheuvel wrote:
> By default, the device tree compiler emits phandle properties twice:
> one called 'phandle' and another called 'linux,phandle'. Given that
> Linux was updated in early 2010 [0] to accept the former (which is
> what is specified in the ePAPR and device tree specifications), there
> is no point in emitting both when compiling device trees for UEFI
> platforms.
> 
> [0] 04b954a673dd02f585a2769c4945a43880faa989
> "of/flattree: Make the kernel accept ePAPR style phandle information"
> 
> Contributed-under: TianoCore Contribution Agreement 1.1
> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> ---
>  BaseTools/Conf/build_rule.template | 2 +-
>  BaseTools/Conf/tools_def.template  | 1 +
>  2 files changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/BaseTools/Conf/build_rule.template b/BaseTools/Conf/build_rule.template
> index 3e6aa8ff0f34..a5e471eb3c10 100755
> --- a/BaseTools/Conf/build_rule.template
> +++ b/BaseTools/Conf/build_rule.template
> @@ -250,7 +250,7 @@
>  
>      <Command.GCC>
>          "$(PP)" $(DTCPP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
> -        "$(DTC)" -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
> +        "$(DTC)" $(DTC_FLAGS) -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>  
>  [Visual-Form-Representation-File]
>      <InputFile>
> diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template
> index 482ef263c274..99ad271471d9 100755
> --- a/BaseTools/Conf/tools_def.template
> +++ b/BaseTools/Conf/tools_def.template
> @@ -4467,6 +4467,7 @@ NOOPT_DDK3790xASL_IPF_DLINK_FLAGS    = /NOLOGO /NODEFAULTLIB /LTCG /DLL /OPT:REF
>  DEBUG_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
>  RELEASE_*_*_OBJCOPY_ADDDEBUGFLAG   =
>  NOOPT_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
> +*_*_*_DTC_FLAGS                    = -H epapr
>  
>  DEFINE GCC_ALL_CC_FLAGS            = -g -Os -fshort-wchar -fno-builtin -fno-strict-aliasing -Wall -Werror -Wno-array-bounds -include AutoGen.h -fno-common
>  DEFINE GCC_IA32_CC_FLAGS           = DEF(GCC_ALL_CC_FLAGS) -m32 -malign-double -freorder-blocks -freorder-blocks-and-partition -O2 -mno-stack-arg-probe
> 

Reviewed-by: Laszlo Ersek <lersek@redhat.com>


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format
  2018-02-01 15:53 ` Laszlo Ersek
@ 2018-02-05 13:58   ` Ard Biesheuvel
  2018-02-06  3:05     ` Gao, Liming
  0 siblings, 1 reply; 5+ messages in thread
From: Ard Biesheuvel @ 2018-02-05 13:58 UTC (permalink / raw)
  To: Laszlo Ersek; +Cc: edk2-devel@lists.01.org, Gao, Liming, Zhu, Yonghong

On 1 February 2018 at 16:53, Laszlo Ersek <lersek@redhat.com> wrote:
> On 02/01/18 12:15, Ard Biesheuvel wrote:
>> By default, the device tree compiler emits phandle properties twice:
>> one called 'phandle' and another called 'linux,phandle'. Given that
>> Linux was updated in early 2010 [0] to accept the former (which is
>> what is specified in the ePAPR and device tree specifications), there
>> is no point in emitting both when compiling device trees for UEFI
>> platforms.
>>
>> [0] 04b954a673dd02f585a2769c4945a43880faa989
>> "of/flattree: Make the kernel accept ePAPR style phandle information"
>>
>> Contributed-under: TianoCore Contribution Agreement 1.1
>> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>> ---
>>  BaseTools/Conf/build_rule.template | 2 +-
>>  BaseTools/Conf/tools_def.template  | 1 +
>>  2 files changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/BaseTools/Conf/build_rule.template b/BaseTools/Conf/build_rule.template
>> index 3e6aa8ff0f34..a5e471eb3c10 100755
>> --- a/BaseTools/Conf/build_rule.template
>> +++ b/BaseTools/Conf/build_rule.template
>> @@ -250,7 +250,7 @@
>>
>>      <Command.GCC>
>>          "$(PP)" $(DTCPP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
>> -        "$(DTC)" -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>> +        "$(DTC)" $(DTC_FLAGS) -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>>
>>  [Visual-Form-Representation-File]
>>      <InputFile>
>> diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template
>> index 482ef263c274..99ad271471d9 100755
>> --- a/BaseTools/Conf/tools_def.template
>> +++ b/BaseTools/Conf/tools_def.template
>> @@ -4467,6 +4467,7 @@ NOOPT_DDK3790xASL_IPF_DLINK_FLAGS    = /NOLOGO /NODEFAULTLIB /LTCG /DLL /OPT:REF
>>  DEBUG_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
>>  RELEASE_*_*_OBJCOPY_ADDDEBUGFLAG   =
>>  NOOPT_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
>> +*_*_*_DTC_FLAGS                    = -H epapr
>>
>>  DEFINE GCC_ALL_CC_FLAGS            = -g -Os -fshort-wchar -fno-builtin -fno-strict-aliasing -Wall -Werror -Wno-array-bounds -include AutoGen.h -fno-common
>>  DEFINE GCC_IA32_CC_FLAGS           = DEF(GCC_ALL_CC_FLAGS) -m32 -malign-double -freorder-blocks -freorder-blocks-and-partition -O2 -mno-stack-arg-probe
>>
>
> Reviewed-by: Laszlo Ersek <lersek@redhat.com>

Thank you.

Liming, any comments?


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format
  2018-02-05 13:58   ` Ard Biesheuvel
@ 2018-02-06  3:05     ` Gao, Liming
  2018-02-06  9:59       ` Ard Biesheuvel
  0 siblings, 1 reply; 5+ messages in thread
From: Gao, Liming @ 2018-02-06  3:05 UTC (permalink / raw)
  To: Ard Biesheuvel, Laszlo Ersek; +Cc: edk2-devel@lists.01.org, Zhu, Yonghong

Reviewed-by: Liming Gao <liming.gao@intel.com>

>-----Original Message-----
>From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
>Sent: Monday, February 05, 2018 9:59 PM
>To: Laszlo Ersek <lersek@redhat.com>
>Cc: edk2-devel@lists.01.org; Gao, Liming <liming.gao@intel.com>; Zhu,
>Yonghong <yonghong.zhu@intel.com>
>Subject: Re: [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format
>
>On 1 February 2018 at 16:53, Laszlo Ersek <lersek@redhat.com> wrote:
>> On 02/01/18 12:15, Ard Biesheuvel wrote:
>>> By default, the device tree compiler emits phandle properties twice:
>>> one called 'phandle' and another called 'linux,phandle'. Given that
>>> Linux was updated in early 2010 [0] to accept the former (which is
>>> what is specified in the ePAPR and device tree specifications), there
>>> is no point in emitting both when compiling device trees for UEFI
>>> platforms.
>>>
>>> [0] 04b954a673dd02f585a2769c4945a43880faa989
>>> "of/flattree: Make the kernel accept ePAPR style phandle information"
>>>
>>> Contributed-under: TianoCore Contribution Agreement 1.1
>>> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>>> ---
>>>  BaseTools/Conf/build_rule.template | 2 +-
>>>  BaseTools/Conf/tools_def.template  | 1 +
>>>  2 files changed, 2 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/BaseTools/Conf/build_rule.template
>b/BaseTools/Conf/build_rule.template
>>> index 3e6aa8ff0f34..a5e471eb3c10 100755
>>> --- a/BaseTools/Conf/build_rule.template
>>> +++ b/BaseTools/Conf/build_rule.template
>>> @@ -250,7 +250,7 @@
>>>
>>>      <Command.GCC>
>>>          "$(PP)" $(DTCPP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
>>> -        "$(DTC)" -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>>> +        "$(DTC)" $(DTC_FLAGS) -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>>>
>>>  [Visual-Form-Representation-File]
>>>      <InputFile>
>>> diff --git a/BaseTools/Conf/tools_def.template
>b/BaseTools/Conf/tools_def.template
>>> index 482ef263c274..99ad271471d9 100755
>>> --- a/BaseTools/Conf/tools_def.template
>>> +++ b/BaseTools/Conf/tools_def.template
>>> @@ -4467,6 +4467,7 @@ NOOPT_DDK3790xASL_IPF_DLINK_FLAGS    =
>/NOLOGO /NODEFAULTLIB /LTCG /DLL /OPT:REF
>>>  DEBUG_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-
>debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
>>>  RELEASE_*_*_OBJCOPY_ADDDEBUGFLAG   =
>>>  NOOPT_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-
>debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
>>> +*_*_*_DTC_FLAGS                    = -H epapr
>>>
>>>  DEFINE GCC_ALL_CC_FLAGS            = -g -Os -fshort-wchar -fno-builtin -fno-
>strict-aliasing -Wall -Werror -Wno-array-bounds -include AutoGen.h -fno-
>common
>>>  DEFINE GCC_IA32_CC_FLAGS           = DEF(GCC_ALL_CC_FLAGS) -m32 -
>malign-double -freorder-blocks -freorder-blocks-and-partition -O2 -mno-
>stack-arg-probe
>>>
>>
>> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
>
>Thank you.
>
>Liming, any comments?

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format
  2018-02-06  3:05     ` Gao, Liming
@ 2018-02-06  9:59       ` Ard Biesheuvel
  0 siblings, 0 replies; 5+ messages in thread
From: Ard Biesheuvel @ 2018-02-06  9:59 UTC (permalink / raw)
  To: Gao, Liming; +Cc: Laszlo Ersek, edk2-devel@lists.01.org, Zhu, Yonghong

On 6 February 2018 at 03:05, Gao, Liming <liming.gao@intel.com> wrote:
> Reviewed-by: Liming Gao <liming.gao@intel.com>
>

Thanks. Pushed as 34a4ddda4d61ede41f575510dc5adcf933d3b6f5


>>-----Original Message-----
>>From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org]
>>Sent: Monday, February 05, 2018 9:59 PM
>>To: Laszlo Ersek <lersek@redhat.com>
>>Cc: edk2-devel@lists.01.org; Gao, Liming <liming.gao@intel.com>; Zhu,
>>Yonghong <yonghong.zhu@intel.com>
>>Subject: Re: [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format
>>
>>On 1 February 2018 at 16:53, Laszlo Ersek <lersek@redhat.com> wrote:
>>> On 02/01/18 12:15, Ard Biesheuvel wrote:
>>>> By default, the device tree compiler emits phandle properties twice:
>>>> one called 'phandle' and another called 'linux,phandle'. Given that
>>>> Linux was updated in early 2010 [0] to accept the former (which is
>>>> what is specified in the ePAPR and device tree specifications), there
>>>> is no point in emitting both when compiling device trees for UEFI
>>>> platforms.
>>>>
>>>> [0] 04b954a673dd02f585a2769c4945a43880faa989
>>>> "of/flattree: Make the kernel accept ePAPR style phandle information"
>>>>
>>>> Contributed-under: TianoCore Contribution Agreement 1.1
>>>> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
>>>> ---
>>>>  BaseTools/Conf/build_rule.template | 2 +-
>>>>  BaseTools/Conf/tools_def.template  | 1 +
>>>>  2 files changed, 2 insertions(+), 1 deletion(-)
>>>>
>>>> diff --git a/BaseTools/Conf/build_rule.template
>>b/BaseTools/Conf/build_rule.template
>>>> index 3e6aa8ff0f34..a5e471eb3c10 100755
>>>> --- a/BaseTools/Conf/build_rule.template
>>>> +++ b/BaseTools/Conf/build_rule.template
>>>> @@ -250,7 +250,7 @@
>>>>
>>>>      <Command.GCC>
>>>>          "$(PP)" $(DTCPP_FLAGS) $(INC) ${src} > ${d_path}(+)${s_base}.i
>>>> -        "$(DTC)" -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>>>> +        "$(DTC)" $(DTC_FLAGS) -I dts -O dtb -o ${dst} ${d_path}(+)${s_base}.i
>>>>
>>>>  [Visual-Form-Representation-File]
>>>>      <InputFile>
>>>> diff --git a/BaseTools/Conf/tools_def.template
>>b/BaseTools/Conf/tools_def.template
>>>> index 482ef263c274..99ad271471d9 100755
>>>> --- a/BaseTools/Conf/tools_def.template
>>>> +++ b/BaseTools/Conf/tools_def.template
>>>> @@ -4467,6 +4467,7 @@ NOOPT_DDK3790xASL_IPF_DLINK_FLAGS    =
>>/NOLOGO /NODEFAULTLIB /LTCG /DLL /OPT:REF
>>>>  DEBUG_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-
>>debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
>>>>  RELEASE_*_*_OBJCOPY_ADDDEBUGFLAG   =
>>>>  NOOPT_*_*_OBJCOPY_ADDDEBUGFLAG     = --add-gnu-
>>debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
>>>> +*_*_*_DTC_FLAGS                    = -H epapr
>>>>
>>>>  DEFINE GCC_ALL_CC_FLAGS            = -g -Os -fshort-wchar -fno-builtin -fno-
>>strict-aliasing -Wall -Werror -Wno-array-bounds -include AutoGen.h -fno-
>>common
>>>>  DEFINE GCC_IA32_CC_FLAGS           = DEF(GCC_ALL_CC_FLAGS) -m32 -
>>malign-double -freorder-blocks -freorder-blocks-and-partition -O2 -mno-
>>stack-arg-probe
>>>>
>>>
>>> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
>>
>>Thank you.
>>
>>Liming, any comments?


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-02-06  9:53 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-01 11:15 [PATCH v2] BaseTools/Conf: disable DTC legacy phandle format Ard Biesheuvel
2018-02-01 15:53 ` Laszlo Ersek
2018-02-05 13:58   ` Ard Biesheuvel
2018-02-06  3:05     ` Gao, Liming
2018-02-06  9:59       ` Ard Biesheuvel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox