xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [RFC] xen/arm: build: add missed dependency for head.S
@ 2016-06-03 10:07 Wei Chen
  2016-06-06 17:08 ` Julien Grall
  0 siblings, 1 reply; 11+ messages in thread
From: Wei Chen @ 2016-06-03 10:07 UTC (permalink / raw)
  To: xen-devel
  Cc: sstabellini, wei.liu2, steve.capper, andrew.cooper3,
	julien.grall, Wei Chen

When we update the header files that had been included in head.S.
The build system would not re-compile the head.S. Because in the
build rules, the dependencies are setting to .*.d (eg. DEPS = .*.d)
files in the same folder as Makefile.

But head.S is very special, it was used by the Makefile in the parent
folder: "ALL_OBJS := $(TARGET_SUBARCH)/head.o".

In this case, the build system could not find the dependency in DEPS.
When we update the header files, the build system is unware of this
update. If we re-build the Xen without doing make clean or touching
the head.S, the build system will not recompile the head.S.

Signed-off-by: Wei Chen <Wei.Chen@linaro.org>
---
In my mind, the better way to fix this bug is converting the DEPS from
ALL_OBJS. But I am afraid of the impact. I am not sure whether there 
are some dependencies are not generated from obj files.
---
xen/Rules.mk          | 3 ++-
 xen/arch/arm/Makefile | 2 ++
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/xen/Rules.mk b/xen/Rules.mk
index 961d533..1247b61 100644
--- a/xen/Rules.mk
+++ b/xen/Rules.mk
@@ -92,9 +92,10 @@ LDFLAGS += $(LDFLAGS-y)
 
 include $(BASEDIR)/arch/$(TARGET_ARCH)/Rules.mk
 
+DEPS = .*.d
+
 include Makefile
 
-DEPS = .*.d
 define gendep
     ifneq ($(1),$(subst /,:,$(1)))
         DEPS += $(dir $(1)).$(notdir $(1)).d
diff --git a/xen/arch/arm/Makefile b/xen/arch/arm/Makefile
index af4d0e1..9e38da3 100644
--- a/xen/arch/arm/Makefile
+++ b/xen/arch/arm/Makefile
@@ -51,6 +51,8 @@ endif
 
 ALL_OBJS := $(TARGET_SUBARCH)/head.o $(ALL_OBJS)
 
+DEPS += $(TARGET_SUBARCH)/.head.o.d
+
 $(TARGET): $(TARGET)-syms $(TARGET).axf
 	$(OBJCOPY) -O binary -S $< $@
 ifeq ($(CONFIG_ARM_64),y)
-- 
2.7.4


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC] xen/arm: build: add missed dependency for head.S
  2016-06-03 10:07 [RFC] xen/arm: build: add missed dependency for head.S Wei Chen
@ 2016-06-06 17:08 ` Julien Grall
  2016-06-07 10:03   ` Ian Jackson
  0 siblings, 1 reply; 11+ messages in thread
From: Julien Grall @ 2016-06-06 17:08 UTC (permalink / raw)
  To: Wei Chen, xen-devel
  Cc: andrew.cooper3, sstabellini, wei.liu2, Ian Jackson, steve.capper

(CC Ian)

Hi,

On 03/06/16 11:07, Wei Chen wrote:
> When we update the header files that had been included in head.S.
> The build system would not re-compile the head.S. Because in the
> build rules, the dependencies are setting to .*.d (eg. DEPS = .*.d)
> files in the same folder as Makefile.
>
> But head.S is very special, it was used by the Makefile in the parent
> folder: "ALL_OBJS := $(TARGET_SUBARCH)/head.o".
>
> In this case, the build system could not find the dependency in DEPS.
> When we update the header files, the build system is unware of this
> update. If we re-build the Xen without doing make clean or touching
> the head.S, the build system will not recompile the head.S.
>
> Signed-off-by: Wei Chen <Wei.Chen@linaro.org>
> ---
> In my mind, the better way to fix this bug is converting the DEPS from
> ALL_OBJS. But I am afraid of the impact. I am not sure whether there
> are some dependencies are not generated from obj files.

My knowledge of the build system is limited. Stefano, Ian, Wei, could 
you give a look?

Regards,

> ---
> xen/Rules.mk          | 3 ++-
>   xen/arch/arm/Makefile | 2 ++
>   2 files changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/xen/Rules.mk b/xen/Rules.mk
> index 961d533..1247b61 100644
> --- a/xen/Rules.mk
> +++ b/xen/Rules.mk
> @@ -92,9 +92,10 @@ LDFLAGS += $(LDFLAGS-y)
>
>   include $(BASEDIR)/arch/$(TARGET_ARCH)/Rules.mk
>
> +DEPS = .*.d
> +
>   include Makefile
>
> -DEPS = .*.d
>   define gendep
>       ifneq ($(1),$(subst /,:,$(1)))
>           DEPS += $(dir $(1)).$(notdir $(1)).d
> diff --git a/xen/arch/arm/Makefile b/xen/arch/arm/Makefile
> index af4d0e1..9e38da3 100644
> --- a/xen/arch/arm/Makefile
> +++ b/xen/arch/arm/Makefile
> @@ -51,6 +51,8 @@ endif
>
>   ALL_OBJS := $(TARGET_SUBARCH)/head.o $(ALL_OBJS)
>
> +DEPS += $(TARGET_SUBARCH)/.head.o.d
> +
>   $(TARGET): $(TARGET)-syms $(TARGET).axf
>   	$(OBJCOPY) -O binary -S $< $@
>   ifeq ($(CONFIG_ARM_64),y)
>

-- 
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* [RFC v2] xen/arm: build: add missed dependency for head.S
@ 2016-06-07  4:34     ` Wei Chen
  2016-06-07 13:18       ` Konrad Rzeszutek Wilk
  2016-06-07 16:01       ` [RFC v2] xen/arm: build: add missed dependency for head.S [and 1 more messages] Ian Jackson
  0 siblings, 2 replies; 11+ messages in thread
From: Wei Chen @ 2016-06-07  4:34 UTC (permalink / raw)
  To: xen-devel
  Cc: sstabellini, wei.liu2, steve.capper, andrew.cooper3, ian.jackson,
	julien.grall, Wei Chen

In current Xen build rules, the build system will only check the
dependencies in current folder and obj-y generated dependencies
in other folder.

But Makefile may add some objects to ALL_OBJS. These objects may
be not in the same folder as Makefile. Use arch/arm/Makefile as
an example:
    ALL_OBJS := $(TARGET_SUBARCH)/head.o

The head.o is not in the same folder as Makefile and is not listed
in obj-y. So, when we update the header files that had been included
in head.S. The build system would not check the dependency of head.S.
The head.S would not be re-compiled.

In this patch, we will get objects added by Makefile and add their
dependencies to check list.

Signed-off-by: Wei Chen <Wei.Chen@linaro.org>
---
v1 -> v2:
- Use a generic method instead of changing Makefiles
---
 xen/Rules.mk | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/xen/Rules.mk b/xen/Rules.mk
index 961d533..fb3087c 100644
--- a/xen/Rules.mk
+++ b/xen/Rules.mk
@@ -95,12 +95,21 @@ include $(BASEDIR)/arch/$(TARGET_ARCH)/Rules.mk
 include Makefile
 
 DEPS = .*.d
+
+# In obj-y and ALL_OBJS, there may have some objects are not in the
+# same folder as Makefile, so we have to use gendep to generate
+# dependencies for them.
+DEP_OBJS = $(obj-y)
+
+# Extract objects from ALL_OBJS added by Makefile.
+DEP_OBJS += $(filter-out %built_in.o,$(ALL_OBJS))
+
 define gendep
     ifneq ($(1),$(subst /,:,$(1)))
         DEPS += $(dir $(1)).$(notdir $(1)).d
     endif
 endef
-$(foreach o,$(filter-out %/,$(obj-y)),$(eval $(call gendep,$(o))))
+$(foreach o,$(filter-out %/,$(DEP_OBJS)),$(eval $(call gendep,$(o))))
 
 # Ensure each subdirectory has exactly one trailing slash.
 subdir-n := $(patsubst %,%/,$(patsubst %/,%,$(subdir-n) $(subdir-)))
