Commit a62969d3 authored by Zheng Zengkai's avatar Zheng Zengkai
Browse files

KABI: Add KABI_AUX_PTR extenstions to some more base structures

hulk inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I4JBL0


CVE: NA

------------------------------

Add KABI_AUX_PTR extenstions to the following base structures
before KABI freeze:

struct device_driver
struct class
struct device
struct hrtimer
struct ipmi_smi_handlers
struct net_device

Signed-off-by: default avatarZheng Zengkai <zhengzengkai@huawei.com>
Reviewed-by: default avatarXie XiuQi <xiexiuqi@huawei.com>
Signed-off-by: default avatarZheng Zengkai <zhengzengkai@huawei.com>
parent e146a64e
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -370,6 +370,12 @@ struct dev_links_info {
	enum dl_dev_state status;
};

/**
 * struct device_extended_resvd - KABI extension struct
 */
struct device_extended_resvd {
};

/**
 * struct device - The basic device structure
 * @parent:	The device's "parent" device, the device to which it is attached.
@@ -560,7 +566,7 @@ struct device {
#ifdef CONFIG_DMA_OPS_BYPASS
	bool			dma_ops_bypass : 1;
#endif

	/* Use device_extended after all RESERVE fields used */
	KABI_RESERVE(1)
	KABI_RESERVE(2)
	KABI_RESERVE(3)
@@ -577,6 +583,7 @@ struct device {
	KABI_RESERVE(14)
	KABI_RESERVE(15)
	KABI_RESERVE(16)
	KABI_AUX_PTR(device_extended)
};

/**
+7 −0
Original line number Diff line number Diff line
@@ -24,6 +24,12 @@
struct device;
struct fwnode_handle;

/**
 * struct class_resvd - KABI extension struct
 */
struct class_resvd {
};

/**
 * struct class - device classes
 * @name:	Name of the class.
@@ -82,6 +88,7 @@ struct class {
	KABI_RESERVE(2)
	KABI_RESERVE(3)
	KABI_RESERVE(4)
	KABI_AUX_PTR(class)
};

struct class_dev_iter {
+7 −0
Original line number Diff line number Diff line
@@ -48,6 +48,12 @@ enum probe_type {
	PROBE_FORCE_SYNCHRONOUS,
};

/**
 * struct device_driver_resvd - KABI extension struct
 */
struct device_driver_resvd {
};

/**
 * struct device_driver - The basic device driver structure
 * @name:	Name of the device driver.
@@ -124,6 +130,7 @@ struct device_driver {
	KABI_RESERVE(2)
	KABI_RESERVE(3)
	KABI_RESERVE(4)
	KABI_AUX_PTR(device_driver)
};


+7 −0
Original line number Diff line number Diff line
@@ -95,6 +95,12 @@ enum hrtimer_restart {
#define HRTIMER_STATE_INACTIVE	0x00
#define HRTIMER_STATE_ENQUEUED	0x01

/**
 * struct hrtimer_resvd - KABI extension struct
 */
struct hrtimer_resvd {
};

/**
 * struct hrtimer - the basic hrtimer structure
 * @node:	timerqueue node, which also manages node.expires,
@@ -128,6 +134,7 @@ struct hrtimer {

	KABI_RESERVE(1)
	KABI_RESERVE(2)
	KABI_AUX_PTR(hrtimer)
};

/**
+10 −0
Original line number Diff line number Diff line
@@ -70,6 +70,15 @@ struct ipmi_smi_msg {
	void (*done)(struct ipmi_smi_msg *msg);
};

/**
 * struct ipmi_smi_handlers_resvd - KABI extension struct
 * This extension must be dynamically allocated for every instance of
 * ipmi_smi_handlers, because ipmi_smi_handlers is embedded in another
 * struct.
 */
struct ipmi_smi_handlers_resvd {
};

struct ipmi_smi_handlers {
	struct module *owner;

@@ -153,6 +162,7 @@ struct ipmi_smi_handlers {
	 * block.
	 */
	void (*set_maintenance_mode)(void *send_info, bool enable);
	KABI_AUX_PTR(ipmi_smi_handlers)
};

struct ipmi_device_id {
Loading