Created
May 5, 2019 03:53
-
-
Save md-jamal/cf20f8eaf7da0abd248bc9a6be837bcb to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <linux/module.h> /* for MODULE_*. module_* */ | |
#include <linux/printk.h> /* for pr_* */ | |
#include <linux/cpumask.h> /* for num_online_cpus */ | |
static int __init mod_init(void) | |
{ | |
pr_info("number of online cpus is %d\n", num_online_cpus()); | |
return 0; | |
} | |
static void __exit mod_exit(void) | |
{ | |
} | |
module_init(mod_init); | |
module_exit(mod_exit); | |
MODULE_LICENSE("GPL"); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment