drm/i915: acpi/video.c fix section mismatch warning
Subsystems (3)
PATCH 1/2 drm/i915: acpi/video.c fix section mismatch warning
Currently acpi_video_exit() is exported as well as using __exit which causes:
WARNING: drivers/acpi/video.o(__ksymtab+0x0): Section mismatch in reference from the variable __ksymtab_acpi_video_exit to the function .exit.text:acpi_video_exit() The symbol acpi_video_exit is exported and annotated __exit
Fix this by removing the __exit annotation of acpi_video_exit or drop the export.
--- drivers/acpi/video.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/acpi/video.c +1 -1
@@ -2334,7 +2334,7 @@ static int __init acpi_video_init(void)return acpi_video_register (); } -void __exit acpi_video_exit(void) +void acpi_video_exit (void ) {acpi_bus_unregister_driver (&acpi_video_bus);
Signature · 1 line
1.6.1.1
PATCH 2/2 drm/i915: intel_lvds.c fix section mismatch warning
intel_no_lvds[] does not require __initdata as it is used only by :
void intel_lvds_init(struct drm_device *dev)
fixes section mismatch warning:
WARNING: drivers/gpu/drm/i915/i915.o(.text+0xf3c5): Section mismatch in reference from the function intel_lvds_init() to the variable .init.data:intel_no_lvds The function intel_lvds_init() references
the variable __initdata intel_no_lvds.
This is often because intel_lvds_init lacks a __initdata
--- drivers/gpu/drm/i915/intel_lvds.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/gpu/drm/i915/intel_lvds.c +1 -1
@@ -391,7 +391,7 @@ static int __init intel_no_lvds_dmi_callback(const struct dmi_system_id *id) }/* These systems claim to have LVDS, but really don't */ -static const struct dmi_system_id __initdata intel_no_lvds[] = { +static const struct dmi_system_id intel_no_lvds[] = { { .callback = intel_no_lvds_dmi_callback, .ident ="Apple Mac Mini (Core series)" ,
Signature · 1 line
1.6.1.1
Re: [PATCH 2/2 -tip] drm/i915: intel_lvds.c fix section mismatch warning
Quoted 11 lines · On Wednesday 20 May 2009 02:27:35 Jaswinder Singh Rajput wrote:
intel_no_lvds[] does not require
__initdataas it is used only by :void
intel_lvds_init(struct drm_device *dev)fixes section mismatch warning:
WARNING: drivers/gpu/drm/i915/i915.o(.text+0xf3c5): Section mismatch in reference from the function
intel_lvds_init()to the variable .init.data:intel_no_lvds The functionintel_lvds_init()references
the variable__initdataintel_no_lvds.
This is often becauseintel_lvds_initlacks a__initdata
This would seem to suggest __initdata should be added to intel_lvds_init, rather than removed from intel_no_lvds...
But I suppose either one would work. Apologies for not catching the initial mismatch... :\
Quoted 18 lines
Signed-off-by Jaswinder Singh Rajput <[email protected]>--- drivers/gpu/drm/i915/intel_lvds.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)drivers/gpu/drm/i915/intel_lvds.c +1
-1@@ -391,7 +391,7 @@ static int __init intel_no_lvds_dmi_callback(const struct dmi_system_id *id) }/* These systems claim to have LVDS, but really don't */ -static const struct dmi_system_id __initdata intel_no_lvds[] = { +static const struct dmi_system_id intel_no_lvds[] = { { .callback = intel_no_lvds_dmi_callback, .ident ="Apple Mac Mini (Core series)" ,
Signature · 2 lines
Jarod Wilson [email protected]
Re: [PATCH 2/2 -tip] drm/i915: intel_lvds.c fix section mismatch warning
Quoted 8 lines · Jarod Wilson
Quoted 7 lines · On Wednesday 20 May 2009 02:27:35 Jaswinder Singh Rajput wrote:
intel_no_lvds[] does not require
__initdataas it is used only by :void
intel_lvds_init(struct drm_device *dev)fixes section mismatch warning:
Quoted 8 lines
Quoted 4 lines
WARNING: drivers/gpu/drm/i915/i915.o(.text+0xf3c5): Section mismatch in reference from the function
intel_lvds_init()to the variable .init.data:intel_no_lvds The functionintel_lvds_init()references
the variable__initdataintel_no_lvds.
This is often becauseintel_lvds_initlacks a__initdataThis would seem to suggest
__initdatashould be added tointel_lvds_init, rather than removed fromintel_no_lvds...
The complete statement is :
WARNING: drivers/gpu/drm/i915/i915.o(.text+0xf3c5): Section mismatch in reference from the function intel_lvds_init() to the variable .init.data:intel_no_lvds The function intel_lvds_init() references
the variable __initdata intel_no_lvds.
This is often because intel_lvds_init lacks a __initdata
annotation or the annotation of intel_no_lvds is wrong.
Quoted 3 lines
But I suppose either one would work. Apologies for not catching the initial mismatch... :\
No another way it will not work.
As intel_no_lvds is used by intel_lvds_init and dmi_check_system.
We can not set intel_lvds_init as intel_lvds_init is used by :
static void intel_setup_outputs(struct drm_device *dev)
We can not set dmi_check_system to __init as it is also exported.
So the only option is to remove __initdata.
It seems the first patch : "[PATCH 1/2 -tip] drm/i915: acpi/video.c fix section mismatch warning" is applied in acpi tree by Len Brown.
I am not sure where this patch should go.
So I am also mailing to Andrew and Dave, it they find this useful then they can add in their tree.
Quoted 20 lines
Quoted 18 lines
Signed-off-by Jaswinder Singh Rajput <[email protected]>--- drivers/gpu/drm/i915/intel_lvds.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)drivers/gpu/drm/i915/intel_lvds.c +1
-1@@ -391,7 +391,7 @@ static int __init intel_no_lvds_dmi_callback(const struct dmi_system_id *id) }/* These systems claim to have LVDS, but really don't */ -static const struct dmi_system_id __initdata intel_no_lvds[] = { +static const struct dmi_system_id intel_no_lvds[] = { { .callback = intel_no_lvds_dmi_callback, .ident ="Apple Mac Mini (Core series)" ,
Jarod Wilson
Acked-byRe: [PATCH 2/2 -tip] drm/i915: intel_lvds.c fix section mismatch warning
Quoted 18 lines · On Friday 29 May 2009 02:16:35 Jaswinder Singh Rajput wrote:
Quoted 8 lines · Jarod Wilson
Quoted 7 lines · On Wednesday 20 May 2009 02:27:35 Jaswinder Singh Rajput wrote:
intel_no_lvds[] does not require
__initdataas it is used only by :void
intel_lvds_init(struct drm_device *dev)fixes section mismatch warning:
Quoted 8 lines
Quoted 4 lines
WARNING: drivers/gpu/drm/i915/i915.o(.text+0xf3c5): Section mismatch in reference from the function
intel_lvds_init()to the variable .init.data:intel_no_lvds The functionintel_lvds_init()references
the variable__initdataintel_no_lvds.
This is often becauseintel_lvds_initlacks a__initdataThis would seem to suggest
__initdatashould be added tointel_lvds_init, rather than removed fromintel_no_lvds...
Quoted 7 lines
The complete statement is :
WARNING: drivers/gpu/drm/i915/i915.o(.text+0xf3c5): Section mismatch in reference from the function
intel_lvds_init()to the variable .init.data:intel_no_lvds The functionintel_lvds_init()references
the variable__initdataintel_no_lvds.
This is often becauseintel_lvds_initlacks a__initdata
annotation or the annotation ofintel_no_lvdsis wrong.
Ah, yeah, I'd have kept my mouth shut if the last line were there the first time, or at least looked at the code more to understand why you went this direction. ;)
Quoted 4 lines
I am not sure where this patch should go.
So I am also mailing to Andrew and Dave, it they find this useful then they can add in their tree.
Dave is on vacation a bit longer, iirc. Not entirely sure where else this might go either. I'm sure *someone* will pick it up sooner or later... In any case, thanks for the fix for my flub.
Signature · 2 lines
Jarod Wilson [email protected]
Re: [PATCH 2/2 -tip] drm/i915: intel_lvds.c fix section mismatch warning
Hi Andrew,
Quoted 12 lines · Jarod Wilson
Quoted 4 lines · On Friday 29 May 2009 02:16:35 Jaswinder Singh Rajput wrote:
I am not sure where this patch should go.
So I am also mailing to Andrew and Dave, it they find this useful then they can add in their tree.
Dave is on vacation a bit longer, iirc. Not entirely sure where else this might go either. I'm sure *someone* will pick it up sooner or later... In any case, thanks for the fix for my flub.
Acked-by Jarod Wilson <[email protected]>
Can you accept this patch with Jarod Ack as Dave is on vacation and Ingo is still busy with perfcounter ;-)
Thanks,
--
JSR
Re: [PATCH 2/2 -tip] drm/i915: intel_lvds.c fix section mismatch warning
Quoted 13 lines · On Fri, 29 May 2009 19:58:36 +0530 Jaswinder Singh Rajput…
Hi Andrew,
Quoted 10 lines · Jarod Wilson
Quoted 4 lines · On Friday 29 May 2009 02:16:35 Jaswinder Singh Rajput wrote:
I am not sure where this patch should go.
So I am also mailing to Andrew and Dave, it they find this useful then they can add in their tree.
Dave is on vacation a bit longer, iirc. Not entirely sure where else this might go either. I'm sure *someone* will pick it up sooner or later... In any case, thanks for the fix for my flub.
Quoted 5 lines
Quoted 2 lines
Acked-by Jarod Wilson <[email protected]>Can you accept this patch with Jarod Ack as Dave is on vacation and Ingo is still busy with perfcounter ;-)
It doesn't sound urgent, or are you seeing crashes due to this? If so I can queue it up to Linus (I'm taking critical fixes while Dave is away, though I think he's back now actually).
Jesse
Re: [PATCH 2/2 -tip] drm/i915: intel_lvds.c fix section mismatch warning
Quoted 19 lines · Jesse Barnes
Quoted 16 lines · On Fri, 29 May 2009 19:58:36 +0530 Jaswinder Singh Rajput…
Hi Andrew,
Quoted 12 lines · Jarod Wilson
Quoted 4 lines · On Friday 29 May 2009 02:16:35 Jaswinder Singh Rajput wrote:
I am not sure where this patch should go.
So I am also mailing to Andrew and Dave, it they find this useful then they can add in their tree.
Dave is on vacation a bit longer, iirc. Not entirely sure where else this might go either. I'm sure *someone* will pick it up sooner or later... In any case, thanks for the fix for my flub.
Acked-by Jarod Wilson <[email protected]>
Quoted 7 lines
Quoted 2 lines
Can you accept this patch with Jarod Ack as Dave is on vacation and Ingo is still busy with perfcounter ;-)
It doesn't sound urgent, or are you seeing crashes due to this? If so I can queue it up to Linus (I'm taking critical fixes while Dave is away, though I think he's back now actually).
Ok, then better wait for Dave :-)
--
JSR
applied to acpi tree.
thanks,
Len Brown, Intel Open Source Technology Center
Quoted 36 lines · Jaswinder Singh Rajput
Currently
acpi_video_exit()is exported as well as using__exitwhich causes:WARNING: drivers/acpi/video.o(__ksymtab+0x0): Section mismatch in reference from the variable
__ksymtab_acpi_video_exitto the function .exit.text:acpi_video_exit() The symbolacpi_video_exitis exported and annotated__exit
Fix this by removing the__exitannotation ofacpi_video_exitor drop the export.Signed-off-by Jaswinder Singh Rajput <[email protected]>--- drivers/acpi/video.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)drivers/acpi/video.c +1
-1@@ -2334,7 +2334,7 @@ static int __init acpi_video_init(void)return acpi_video_register (); } -void __exit acpi_video_exit(void) +void acpi_video_exit (void ) {acpi_bus_unregister_driver (&acpi_video_bus);Signature · 9 lines
1.6.1.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/