KaiGai Kohei | 2 Jul 16:08
Picon

Re: unused fs/jffs2/acl.c:jffs2_clear_acl()

[JFFS2][XATTR] Fix memory leak in POSIX-ACL support

* jffs2-xattr-v6.2-02-fix-posix_acl-memory-leak.patch

jffs2_clear_acl() which releases acl caches allocated by kmalloc()
was defined but it was never called. Thus, we faced to the risk
of memory leaking.

This patch plugs jffs2_clear_acl() into jffs2_do_clear_inode().
It ensures to release acl cache when inode is cleared.

Signed-off-by: KaiGai Kohei <kaigai <at> ak.jp.nec.com>

Thanks,

KaiGai Kohei wrote:
> David Woodhouse wrote:
> 
>>On Thu, 2006-06-29 at 15:01 +0200, Adrian Bunk wrote:
>>
>>
>>>it might not have been intended that jffs2_clear_acl() in Linus' tree
>>>is unused?
>>
>>
>>I suspect you're right -- thanks for pointing it out.
>>
>>Kaigai-san?
> 
> 
(Continue reading)

Adrian Bunk | 6 Jul 22:37
Picon
Favicon

[2.6 patch] make fs/jffs2/nodelist.c:jffs2_obsolete_node_frag() static

This patch makes the needlessly global jffs2_obsolete_node_frag() 
static.

Signed-off-by: Adrian Bunk <bunk <at> stusta.de>

---

 fs/jffs2/nodelist.c |    6 +++++-
 fs/jffs2/nodelist.h |    1 -
 2 files changed, 5 insertions(+), 2 deletions(-)

--- linux-2.6.17-mm6-full/fs/jffs2/nodelist.h.old	2006-07-06 22:12:01.000000000 +0200
+++ linux-2.6.17-mm6-full/fs/jffs2/nodelist.h	2006-07-06 22:12:08.000000000 +0200
@@ -334,7 +334,6 @@
 struct rb_node *rb_next(struct rb_node *);
 struct rb_node *rb_prev(struct rb_node *);
 void rb_replace_node(struct rb_node *victim, struct rb_node *new, struct rb_root *root);
-void jffs2_obsolete_node_frag(struct jffs2_sb_info *c, struct jffs2_node_frag *this);
 int jffs2_add_full_dnode_to_inode(struct jffs2_sb_info *c, struct jffs2_inode_info *f, struct
jffs2_full_dnode *fn);
 void jffs2_truncate_fragtree (struct jffs2_sb_info *c, struct rb_root *list, uint32_t size);
 int jffs2_add_older_frag_to_fragtree(struct jffs2_sb_info *c, struct jffs2_inode_info *f, struct
jffs2_tmp_dnode_info *tn);
--- linux-2.6.17-mm6-full/fs/jffs2/nodelist.c.old	2006-07-06 22:12:17.000000000 +0200
+++ linux-2.6.17-mm6-full/fs/jffs2/nodelist.c	2006-07-06 22:12:55.000000000 +0200
@@ -21,6 +21,9 @@
 #include <linux/pagemap.h>
 #include "nodelist.h"

+static void jffs2_obsolete_node_frag(struct jffs2_sb_info *c,
(Continue reading)

lba292 | 11 Jul 23:52

Block size

Does jffs2 support block size larger than 4KB?

Thanks,

Lan

_________________________________________________________
This message was sent through the NU ECE webmail gateway.

To unsubscribe from this list: send the line "unsubscribe jffs-dev" in
the body of a message to majordomo <at> axis.com

Josh Boyer | 12 Jul 13:56
Picon
Favicon

Re: Block size

On Tue, 2006-07-11 at 16:52 -0500, lba292 <at> ece.northwestern.edu wrote:
> Does jffs2 support block size larger than 4KB?

Depends on what you mean by block size.  If you mean eraseblock size,
yes.  If you mean the maximum size of a JFFS2 data node, no.

josh

To unsubscribe from this list: send the line "unsubscribe jffs-dev" in
the body of a message to majordomo <at> axis.com

takis | 21 Jul 13:50

[PATCH] fs: Memory allocation cleanups

From: Panagiotis Issaris <takis <at> issaris.org>

- Remove useless casts from k(m|z)alloc and vmallocs
- One conversion of kmalloc+memset to kzalloc

Signed-off-by: Panagiotis Issaris <takis <at> issaris.org>
---
 fs/autofs4/inode.c      |    4 +---
 fs/befs/btree.c         |    2 +-
 fs/befs/debug.c         |    6 +++---
 fs/binfmt_misc.c        |    2 +-
 fs/binfmt_som.c         |    2 +-
 fs/cifs/cifssmb.c       |    3 +--
 fs/cifs/misc.c          |    8 ++------
 fs/file.c               |    8 ++++----
 fs/jffs/inode-v23.c     |    4 ++--
 fs/jffs/intrep.c        |   14 +++++++-------
 fs/jfs/jfs_dtree.c      |   14 ++++----------
 fs/jfs/jfs_imap.c       |    2 +-
 fs/lockd/svcshare.c     |    3 +--
 fs/nfs/nfs4proc.c       |    2 +-
 fs/reiserfs/xattr_acl.c |    3 +--
 15 files changed, 31 insertions(+), 46 deletions(-)

diff --git a/fs/autofs4/inode.c b/fs/autofs4/inode.c
index fde78b1..8e40bc1 100644
--- a/fs/autofs4/inode.c
+++ b/fs/autofs4/inode.c
@@ -305,13 +305,11 @@ int autofs4_fill_super(struct super_bloc
 	struct autofs_sb_info *sbi;
(Continue reading)

takis | 21 Jul 16:06

[PATCH 3/4] fs: Removing useless casts

From: Panagiotis Issaris <takis <at> issaris.org>

* Removing useless casts
* Removing useless wrapper
* Conversion from kmalloc+memset to kzalloc

Signed-off-by: Panagiotis Issaris <takis <at> issaris.org>
---
 fs/coda/dir.c               |    2 +-
 fs/ext2/acl.c               |    4 ++--
 fs/ext3/acl.c               |    4 ++--
 fs/ext3/resize.c            |    4 ++--
 fs/hpfs/buffer.c            |    2 +-
 fs/jffs/inode-v23.c         |    8 ++++----
 fs/jffs/intrep.c            |   11 ++++-------
 fs/jffs/jffs_fm.c           |    6 ++----
 fs/jfs/jfs_txnmgr.c         |    4 ++--
 fs/lockd/clntproc.c         |    2 +-
 fs/ncpfs/symlink.c          |    4 ++--
 fs/nfs/delegation.c         |    7 +------
 fs/nfs/inode.c              |    2 +-
 fs/nfs/nfs3proc.c           |    2 +-
 fs/nfs/proc.c               |    2 +-
 fs/ntfs/dir.c               |    5 ++---
 fs/ntfs/inode.c             |    2 +-
 fs/ntfs/mft.c               |    4 ++--
 fs/ntfs/unistr.c            |    4 ++--
 fs/xfs/linux-2.6/xfs_file.c |    2 +-
 fs/xfs/linux-2.6/xfs_iops.c |    4 ++--
 21 files changed, 37 insertions(+), 48 deletions(-)
(Continue reading)

Frederik Deweerdt | 21 Jul 16:37
Picon
Favicon

Re: [PATCH] fs: Memory allocation cleanups

On Fri, Jul 21, 2006 at 01:50:55PM +0200, takis <at> issaris.org wrote:
> -		dnotify_req = (struct dir_notify_req *) kmalloc(
> -						sizeof(struct dir_notify_req),
> +		dnotify_req = kmalloc(sizeof(struct dir_notify_req),
>  						 GFP_KERNEL);
						^^^^^ 
Should be aligned with the kmalloc?
> -	ext_acl = (reiserfs_acl_header *) kmalloc(sizeof(reiserfs_acl_header) +
> -						  acl->a_count *
> +	ext_acl = kmalloc(sizeof(reiserfs_acl_header) + acl->a_count *
>  						  sizeof(reiserfs_acl_entry),
>  						  GFP_NOFS);
						^^^^^
This should be aligned too, I think.

Regards,
Frederik
Dave Kleikamp | 24 Jul 16:41
Picon
Favicon

Re: [PATCH] fs: Memory allocation cleanups

On Fri, 2006-07-21 at 13:50 +0200, takis <at> issaris.org wrote:
> From: Panagiotis Issaris <takis <at> issaris.org>
> 
> - Remove useless casts from k(m|z)alloc and vmallocs
> - One conversion of kmalloc+memset to kzalloc
> 
> Signed-off-by: Panagiotis Issaris <takis <at> issaris.org>

Acked-by: Dave Kleikamp <shaggy <at> austin.ibm.com>

The jfs part looks good.

Shaggy
--

-- 
David Kleikamp
IBM Linux Technology Center

Dave Kleikamp | 24 Jul 16:48
Picon
Favicon

Re: [PATCH 3/4] fs: Removing useless casts

On Fri, 2006-07-21 at 16:06 +0200, takis <at> issaris.org wrote:
> From: Panagiotis Issaris <takis <at> issaris.org>
> 
> * Removing useless casts
> * Removing useless wrapper
> * Conversion from kmalloc+memset to kzalloc
> 
> Signed-off-by: Panagiotis Issaris <takis <at> issaris.org> 

Acked-by: Dave Kleikamp <shaggy <at> austin.ibm.com>

The jfs bit is okay.

Shaggy
--

-- 
David Kleikamp
IBM Linux Technology Center

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

Gmane