diff options
author | Artem B. Bityuckiy <dedekind@infradead.org> | 2005-03-01 10:50:52 (GMT) |
---|---|---|
committer | Thomas Gleixner <tglx@mtd.linutronix.de> | 2005-05-23 10:48:15 (GMT) |
commit | 32f1a95d505b99b1f01b6aeea36ec3f97245b357 (patch) | |
tree | 5da0e8b01362cf6b0cc79f11e5e9b3fd4ad169d6 /fs/jffs2/read.c | |
parent | 20a6c211903dce92a0db7f19c221cfa3f2cb4c32 (diff) | |
download | linux-32f1a95d505b99b1f01b6aeea36ec3f97245b357.tar.xz |
[JFFS2] Add symlink caching support.
Signed-off-by: Artem B. Bityuckiy <dedekind@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'fs/jffs2/read.c')
-rw-r--r-- | fs/jffs2/read.c | 32 |
1 files changed, 1 insertions, 31 deletions
diff --git a/fs/jffs2/read.c b/fs/jffs2/read.c index eb493dc..c7f9068 100644 --- a/fs/jffs2/read.c +++ b/fs/jffs2/read.c @@ -7,7 +7,7 @@ * * For licensing information, see the file 'LICENCE' in this directory. * - * $Id: read.c,v 1.38 2004/11/16 20:36:12 dwmw2 Exp $ + * $Id: read.c,v 1.39 2005/03/01 10:34:03 dedekind Exp $ * */ @@ -214,33 +214,3 @@ int jffs2_read_inode_range(struct jffs2_sb_info *c, struct jffs2_inode_info *f, return 0; } -/* Core function to read symlink target. */ -char *jffs2_getlink(struct jffs2_sb_info *c, struct jffs2_inode_info *f) -{ - char *buf; - int ret; - - down(&f->sem); - - if (!f->metadata) { - printk(KERN_NOTICE "No metadata for symlink inode #%u\n", f->inocache->ino); - up(&f->sem); - return ERR_PTR(-EINVAL); - } - buf = kmalloc(f->metadata->size+1, GFP_USER); - if (!buf) { - up(&f->sem); - return ERR_PTR(-ENOMEM); - } - buf[f->metadata->size]=0; - - ret = jffs2_read_dnode(c, f, f->metadata, buf, 0, f->metadata->size); - - up(&f->sem); - - if (ret) { - kfree(buf); - return ERR_PTR(ret); - } - return buf; -} |