History

Merge tag 's390-5.9-1' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux

Pull s390 updates from Heiko Carstens: - Add support for function error injection. - Add support for custom exception handlers, as required by BPF_PROBE_MEM. - Add support for BPF_PROBE_MEM. - Add trace events for idle enter / exit for the s390 specific idle implementation. - Remove unused zcore memmmap device. - Remove unused "raw view" from s390 debug feature. - AP bus + zcrypt device driver code refactoring. - Provide cex4 cca sysfs attributes for cex3 for zcrypt device driver. - Expose only minimal interface to walk physmem for mm/memblock. This is a common code change and it has been agreed on with Mike Rapoport and Andrew Morton that this can go upstream via the s390 tree. - Rework of the s390 vmem/vmmemap code to allow for future memory hot remove. - Get rid of FORCE_MAX_ZONEORDER to finally allow for order-10 allocations again, instead of only order-8 allocations. - Various small improvements and fixes. * tag 's390-5.9-1' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: (48 commits) s390/vmemmap: coding style updates s390/vmemmap: avoid memset(PAGE_UNUSED) when adding consecutive sections s390/vmemmap: remember unused sub-pmd ranges s390/vmemmap: fallback to PTEs if mapping large PMD fails s390/vmem: cleanup empty page tables s390/vmemmap: take the vmem_mutex when populating/freeing s390/vmemmap: cleanup when vmemmap_populate() fails s390/vmemmap: extend modify_pagetable() to handle vmemmap s390/vmem: consolidate vmem_add_range() and vmem_remove_range() s390/vmem: rename vmem_add_mem() to vmem_add_range() s390: enable HAVE_FUNCTION_ERROR_INJECTION s390/pci: clarify comment in s390_mmio_read/write s390/time: improve comparison for tod steering s390/time: select CLOCKSOURCE_VALIDATE_LAST_CYCLE s390/time: use CLOCKSOURCE_MASK s390/bpf: implement BPF_PROBE_MEM s390/kernel: expand exception table logic to allow new handling options s390/kernel: unify EX_TABLE* implementations s390/mm: allow order 10 allocations s390/mm: avoid trimming to MAX_ORDER ...

Linus Torvalds committed 6 years ago

Commit 45365a02 parents cdc8fcb 9a996c655 files · +1595 −1259Browse files

Showing the changes to include/linux (1 of 55 files). Show all

Unified · Split

include/linux/memblock.h+24−4
@@ -77,16 +77,12 @@ struct memblock_type { · 76 unmodified lines
7777 * @current_limit: physical address of the current allocation limit
7878 * @memory: usable memory regions
7979 * @reserved: reserved memory regions
80− * @physmem: all physical memory
8180 */
8281 struct memblock {
8382 bool bottom_up; /* is bottom up direction? */
8483 phys_addr_t current_limit;
8584 struct memblock_type memory;
8685 struct memblock_type reserved;
87−#ifdef CONFIG_HAVE_MEMBLOCK_PHYS_MAP
88− struct memblock_type physmem;
89−#endif
9086 };
9187
9288 extern struct memblock memblock;
@@ -145,6 +141,30 @@ void __next_reserved_mem_region(u64 *idx, phys_addr_t *out_start, · 52 unmodified lines
145141
146142 void __memblock_free_late(phys_addr_t base, phys_addr_t size);
147143
144+#ifdef CONFIG_HAVE_MEMBLOCK_PHYS_MAP
145+static inline void __next_physmem_range(u64 *idx, struct memblock_type *type,
146+ phys_addr_t *out_start,
147+ phys_addr_t *out_end)
148+{
149+ extern struct memblock_type physmem;
150+
151+ __next_mem_range(idx, NUMA_NO_NODE, MEMBLOCK_NONE, &physmem, type,
152+ out_start, out_end, NULL);
153+}
154+
155+/**
156+ * for_each_physmem_range - iterate through physmem areas not included in type.
157+ * @i: u64 used as loop variable
158+ * @type: ptr to memblock_type which excludes from the iteration, can be %NULL
159+ * @p_start: ptr to phys_addr_t for start address of the range, can be %NULL
160+ * @p_end: ptr to phys_addr_t for end address of the range, can be %NULL
161+ */
162+#define for_each_physmem_range(i, type, p_start, p_end) \
163+ for (i = 0, __next_physmem_range(&i, type, p_start, p_end); \
164+ i != (u64)ULLONG_MAX; \
165+ __next_physmem_range(&i, type, p_start, p_end))
166+#endif /* CONFIG_HAVE_MEMBLOCK_PHYS_MAP */
167+
148168 /**
149169 * for_each_mem_range - iterate through memblock areas from type_a and not
150170 * included in type_b. Or just type_a if type_b is NULL.

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