IPMI: fix devinit placement
PATCH 1/1 IPMI: fix devinit placement
From: Randy Dunlap <[email protected]>
gcc complains about __devinit in the wrong location:drivers/char/ipmi/ipmi_si_intf.c:2205: warning: '__section__' attribute does not apply to types
--- drivers/char/ipmi/ipmi_si_intf.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/char/ipmi/ipmi_si_intf.c +2 -2
@@ -2198,11 +2198,11 @@ static inline void wait_for_timer_and_th } } -static struct ipmi_default_vals +static __devinit struct ipmi_default_vals {int type;int port; -}__devinit ipmi_defaults[] = +} ipmi_defaults[] = { { .type =SI_KCS , .port =0xca2 }, { .type =SI_SMIC , .port =0xca9 },
---
Looks fine to me. Thanks.
-Corey
Quoted 31 lines · Randy.Dunlap
From: Randy Dunlap <[email protected]>
gcc complains about
__devinitin the wrong location:drivers/char/ipmi/ipmi_si_intf.c:2205: warning: '__section__' attribute does not apply to typesSigned-off-by Randy Dunlap <[email protected]>---
drivers/char/ipmi/ipmi_si_intf.c| 4 ++--1 files changed, 2 insertions(+), 2 deletions(-)drivers/char/ipmi/ipmi_si_intf.c +2
-3@@ -2198,11 +2198,11 @@ static inline void wait_for_timer_and_th } } -static struct ipmi_default_vals +static __devinit struct ipmi_default_vals {int type;int port; -}__devinit ipmi_defaults[] = +} ipmi_defaults[] = { { .type =SI_KCS , .port =0xca2 }, { .type =SI_SMIC , .port =0xca9 }, ---
PATCH 1/1 IPMI: fix devinit placement (take 2)
In reply to Randy.DunlapFrom: Randy Dunlap <[email protected]>
gcc complains about __devinit in the wrong location:drivers/char/ipmi/ipmi_si_intf.c:2205: warning: '__section__' attribute does not apply to types
Actually for data it should be __devinitdata instead of __devinit. Otherwise it causes another gcc section mismatch error.
--- drivers/char/ipmi/ipmi_si_intf.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/char/ipmi/ipmi_si_intf.c +2 -2
@@ -2198,11 +2198,11 @@ static inline void wait_for_timer_and_th } } -static struct ipmi_default_vals +static __devinitdata struct ipmi_default_vals {int type;int port; -}__devinit ipmi_defaults[] = +} ipmi_defaults[] = { { .type =SI_KCS , .port =0xca2 }, { .type =SI_SMIC , .port =0xca9 },
---