* [PATCH v1 1/1] UBI: Fix section mismatch
@ 2017-01-09 18:10 Andy Shevchenko
2017-01-09 19:34 ` Andy Shevchenko
0 siblings, 1 reply; 5+ messages in thread
From: Andy Shevchenko @ 2017-01-09 18:10 UTC (permalink / raw)
To: Artem Bityutskiy, Boris Brezillon, linux-mtd, Brian Norris
Cc: Andy Shevchenko, Richard Weinberger
WARNING: vmlinux.o(.text+0x1f2a80): Section mismatch in reference from the variable __param_ops_mtd to the function .init.text:ubi_mtd_param_parse()
The function __param_ops_mtd() references
the function __init ubi_mtd_param_parse().
This is often because __param_ops_mtd lacks a __init
annotation or the annotation of ubi_mtd_param_parse is wrong.
Cc: Richard Weinberger <richard@nod.at>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/mtd/ubi/build.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c
index 85d54f37e28f..00a46ff61528 100644
--- a/drivers/mtd/ubi/build.c
+++ b/drivers/mtd/ubi/build.c
@@ -1389,7 +1389,7 @@ static int __init bytes_str_to_int(const char *str)
* This function returns zero in case of success and a negative error code in
* case of error.
*/
-static int __init ubi_mtd_param_parse(const char *val, struct kernel_param *kp)
+static int ubi_mtd_param_parse(const char *val, struct kernel_param *kp)
{
int i, len;
struct mtd_dev_param *p;
--
2.11.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v1 1/1] UBI: Fix section mismatch
2017-01-09 18:10 [PATCH v1 1/1] UBI: Fix section mismatch Andy Shevchenko
@ 2017-01-09 19:34 ` Andy Shevchenko
2017-01-10 8:37 ` Boris Brezillon
0 siblings, 1 reply; 5+ messages in thread
From: Andy Shevchenko @ 2017-01-09 19:34 UTC (permalink / raw)
To: Artem Bityutskiy, Boris Brezillon, linux-mtd, Brian Norris
Cc: Richard Weinberger
On Mon, 2017-01-09 at 20:10 +0200, Andy Shevchenko wrote:
> WARNING: vmlinux.o(.text+0x1f2a80): Section mismatch in reference from
> the variable __param_ops_mtd to the function
> .init.text:ubi_mtd_param_parse()
> The function __param_ops_mtd() references
> the function __init ubi_mtd_param_parse().
> This is often because __param_ops_mtd lacks a __init
> annotation or the annotation of ubi_mtd_param_parse is wrong.
Please, discard this. It fixes one and add another.
>
> Cc: Richard Weinberger <richard@nod.at>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> ---
> drivers/mtd/ubi/build.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c
> index 85d54f37e28f..00a46ff61528 100644
> --- a/drivers/mtd/ubi/build.c
> +++ b/drivers/mtd/ubi/build.c
> @@ -1389,7 +1389,7 @@ static int __init bytes_str_to_int(const char
> *str)
> * This function returns zero in case of success and a negative error
> code in
> * case of error.
> */
> -static int __init ubi_mtd_param_parse(const char *val, struct
> kernel_param *kp)
> +static int ubi_mtd_param_parse(const char *val, struct kernel_param
> *kp)
> {
> int i, len;
> struct mtd_dev_param *p;
--
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v1 1/1] UBI: Fix section mismatch
2017-01-09 19:34 ` Andy Shevchenko
@ 2017-01-10 8:37 ` Boris Brezillon
2017-01-10 11:45 ` Andy Shevchenko
0 siblings, 1 reply; 5+ messages in thread
From: Boris Brezillon @ 2017-01-10 8:37 UTC (permalink / raw)
To: Andy Shevchenko
Cc: Artem Bityutskiy, linux-mtd, Brian Norris, Richard Weinberger
On Mon, 09 Jan 2017 21:34:26 +0200
Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote:
> On Mon, 2017-01-09 at 20:10 +0200, Andy Shevchenko wrote:
> > WARNING: vmlinux.o(.text+0x1f2a80): Section mismatch in reference from
> > the variable __param_ops_mtd to the function
> > .init.text:ubi_mtd_param_parse()
> > The function __param_ops_mtd() references
> > the function __init ubi_mtd_param_parse().
> > This is often because __param_ops_mtd lacks a __init
> > annotation or the annotation of ubi_mtd_param_parse is wrong.
>
> Please, discard this. It fixes one and add another.
Just remove the __initdata specifiers on mtd_devs and mtd_dev_param and
you should be fine.
>
> >
> > Cc: Richard Weinberger <richard@nod.at>
> > Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> > ---
> > drivers/mtd/ubi/build.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c
> > index 85d54f37e28f..00a46ff61528 100644
> > --- a/drivers/mtd/ubi/build.c
> > +++ b/drivers/mtd/ubi/build.c
> > @@ -1389,7 +1389,7 @@ static int __init bytes_str_to_int(const char
> > *str)
> > * This function returns zero in case of success and a negative error
> > code in
> > * case of error.
> > */
> > -static int __init ubi_mtd_param_parse(const char *val, struct
> > kernel_param *kp)
> > +static int ubi_mtd_param_parse(const char *val, struct kernel_param
> > *kp)
> > {
> > int i, len;
> > struct mtd_dev_param *p;
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v1 1/1] UBI: Fix section mismatch
2017-01-10 8:37 ` Boris Brezillon
@ 2017-01-10 11:45 ` Andy Shevchenko
2017-01-10 12:40 ` Boris Brezillon
0 siblings, 1 reply; 5+ messages in thread
From: Andy Shevchenko @ 2017-01-10 11:45 UTC (permalink / raw)
To: Boris Brezillon
Cc: Artem Bityutskiy, linux-mtd, Brian Norris, Richard Weinberger
On Tue, 2017-01-10 at 09:37 +0100, Boris Brezillon wrote:
> On Mon, 09 Jan 2017 21:34:26 +0200
> Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote:
>
> > On Mon, 2017-01-09 at 20:10 +0200, Andy Shevchenko wrote:
> > > WARNING: vmlinux.o(.text+0x1f2a80): Section mismatch in reference
> > > from
> > > the variable __param_ops_mtd to the function
> > > .init.text:ubi_mtd_param_parse()
> > > The function __param_ops_mtd() references
> > > the function __init ubi_mtd_param_parse().
> > > This is often because __param_ops_mtd lacks a __init
> > > annotation or the annotation of ubi_mtd_param_parse is wrong.
> >
> > Please, discard this. It fixes one and add another.
>
> Just remove the __initdata specifiers on mtd_devs and mtd_dev_param
> and
> you should be fine.
Yes, I already have this patch.
But I decided to talk to Artem and just talked.
We thought about comment to explain what is going on there and why
section mismatch is false positive, though a bit error prone (since you
have to keep in mind 0000 permissions).
So, one solution here is to unmark them and, what I would add, change
permissions to read-only.
If you are okay with this I will send series.
>
> >
> > >
> > > Cc: Richard Weinberger <richard@nod.at>
> > > Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> > > ---
> > > drivers/mtd/ubi/build.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c
> > > index 85d54f37e28f..00a46ff61528 100644
> > > --- a/drivers/mtd/ubi/build.c
> > > +++ b/drivers/mtd/ubi/build.c
> > > @@ -1389,7 +1389,7 @@ static int __init bytes_str_to_int(const
> > > char
> > > *str)
> > > * This function returns zero in case of success and a negative
> > > error
> > > code in
> > > * case of error.
> > > */
> > > -static int __init ubi_mtd_param_parse(const char *val, struct
> > > kernel_param *kp)
> > > +static int ubi_mtd_param_parse(const char *val, struct
> > > kernel_param
> > > *kp)
> > > {
> > > int i, len;
> > > struct mtd_dev_param *p;
>
>
--
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v1 1/1] UBI: Fix section mismatch
2017-01-10 11:45 ` Andy Shevchenko
@ 2017-01-10 12:40 ` Boris Brezillon
0 siblings, 0 replies; 5+ messages in thread
From: Boris Brezillon @ 2017-01-10 12:40 UTC (permalink / raw)
To: Andy Shevchenko
Cc: Artem Bityutskiy, linux-mtd, Brian Norris, Richard Weinberger
On Tue, 10 Jan 2017 13:45:11 +0200
Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote:
> On Tue, 2017-01-10 at 09:37 +0100, Boris Brezillon wrote:
> > On Mon, 09 Jan 2017 21:34:26 +0200
> > Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote:
> >
> > > On Mon, 2017-01-09 at 20:10 +0200, Andy Shevchenko wrote:
> > > > WARNING: vmlinux.o(.text+0x1f2a80): Section mismatch in reference
> > > > from
> > > > the variable __param_ops_mtd to the function
> > > > .init.text:ubi_mtd_param_parse()
> > > > The function __param_ops_mtd() references
> > > > the function __init ubi_mtd_param_parse().
> > > > This is often because __param_ops_mtd lacks a __init
> > > > annotation or the annotation of ubi_mtd_param_parse is wrong.
> > >
> > > Please, discard this. It fixes one and add another.
> >
> > Just remove the __initdata specifiers on mtd_devs and mtd_dev_param
> > and
> > you should be fine.
>
> Yes, I already have this patch.
>
> But I decided to talk to Artem and just talked.
>
> We thought about comment to explain what is going on there and why
> section mismatch is false positive, though a bit error prone (since you
> have to keep in mind 0000 permissions).
>
> So, one solution here is to unmark them and, what I would add, change
> permissions to read-only.
>
> If you are okay with this I will send series.
Sounds good.
>
> >
> > >
> > > >
> > > > Cc: Richard Weinberger <richard@nod.at>
> > > > Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> > > > ---
> > > > drivers/mtd/ubi/build.c | 2 +-
> > > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/drivers/mtd/ubi/build.c b/drivers/mtd/ubi/build.c
> > > > index 85d54f37e28f..00a46ff61528 100644
> > > > --- a/drivers/mtd/ubi/build.c
> > > > +++ b/drivers/mtd/ubi/build.c
> > > > @@ -1389,7 +1389,7 @@ static int __init bytes_str_to_int(const
> > > > char
> > > > *str)
> > > > * This function returns zero in case of success and a negative
> > > > error
> > > > code in
> > > > * case of error.
> > > > */
> > > > -static int __init ubi_mtd_param_parse(const char *val, struct
> > > > kernel_param *kp)
> > > > +static int ubi_mtd_param_parse(const char *val, struct
> > > > kernel_param
> > > > *kp)
> > > > {
> > > > int i, len;
> > > > struct mtd_dev_param *p;
> >
> >
>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2017-01-10 12:49 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-09 18:10 [PATCH v1 1/1] UBI: Fix section mismatch Andy Shevchenko
2017-01-09 19:34 ` Andy Shevchenko
2017-01-10 8:37 ` Boris Brezillon
2017-01-10 11:45 ` Andy Shevchenko
2017-01-10 12:40 ` Boris Brezillon
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.