From: Hanjun Guo <guohanjun@huawei.com>
To: Kefeng Wang <wangkefeng.wang@huawei.com>,
Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>,
Sudeep Holla <sudeep.holla@arm.com>, <linux-acpi@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>
Cc: Hulk Robot <hulkci@huawei.com>
Subject: Re: [PATCH -next] arm64: gtdt: Fix section mismatch in next_platform_timer()
Date: Sat, 9 May 2020 09:18:07 +0800 [thread overview]
Message-ID: <e2328035-9caa-590c-b80a-b11860010020@huawei.com> (raw)
In-Reply-To: <20200508152653.157663-1-wangkefeng.wang@huawei.com>
On 2020/5/8 23:26, Kefeng Wang wrote:
> Drop the __initdata for acpi_gtdt_desc variable to fix the section mismatch,
>
> WARNING: modpost: vmlinux.o(.text.unlikely+0x95ac): Section mismatch in reference from the function next_platform_timer() to the variable .init.data:acpi_gtdt_desc
> The function next_platform_timer() references
> the variable __initdata acpi_gtdt_desc.
> This is often because next_platform_timer lacks a __initdata
> annotation or the annotation of acpi_gtdt_desc is wrong.
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
> ---
> drivers/acpi/arm64/gtdt.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/acpi/arm64/gtdt.c b/drivers/acpi/arm64/gtdt.c
> index 01962c63a711..6a327616a299 100644
> --- a/drivers/acpi/arm64/gtdt.c
> +++ b/drivers/acpi/arm64/gtdt.c
> @@ -34,7 +34,7 @@ struct acpi_gtdt_descriptor {
> void *platform_timer;
> };
>
> -static struct acpi_gtdt_descriptor acpi_gtdt_desc __initdata;
> +static struct acpi_gtdt_descriptor acpi_gtdt_desc;
>
> static inline void *next_platform_timer(void *platform_timer)
I prefer to make this function as no inline, and make it
as __init function, becasue acpi_gtdt_desc is not used after
gtdt_sbsa_gwdt_init().
Thanks
Hanjun
WARNING: multiple messages have this Message-ID (diff)
From: Hanjun Guo <guohanjun@huawei.com>
To: Kefeng Wang <wangkefeng.wang@huawei.com>,
Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>,
Sudeep Holla <sudeep.holla@arm.com>, <linux-acpi@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>
Cc: Hulk Robot <hulkci@huawei.com>
Subject: Re: [PATCH -next] arm64: gtdt: Fix section mismatch in next_platform_timer()
Date: Sat, 9 May 2020 09:18:07 +0800 [thread overview]
Message-ID: <e2328035-9caa-590c-b80a-b11860010020@huawei.com> (raw)
In-Reply-To: <20200508152653.157663-1-wangkefeng.wang@huawei.com>
On 2020/5/8 23:26, Kefeng Wang wrote:
> Drop the __initdata for acpi_gtdt_desc variable to fix the section mismatch,
>
> WARNING: modpost: vmlinux.o(.text.unlikely+0x95ac): Section mismatch in reference from the function next_platform_timer() to the variable .init.data:acpi_gtdt_desc
> The function next_platform_timer() references
> the variable __initdata acpi_gtdt_desc.
> This is often because next_platform_timer lacks a __initdata
> annotation or the annotation of acpi_gtdt_desc is wrong.
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
> ---
> drivers/acpi/arm64/gtdt.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/acpi/arm64/gtdt.c b/drivers/acpi/arm64/gtdt.c
> index 01962c63a711..6a327616a299 100644
> --- a/drivers/acpi/arm64/gtdt.c
> +++ b/drivers/acpi/arm64/gtdt.c
> @@ -34,7 +34,7 @@ struct acpi_gtdt_descriptor {
> void *platform_timer;
> };
>
> -static struct acpi_gtdt_descriptor acpi_gtdt_desc __initdata;
> +static struct acpi_gtdt_descriptor acpi_gtdt_desc;
>
> static inline void *next_platform_timer(void *platform_timer)
I prefer to make this function as no inline, and make it
as __init function, becasue acpi_gtdt_desc is not used after
gtdt_sbsa_gwdt_init().
Thanks
Hanjun
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2020-05-09 1:18 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-08 15:26 [PATCH -next] arm64: gtdt: Fix section mismatch in next_platform_timer() Kefeng Wang
2020-05-08 15:26 ` Kefeng Wang
2020-05-09 1:18 ` Hanjun Guo [this message]
2020-05-09 1:18 ` Hanjun Guo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e2328035-9caa-590c-b80a-b11860010020@huawei.com \
--to=guohanjun@huawei.com \
--cc=hulkci@huawei.com \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=lorenzo.pieralisi@arm.com \
--cc=sudeep.holla@arm.com \
--cc=wangkefeng.wang@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.