-- 
2.7.4


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC] xen/arm: build: add missed dependency for head.S
  2016-06-06 17:08 ` Julien Grall
@ 2016-06-07 10:03   ` Ian Jackson
  2016-06-07  4:34     ` [RFC v2] " Wei Chen
  2016-06-07 10:07     ` [RFC] xen/arm: build: add missed dependency for head.S Julien Grall
  0 siblings, 2 replies; 11+ messages in thread
From: Ian Jackson @ 2016-06-07 10:03 UTC (permalink / raw)
  To: Julien Grall
  Cc: sstabellini, wei.liu2, steve.capper, andrew.cooper3, xen-devel, Wei Chen

Julien Grall writes ("Re: [RFC] xen/arm: build: add missed dependency for head.S"):
> On 03/06/16 11:07, Wei Chen wrote:
> > When we update the header files that had been included in head.S.
> > The build system would not re-compile the head.S. Because in the
> > build rules, the dependencies are setting to .*.d (eg. DEPS = .*.d)
> > files in the same folder as Makefile.
> >
> > But head.S is very special, it was used by the Makefile in the parent
> > folder: "ALL_OBJS := $(TARGET_SUBARCH)/head.o".
> >
> > In this case, the build system could not find the dependency in DEPS.
> > When we update the header files, the build system is unware of this
> > update. If we re-build the Xen without doing make clean or touching
> > the head.S, the build system will not recompile the head.S.
> >
> > Signed-off-by: Wei Chen <Wei.Chen@linaro.org>

Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>

This should be in 4.7 and is a backport candidate.

> > In my mind, the better way to fix this bug is converting the DEPS from
> > ALL_OBJS. But I am afraid of the impact. I am not sure whether there
> > are some dependencies are not generated from obj files.

I do like this idea but I have the same worry.  It might be possible
to dump ALL_OBJS out somehow and check this, but it might be
arch-dependent.

Wei Chen's patch is IMO a straightforward fix.

Thanks,
Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC] xen/arm: build: add missed dependency for head.S
  2016-06-07 10:03   ` Ian Jackson
  2016-06-07  4:34     ` [RFC v2] " Wei Chen
@ 2016-06-07 10:07     ` Julien Grall
  1 sibling, 0 replies; 11+ messages in thread
From: Julien Grall @ 2016-06-07 10:07 UTC (permalink / raw)
  To: Ian Jackson
  Cc: sstabellini, wei.liu2, steve.capper, andrew.cooper3, xen-devel, Wei Chen

Hi Ian,

On 07/06/16 11:03, Ian Jackson wrote:
> Julien Grall writes ("Re: [RFC] xen/arm: build: add missed dependency for head.S"):
>> On 03/06/16 11:07, Wei Chen wrote:
>>> When we update the header files that had been included in head.S.
>>> The build system would not re-compile the head.S. Because in the
>>> build rules, the dependencies are setting to .*.d (eg. DEPS = .*.d)
>>> files in the same folder as Makefile.
>>>
>>> But head.S is very special, it was used by the Makefile in the parent
>>> folder: "ALL_OBJS := $(TARGET_SUBARCH)/head.o".
>>>
>>> In this case, the build system could not find the dependency in DEPS.
>>> When we update the header files, the build system is unware of this
>>> update. If we re-build the Xen without doing make clean or touching
>>> the head.S, the build system will not recompile the head.S.
>>>
>>> Signed-off-by: Wei Chen <Wei.Chen@linaro.org>
>
> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
>
> This should be in 4.7 and is a backport candidate.

Sounds good to me.

>>> In my mind, the better way to fix this bug is converting the DEPS from
>>> ALL_OBJS. But I am afraid of the impact. I am not sure whether there
>>> are some dependencies are not generated from obj files.
>
> I do like this idea but I have the same worry.  It might be possible
> to dump ALL_OBJS out somehow and check this, but it might be
> arch-dependent.

FWIW, Wei sent a new version today [1] which implement his suggestion. 
Although it might be too risky for Xen 4.7.

Regards,

[1] 
http://lists.xenproject.org/archives/html/xen-devel/2016-06/msg00781.html

-- 
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC v2] xen/arm: build: add missed dependency for head.S
  2016-06-07  4:34     ` [RFC v2] " Wei Chen
