KABI reservation for tty/mtd/mmc/ipmi
Yi Yang (5): tty: kabi: KABI reservation for tty mtd: kabi: KABI reservation for mtd mmc: kabi: KABI reservation for mmc ipmi: kabi: KABI reservation for ipmi audit: kabi: Remove extra semicolons
drivers/char/ipmi/ipmi_msghandler.c | 7 +++++++ include/linux/ipmi.h | 3 +++ include/linux/ipmi_smi.h | 5 +++++ include/linux/mmc/card.h | 6 ++++++ include/linux/mmc/host.h | 8 ++++++++ include/linux/mtd/mtd.h | 11 +++++++++++ include/linux/mtd/partitions.h | 3 +++ include/linux/tty.h | 7 +++++++ include/linux/tty_buffer.h | 5 +++++ include/linux/tty_driver.h | 3 +++ include/linux/tty_ldisc.h | 3 +++ include/linux/tty_port.h | 3 +++ kernel/audit.h | 4 ++-- 13 files changed, 66 insertions(+), 2 deletions(-)
hulk inclusion category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I8T231
--------------------------------
Reserve space for tty module in advance to prepare for merging new feature in the future.
Signed-off-by: Yi Yang yiyang13@huawei.com --- include/linux/tty.h | 7 +++++++ include/linux/tty_buffer.h | 5 +++++ include/linux/tty_driver.h | 3 +++ include/linux/tty_ldisc.h | 3 +++ include/linux/tty_port.h | 3 +++ 5 files changed, 21 insertions(+)
diff --git a/include/linux/tty.h b/include/linux/tty.h index f002d0f25db7..daddeca8737e 100644 --- a/include/linux/tty.h +++ b/include/linux/tty.h @@ -15,6 +15,7 @@ #include <uapi/linux/tty.h> #include <linux/rwsem.h> #include <linux/llist.h> +#include <linux/kabi.h>
/* @@ -248,6 +249,12 @@ struct tty_struct {
#define N_TTY_BUF_SIZE 4096 struct work_struct SAK_work; + KABI_RESERVE(0) + KABI_RESERVE(1) + KABI_RESERVE(2) + KABI_RESERVE(3) + KABI_RESERVE(4) + KABI_RESERVE(5) } __randomize_layout;
/* Each of a tty's open files has private_data pointing to tty_file_private */ diff --git a/include/linux/tty_buffer.h b/include/linux/tty_buffer.h index 31125e3be3c5..82c6ad8bd59f 100644 --- a/include/linux/tty_buffer.h +++ b/include/linux/tty_buffer.h @@ -6,6 +6,7 @@ #include <linux/llist.h> #include <linux/mutex.h> #include <linux/workqueue.h> +#include <linux/kabi.h>
struct tty_buffer { union { @@ -18,6 +19,8 @@ struct tty_buffer { unsigned int lookahead; /* Lazy update on recv, can become less than "read" */ unsigned int read; bool flags; + KABI_RESERVE(0) + KABI_RESERVE(1) /* Data points here */ u8 data[] __aligned(sizeof(unsigned long)); }; @@ -42,6 +45,8 @@ struct tty_bufhead { atomic_t mem_used; /* In-use buffers excluding free list */ int mem_limit; struct tty_buffer *tail; /* Active buffer */ + KABI_RESERVE(0) + KABI_RESERVE(1) };
/* diff --git a/include/linux/tty_driver.h b/include/linux/tty_driver.h index 18beff0cec1a..e4883dcf1656 100644 --- a/include/linux/tty_driver.h +++ b/include/linux/tty_driver.h @@ -10,6 +10,7 @@ #include <linux/uaccess.h> #include <linux/termios.h> #include <linux/seq_file.h> +#include <linux/kabi.h>
struct tty_struct; struct tty_driver; @@ -391,6 +392,8 @@ struct tty_operations { void (*poll_put_char)(struct tty_driver *driver, int line, char ch); #endif int (*proc_show)(struct seq_file *m, void *driver); + KABI_RESERVE(0) + KABI_RESERVE(1) } __randomize_layout;
/** diff --git a/include/linux/tty_ldisc.h b/include/linux/tty_ldisc.h index af01e89074b2..89a41873372c 100644 --- a/include/linux/tty_ldisc.h +++ b/include/linux/tty_ldisc.h @@ -10,6 +10,7 @@ struct tty_struct; #include <linux/list.h> #include <linux/lockdep.h> #include <linux/seq_file.h> +#include <linux/kabi.h>
/* * the semaphore definition @@ -264,6 +265,8 @@ struct tty_ldisc_ops { const u8 *fp, size_t count);
struct module *owner; + KABI_RESERVE(0) + KABI_RESERVE(1) };
struct tty_ldisc { diff --git a/include/linux/tty_port.h b/include/linux/tty_port.h index 6b367eb17979..f30310a3b226 100644 --- a/include/linux/tty_port.h +++ b/include/linux/tty_port.h @@ -7,6 +7,7 @@ #include <linux/mutex.h> #include <linux/tty_buffer.h> #include <linux/wait.h> +#include <linux/kabi.h>
struct attribute_group; struct tty_driver; @@ -121,6 +122,8 @@ struct tty_port { int drain_delay; struct kref kref; void *client_data; + KABI_RESERVE(0) + KABI_RESERVE(1) };
/* tty_port::iflags bits -- use atomic bit ops */
hulk inclusion category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I8T231
--------------------------------
Reserve space for mtd module in advance to prepare for merging new feature in the future.
Signed-off-by: Yi Yang yiyang13@huawei.com --- include/linux/mtd/mtd.h | 11 +++++++++++ include/linux/mtd/partitions.h | 3 +++ 2 files changed, 14 insertions(+)
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h index 914a9f974baa..e6e56b19383e 100644 --- a/include/linux/mtd/mtd.h +++ b/include/linux/mtd/mtd.h @@ -13,6 +13,7 @@ #include <linux/device.h> #include <linux/of.h> #include <linux/nvmem-provider.h> +#include <linux/kabi.h>
#include <mtd/mtd-abi.h>
@@ -77,6 +78,8 @@ struct mtd_oob_ops { uint8_t *datbuf; uint8_t *oobbuf; struct mtd_req_stats *stats; + KABI_RESERVE(0) + KABI_RESERVE(1) };
/** @@ -215,6 +218,8 @@ struct mtd_part { u64 offset; u64 size; u32 flags; + KABI_RESERVE(0) + KABI_RESERVE(1) };
/** @@ -233,6 +238,8 @@ struct mtd_master { struct mutex partitions_lock; struct mutex chrdev_lock; unsigned int suspended : 1; + KABI_RESERVE(0) + KABI_RESERVE(1) };
struct mtd_info { @@ -398,6 +405,10 @@ struct mtd_info {
struct mtd_part part; struct mtd_master master; + KABI_RESERVE(0) + KABI_RESERVE(1) + KABI_RESERVE(2) + KABI_RESERVE(3) };
static inline struct mtd_info *mtd_get_master(struct mtd_info *mtd) diff --git a/include/linux/mtd/partitions.h b/include/linux/mtd/partitions.h index b74a539ec581..1723d7cc4921 100644 --- a/include/linux/mtd/partitions.h +++ b/include/linux/mtd/partitions.h @@ -10,6 +10,7 @@ #define MTD_PARTITIONS_H
#include <linux/types.h> +#include <linux/kabi.h>
/* @@ -51,6 +52,8 @@ struct mtd_partition { uint32_t mask_flags; /* master MTD flags to mask out for this partition */ uint32_t add_flags; /* flags to add to the partition */ struct device_node *of_node; + KABI_RESERVE(0) + KABI_RESERVE(1) };
#define MTDPART_OFS_RETAIN (-3)
hulk inclusion category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I8T231
--------------------------------
Reserve space for mmc module in advance to prepare for merging new feature in the future.
Signed-off-by: Yi Yang yiyang13@huawei.com --- include/linux/mmc/card.h | 6 ++++++ include/linux/mmc/host.h | 8 ++++++++ 2 files changed, 14 insertions(+)
diff --git a/include/linux/mmc/card.h b/include/linux/mmc/card.h index 7b12eebc5586..0fe6576eb81f 100644 --- a/include/linux/mmc/card.h +++ b/include/linux/mmc/card.h @@ -9,6 +9,7 @@
#include <linux/device.h> #include <linux/mod_devicetable.h> +#include <linux/kabi.h>
struct mmc_cid { unsigned int manfid; @@ -126,6 +127,8 @@ struct mmc_ext_csd { u8 device_life_time_est_typ_b; /* 269 */
unsigned int feature_support; + KABI_RESERVE(0) + KABI_RESERVE(1) #define MMC_DISCARD_FEATURE BIT(0) /* CMD38 feature */ };
@@ -341,6 +344,9 @@ struct mmc_card { unsigned int nr_parts;
struct workqueue_struct *complete_wq; /* Private workqueue */ + KABI_RESERVE(0) + KABI_RESERVE(1) + KABI_RESERVE(2) };
static inline bool mmc_large_sector(struct mmc_card *card) diff --git a/include/linux/mmc/host.h b/include/linux/mmc/host.h index 62a6847a3b6f..6e54e83cd918 100644 --- a/include/linux/mmc/host.h +++ b/include/linux/mmc/host.h @@ -16,6 +16,7 @@ #include <linux/mmc/pm.h> #include <linux/dma-direction.h> #include <linux/blk-crypto-profile.h> +#include <linux/kabi.h>
struct mmc_ios { unsigned int clock; /* clock rate */ @@ -78,6 +79,8 @@ struct mmc_ios { #define MMC_SET_DRIVER_TYPE_D 3
bool enhanced_strobe; /* hs400es selection */ + KABI_RESERVE(0) + KABI_RESERVE(1) };
struct mmc_clk_phase { @@ -218,6 +221,8 @@ struct mmc_host_ops {
/* Initialize an SD express card, mandatory for MMC_CAP2_SD_EXP. */ int (*init_sd_express)(struct mmc_host *host, struct mmc_ios *ios); + KABI_RESERVE(0) + KABI_RESERVE(1) };
struct mmc_cqe_ops { @@ -528,6 +533,9 @@ struct mmc_host { bool hsq_enabled;
u32 err_stats[MMC_ERR_MAX]; + KABI_RESERVE(0) + KABI_RESERVE(1) + KABI_RESERVE(2) unsigned long private[] ____cacheline_aligned; };
hulk inclusion category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I8T231
--------------------------------
Reserve space for ipmi module in advance to prepare for merging new feature in the future.
Signed-off-by: Yi Yang yiyang13@huawei.com --- drivers/char/ipmi/ipmi_msghandler.c | 7 +++++++ include/linux/ipmi.h | 3 +++ include/linux/ipmi_smi.h | 5 +++++ 3 files changed, 15 insertions(+)
diff --git a/drivers/char/ipmi/ipmi_msghandler.c b/drivers/char/ipmi/ipmi_msghandler.c index 186f1fee7534..780f32e6424d 100644 --- a/drivers/char/ipmi/ipmi_msghandler.c +++ b/drivers/char/ipmi/ipmi_msghandler.c @@ -36,6 +36,7 @@ #include <linux/nospec.h> #include <linux/vmalloc.h> #include <linux/delay.h> +#include <linux/kabi.h>
#define IPMI_DRIVER_VERSION "39.2"
@@ -203,6 +204,8 @@ struct ipmi_user {
/* Free must run in process context for RCU cleanup. */ struct work_struct remove_work; + KABI_RESERVE(0) + KABI_RESERVE(1) };
static struct workqueue_struct *remove_work_wq; @@ -603,6 +606,10 @@ struct ipmi_smi { * parameters passed by "low" level IPMI code. */ int run_to_completion; + KABI_RESERVE(0) + KABI_RESERVE(1) + KABI_RESERVE(2) + KABI_RESERVE(3) }; #define to_si_intf_from_dev(device) container_of(device, struct ipmi_smi, dev)
diff --git a/include/linux/ipmi.h b/include/linux/ipmi.h index a1c9c0d48ebf..3941aff8908c 100644 --- a/include/linux/ipmi.h +++ b/include/linux/ipmi.h @@ -19,6 +19,7 @@ #include <linux/list.h> #include <linux/proc_fs.h> #include <linux/acpi.h> /* For acpi_handle */ +#include <linux/kabi.h>
struct module; struct device; @@ -70,6 +71,8 @@ struct ipmi_recv_msg { * the size or existence of this, since it may change. */ unsigned char msg_data[IPMI_MAX_MSG_LENGTH]; + KABI_RESERVE(0) + KABI_RESERVE(1) };
#define INIT_IPMI_RECV_MSG(done_handler) \ diff --git a/include/linux/ipmi_smi.h b/include/linux/ipmi_smi.h index 5d69820d8b02..fec206901a00 100644 --- a/include/linux/ipmi_smi.h +++ b/include/linux/ipmi_smi.h @@ -19,6 +19,7 @@ #include <linux/proc_fs.h> #include <linux/platform_device.h> #include <linux/ipmi.h> +#include <linux/kabi.h>
struct device;
@@ -123,6 +124,8 @@ struct ipmi_smi_msg { * (presumably to free it). */ void (*done)(struct ipmi_smi_msg *msg); + KABI_RESERVE(0) + KABI_RESERVE(1) };
#define INIT_IPMI_SMI_MSG(done_handler) \ @@ -218,6 +221,8 @@ struct ipmi_smi_handlers { * block. */ void (*set_maintenance_mode)(void *send_info, bool enable); + KABI_RESERVE(0) + KABI_RESERVE(1) };
struct ipmi_device_id {
hulk inclusion category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I8WCAR
--------------------------------
Signed-off-by: Yi Yang yiyang13@huawei.com --- kernel/audit.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/kernel/audit.h b/kernel/audit.h index 81e241039fd6..457ca207e08a 100644 --- a/kernel/audit.h +++ b/kernel/audit.h @@ -209,8 +209,8 @@ struct audit_context { }; int fds[2]; struct audit_proctitle proctitle; - KABI_RESERVE(0); - KABI_RESERVE(1); + KABI_RESERVE(0) + KABI_RESERVE(1) };
extern bool audit_ever_enabled;
反馈: 您发送到kernel@openeuler.org的补丁/补丁集,已成功转换为PR! PR链接地址: https://gitee.com/openeuler/kernel/pulls/4373 邮件列表地址:https://mailweb.openeuler.org/hyperkitty/list/kernel@openeuler.org/message/N...
FeedBack: The patch(es) which you have sent to kernel@openeuler.org mailing list has been converted to a pull request successfully! Pull request link: https://gitee.com/openeuler/kernel/pulls/4373 Mailing list address: https://mailweb.openeuler.org/hyperkitty/list/kernel@openeuler.org/message/N...