[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1299769165.8937.2435.camel@nimitz>
Date: Thu, 10 Mar 2011 06:59:25 -0800
From: Dave Hansen <dave@...ux.vnet.ibm.com>
To: Daniel Kiper <dkiper@...-space.pl>
Cc: ian.campbell@...rix.com, akpm@...ux-foundation.org,
andi.kleen@...el.com, haicheng.li@...ux.intel.com,
fengguang.wu@...el.com, jeremy@...p.org, konrad.wilk@...cle.com,
dan.magenheimer@...cle.com, v.tolstov@...fip.ru, pasik@....fi,
wdauchy@...il.com, rientjes@...gle.com,
xen-devel@...ts.xensource.com, linux-kernel@...r.kernel.org,
linux-mm@...ck.org
Subject: Re: [PATCH R4 7/7] xen/balloon: Memory hotplug support for Xen
balloon driver
On Thu, 2011-03-10 at 10:02 +0100, Daniel Kiper wrote:
> On Tue, Mar 08, 2011 at 04:02:19PM -0800, Dave Hansen wrote:
> > > + mutex_lock(&balloon_mutex);
> > > +
> > > + __balloon_append(page);
> > > +
> > > + if (balloon_stats.hotplug_pages)
> > > + --balloon_stats.hotplug_pages;
> > > + else
> > > + --balloon_stats.balloon_hotplug;
> > > +
> > > + mutex_unlock(&balloon_mutex);
> > > +
> > > + return NOTIFY_STOP;
> > > +}
> >
> > I'm not a _huge_ fan of these notifier chains, but I guess it works.
>
> Could you tell me why ??? I think that in that case new
> (faster, simpler, etc.) mechanism is an overkill. I prefer
> to use something which is writen, tested and ready for usage.
Personally, I find it much harder to figure out what's going on there
than if we had some #ifdefs or plain old function calls.
It would be one thing if we really had a large or undefined set of
things that needs to interact here, but we really just need to
conditionally free the page either in to the buddy allocator or back to
Xen. I think that calls for a simpler mechanism than notifier_blocks.
-- Dave
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists