>> On Wed, Oct 22 2014, Pintu Kumar wrote: >>> diff --git a/mm/page_alloc.c b/mm/page_alloc.c >>> index dd73f9a..ababbd8 100644 >>> --- a/mm/page_alloc.c >>> +++ b/mm/page_alloc.c >>> @@ -110,6 +110,7 @@ static DEFINE_SPINLOCK(managed_page_count_lock); >>> >>> unsigned long totalram_pages __read_mostly; >>> unsigned long totalreserve_pages __read_mostly; >>> +unsigned long totalcma_pages __read_mostly; >> >> Move this to cma.c. On Fri, Oct 24 2014, PINTU KUMAR <pintu.k@xxxxxxxxxxx> wrote: > In our earlier patch (first version), we added it in cmc.c itself. > But, Andrew wanted this variable to be visible in non-CMA case as well to avoid build error, when we use > this variable in mem_init_print_info, without CONFIG_CMA. > So, we moved it to page_alloc.c If you add +#ifdef CONFIG_CMA +extern unsigned long totalcma_pages; +#else +# define totalcma_pages 0UL +#endif to linux/cma.h the variable will get replaced with a constant zero if !CONFIG_CMA. -- Best regards, _ _ .o. | Liege of Serenely Enlightened Majesty of o' \,=./ `o ..o | Computer Science, Michał “mina86” Nazarewicz (o o) ooo +--<mpn@xxxxxxxxxx>--<xmpp:mina86@xxxxxxxxxx>--ooO--(_)--Ooo-- -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href