diff options
Diffstat (limited to 'fs/ecryptfs/netlink.c')
-rw-r--r-- | fs/ecryptfs/netlink.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/ecryptfs/netlink.c b/fs/ecryptfs/netlink.c index e3aa2253c850..fe9186312d7c 100644 --- a/fs/ecryptfs/netlink.c +++ b/fs/ecryptfs/netlink.c | |||
@@ -97,7 +97,7 @@ out: | |||
97 | */ | 97 | */ |
98 | static int ecryptfs_process_nl_response(struct sk_buff *skb) | 98 | static int ecryptfs_process_nl_response(struct sk_buff *skb) |
99 | { | 99 | { |
100 | struct nlmsghdr *nlh = (struct nlmsghdr*)skb->data; | 100 | struct nlmsghdr *nlh = nlmsg_hdr(skb); |
101 | struct ecryptfs_message *msg = NLMSG_DATA(nlh); | 101 | struct ecryptfs_message *msg = NLMSG_DATA(nlh); |
102 | int rc; | 102 | int rc; |
103 | 103 | ||
@@ -181,7 +181,7 @@ receive: | |||
181 | "rc = [%d]\n", rc); | 181 | "rc = [%d]\n", rc); |
182 | return; | 182 | return; |
183 | } | 183 | } |
184 | nlh = (struct nlmsghdr *)skb->data; | 184 | nlh = nlmsg_hdr(skb); |
185 | if (!NLMSG_OK(nlh, skb->len)) { | 185 | if (!NLMSG_OK(nlh, skb->len)) { |
186 | ecryptfs_printk(KERN_ERR, "Received corrupt netlink " | 186 | ecryptfs_printk(KERN_ERR, "Received corrupt netlink " |
187 | "message\n"); | 187 | "message\n"); |
@@ -229,7 +229,7 @@ int ecryptfs_init_netlink(void) | |||
229 | 229 | ||
230 | ecryptfs_nl_sock = netlink_kernel_create(NETLINK_ECRYPTFS, 0, | 230 | ecryptfs_nl_sock = netlink_kernel_create(NETLINK_ECRYPTFS, 0, |
231 | ecryptfs_receive_nl_message, | 231 | ecryptfs_receive_nl_message, |
232 | THIS_MODULE); | 232 | NULL, THIS_MODULE); |
233 | if (!ecryptfs_nl_sock) { | 233 | if (!ecryptfs_nl_sock) { |
234 | rc = -EIO; | 234 | rc = -EIO; |
235 | ecryptfs_printk(KERN_ERR, "Failed to create netlink socket\n"); | 235 | ecryptfs_printk(KERN_ERR, "Failed to create netlink socket\n"); |