| #include <linux/kernel.h> |
| #include <linux/module.h> |
| #include <linux/export.h> |
| #include <linux/vmalloc.h> |
| #include <asm/bootinfo.h> |
| static int __init test_debug_virtual_init(void) |
| va = (void *)VMALLOC_START; |
| pr_info("PA: %pa for VA: 0x%lx\n", &pa, (unsigned long)va); |
| foo = kzalloc(sizeof(*foo), GFP_KERNEL); |
| pr_info("PA: %pa for VA: 0x%lx\n", &pa, (unsigned long)va); |
| module_init(test_debug_virtual_init); |
| static void __exit test_debug_virtual_exit(void) |
| module_exit(test_debug_virtual_exit); |
| MODULE_DESCRIPTION("Test module for CONFIG_DEBUG_VIRTUAL"); |