History

memremap: replace the altmap_valid field with a PGMAP_ALTMAP_VALID flag

Add a flags field to struct dev_pagemap to replace the altmap_valid boolean to be a little more extensible. Also add a pgmap_altmap() helper to find the optional altmap and clean up the code using the altmap using it.

Christoph Hellwig committed 7 years ago

Commit 514caf21 parent 80a72d09 files · +29 −43Browse files

Showing the changes to mm/memory_hotplug.c (1 of 9 files). Show all

Unified · Split

mm/memory_hotplug.c+2−4
@@ -557,10 +557,8 @@ void __remove_pages(struct zone *zone, unsigned long phys_start_pfn, · 556 unmodified lines
557557 int sections_to_remove;
558558
559559 /* In the ZONE_DEVICE case device driver owns the memory region */
560− if (is_dev_zone(zone)) {
561− if (altmap)
562− map_offset = vmem_altmap_offset(altmap);
563− }
560+ if (is_dev_zone(zone))
561+ map_offset = vmem_altmap_offset(altmap);
564562
565563 clear_zone_contiguous(zone);
566564

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t