public inbox for linux-kbuild@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Let modpost parses vmlinux instead of vmlinux.o
       [not found] <4F737193.4030709@am.sony.com>
@ 2012-03-29 14:53 ` Alessio Igor Bogani
  2012-03-29 20:23   ` Sam Ravnborg
  2012-03-29 21:53   ` Frank Rowand
  0 siblings, 2 replies; 4+ messages in thread
From: Alessio Igor Bogani @ 2012-03-29 14:53 UTC (permalink / raw)
  To: Frank Rowand
  Cc: Rowand Frank, Rusty Russell, Jan Beulich, Kbuild, LKML, Tim Bird,
	Anders Kaseorg, Arnaud Lacombe, Alessio Igor Bogani

Dear Mr. Rowand,

What do you think about this patch?
Thanks!

Ciao,
Alessio

---
 Makefile                 |    2 +-
 scripts/Makefile.modpost |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 123d858..b589d1f 100644
--- a/Makefile
+++ b/Makefile
@@ -876,7 +876,7 @@ quiet_cmd_vmlinux-modpost = LD      $@
 define rule_vmlinux-modpost
 	:
 	+$(call cmd,vmlinux-modpost)
-	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $@
+	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $*
 	$(Q)echo 'cmd_$@ := $(cmd_vmlinux-modpost)' > $(dot-target).cmd
 endef
 
diff --git a/scripts/Makefile.modpost b/scripts/Makefile.modpost
index 56dfafc..ca0db29 100644
--- a/scripts/Makefile.modpost
+++ b/scripts/Makefile.modpost
@@ -93,7 +93,7 @@ __modpost: $(modules:.ko=.o) FORCE
 quiet_cmd_kernel-mod = MODPOST $@
       cmd_kernel-mod = $(modpost) $@
 
-vmlinux.o: FORCE
+vmlinux vmlinux.o: FORCE
 	$(call cmd,kernel-mod)
 
 # Declare generated files as targets for modpost
-- 
1.7.5.4


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

* Re: [PATCH] Let modpost parses vmlinux instead of vmlinux.o
  2012-03-29 14:53 ` [PATCH] Let modpost parses vmlinux instead of vmlinux.o Alessio Igor Bogani
@ 2012-03-29 20:23   ` Sam Ravnborg
  2012-03-29 21:53   ` Frank Rowand
  1 sibling, 0 replies; 4+ messages in thread
From: Sam Ravnborg @ 2012-03-29 20:23 UTC (permalink / raw)
  To: Alessio Igor Bogani
  Cc: Frank Rowand, Rowand Frank, Rusty Russell, Jan Beulich, Kbuild,
	LKML, Tim Bird, Anders Kaseorg, Arnaud Lacombe

On Thu, Mar 29, 2012 at 04:53:06PM +0200, Alessio Igor Bogani wrote:
> Dear Mr. Rowand,
> 
> What do you think about this patch?
> Thanks!
> 
> Ciao,
> Alessio

Hi Alession.

I am not Mr. Rowand - obviously...

The title alone looks like you are doing something wrong.
The difference between vmlinux.o and vmlinux is that the latter
is linked using the linker scripts. So a lot of sections are merged.
And modpost uses these section for the section mismatch analysis.

Then your patch fails to describe why it is needed.
And on top of this I do not understand the patch.

