Re: [PATCH] sysfs: add necessary Null check in sysfs_do_create_link_sd

2013-12-02 Thread Rui Xiang
On 2013/12/3 10:47, Greg Kroah-Hartman wrote: > On Tue, Dec 03, 2013 at 09:38:47AM +0800, Rui Xiang wrote: >> While target_sd or sd are null, it won't need sysfs_put and >> should return -ENOENT directly. Here add null check for >> target_sd and sd. >> >> Signed-off-by: Rui Xiang >> --- >> fs/sys

Re: [PATCH] sysfs: add necessary Null check in sysfs_do_create_link_sd

2013-12-02 Thread Greg Kroah-Hartman
On Tue, Dec 03, 2013 at 09:38:47AM +0800, Rui Xiang wrote: > While target_sd or sd are null, it won't need sysfs_put and > should return -ENOENT directly. Here add null check for > target_sd and sd. > > Signed-off-by: Rui Xiang > --- > fs/sysfs/symlink.c | 6 -- > 1 file changed, 4 insertion

[PATCH] sysfs: add necessary Null check in sysfs_do_create_link_sd

2013-12-02 Thread Rui Xiang
While target_sd or sd are null, it won't need sysfs_put and should return -ENOENT directly. Here add null check for target_sd and sd. Signed-off-by: Rui Xiang --- fs/sysfs/symlink.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/fs/sysfs/symlink.c b/fs/sysfs/symlink.c