lkml.org 
[lkml]   [2011]   [Sep]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
Subject[RFC]fs/ramfs/inode.c
From
Hi all,
When i read ramfs's inode file fs/ramfs/inode.c. I just see the following codes
and get some confusions.

[......]
static void ramfs_kill_sb(struct super_block *sb)
{
kfree(sb->s_fs_info);
kill_litter_super(sb);
}
[.....]

If we can really free the sb->s_fs_info successfully everytime? Ok, you may say
kfree returns no value. But how we can guarantee it can be freed
right. And The same
problem with the function kill_litter_super(sb). We also have some
other functions, which
i have the same confusions. I have searched the relevant codes about
kfree() with the tool
ctags and cscope, but i get so many relevant codes. I can not
distinguish which is the right
one. I think if we can not let the os stop, we just printk the
relevant error logs and make os
run as usual.


Thanks
Harry Wei


\
 
 \ /
  Last update: 2011-09-30 17:05    [W:0.019 / U:0.796 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site