kernel: bump kernel 4.4 to 4.4.129 for 17.01
[openwrt/openwrt.git] / target / linux / generic / patches-4.4 / 506-yaffs2-using-new-follow_link-and-put_link.patch
1 From d4eb3ab036f8c37c5bc5f45ad0fa4dc34b7228c8 Mon Sep 17 00:00:00 2001
2 From: Kevin Hao <kexin.hao@windriver.com>
3 Date: Wed, 24 Feb 2016 14:37:13 +0800
4 Subject: [PATCH 3/3] yaffs2: using new ->follow_link() and ->put_link()
5 calling conventions
6
7 As what we did in commit 680baacbca69 ("new ->follow_link() and
8 ->put_link() calling conventions").
9
10 Signed-off-by: Kevin Hao <kexin.hao@windriver.com>
11 Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
12 ---
13 fs/yaffs2/yaffs_vfs.c | 8 ++++----
14 1 file changed, 4 insertions(+), 4 deletions(-)
15
16 --- a/fs/yaffs2/yaffs_vfs.c
17 +++ b/fs/yaffs2/yaffs_vfs.c
18 @@ -1060,7 +1060,7 @@ static int yaffs_readlink(struct dentry
19 }
20
21 #if (YAFFS_NEW_FOLLOW_LINK == 1)
22 -static void *yaffs_follow_link(struct dentry *dentry, struct nameidata *nd)
23 +static const char *yaffs_follow_link(struct dentry *dentry, void **cookie)
24 {
25 void *ret;
26 #else
27 @@ -1082,7 +1082,7 @@ static int yaffs_follow_link(struct dent
28 goto out;
29 }
30 #if (YAFFS_NEW_FOLLOW_LINK == 1)
31 - nd_set_link(nd, alias);
32 + *cookie = alias;
33 ret = alias;
34 out:
35 if (ret_int)
36 @@ -1114,9 +1114,9 @@ static void yaffs_put_inode(struct inode
37 #endif
38
39 #if (YAFFS_NEW_FOLLOW_LINK == 1)
40 -void yaffs_put_link(struct dentry *dentry, struct nameidata *nd, void *alias)
41 +void yaffs_put_link(struct inode *inode, void *cookie)
42 {
43 - kfree(alias);
44 + kfree(cookie);
45 }
46 #endif
47