mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-10 12:57:06 +09:00
ANDROID: GKI: mm: add Android ABI padding to some structures
Try to mitigate potential future driver core api changes by adding a padding to stuct vm_area_struct and struct zone. Based on a patch from Michal Marek <mmarek@suse.cz> from the SLES kernel Bug: 151154716 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com> Change-Id: I81702aa833f419928e0e32e9609722b98592c171
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
#include <linux/uprobes.h>
|
||||
#include <linux/page-flags-layout.h>
|
||||
#include <linux/workqueue.h>
|
||||
#include <linux/android_kabi.h>
|
||||
|
||||
#include <asm/mmu.h>
|
||||
|
||||
@@ -335,6 +336,11 @@ struct vm_area_struct {
|
||||
struct mempolicy *vm_policy; /* NUMA policy for the VMA */
|
||||
#endif
|
||||
struct vm_userfaultfd_ctx vm_userfaultfd_ctx;
|
||||
|
||||
ANDROID_KABI_RESERVE(1);
|
||||
ANDROID_KABI_RESERVE(2);
|
||||
ANDROID_KABI_RESERVE(3);
|
||||
ANDROID_KABI_RESERVE(4);
|
||||
} __randomize_layout;
|
||||
|
||||
struct core_thread {
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include <linux/pageblock-flags.h>
|
||||
#include <linux/page-flags-layout.h>
|
||||
#include <linux/atomic.h>
|
||||
#include <linux/android_kabi.h>
|
||||
#include <asm/page.h>
|
||||
|
||||
/* Free memory management - zoned buddy allocator. */
|
||||
@@ -519,6 +520,11 @@ struct zone {
|
||||
/* Zone statistics */
|
||||
atomic_long_t vm_stat[NR_VM_ZONE_STAT_ITEMS];
|
||||
atomic_long_t vm_numa_stat[NR_VM_NUMA_STAT_ITEMS];
|
||||
|
||||
ANDROID_KABI_RESERVE(1);
|
||||
ANDROID_KABI_RESERVE(2);
|
||||
ANDROID_KABI_RESERVE(3);
|
||||
ANDROID_KABI_RESERVE(4);
|
||||
} ____cacheline_internodealigned_in_smp;
|
||||
|
||||
enum pgdat_flags {
|
||||
|
||||
Reference in New Issue
Block a user