lkml.org 
[lkml]   [2011]   [Apr]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 08/12] netvm: Allow skb allocation to use PFMEMALLOC reserves
On Thu, Apr 14, 2011 at 02:33:35PM -0700, David Miller wrote:
> From: Mel Gorman <mgorman@suse.de>
> Date: Thu, 14 Apr 2011 11:41:34 +0100
>
> > +extern int memalloc_socks;
> > +static inline int sk_memalloc_socks(void)
> > +{
> > + return memalloc_socks;
> > +}
> > +
> ...
> > +static DEFINE_MUTEX(memalloc_socks_lock);
> > +int memalloc_socks __read_mostly;
>
> Please use an atomic_t, it has to be more efficient than this mutex
> business.

Will fix.

Thanks.

--
Mel Gorman
SUSE Labs


\
 
 \ /
  Last update: 2011-04-15 12:47    [W:0.111 / U:0.200 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site