@ 2016-06-07 13:18       ` Konrad Rzeszutek Wilk
  2016-06-08  3:10         ` Wei Chen
  2016-06-07 16:01       ` [RFC v2] xen/arm: build: add missed dependency for head.S [and 1 more messages] Ian Jackson
  1 sibling, 1 reply; 11+ messages in thread
From: Konrad Rzeszutek Wilk @ 2016-06-07 13:18 UTC (permalink / raw)
  To: Wei Chen
  Cc: sstabellini, wei.liu2, steve.capper, andrew.cooper3, ian.jackson,
	xen-devel, julien.grall

On Tue, Jun 07, 2016 at 12:34:43PM +0800, Wei Chen wrote:
> In current Xen build rules, the build system will only check the
> dependencies in current folder and obj-y generated dependencies
> in other folder.
> 
> But Makefile may add some objects to ALL_OBJS. These objects may
> be not in the same folder as Makefile. Use arch/arm/Makefile as
> an example:
>     ALL_OBJS := $(TARGET_SUBARCH)/head.o
> 
> The head.o is not in the same folder as Makefile and is not listed
> in obj-y. So, when we update the header files that had been included
> in head.S. The build system would not check the dependency of head.S.
> The head.S would not be re-compiled.
> 
> In this patch, we will get objects added by Makefile and add their
> dependencies to check list.
> 
> Signed-off-by: Wei Chen <Wei.Chen@linaro.org>
> ---
> v1 -> v2:
> - Use a generic method instead of changing Makefiles
> ---
>  xen/Rules.mk | 11 ++++++++++-
>  1 file changed, 10 insertions(+), 1 deletion(-)
> 
> diff --git a/xen/Rules.mk b/xen/Rules.mk
> index 961d533..fb3087c 100644
> --- a/xen/Rules.mk
> +++ b/xen/Rules.mk
> @@ -95,12 +95,21 @@ include $(BASEDIR)/arch/$(TARGET_ARCH)/Rules.mk
>  include Makefile
>  
>  DEPS = .*.d
> +
> +# In obj-y and ALL_OBJS, there may have some objects are not in the

You are missing a verb here.

I think you mean to say 'there may be some objects which are not in the'
> +# same folder as Makefile, so we have to use gendep to generate
> +# dependencies for them.
> +DEP_OBJS = $(obj-y)
> +
> +# Extract objects from ALL_OBJS added by Makefile.
> +DEP_OBJS += $(filter-out %built_in.o,$(ALL_OBJS))
> +
>  define gendep
>      ifneq ($(1),$(subst /,:,$(1)))
>          DEPS += $(dir $(1)).$(notdir $(1)).d
>      endif
>  endef
> -$(foreach o,$(filter-out %/,$(obj-y)),$(eval $(call gendep,$(o))))
> +$(foreach o,$(filter-out %/,$(DEP_OBJS)),$(eval $(call gendep,$(o))))
>  
>  # Ensure each subdirectory has exactly one trailing slash.
>  subdir-n := $(patsubst %,%/,$(patsubst %/,%,$(subdir-n) $(subdir-)))
> -- 
> 2.7.4
> 
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> http://lists.xen.org/xen-devel

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC v2] xen/arm: build: add missed dependency for head.S [and 1 more messages]
  2016-06-07  4:34     ` [RFC v2] " Wei Chen
  2016-06-07 13:18       ` Konrad Rzeszutek Wilk
@ 2016-06-07 16:01       ` Ian Jackson
  2016-06-07 16:24         ` Wei Liu
  1 sibling, 1 reply; 11+ messages in thread
From: Ian Jackson @ 2016-06-07 16:01 UTC (permalink / raw)
  To: Wei Chen
  Cc: sstabellini, wei.liu2, steve.capper, andrew.cooper3, xen-devel,
	julien.grall

Wei Chen writes ("[RFC v2] xen/arm: build: add missed dependency for head.S"):
> In current Xen build rules, the build system will only check the
> dependencies in current folder and obj-y generated dependencies
> in other folder.
> 
> But Makefile may add some objects to ALL_OBJS. These objects may
> be not in the same folder as Makefile. Use arch/arm/Makefile as
> an example:
>     ALL_OBJS := $(TARGET_SUBARCH)/head.o

Thanks for the v2.

But I think I actually somewhat prefer the v1 approach, for these
reasons:

On 03/06/16 11:07, Wei Chen wrote:
> In my mind, the better way to fix this bug is converting the DEPS from
> ALL_OBJS. But I am afraid of the impact. I am not sure whether there
> are some dependencies are not generated from obj files.
> 
Ian Jackson writes ("Re: [RFC] xen/arm: build: add missed dependency for head.S"):
> I do like this idea but I have the same worry.  It might be possible
> to dump ALL_OBJS out somehow and check this, but it might be
> arch-dependent.
> 
> Wei Chen's patch is IMO a straightforward fix.

I won't NAK the v2 but I think if Wei Chen is still happy for us to do
so, we should commit the v1.

Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC v2] xen/arm: build: add missed dependency for head.S [and 1 more messages]
  2016-06-07 16:01       ` [RFC v2] xen/arm: build: add missed dependency for head.S [and 1 more messages] Ian Jackson
