linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Laura Abbott <lauraa@codeaurora.org>
To: Minchan Kim <minchan@kernel.org>
Cc: Dave Hansen <dave@sr71.net>,
	Andrew Morton <akpm@linux-foundation.org>,
	Kyungmin Park <kmpark@infradead.org>,
	linux-mm@kvack.org, Russell King <linux@arm.linux.org.uk>,
	linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCHv3 00/11] Intermix Lowmem and vmalloc
Date: Mon, 06 Jan 2014 11:08:26 -0800	[thread overview]
Message-ID: <52CAFF2A.5060407@codeaurora.org> (raw)
In-Reply-To: <20140104073143.GA5594@gmail.com>

On 1/3/2014 11:31 PM, Minchan Kim wrote:
> Hello,
>
> On Fri, Jan 03, 2014 at 02:08:52PM -0800, Laura Abbott wrote:
>> On 1/3/2014 10:23 AM, Dave Hansen wrote:
>>> On 01/02/2014 01:53 PM, Laura Abbott wrote:
>>>> The goal here is to allow as much lowmem to be mapped as if the block of memory
>>>> was not reserved from the physical lowmem region. Previously, we had been
>>>> hacking up the direct virt <-> phys translation to ignore a large region of
>>>> memory. This did not scale for multiple holes of memory however.
>>>
>>> How much lowmem do these holes end up eating up in practice, ballpark?
>>> I'm curious how painful this is going to get.
>>>
>>
>> In total, the worst case can be close to 100M with an average case
>> around 70M-80M. The split and number of holes vary with the layout
>> but end up with 60M-80M one hole and the rest in the other.
>
> One more thing I'd like to know is how bad direct virt <->phys tranlsation
> in scale POV and how often virt<->phys tranlsation is called in your worload
> so what's the gain from this patch?
>
> Thanks.
>

With one hole we did

#define __phys_to_virt(phys)
	phys >= mem_hole_end ? mem_hole : normal

We had a single global variable to check for the bounds and to do 
something similar with multiple holes the worst case would be O(number 
of holes). This would also all need to be macroized. Detection and 
accounting for these holes in other data structures (e.g. ARM meminfo) 
would be increasingly complex and lead to delays in bootup. The 
error/sanity checking for bad memory configurations would also be 
messier. Non-linear lowmem mappings also make debugging more difficult.

virt <-> phys translation is used on hot paths in IOMMU mapping so we 
want to keep virt <-> phys as fast as possible and not have to walk an 
array of addresses every time.

Thanks,
Laura

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
hosted by The Linux Foundation

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2014-01-06 19:08 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-02 21:53 [RFC PATCHv3 00/11] Intermix Lowmem and vmalloc Laura Abbott
2014-01-02 21:53 ` [RFC PATCHv3 01/11] mce: acpi/apei: Use get_vm_area directly Laura Abbott
2014-01-03  2:33   ` Chen, Gong
2014-01-02 21:53 ` [RFC PATCHv3 02/11] iommu/omap: " Laura Abbott
2014-01-03  2:40   ` Chen, Gong
2014-01-02 21:53 ` [RFC PATCHv3 03/11] percpu: use VMALLOC_TOTAL instead of VMALLOC_END - VMALLOC_START Laura Abbott
2014-01-12  3:39   ` Tejun Heo
2014-01-02 21:53 ` [RFC PATCHv3 04/11] dm: Use VMALLOC_TOTAL instead of VMALLCO_END " Laura Abbott
2014-01-02 21:53 ` [RFC PATCHv3 05/11] staging: lustre: Use is_vmalloc_addr Laura Abbott
2014-01-02 21:53 ` [RFC PATCHv3 06/11] arm: use is_vmalloc_addr Laura Abbott
2014-01-02 22:13   ` Dave Hansen
2014-01-02 21:53 ` [RFC PATCHv3 07/11] arm: mm: Add iotable_init_novmreserve Laura Abbott
2014-01-02 21:53 ` [RFC PATCHv3 08/11] mm/vmalloc.c: Allow lowmem to be tracked in vmalloc Laura Abbott
2014-01-02 21:53 ` [RFC PATCHv3 09/11] arm: mm: Track lowmem " Laura Abbott
2014-01-02 21:53 ` [RFC PATCHv3 10/11] arm: Use for_each_potential_vmalloc_area Laura Abbott
2014-01-02 21:53 ` [RFC PATCHv3 11/11] fs/proc/kcore.c: " Laura Abbott
2014-01-03 18:23 ` [RFC PATCHv3 00/11] Intermix Lowmem and vmalloc Dave Hansen
2014-01-03 22:08   ` Laura Abbott
2014-01-04  7:31     ` Minchan Kim
2014-01-06 19:08       ` Laura Abbott [this message]
2014-01-08  2:52         ` Minchan Kim

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=52CAFF2A.5060407@codeaurora.org \
    --to=lauraa@codeaurora.org \
    --cc=akpm@linux-foundation.org \
    --cc=dave@sr71.net \
    --cc=kmpark@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux@arm.linux.org.uk \
    --cc=minchan@kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).