mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-24 02:35:58 +01:00
bak
This commit is contained in:
@@ -74,6 +74,7 @@ static int open(struct inode *inode, struct file *filp)
|
||||
|
||||
pr_info("open\n");
|
||||
info = kmalloc(sizeof(struct mmap_info), GFP_KERNEL);
|
||||
pr_info("virt_to_phys = 0x%llx\n", (unsigned long long)virt_to_phys((void *)info->data));
|
||||
info->data = (char *)get_zeroed_page(GFP_KERNEL);
|
||||
memcpy(info->data, "asdf", BUFFER_SIZE);
|
||||
filp->private_data = info;
|
||||
|
||||
Reference in New Issue
Block a user