public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [patch 0/6] Section mismatch fixes
@ 2010-01-13  0:48 Jeff Mahoney
  2010-01-13  0:48 ` [patch 2/6] hugetlb: Fix section mismatches Jeff Mahoney
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Jeff Mahoney @ 2010-01-13  0:48 UTC (permalink / raw)
  To: linux-kernel; +Cc: akpm

 This series fixes section mismatch warnings in 2.6.33-rc3-git5.

 -Jeff



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

* [patch 2/6] hugetlb: Fix section mismatches
  2010-01-13  0:48 [patch 0/6] Section mismatch fixes Jeff Mahoney
@ 2010-01-13  0:48 ` Jeff Mahoney
  2010-01-13  9:28   ` David Rientjes
  2010-01-13 15:40   ` [patch 2/6] hugetlb: Fix section mismatches Lee Schermerhorn
  2010-01-13  0:48 ` [patch 4/6] acpi: Fix section mismatch Jeff Mahoney
  2010-01-13  0:49 ` [patch 6/6] virtio: fix section mismatch warnings Jeff Mahoney
  2 siblings, 2 replies; 14+ messages in thread
From: Jeff Mahoney @ 2010-01-13  0:48 UTC (permalink / raw)
  To: Linux Kernel Mailing List; +Cc: Andrew Morton, Linux-MM

[-- Attachment #1: patches.rpmify/hugetlbfs-fix-section-mismatches --]
[-- Type: text/plain, Size: 1048 bytes --]

 hugetlb_register_node calls hugetlb_sysfs_add_hstate, which is marked with
 __init. Since hugetlb_register_node is only called by
 hugetlb_register_all_nodes, which in turn is only called by hugetlb_init,
 it's safe to mark both of them as __init.

Signed-off-by: Jeff Mahoney <jeffm@suse.com>
---
 mm/hugetlb.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/mm/hugetlb.c
+++ b/mm/hugetlb.c
@@ -1630,7 +1630,7 @@ void hugetlb_unregister_node(struct node
  * hugetlb module exit:  unregister hstate attributes from node sysdevs
  * that have them.
  */
-static void hugetlb_unregister_all_nodes(void)
+static void __init hugetlb_unregister_all_nodes(void)
 {
 	int nid;
 
@@ -1650,7 +1650,7 @@ static void hugetlb_unregister_all_nodes
  * Register hstate attributes for a single node sysdev.
  * No-op if attributes already registered.
  */
-void hugetlb_register_node(struct node *node)
+void __init hugetlb_register_node(struct node *node)
 {
 	struct hstate *h;
 	struct node_hstate *nhs = &node_hstates[node->sysdev.id];



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

* [patch 4/6] acpi: Fix section mismatch
  2010-01-13  0:48 [patch 0/6] Section mismatch fixes Jeff Mahoney
  2010-01-13  0:48 ` [patch 2/6] hugetlb: Fix section mismatches Jeff Mahoney
@ 2010-01-13  0:48 ` Jeff Mahoney
  2010-01-13  3:58   ` Alex Chiang
  2010-01-13  0:49 ` [patch 6/6] virtio: fix section mismatch warnings Jeff Mahoney
  2 siblings, 1 reply; 14+ messages in thread
From: Jeff Mahoney @ 2010-01-13  0:48 UTC (permalink / raw)
  To: Linux Kernel Mailing List; +Cc: Andrew Morton, Alex Chiang

[-- Attachment #1: patches.rpmify/acpi-fix-section-mismatch --]
[-- Type: text/plain, Size: 617 bytes --]

 acpi_early_processor_set_pdc uses processor_idle_dmi_table, which is
 marked __cpuinitdata. It's only called by acpi_bus_init, which is __init.
 We mark it __cpuinit.

Signed-off-by: Jeff Mahoney <jeffm@suse.com>
---
 drivers/acpi/processor_pdc.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/acpi/processor_pdc.c
+++ b/drivers/acpi/processor_pdc.c
@@ -151,7 +151,7 @@ early_init_pdc(acpi_handle handle, u32 l
 	return AE_OK;
 }
 
-void acpi_early_processor_set_pdc(void)
+void __cpuinit acpi_early_processor_set_pdc(void)
 {
 	/*
 	 * Check whether the system is DMI table. If yes, OSPM



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

* [patch 6/6] virtio: fix section mismatch warnings
  2010-01-13  0:48 [patch 0/6] Section mismatch fixes Jeff Mahoney
  2010-01-13  0:48 ` [patch 2/6] hugetlb: Fix section mismatches Jeff Mahoney
  2010-01-13  0:48 ` [patch 4/6] acpi: Fix section mismatch Jeff Mahoney
@ 2010-01-13  0:49 ` Jeff Mahoney
  2010-01-13 10:57   ` Rusty Russell
  2 siblings, 1 reply; 14+ messages in thread
From: Jeff Mahoney @ 2010-01-13  0:49 UTC (permalink / raw)
  To: linux-kernel; +Cc: akpm, Rusty Russell

[-- Attachment #1: patches.rpmify/virtio-fix-section-mismatch-warnings --]
[-- Type: text/plain, Size: 2164 bytes --]

 This patch fixes the following warnings by renaming the driver structures
 to be suffixed with _driver.

 WARNING: drivers/virtio/virtio_balloon.o(.data+0x88): Section mismatch in reference from the variable virtio_balloon to the function .devexit.text:virtballoon_remove()

 WARNING: drivers/char/hw_random/virtio-rng.o(.data+0x88): Section mismatch in reference from the variable virtio_rng to the function .devexit.text:virtrng_remove()

Signed-off-by: Jeff Mahoney <jeffm@suse.com>
---
 drivers/char/hw_random/virtio-rng.c |    6 +++---
 drivers/virtio/virtio_balloon.c     |    6 +++---
 2 files changed, 6 insertions(+), 6 deletions(-)

--- a/drivers/char/hw_random/virtio-rng.c
+++ b/drivers/char/hw_random/virtio-rng.c
@@ -114,7 +114,7 @@ static struct virtio_device_id id_table[
 	{ 0 },
 };
 
-static struct virtio_driver virtio_rng = {
+static struct virtio_driver virtio_rng_driver = {
 	.driver.name =	KBUILD_MODNAME,
 	.driver.owner =	THIS_MODULE,
 	.id_table =	id_table,
@@ -124,12 +124,12 @@ static struct virtio_driver virtio_rng =
 
 static int __init init(void)
 {
-	return register_virtio_driver(&virtio_rng);
+	return register_virtio_driver(&virtio_rng_driver);
 }
 
 static void __exit fini(void)
 {
-	unregister_virtio_driver(&virtio_rng);
+	unregister_virtio_driver(&virtio_rng_driver);
 }
 module_init(init);
 module_exit(fini);
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -266,7 +266,7 @@ static void __devexit virtballoon_remove
 
 static unsigned int features[] = { VIRTIO_BALLOON_F_MUST_TELL_HOST };
 
-static struct virtio_driver virtio_balloon = {
+static struct virtio_driver virtio_balloon_driver = {
 	.feature_table = features,
 	.feature_table_size = ARRAY_SIZE(features),
 	.driver.name =	KBUILD_MODNAME,
@@ -279,12 +279,12 @@ static struct virtio_driver virtio_ballo
 
 static int __init init(void)
 {
-	return register_virtio_driver(&virtio_balloon);
+	return register_virtio_driver(&virtio_balloon_driver);
 }
 
 static void __exit fini(void)
 {
-	unregister_virtio_driver(&virtio_balloon);
+	unregister_virtio_driver(&virtio_balloon_driver);
 }
 module_init(init);
 module_exit(fini);



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

* Re: [patch 4/6] acpi: Fix section mismatch
  2010-01-13  0:48 ` [patch 4/6] acpi: Fix section mismatch Jeff Mahoney
@ 2010-01-13  3:58   ` Alex Chiang
  0 siblings, 0 replies; 14+ messages in thread
From: Alex Chiang @ 2010-01-13  3:58 UTC (permalink / raw)
  To: Jeff Mahoney; +Cc: Linux Kernel Mailing List, Andrew Morton, lenb

Tony Luck already sent a patch for this to Len Brown (which I
acked).

Thanks,
/ac

* Jeff Mahoney <jeffm@suse.com>:
>  acpi_early_processor_set_pdc uses processor_idle_dmi_table, which is
>  marked __cpuinitdata. It's only called by acpi_bus_init, which is __init.
>  We mark it __cpuinit.
> 
> Signed-off-by: Jeff Mahoney <jeffm@suse.com>
> ---
>  drivers/acpi/processor_pdc.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- a/drivers/acpi/processor_pdc.c
> +++ b/drivers/acpi/processor_pdc.c
> @@ -151,7 +151,7 @@ early_init_pdc(acpi_handle handle, u32 l
>  	return AE_OK;
>  }
>  
> -void acpi_early_processor_set_pdc(void)
> +void __cpuinit acpi_early_processor_set_pdc(void)
>  {
>  	/*
>  	 * Check whether the system is DMI table. If yes, OSPM
> 
> 

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

* Re: [patch 2/6] hugetlb: Fix section mismatches
  2010-01-13  0:48 ` [patch 2/6] hugetlb: Fix section mismatches Jeff Mahoney
@ 2010-01-13  9:28   ` David Rientjes
  2010-01-13 14:29     ` Jeff Mahoney
  2010-01-13 15:03     ` [patch] hugetlb: Fix section mismatches #2 Jeff Mahoney
  2010-01-13 15:40   ` [patch 2/6] hugetlb: Fix section mismatches Lee Schermerhorn
  1 sibling, 2 replies; 14+ messages in thread
From: David Rientjes @ 2010-01-13  9:28 UTC (permalink / raw)
  To: Jeff Mahoney
  Cc: Linux Kernel Mailing List, Andrew Morton, Linux-MM,
	Lee Schermerhorn

On Tue, 12 Jan 2010, Jeff Mahoney wrote:

>  hugetlb_register_node calls hugetlb_sysfs_add_hstate, which is marked with
>  __init. Since hugetlb_register_node is only called by
>  hugetlb_register_all_nodes, which in turn is only called by hugetlb_init,
>  it's safe to mark both of them as __init.
> 
> Signed-off-by: Jeff Mahoney <jeffm@suse.com>
> ---
>  mm/hugetlb.c |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> --- a/mm/hugetlb.c
> +++ b/mm/hugetlb.c
> @@ -1630,7 +1630,7 @@ void hugetlb_unregister_node(struct node
>   * hugetlb module exit:  unregister hstate attributes from node sysdevs
>   * that have them.
>   */
> -static void hugetlb_unregister_all_nodes(void)
> +static void __init hugetlb_unregister_all_nodes(void)
>  {
>  	int nid;
>  

This is wrong, you want to move hugetlb_register_all_nodes() to 
.init.text, not hugetlb_unregister_all_nodes().

> @@ -1650,7 +1650,7 @@ static void hugetlb_unregister_all_nodes
>   * Register hstate attributes for a single node sysdev.
>   * No-op if attributes already registered.
>   */
> -void hugetlb_register_node(struct node *node)
> +void __init hugetlb_register_node(struct node *node)
>  {
>  	struct hstate *h;
>  	struct node_hstate *nhs = &node_hstates[node->sysdev.id];

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

* Re: [patch 6/6] virtio: fix section mismatch warnings
  2010-01-13  0:49 ` [patch 6/6] virtio: fix section mismatch warnings Jeff Mahoney
@ 2010-01-13 10:57   ` Rusty Russell
  2010-01-14  1:07     ` Andrew Morton
  0 siblings, 1 reply; 14+ messages in thread
From: Rusty Russell @ 2010-01-13 10:57 UTC (permalink / raw)
  To: Jeff Mahoney; +Cc: linux-kernel, akpm

On Wed, 13 Jan 2010 11:19:01 am Jeff Mahoney wrote:
>  This patch fixes the following warnings by renaming the driver structures
>  to be suffixed with _driver.
> 
>  WARNING: drivers/virtio/virtio_balloon.o(.data+0x88): Section mismatch in reference from the variable virtio_balloon to the function .devexit.text:virtballoon_remove()
> 
>  WARNING: drivers/char/hw_random/virtio-rng.o(.data+0x88): Section mismatch in reference from the variable virtio_rng to the function .devexit.text:virtrng_remove()
> 
> Signed-off-by: Jeff Mahoney <jeffm@suse.com>

Acked-by: Rusty Russell <rusty@rustcorp.com.au>

Andrew, will you take these?

Thanks,
Rusty.

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

* Re: [patch 2/6] hugetlb: Fix section mismatches
  2010-01-13  9:28   ` David Rientjes
@ 2010-01-13 14:29     ` Jeff Mahoney
  2010-01-13 15:03     ` [patch] hugetlb: Fix section mismatches #2 Jeff Mahoney
  1 sibling, 0 replies; 14+ messages in thread
From: Jeff Mahoney @ 2010-01-13 14:29 UTC (permalink / raw)
  To: David Rientjes
  Cc: Linux Kernel Mailing List, Andrew Morton, Linux-MM,
	Lee Schermerhorn

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 01/13/2010 04:28 AM, David Rientjes wrote:
> On Tue, 12 Jan 2010, Jeff Mahoney wrote:
> 
>>  hugetlb_register_node calls hugetlb_sysfs_add_hstate, which is marked with
>>  __init. Since hugetlb_register_node is only called by
>>  hugetlb_register_all_nodes, which in turn is only called by hugetlb_init,
>>  it's safe to mark both of them as __init.
>>
>> Signed-off-by: Jeff Mahoney <jeffm@suse.com>
>> ---
>>  mm/hugetlb.c |    4 ++--
>>  1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> --- a/mm/hugetlb.c
>> +++ b/mm/hugetlb.c
>> @@ -1630,7 +1630,7 @@ void hugetlb_unregister_node(struct node
>>   * hugetlb module exit:  unregister hstate attributes from node sysdevs
>>   * that have them.
>>   */
>> -static void hugetlb_unregister_all_nodes(void)
>> +static void __init hugetlb_unregister_all_nodes(void)
>>  {
>>  	int nid;
>>  
> 
> This is wrong, you want to move hugetlb_register_all_nodes() to 
> .init.text, not hugetlb_unregister_all_nodes().

Yep. You're right. I had this correct in my initial version of the patch
but accidentally deleted it while renaming them. I'll re-send.

- -Jeff

>> @@ -1650,7 +1650,7 @@ static void hugetlb_unregister_all_nodes
>>   * Register hstate attributes for a single node sysdev.
>>   * No-op if attributes already registered.
>>   */
>> -void hugetlb_register_node(struct node *node)
>> +void __init hugetlb_register_node(struct node *node)
>>  {
>>  	struct hstate *h;
>>  	struct node_hstate *nhs = &node_hstates[node->sysdev.id];


- -- 
Jeff Mahoney
SUSE Labs
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org/

iEYEARECAAYFAktN2NsACgkQLPWxlyuTD7LWzACcDpwbTkDEaZpdHUOYBiFqj0xP
9NkAnjoySOmUkV45P8yaMK6Z7N8xWnvn
=dTst
-----END PGP SIGNATURE-----

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

* [patch] hugetlb: Fix section mismatches #2
  2010-01-13  9:28   ` David Rientjes
  2010-01-13 14:29     ` Jeff Mahoney
@ 2010-01-13 15:03     ` Jeff Mahoney
  2010-01-13 20:51       ` David Rientjes
  1 sibling, 1 reply; 14+ messages in thread
From: Jeff Mahoney @ 2010-01-13 15:03 UTC (permalink / raw)
  To: David Rientjes
  Cc: Linux Kernel Mailing List, Andrew Morton, Linux-MM,
	Lee Schermerhorn

 hugetlb_register_node calls hugetlb_sysfs_add_hstate, which is marked with
 __init. Since hugetlb_register_node is only called by
 hugetlb_register_all_nodes, which in turn is only called by hugetlb_init,
 it's safe to mark both of them as __init.

Signed-off-by: Jeff Mahoney <jeffm@suse.com>
---
 mm/hugetlb.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/mm/hugetlb.c
+++ b/mm/hugetlb.c
@@ -1650,7 +1650,7 @@ static void hugetlb_unregister_all_nodes
  * Register hstate attributes for a single node sysdev.
  * No-op if attributes already registered.
  */
-void hugetlb_register_node(struct node *node)
+void __init hugetlb_register_node(struct node *node)
 {
 	struct hstate *h;
 	struct node_hstate *nhs = &node_hstates[node->sysdev.id];
@@ -1683,7 +1683,7 @@ void hugetlb_register_node(struct node *
  * sysdevs of nodes that have memory.  All on-line nodes should have
  * registered their associated sysdev by this time.
  */
-static void hugetlb_register_all_nodes(void)
+static void __init hugetlb_register_all_nodes(void)
 {
 	int nid;
 
-- 
Jeff Mahoney
SUSE Labs

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

* Re: [patch 2/6] hugetlb: Fix section mismatches
  2010-01-13  0:48 ` [patch 2/6] hugetlb: Fix section mismatches Jeff Mahoney
  2010-01-13  9:28   ` David Rientjes
@ 2010-01-13 15:40   ` Lee Schermerhorn
  2010-01-13 15:42     ` Jeff Mahoney
  1 sibling, 1 reply; 14+ messages in thread
From: Lee Schermerhorn @ 2010-01-13 15:40 UTC (permalink / raw)
  To: Jeff Mahoney; +Cc: Linux Kernel Mailing List, Andrew Morton, Linux-MM

On Tue, 2010-01-12 at 19:48 -0500, Jeff Mahoney wrote:
> plain text document attachment (patches.rpmify)
> hugetlb_register_node calls hugetlb_sysfs_add_hstate, which is marked with
>  __init. Since hugetlb_register_node is only called by
>  hugetlb_register_all_nodes, which in turn is only called by hugetlb_init,
>  it's safe to mark both of them as __init.

Actually, hugetlb_register_node() also called, via a function pointer
that hugetlb registers with the sysfs node driver, when a node is hot
plugged.  So, I think the correct approach is to remove the '__init'
from hugetlb_sysfs_add_hstate() as this is also used at runtime.  I
missed this in the original submittal.

Regards,
Lee Schermerhorn

> 
> Signed-off-by: Jeff Mahoney <jeffm@suse.com>
> ---
>  mm/hugetlb.c |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> --- a/mm/hugetlb.c
> +++ b/mm/hugetlb.c
> @@ -1630,7 +1630,7 @@ void hugetlb_unregister_node(struct node
>   * hugetlb module exit:  unregister hstate attributes from node sysdevs
>   * that have them.
>   */
> -static void hugetlb_unregister_all_nodes(void)
> +static void __init hugetlb_unregister_all_nodes(void)
>  {
>  	int nid;
>  
> @@ -1650,7 +1650,7 @@ static void hugetlb_unregister_all_nodes
>   * Register hstate attributes for a single node sysdev.
>   * No-op if attributes already registered.
>   */
> -void hugetlb_register_node(struct node *node)
> +void __init hugetlb_register_node(struct node *node)
>  {
>  	struct hstate *h;
>  	struct node_hstate *nhs = &node_hstates[node->sysdev.id];
> 
> 
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majordomo@kvack.org.  For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>


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

* Re: [patch 2/6] hugetlb: Fix section mismatches
  2010-01-13 15:40   ` [patch 2/6] hugetlb: Fix section mismatches Lee Schermerhorn
@ 2010-01-13 15:42     ` Jeff Mahoney
  0 siblings, 0 replies; 14+ messages in thread
From: Jeff Mahoney @ 2010-01-13 15:42 UTC (permalink / raw)
  To: Lee Schermerhorn; +Cc: Linux Kernel Mailing List, Andrew Morton, Linux-MM

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 01/13/2010 10:40 AM, Lee Schermerhorn wrote:
> On Tue, 2010-01-12 at 19:48 -0500, Jeff Mahoney wrote:
>> plain text document attachment (patches.rpmify)
>> hugetlb_register_node calls hugetlb_sysfs_add_hstate, which is marked with
>>  __init. Since hugetlb_register_node is only called by
>>  hugetlb_register_all_nodes, which in turn is only called by hugetlb_init,
>>  it's safe to mark both of them as __init.
> 
> Actually, hugetlb_register_node() also called, via a function pointer
> that hugetlb registers with the sysfs node driver, when a node is hot
> plugged.  So, I think the correct approach is to remove the '__init'
> from hugetlb_sysfs_add_hstate() as this is also used at runtime.  I
> missed this in the original submittal.

Yep. You're right. Sorry for the noise.

- -Jeff

> Regards,
> Lee Schermerhorn
> 
>>
>> Signed-off-by: Jeff Mahoney <jeffm@suse.com>
>> ---
>>  mm/hugetlb.c |    4 ++--
>>  1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> --- a/mm/hugetlb.c
>> +++ b/mm/hugetlb.c
>> @@ -1630,7 +1630,7 @@ void hugetlb_unregister_node(struct node
>>   * hugetlb module exit:  unregister hstate attributes from node sysdevs
>>   * that have them.
>>   */
>> -static void hugetlb_unregister_all_nodes(void)
>> +static void __init hugetlb_unregister_all_nodes(void)
>>  {
>>  	int nid;
>>  
>> @@ -1650,7 +1650,7 @@ static void hugetlb_unregister_all_nodes
>>   * Register hstate attributes for a single node sysdev.
>>   * No-op if attributes already registered.
>>   */
>> -void hugetlb_register_node(struct node *node)
>> +void __init hugetlb_register_node(struct node *node)
>>  {
>>  	struct hstate *h;
>>  	struct node_hstate *nhs = &node_hstates[node->sysdev.id];
>>
>>
>> --
>> To unsubscribe, send a message with 'unsubscribe linux-mm' in
>> the body to majordomo@kvack.org.  For more info on Linux MM,
>> see: http://www.linux-mm.org/ .
>> Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
> 


- -- 
Jeff Mahoney
SUSE Labs
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org/

iEYEARECAAYFAktN6dYACgkQLPWxlyuTD7JzEgCfXZKyPnW9VKO7OTatSm5k5WSI
l6sAoIVB0cTvz1AwN2mG7ANGPt6VVuTi
=TYGp
-----END PGP SIGNATURE-----

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

* Re: [patch] hugetlb: Fix section mismatches #2
  2010-01-13 15:03     ` [patch] hugetlb: Fix section mismatches #2 Jeff Mahoney
@ 2010-01-13 20:51       ` David Rientjes
  0 siblings, 0 replies; 14+ messages in thread
From: David Rientjes @ 2010-01-13 20:51 UTC (permalink / raw)
  To: Jeff Mahoney, Andrew Morton
  Cc: Linux Kernel Mailing List, Linux-MM, Lee Schermerhorn

On Wed, 13 Jan 2010, Jeff Mahoney wrote:

>  hugetlb_register_node calls hugetlb_sysfs_add_hstate, which is marked with
>  __init. Since hugetlb_register_node is only called by
>  hugetlb_register_all_nodes, which in turn is only called by hugetlb_init,
>  it's safe to mark both of them as __init.
> 
> Signed-off-by: Jeff Mahoney <jeffm@suse.com>

Acked-by: David Rientjes <rientjes@google.com>

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

* Re: [patch 6/6] virtio: fix section mismatch warnings
  2010-01-13 10:57   ` Rusty Russell
@ 2010-01-14  1:07     ` Andrew Morton
  2010-01-14  2:01       ` Jeff Mahoney
  0 siblings, 1 reply; 14+ messages in thread
From: Andrew Morton @ 2010-01-14  1:07 UTC (permalink / raw)
  To: Rusty Russell; +Cc: Jeff Mahoney, linux-kernel

On Wed, 13 Jan 2010 21:27:26 +1030
Rusty Russell <rusty@rustcorp.com.au> wrote:

> On Wed, 13 Jan 2010 11:19:01 am Jeff Mahoney wrote:
> >  This patch fixes the following warnings by renaming the driver structures
> >  to be suffixed with _driver.
> > 
> >  WARNING: drivers/virtio/virtio_balloon.o(.data+0x88): Section mismatch in reference from the variable virtio_balloon to the function .devexit.text:virtballoon_remove()
> > 
> >  WARNING: drivers/char/hw_random/virtio-rng.o(.data+0x88): Section mismatch in reference from the variable virtio_rng to the function .devexit.text:virtrng_remove()
> > 
> > Signed-off-by: Jeff Mahoney <jeffm@suse.com>
> 
> Acked-by: Rusty Russell <rusty@rustcorp.com.au>
> 
> Andrew, will you take these?
> 

umm, sure.  But I wish I knew how the patch worked.  Is there some
magic sauce which moves a variable called foo_driver into a different
section or what?

And if so, what was I doing when that got done :(

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

* Re: [patch 6/6] virtio: fix section mismatch warnings
  2010-01-14  1:07     ` Andrew Morton
@ 2010-01-14  2:01       ` Jeff Mahoney
  0 siblings, 0 replies; 14+ messages in thread
From: Jeff Mahoney @ 2010-01-14  2:01 UTC (permalink / raw)
  To: Andrew Morton; +Cc: Rusty Russell, linux-kernel

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 01/13/2010 08:07 PM, Andrew Morton wrote:
> On Wed, 13 Jan 2010 21:27:26 +1030
> Rusty Russell <rusty@rustcorp.com.au> wrote:
> 
>> On Wed, 13 Jan 2010 11:19:01 am Jeff Mahoney wrote:
>>>  This patch fixes the following warnings by renaming the driver structures
>>>  to be suffixed with _driver.
>>>
>>>  WARNING: drivers/virtio/virtio_balloon.o(.data+0x88): Section mismatch in reference from the variable virtio_balloon to the function .devexit.text:virtballoon_remove()
>>>
>>>  WARNING: drivers/char/hw_random/virtio-rng.o(.data+0x88): Section mismatch in reference from the variable virtio_rng to the function .devexit.text:virtrng_remove()
>>>
>>> Signed-off-by: Jeff Mahoney <jeffm@suse.com>
>>
>> Acked-by: Rusty Russell <rusty@rustcorp.com.au>
>>
>> Andrew, will you take these?
>>
> 
> umm, sure.  But I wish I knew how the patch worked.  Is there some
> magic sauce which moves a variable called foo_driver into a different
> section or what?
> 
> And if so, what was I doing when that got done :(

It doesn't move it into a different section, it just shuts the warning
up. modpost has a whitelist it uses to ignore the mismatch warning.

- -Jeff

- -- 
Jeff Mahoney
SUSE Labs
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org/

iEYEARECAAYFAktOewsACgkQLPWxlyuTD7IGKgCfSETonDGCsM/AgsUmdGtvSzCi
omQAn3tMc0Ol6PkpaX0Qf6+tvcUnlqcU
=jUja
-----END PGP SIGNATURE-----

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

end of thread, other threads:[~2010-01-14  2:02 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-13  0:48 [patch 0/6] Section mismatch fixes Jeff Mahoney
2010-01-13  0:48 ` [patch 2/6] hugetlb: Fix section mismatches Jeff Mahoney
2010-01-13  9:28   ` David Rientjes
2010-01-13 14:29     ` Jeff Mahoney
2010-01-13 15:03     ` [patch] hugetlb: Fix section mismatches #2 Jeff Mahoney
2010-01-13 20:51       ` David Rientjes
2010-01-13 15:40   ` [patch 2/6] hugetlb: Fix section mismatches Lee Schermerhorn
2010-01-13 15:42     ` Jeff Mahoney
2010-01-13  0:48 ` [patch 4/6] acpi: Fix section mismatch Jeff Mahoney
2010-01-13  3:58   ` Alex Chiang
2010-01-13  0:49 ` [patch 6/6] virtio: fix section mismatch warnings Jeff Mahoney
2010-01-13 10:57   ` Rusty Russell
2010-01-14  1:07     ` Andrew Morton
2010-01-14  2:01       ` Jeff Mahoney

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