@ 2016-06-07 16:24         ` Wei Liu
  2016-06-08  3:14           ` Wei Chen
  0 siblings, 1 reply; 11+ messages in thread
From: Wei Liu @ 2016-06-07 16:24 UTC (permalink / raw)
  To: Ian Jackson
  Cc: sstabellini, wei.liu2, steve.capper, andrew.cooper3, xen-devel,
	julien.grall, Wei Chen

On Tue, Jun 07, 2016 at 05:01:35PM +0100, Ian Jackson wrote:
> Wei Chen writes ("[RFC v2] xen/arm: build: add missed dependency for head.S"):
> > In current Xen build rules, the build system will only check the
> > dependencies in current folder and obj-y generated dependencies
> > in other folder.
> > 
> > But Makefile may add some objects to ALL_OBJS. These objects may
> > be not in the same folder as Makefile. Use arch/arm/Makefile as
> > an example:
> >     ALL_OBJS := $(TARGET_SUBARCH)/head.o
> 
> Thanks for the v2.
> 
> But I think I actually somewhat prefer the v1 approach, for these
> reasons:
> 
> On 03/06/16 11:07, Wei Chen wrote:
> > In my mind, the better way to fix this bug is converting the DEPS from
> > ALL_OBJS. But I am afraid of the impact. I am not sure whether there
> > are some dependencies are not generated from obj files.
> > 
> Ian Jackson writes ("Re: [RFC] xen/arm: build: add missed dependency for head.S"):
> > I do like this idea but I have the same worry.  It might be possible
> > to dump ALL_OBJS out somehow and check this, but it might be
> > arch-dependent.
> > 
> > Wei Chen's patch is IMO a straightforward fix.
> 
> I won't NAK the v2 but I think if Wei Chen is still happy for us to do
> so, we should commit the v1.
> 
> Ian.

We shall take either v1 or v2. I don't really have an opinion which one.

Either one:

Release-acked-by: Wei Liu <wei.liu2@citrix.com>

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC v2] xen/arm: build: add missed dependency for head.S
  2016-06-07 13:18       ` Konrad Rzeszutek Wilk
@ 2016-06-08  3:10         ` Wei Chen
  0 siblings, 0 replies; 11+ messages in thread
From: Wei Chen @ 2016-06-08  3:10 UTC (permalink / raw)
  To: Konrad Rzeszutek Wilk
  Cc: Stefano Stabellini, Wei Liu, steve.capper, andrew.cooper3,
	ian.jackson, xen-devel, Julien Grall