So a lot of things looks bad :-(

	Sam
> 
> ---
>  Makefile                 |    2 +-
>  scripts/Makefile.modpost |    2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/Makefile b/Makefile
> index 123d858..b589d1f 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -876,7 +876,7 @@ quiet_cmd_vmlinux-modpost = LD      $@
>  define rule_vmlinux-modpost
>  	:
>  	+$(call cmd,vmlinux-modpost)
> -	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $@
> +	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $*

I do not see where the stem is coming from - and why this is needed.


>  	$(Q)echo 'cmd_$@ := $(cmd_vmlinux-modpost)' > $(dot-target).cmd
>  endef
>  
> diff --git a/scripts/Makefile.modpost b/scripts/Makefile.modpost
> index 56dfafc..ca0db29 100644
> --- a/scripts/Makefile.modpost
> +++ b/scripts/Makefile.modpost
> @@ -93,7 +93,7 @@ __modpost: $(modules:.ko=.o) FORCE
>  quiet_cmd_kernel-mod = MODPOST $@
>        cmd_kernel-mod = $(modpost) $@
>  
> -vmlinux.o: FORCE
> +vmlinux vmlinux.o: FORCE
>  	$(call cmd,kernel-mod)
It looks like you process both of vmlinux.o and vmlinux?!?!

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

* Re: [PATCH] Let modpost parses vmlinux instead of vmlinux.o
  2012-03-29 14:53 ` [PATCH] Let modpost parses vmlinux instead of vmlinux.o Alessio Igor Bogani
  2012-03-29 20:23   ` Sam Ravnborg
@ 2012-03-29 21:53   ` Frank Rowand
  2012-03-29 21:57     ` Frank Rowand
  1 sibling, 1 reply; 4+ messages in thread
From: Frank Rowand @ 2012-03-29 21:53 UTC (permalink / raw)
  To: Alessio Igor Bogani
  Cc: Rowand, Frank, Rusty Russell, Jan Beulich, Kbuild, LKML,
	Bird, Tim, Anders Kaseorg, Arnaud Lacombe

On 03/29/12 07:53, Alessio Igor Bogani wrote:
> Dear Mr. Rowand,

No need to be formal, "Frank" is ok.


> 
> What do you think about this patch?

It does not work for me.  The resulting Module.symvers is empty.

Before applying the Makefile patch, "make V=1" shows the command
to generate Module.symvers is:

  scripts/mod/modpost   -o /a/home/frowand/me/src/linux/kernel-org/build/crest/Module.symvers    -S   vmlinux.o

after applying the patch, the command becomes:

  scripts/mod/modpost   -o /a/home/frowand/me/src/linux/kernel-org/build/crest/Module.symvers    -S   -s


-Frank

> Thanks!
> 
> Ciao,
> Alessio
> 
> ---
>  Makefile                 |    2 +-
>  scripts/Makefile.modpost |    2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/Makefile b/Makefile
> index 123d858..b589d1f 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -876,7 +876,7 @@ quiet_cmd_vmlinux-modpost = LD      $@
>  define rule_vmlinux-modpost
>  	:
>  	+$(call cmd,vmlinux-modpost)
> -	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $@
> +	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $*
>  	$(Q)echo 'cmd_$@ := $(cmd_vmlinux-modpost)' > $(dot-target).cmd
>  endef
>  
> diff --git a/scripts/Makefile.modpost b/scripts/Makefile.modpost
> index 56dfafc..ca0db29 100644
> --- a/scripts/Makefile.modpost
> +++ b/scripts/Makefile.modpost
> @@ -93,7 +93,7 @@ __modpost: $(modules:.ko=.o) FORCE
>  quiet_cmd_kernel-mod = MODPOST $@
>        cmd_kernel-mod = $(modpost) $@
>  
> -vmlinux.o: FORCE
> +vmlinux vmlinux.o: FORCE
>  	$(call cmd,kernel-mod)
>  
>  # Declare generated files as targets for modpost



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

* Re: [PATCH] Let modpost parses vmlinux instead of vmlinux.o
  2012-03-29 21:53   ` Frank Rowand
@ 2012-03-29 21:57     ` Frank Rowand
  0 siblings, 0 replies; 4+ messages in thread
From: Frank Rowand @ 2012-03-29 21:57 UTC (permalink / raw)
  To: Rowand, Frank
  Cc: Alessio Igor Bogani, Rusty Russell, Jan Beulich, Kbuild, LKML,
	Bird, Tim, Anders Kaseorg, Arnaud Lacombe

On 03/29/12 14:53, Frank Rowand wrote:
> On 03/29/12 07:53, Alessio Igor Bogani wrote:
>> Dear Mr. Rowand,
> 
> No need to be formal, "Frank" is ok.
> 
> 
>>
>> What do you think about this patch?
> 
> It does not work for me.  The resulting Module.symvers is empty.
> 
> Before applying the Makefile patch, "make V=1" shows the command
                                      ^^^ "make V=1 vmlinux"
> to generate Module.symvers is:
> 
>   scripts/mod/modpost   -o /a/home/frowand/me/src/linux/kernel-org/build/crest/Module.symvers    -S   vmlinux.o
> 
> after applying the patch, the command becomes:
> 
>   scripts/mod/modpost   -o /a/home/frowand/me/src/linux/kernel-org/build/crest/Module.symvers    -S   -s
> 
> 
> -Frank
> 
>> Thanks!
>>
>> Ciao,
>> Alessio
>>
>> ---
>>  Makefile                 |    2 +-
>>  scripts/Makefile.modpost |    2 +-
>>  2 files changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/Makefile b/Makefile
>> index 123d858..b589d1f 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -876,7 +876,7 @@ quiet_cmd_vmlinux-modpost = LD      $@
>>  define rule_vmlinux-modpost
>>  	:
>>  	+$(call cmd,vmlinux-modpost)
>> -	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $@
>> +	$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost $*
>>  	$(Q)echo 'cmd_$@ := $(cmd_vmlinux-modpost)' > $(dot-target).cmd
>>  endef
>>  
>> diff --git a/scripts/Makefile.modpost b/scripts/Makefile.modpost
>> index 56dfafc..ca0db29 100644
>> --- a/scripts/Makefile.modpost
>> +++ b/scripts/Makefile.modpost
>> @@ -93,7 +93,7 @@ __modpost: $(modules:.ko=.o) FORCE
>>  quiet_cmd_kernel-mod = MODPOST $@
>>        cmd_kernel-mod = $(modpost) $@
>>  
>> -vmlinux.o: FORCE
>> +vmlinux vmlinux.o: FORCE
>>  	$(call cmd,kernel-mod)
>>  
>>  # Declare generated files as targets for modpost
> 
> .
> 



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

end of thread, other threads:[~2012-03-29 21:58 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <4F737193.4030709@am.sony.com>
2012-03-29 14:53 ` [PATCH] Let modpost parses vmlinux instead of vmlinux.o Alessio Igor Bogani
2012-03-29 20:23   ` Sam Ravnborg
2012-03-29 21:53   ` Frank Rowand
2012-03-29 21:57     ` Frank Rowand

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