There is function memblock_phys_mem_size at linux/memblock.h header, but it doesn't exported from kernel so it can't be used in module.
Is there another way to identify RAM size?
Use the following symbols:
$ grep EXPORT_SYMBOL mm/*.c | grep total
mm/highmem.c:EXPORT_SYMBOL(totalhigh_pages);
mm/page_alloc.c:EXPORT_SYMBOL(totalram_pages);
__initin addition so event if you try to use it you can't - Ilya Matveychikov 2012-04-04 12:49