Patches for -next
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest0 of 4 patches 0 repliesNew
Patches in v1 No applies recorded yet
None of the 4 patches the cover letter announces are in this archive.
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 0/4] Patches for -next
Review
Quoted 5 lines · Catalin Marinas
(quoted diff) +5
-0+#ifdef CONFIG_SMP +void __sync_icache_dcache(pte_t pteval) +{ + struct page *page = pte_page(pteval); + struct address_space *mapping = page_mapping(page);
Err. no. You're assuming that the physical page associated with the PTE always has a struct page. What if it's a device mapping? What if it's a mapping for some memory which isn't being handled by the kernel?
You want this to be:
unsigned long pfn = pte_pfn(pteval);
if (pfn_valid(pfn)) {
struct page *page = pfn_to_page(pfn);
struct address_space *mapping = page_mapping(page);