Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Hugh Dickins <hugh@xxxxxxxxxxx>
- Date: Mon, 4 Aug 2008 20:55:44 +0100 (BST)
On Mon, 4 Aug 2008, Keith Packard wrote:
On Mon, 2008-08-04 at 19:39 +0100, Hugh Dickins wrote:
For how long are these objects' pages pinned in memory like this?
Forever? The only reason an object would get unpinned would be on
eviction from the GTT, and objects will only be evicted if we fill the
aperture with other stuff. When we add a register_shrinker callback,
we'll also unpin pages at that point.
A busy system should have the GTT entirely full, and that will be
somewhere between 256MB and 1GB.
Okay, thanks for the warning. It sounds like the shrinker will be
important, but we'll also need to mark those pages as unevictable
while they're unshrunk. (Usually when drivers grab a large number
of pages, they're not on any LRU to begin with: you're being nice
by choosing swappable LRU pages - in the tmpfs case - but enough
to upset the balance while they're not swappable.) Offhand I can't
say what will be the appropriate way to do that, it's something we
need to revisit later (from your point of view it should amount to
one function call or flag set somewhere, not any grand redesign).
Hugh
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- Follow-Ups:
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: John Stoffel
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Keith Packard
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- References:
- [PATCH] PCI: Add pci_read_base() API
- From: Eric Anholt
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Nick Piggin
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Keith Packard
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Nick Piggin
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Keith Packard
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Hugh Dickins
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Keith Packard
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Hugh Dickins
- Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- From: Keith Packard
- [PATCH] PCI: Add pci_read_base() API
- Prev by Date: Re: [PATCH 1/7] Add mISDN driver
- Next by Date: Re: [rfc-patch, bugfix] x86-microcode
- Previous by thread: Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- Next by thread: Re: [PATCH] Export shmem_file_setup and shmem_getpage for DRM-GEM
- Index(es):