Commit 64c23c60 authored by Luotao Fu's avatar Luotao Fu

rename set_link and switch to static. remove internally used structs from header

Signed-off-by: 's avatarLuotao Fu <l.fu@pengutronix.de>
parent 529838a5
......@@ -14,30 +14,9 @@
#define GET_RESTART_MS 2
#define GET_BITTIMING 3
struct get_req {
struct nlmsghdr n;
struct rtgenmsg g;
};
struct set_req {
struct nlmsghdr n;
struct ifinfomsg i;
char buf[1024];
};
struct req_info {
__u8 restart;
__u8 disable_autorestart;
__u32 restart_ms;
__u32 bitrate;
__u32 ctrlmode;
__u32 flags;
};
int if_down(int fd, const char *name);
int if_up(int fd, const char *name);
int set_link_can(const char *name, struct req_info *req_info);
int set_restart(const char *name);
int set_bitrate(const char *name, __u32 bitrate);
int set_restart_ms(const char *name, __u32 restart_ms);
......
......@@ -18,6 +18,25 @@
#define NLMSG_TAIL(nmsg) \
((struct rtattr *) (((void *) (nmsg)) + NLMSG_ALIGN((nmsg)->nlmsg_len)))
struct get_req {
struct nlmsghdr n;
struct rtgenmsg g;
};
struct set_req {
struct nlmsghdr n;
struct ifinfomsg i;
char buf[1024];
};
struct req_info {
__u8 restart;
__u8 disable_autorestart;
__u32 restart_ms;
__u32 bitrate;
__u32 ctrlmode;
__u32 flags;
};
static void
parse_rtattr(struct rtattr **tb, int max, struct rtattr *rta, int len)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment