linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch] ext4: signedness bug breaks ext4_inode_touch_time_cmp()
@ 2013-06-20  8:08 Dan Carpenter
  2013-06-20 14:13 ` Theodore Ts'o
  2013-06-20 15:21 ` Zheng Liu
  0 siblings, 2 replies; 4+ messages in thread
From: Dan Carpenter @ 2013-06-20  8:08 UTC (permalink / raw)
  To: Theodore Ts'o, Zheng Liu; +Cc: Andreas Dilger, linux-ext4, kernel-janitors

"diff" is unsigned so this doesn't sort the LRU list correctly.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
This was introduced in 6480bad916be "ext4: improve extent cache shrink
mechanism to avoid to burn CPU time"

diff --git a/fs/ext4/extents_status.c b/fs/ext4/extents_status.c
index e0190f6..79e097d 100644
--- a/fs/ext4/extents_status.c
+++ b/fs/ext4/extents_status.c
@@ -880,7 +880,7 @@ static int ext4_inode_touch_time_cmp(void *priv, struct list_head *a,
 				     struct list_head *b)
 {
 	struct ext4_inode_info *eia, *eib;
-	unsigned long diff;
+	long diff;
 
 	eia = list_entry(a, struct ext4_inode_info, i_es_lru);
 	eib = list_entry(b, struct ext4_inode_info, i_es_lru);

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-06-20 15:24 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-20  8:08 [patch] ext4: signedness bug breaks ext4_inode_touch_time_cmp() Dan Carpenter
2013-06-20 14:13 ` Theodore Ts'o
2013-06-20 15:24   ` Zheng Liu
2013-06-20 15:21 ` Zheng Liu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).