On 7 June 2016 at 21:18, Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> wrote:
> On Tue, Jun 07, 2016 at 12:34:43PM +0800, Wei Chen wrote:
>> In current Xen build rules, the build system will only check the
>> dependencies in current folder and obj-y generated dependencies
>> in other folder.
>>
>> But Makefile may add some objects to ALL_OBJS. These objects may
>> be not in the same folder as Makefile. Use arch/arm/Makefile as
>> an example:
>>     ALL_OBJS := $(TARGET_SUBARCH)/head.o
>>
>> The head.o is not in the same folder as Makefile and is not listed
>> in obj-y. So, when we update the header files that had been included
>> in head.S. The build system would not check the dependency of head.S.
>> The head.S would not be re-compiled.
>>
>> In this patch, we will get objects added by Makefile and add their
>> dependencies to check list.
>>
>> Signed-off-by: Wei Chen <Wei.Chen@linaro.org>
>> ---
>> v1 -> v2:
>> - Use a generic method instead of changing Makefiles
>> ---
>>  xen/Rules.mk | 11 ++++++++++-
>>  1 file changed, 10 insertions(+), 1 deletion(-)
>>
>> diff --git a/xen/Rules.mk b/xen/Rules.mk
>> index 961d533..fb3087c 100644
>> --- a/xen/Rules.mk
>> +++ b/xen/Rules.mk
>> @@ -95,12 +95,21 @@ include $(BASEDIR)/arch/$(TARGET_ARCH)/Rules.mk
>>  include Makefile
>>
>>  DEPS = .*.d
>> +
>> +# In obj-y and ALL_OBJS, there may have some objects are not in the
>
> You are missing a verb here.
>
> I think you mean to say 'there may be some objects which are not in the'
Thank you! it's my mistake.

>> +# same folder as Makefile, so we have to use gendep to generate
>> +# dependencies for them.
>> +DEP_OBJS = $(obj-y)
>> +
>> +# Extract objects from ALL_OBJS added by Makefile.
>> +DEP_OBJS += $(filter-out %built_in.o,$(ALL_OBJS))
>> +
>>  define gendep
>>      ifneq ($(1),$(subst /,:,$(1)))
>>          DEPS += $(dir $(1)).$(notdir $(1)).d
>>      endif
>>  endef
>> -$(foreach o,$(filter-out %/,$(obj-y)),$(eval $(call gendep,$(o))))
>> +$(foreach o,$(filter-out %/,$(DEP_OBJS)),$(eval $(call gendep,$(o))))
>>
>>  # Ensure each subdirectory has exactly one trailing slash.
>>  subdir-n := $(patsubst %,%/,$(patsubst %/,%,$(subdir-n) $(subdir-)))
>> --
>> 2.7.4
>>
>>
>> _______________________________________________
>> Xen-devel mailing list
>> Xen-devel@lists.xen.org
>> http://lists.xen.org/xen-devel

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC v2] xen/arm: build: add missed dependency for head.S [and 1 more messages]
  2016-06-07 16:24         ` Wei Liu
@ 2016-06-08  3:14           ` Wei Chen
  2016-06-08  8:09             ` Wei Liu
  0 siblings, 1 reply; 11+ messages in thread
From: Wei Chen @ 2016-06-08  3:14 UTC (permalink / raw)
  To: Wei Liu
  Cc: Stefano Stabellini, steve.capper, andrew.cooper3, Ian Jackson,
	xen-devel, Julien Grall

Hi,

On 8 June 2016 at 00:24, Wei Liu <wei.liu2@citrix.com> wrote:
> On Tue, Jun 07, 2016 at 05:01:35PM +0100, Ian Jackson wrote:
>> Wei Chen writes ("[RFC v2] xen/arm: build: add missed dependency for head.S"):
>> > In current Xen build rules, the build system will only check the
>> > dependencies in current folder and obj-y generated dependencies
>> > in other folder.
>> >
>> > But Makefile may add some objects to ALL_OBJS. These objects may
>> > be not in the same folder as Makefile. Use arch/arm/Makefile as
>> > an example:
>> >     ALL_OBJS := $(TARGET_SUBARCH)/head.o
>>
>> Thanks for the v2.
>>
>> But I think I actually somewhat prefer the v1 approach, for these
>> reasons:
>>
>> On 03/06/16 11:07, Wei Chen wrote:
>> > In my mind, the better way to fix this bug is converting the DEPS from
>> > ALL_OBJS. But I am afraid of the impact. I am not sure whether there
>> > are some dependencies are not generated from obj files.
>> >
>> Ian Jackson writes ("Re: [RFC] xen/arm: build: add missed dependency for head.S"):
>> > I do like this idea but I have the same worry.  It might be possible
>> > to dump ALL_OBJS out somehow and check this, but it might be
>> > arch-dependent.
>> >
>> > Wei Chen's patch is IMO a straightforward fix.
>>
>> I won't NAK the v2 but I think if Wei Chen is still happy for us to do
>> so, we should commit the v1.
>>
>> Ian.
>
> We shall take either v1 or v2. I don't really have an opinion which one.
>

Thank you. I will be happy if anyone would be committed. IMO, please
commit the v1 patch.
The v1 patch gives the arch Makefile more right to add dependencies
not just only in ALL_OBJS.

> Either one:
>
> Release-acked-by: Wei Liu <wei.liu2@citrix.com>

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

* Re: [RFC v2] xen/arm: build: add missed dependency for head.S [and 1 more messages]
  2016-06-08  3:14           ` Wei Chen
