From: Real Name <enjoymindful@gmail.com>
To: user-mode-linux-devel@lists.sourceforge.net
Cc: richard@nod.at, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] delete unnecessary bootmem struct page array
Date: Sun, 1 Jun 2014 08:12:45 +0800 [thread overview]
Message-ID: <20140601001245.GA6328@name> (raw)
In-Reply-To: <1401579282-17987-1-git-send-email-enjoymindful@gmail.com>
On Sun, Jun 01, 2014 at 07:34:42AM +0800, Real Name wrote:
I'm very sorry. Please ignore this email, the wrong patch had been sent
out.
> 1) uml kernel bootmem managed through bootmem_data->node_bootmem_map,
> not struct page array, so it is unnecessary.
>
> 2) the struct page array allocate has been pointer by a *loacl* pointer
> struct page *map in init_maps function. The array can't be access after
> the init_maps exit. As a result, there is about 1% of total memory leak.
> ---
> arch/um/kernel/um_arch.c | 5 -----
> 1 file changed, 5 deletions(-)
>
> diff --git a/arch/um/kernel/um_arch.c b/arch/um/kernel/um_arch.c
> index 016adf0..9f3c6d1 100644
> --- a/arch/um/kernel/um_arch.c
> +++ b/arch/um/kernel/um_arch.c
> @@ -309,11 +309,6 @@ int __init linux_main(int argc, char **argv)
> */
>
> diff = UML_ROUND_UP(brk_start) - UML_ROUND_UP(&_end);
> - if (diff > 1024 * 1024) {
> - printf("Adding %ld bytes to physical memory to account for "
> - "exec-shield gap\n", diff);
> - physmem_size += UML_ROUND_UP(brk_start) - UML_ROUND_UP(&_end);
> - }
>
> uml_physmem = (unsigned long) &__binary_start & PAGE_MASK;
>
> --
> 1.8.3.1
>
next prev parent reply other threads:[~2014-06-01 0:13 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-31 23:34 [PATCH] delete unnecessary bootmem struct page array Real Name
2014-06-01 0:12 ` Real Name [this message]
-- strict thread matches above, loose matches on Subject: below --
2014-06-01 0:24 Real Name
2014-06-01 7:54 ` Richard Weinberger
2014-06-01 13:08 Real Name
2014-06-01 13:08 ` Real Name
2014-06-01 13:57 ` Richard Weinberger
2014-06-03 5:30 [PATCH v2] " Real Name
2014-06-03 5:30 ` [PATCH] " Real Name
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=20140601001245.GA6328@name \
--to=enjoymindful@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=richard@nod.at \
--cc=user-mode-linux-devel@lists.sourceforge.net \
/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