|
@@ -490,7 +490,7 @@ read_kcore(struct file *file, char __user *buffer, size_t buflen, loff_t *fpos)
|
|
}
|
|
}
|
|
read_unlock(&kclist_lock);
|
|
read_unlock(&kclist_lock);
|
|
|
|
|
|
- if (m == NULL) {
|
|
|
|
|
|
+ if (&m->list == &kclist_head) {
|
|
if (clear_user(buffer, tsz))
|
|
if (clear_user(buffer, tsz))
|
|
return -EFAULT;
|
|
return -EFAULT;
|
|
} else if (is_vmalloc_or_module_addr((void *)start)) {
|
|
} else if (is_vmalloc_or_module_addr((void *)start)) {
|