From: Stafford Horne <shorne@gmail.com>
To: Mike Rapoport <rppt@kernel.org>
Cc: Jonas Bonn <jonas@southpole.se>,
Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>,
Mike Rapoport <rppt@linux.ibm.com>,
openrisc@lists.librecores.org, linux-kernel@vger.kernel.org,
kernel test robot <lkp@intel.com>
Subject: Re: [PATCH 1/2] openrisc: mm/init.c: remove unused memblock_region variable in map_ram()
Date: Mon, 10 May 2021 06:17:13 +0900 [thread overview]
Message-ID: <YJhRWQEy2Cpd1sKy@antec> (raw)
In-Reply-To: <20210509091103.7985-2-rppt@kernel.org>
On Sun, May 09, 2021 at 12:11:02PM +0300, Mike Rapoport wrote:
> From: Mike Rapoport <rppt@linux.ibm.com>
>
> Kernel test robot reports:
>
> cppcheck possible warnings: (new ones prefixed by >>, may not real problems)
>
> >> arch/openrisc/mm/init.c:125:10: warning: Uninitialized variable: region [uninitvar]
> region->base, region->base + region->size);
> ^
>
> Replace usage of memblock_region fields with 'start' and 'end' variables
> that are initialized in for_each_mem_range() and remove the declaration of
> region.
>
> Fixes: b10d6bca8720 ("arch, drivers: replace for_each_membock() with for_each_mem_range()")
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Mike Rapoport <rppt@linux.ibm.com>
> ---
> arch/openrisc/mm/init.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/arch/openrisc/mm/init.c b/arch/openrisc/mm/init.c
> index bf9b2310fc93..f3fa02b8838a 100644
> --- a/arch/openrisc/mm/init.c
> +++ b/arch/openrisc/mm/init.c
> @@ -75,7 +75,6 @@ static void __init map_ram(void)
> /* These mark extents of read-only kernel pages...
> * ...from vmlinux.lds.S
> */
> - struct memblock_region *region;
>
> v = PAGE_OFFSET;
>
> @@ -121,7 +120,7 @@ static void __init map_ram(void)
> }
>
> printk(KERN_INFO "%s: Memory: 0x%x-0x%x\n", __func__,
> - region->base, region->base + region->size);
> + start, end);
> }
> }
Thanks I will queue this.
-Stafford
next prev parent reply other threads:[~2021-05-09 21:17 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-09 9:11 [PATCH 0/2] openrisc: mm/init.c: fix compilation warnings Mike Rapoport
2021-05-09 9:11 ` [PATCH 1/2] openrisc: mm/init.c: remove unused memblock_region variable in map_ram() Mike Rapoport
2021-05-09 21:17 ` Stafford Horne [this message]
2021-05-09 9:11 ` [PATCH 2/2] openrisc: mm/init.c: remove unused variable 'end' in paging_init() Mike Rapoport
2021-05-09 21:18 ` Stafford Horne
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=YJhRWQEy2Cpd1sKy@antec \
--to=shorne@gmail.com \
--cc=jonas@southpole.se \
--cc=linux-kernel@vger.kernel.org \
--cc=lkp@intel.com \
--cc=openrisc@lists.librecores.org \
--cc=rppt@kernel.org \
--cc=rppt@linux.ibm.com \
--cc=stefan.kristiansson@saunalahti.fi \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox