lkml.org 
[lkml]   [2021]   [Sep]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v1 8/8] virtio-mem: kdump mode to sanitize /proc/vmcore access
From
Date
[...]

> +
> +static bool virtio_mem_vmcore_pfn_is_ram(struct vmcore_cb *cb,
> + unsigned long pfn)
> +{
> + struct virtio_mem *vm = container_of(cb, struct virtio_mem,
> + vmcore_cb);
> + uint64_t addr = PFN_PHYS(pfn);
> + bool is_ram;
> + int rc;
> +
> + if (!virtio_mem_contains_range(vm, addr, addr + PAGE_SIZE))

Some more testing revealed that this has to be

if (!virtio_mem_contains_range(vm, addr, PAGE_SIZE))


--
Thanks,

David / dhildenb

\
 
 \ /
  Last update: 2021-09-29 10:38    [W:0.836 / U:1.112 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site