Re: [patch 8/9] Guest page hinting: discarded page list.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2006-09-01 at 08:17 -0700, Dave Hansen wrote:
> > +#if defined(CONFIG_PAGE_DISCARD_LIST)
> > +       if (page_host_discards() && unlikely(PageDiscarded(page))) {
> > +               local_irq_disable();
> > +               list_add_tail(&page->lru,
> > +                             &__get_cpu_var(page_discard_list));
> > +               local_irq_enable();
> > +               return;
> > +       }
> > +#endif 
> 
> If PageDiscarded() was #ifdef'd in the header, you wouldn't need this in
> the .c file.

No, unfortunately not. There is a new variable page_discard_list that is
only defined if CONFG_PAGE_DISCARD_LIST is set. The compiler will
complain about the absence of the variable, even if the code is never
reached because PageDiscarded always returns 0.

-- 
blue skies,
  Martin.

Martin Schwidefsky
Linux for zSeries Development & Services
IBM Deutschland Entwicklung GmbH

"Reality continues to ruin my life." - Calvin.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux