提交 1aa7ceab 编写于 作者: W Wang Hai 提交者: Zheng Zengkai

kabi: net: reserve space for net can subsystem related structure

hulk inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I4HE7P?from=project-issue
CVE: NA

--------

Reserve some fields beforehand for net can framework related structures prone
to change.

---------
Signed-off-by: NWang Hai <wanghai38@huawei.com>
Reviewed-by: NWei Yongjun <weiyongjun1@huawei.com>
Reviewed-by: NYue Haibing <yuehaibing@huawei.com>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
上级 f13098db
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
#include <linux/can.h> #include <linux/can.h>
#include <linux/skbuff.h> #include <linux/skbuff.h>
#include <linux/netdevice.h> #include <linux/netdevice.h>
#include <linux/kabi.h>
#define DNAME(dev) ((dev) ? (dev)->name : "any") #define DNAME(dev) ((dev) ? (dev)->name : "any")
...@@ -32,6 +33,9 @@ struct can_proto { ...@@ -32,6 +33,9 @@ struct can_proto {
int protocol; int protocol;
const struct proto_ops *ops; const struct proto_ops *ops;
struct proto *prot; struct proto *prot;
KABI_RESERVE(1)
KABI_RESERVE(2)
}; };
/* required_size /* required_size
......
...@@ -20,6 +20,7 @@ ...@@ -20,6 +20,7 @@
#include <linux/can/netlink.h> #include <linux/can/netlink.h>
#include <linux/can/skb.h> #include <linux/can/skb.h>
#include <linux/netdevice.h> #include <linux/netdevice.h>
#include <linux/kabi.h>
/* /*
* CAN mode * CAN mode
...@@ -80,6 +81,11 @@ struct can_priv { ...@@ -80,6 +81,11 @@ struct can_priv {
struct led_trigger *rxtx_led_trig; struct led_trigger *rxtx_led_trig;
char rxtx_led_trig_name[CAN_LED_NAME_SZ]; char rxtx_led_trig_name[CAN_LED_NAME_SZ];
#endif #endif
KABI_RESERVE(1)
KABI_RESERVE(2)
KABI_RESERVE(3)
KABI_RESERVE(4)
}; };
#define CAN_SYNC_SEG 1 #define CAN_SYNC_SEG 1
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
#include <linux/netdevice.h> #include <linux/netdevice.h>
#include <linux/can.h> #include <linux/can.h>
#include <linux/kabi.h>
struct can_rx_offload { struct can_rx_offload {
struct net_device *dev; struct net_device *dev;
...@@ -28,6 +29,9 @@ struct can_rx_offload { ...@@ -28,6 +29,9 @@ struct can_rx_offload {
struct napi_struct napi; struct napi_struct napi;
bool inc; bool inc;
KABI_RESERVE(1)
KABI_RESERVE(2)
}; };
int can_rx_offload_add_timestamp(struct net_device *dev, int can_rx_offload_add_timestamp(struct net_device *dev,
......
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
struct can_skb_priv { struct can_skb_priv {
int ifindex; int ifindex;
int skbcnt; int skbcnt;
struct can_frame cf[]; struct can_frame cf[];
}; };
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
#define __NETNS_CAN_H__ #define __NETNS_CAN_H__
#include <linux/spinlock.h> #include <linux/spinlock.h>
#include <linux/kabi.h>
struct can_dev_rcv_lists; struct can_dev_rcv_lists;
struct can_pkg_stats; struct can_pkg_stats;
...@@ -35,6 +36,8 @@ struct netns_can { ...@@ -35,6 +36,8 @@ struct netns_can {
/* CAN GW per-net gateway jobs */ /* CAN GW per-net gateway jobs */
struct hlist_head cgw_list; struct hlist_head cgw_list;
KABI_RESERVE(1)
}; };
#endif /* __NETNS_CAN_H__ */ #endif /* __NETNS_CAN_H__ */
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册