@ 2016-06-08  8:09             ` Wei Liu
  0 siblings, 0 replies; 11+ messages in thread
From: Wei Liu @ 2016-06-08  8:09 UTC (permalink / raw)
  To: Wei Chen
  Cc: Stefano Stabellini, Wei Liu, steve.capper, andrew.cooper3,
	Ian Jackson, xen-devel, Julien Grall

On Wed, Jun 08, 2016 at 11:14:14AM +0800, Wei Chen wrote:
> Hi,
> 
> On 8 June 2016 at 00:24, Wei Liu <wei.liu2@citrix.com> wrote:
> > On Tue, Jun 07, 2016 at 05:01:35PM +0100, Ian Jackson wrote:
> >> Wei Chen writes ("[RFC v2] xen/arm: build: add missed dependency for head.S"):
> >> > In current Xen build rules, the build system will only check the
> >> > dependencies in current folder and obj-y generated dependencies
> >> > in other folder.
> >> >
> >> > But Makefile may add some objects to ALL_OBJS. These objects may
> >> > be not in the same folder as Makefile. Use arch/arm/Makefile as
> >> > an example:
> >> >     ALL_OBJS := $(TARGET_SUBARCH)/head.o
> >>
> >> Thanks for the v2.
> >>
> >> But I think I actually somewhat prefer the v1 approach, for these
> >> reasons:
> >>
> >> On 03/06/16 11:07, Wei Chen wrote:
> >> > In my mind, the better way to fix this bug is converting the DEPS from
> >> > ALL_OBJS. But I am afraid of the impact. I am not sure whether there
> >> > are some dependencies are not generated from obj files.
> >> >
> >> Ian Jackson writes ("Re: [RFC] xen/arm: build: add missed dependency for head.S"):
> >> > I do like this idea but I have the same worry.  It might be possible
> >> > to dump ALL_OBJS out somehow and check this, but it might be
> >> > arch-dependent.
> >> >
> >> > Wei Chen's patch is IMO a straightforward fix.
> >>
> >> I won't NAK the v2 but I think if Wei Chen is still happy for us to do
> >> so, we should commit the v1.
> >>
> >> Ian.
> >
> > We shall take either v1 or v2. I don't really have an opinion which one.
> >
> 
> Thank you. I will be happy if anyone would be committed. IMO, please
> commit the v1 patch.

Thanks for confirming.

Since both you and Ian prefer v1, I've queued up v1 for both
xen-unstable and 4.7 branch.

Wei.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

end of thread, other threads:[~2016-06-08  8:09 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-03 10:07 [RFC] xen/arm: build: add missed dependency for head.S Wei Chen
2016-06-06 17:08 ` Julien Grall
2016-06-07 10:03   ` Ian Jackson
2016-06-07  4:34     ` [RFC v2] " Wei Chen
2016-06-07 13:18       ` Konrad Rzeszutek Wilk
2016-06-08  3:10         ` Wei Chen
2016-06-07 16:01       ` [RFC v2] xen/arm: build: add missed dependency for head.S [and 1 more messages] Ian Jackson
2016-06-07 16:24         ` Wei Liu
2016-06-08  3:14           ` Wei Chen
2016-06-08  8:09             ` Wei Liu
2016-06-07 10:07     ` [RFC] xen/arm: build: add missed dependency for head.S Julien Grall

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).