Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-07-02 Thread Johannes Weiner
On Mon, Jun 30, 2014 at 03:48:39PM -0700, Hugh Dickins wrote: > Under shmem swapping and swapoff load, I sometimes hit the > VM_BUG_ON_PAGE(!page->mapping) in mem_cgroup_commit_charge() at > mm/memcontrol.c:6502! Each time it has been a call from shmem_unuse(). > > Yes, there are some cases

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-07-02 Thread Johannes Weiner
On Mon, Jun 30, 2014 at 03:48:39PM -0700, Hugh Dickins wrote: Under shmem swapping and swapoff load, I sometimes hit the VM_BUG_ON_PAGE(!page-mapping) in mem_cgroup_commit_charge() at mm/memcontrol.c:6502! Each time it has been a call from shmem_unuse(). Yes, there are some cases (most

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Hugh Dickins
On Mon, 30 Jun 2014, Andrew Morton wrote: > On Mon, 30 Jun 2014 17:10:54 -0700 (PDT) Hugh Dickins > wrote: > > On Mon, 30 Jun 2014, Andrew Morton wrote: > > > On Mon, 30 Jun 2014 15:48:39 -0700 (PDT) Hugh Dickins > > > wrote: > > > > - return 0; > > > > + return

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Andrew Morton
On Mon, 30 Jun 2014 17:10:54 -0700 (PDT) Hugh Dickins wrote: > On Mon, 30 Jun 2014, Andrew Morton wrote: > > On Mon, 30 Jun 2014 15:48:39 -0700 (PDT) Hugh Dickins > > wrote: > > > - return 0; > > > + return -EAGAIN; > > > > Maybe it's time to document the shmem_unuse_inode()

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Hugh Dickins
On Mon, 30 Jun 2014, Andrew Morton wrote: > On Mon, 30 Jun 2014 15:48:39 -0700 (PDT) Hugh Dickins > wrote: > > - return 0; > > + return -EAGAIN; > > Maybe it's time to document the shmem_unuse_inode() return values. Oh dear. I had hoped they would look after themselves.

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Andrew Morton
On Mon, 30 Jun 2014 15:48:39 -0700 (PDT) Hugh Dickins wrote: > Under shmem swapping and swapoff load, I sometimes hit the > VM_BUG_ON_PAGE(!page->mapping) in mem_cgroup_commit_charge() at > mm/memcontrol.c:6502! Each time it has been a call from shmem_unuse(). > > Yes, there are some cases

[PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Hugh Dickins
Under shmem swapping and swapoff load, I sometimes hit the VM_BUG_ON_PAGE(!page->mapping) in mem_cgroup_commit_charge() at mm/memcontrol.c:6502! Each time it has been a call from shmem_unuse(). Yes, there are some cases (most commonly when the page being unswapped is in a file being unlinked and

[PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Hugh Dickins
Under shmem swapping and swapoff load, I sometimes hit the VM_BUG_ON_PAGE(!page-mapping) in mem_cgroup_commit_charge() at mm/memcontrol.c:6502! Each time it has been a call from shmem_unuse(). Yes, there are some cases (most commonly when the page being unswapped is in a file being unlinked and

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Andrew Morton
On Mon, 30 Jun 2014 15:48:39 -0700 (PDT) Hugh Dickins hu...@google.com wrote: Under shmem swapping and swapoff load, I sometimes hit the VM_BUG_ON_PAGE(!page-mapping) in mem_cgroup_commit_charge() at mm/memcontrol.c:6502! Each time it has been a call from shmem_unuse(). Yes, there are some

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Hugh Dickins
On Mon, 30 Jun 2014, Andrew Morton wrote: On Mon, 30 Jun 2014 15:48:39 -0700 (PDT) Hugh Dickins hu...@google.com wrote: - return 0; + return -EAGAIN; Maybe it's time to document the shmem_unuse_inode() return values. Oh dear. I had hoped they would look after

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Andrew Morton
On Mon, 30 Jun 2014 17:10:54 -0700 (PDT) Hugh Dickins hu...@google.com wrote: On Mon, 30 Jun 2014, Andrew Morton wrote: On Mon, 30 Jun 2014 15:48:39 -0700 (PDT) Hugh Dickins hu...@google.com wrote: - return 0; + return -EAGAIN; Maybe it's time to document the

Re: [PATCH mmotm/next] mm: memcontrol: rewrite charge API: fix shmem_unuse

2014-06-30 Thread Hugh Dickins
On Mon, 30 Jun 2014, Andrew Morton wrote: On Mon, 30 Jun 2014 17:10:54 -0700 (PDT) Hugh Dickins hu...@google.com wrote: On Mon, 30 Jun 2014, Andrew Morton wrote: On Mon, 30 Jun 2014 15:48:39 -0700 (PDT) Hugh Dickins hu...@google.com wrote: - return 0; +