lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 29 Dec 2011 15:59:21 +0530
From:	Ajeet Yadav <ajeet.yadav.77@...il.com>
To:	Phillip Lougher <phillip@...ashfs.org.uk>,
	linux-kernel@...r.kernel.org
Subject: [PATCH] Squashfs: wake all waiting for unused cache entry

>From aedb5bd99c423945699fa82d592f62ad928bf943 Mon Sep 17 00:00:00 2001
From: Ajeet Yadav <ajeet.yadav.77@...il.com>
Date: Thu, 29 Dec 2011 15:45:58 +0530
Subject: [PATCH] Squashfs: wake all waiting for unused cache entry

Current implementation considers the case where different
blocks are waiting for unused cache entry, but it does not
consider the case where all / most of the waits are for the
same block, in that case, its good to wait for only one entry
and allow all other waits to use the newly allocated cache
entry.
While debugging we found that the wait is mostly for the same
block, hence its good to use wake_up_all().

Signed-off-by: Ajeet Yadav <ajeet.yadav.77@...il.com>
---
 fs/squashfs/cache.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/fs/squashfs/cache.c b/fs/squashfs/cache.c
index 30111a2..44ceecf 100644
--- a/fs/squashfs/cache.c
+++ b/fs/squashfs/cache.c
@@ -194,7 +194,7 @@ void squashfs_cache_put(struct squashfs_cache_entry *entry)
                 * available, wake one up.
                 */
                if (cache->num_waiters)
-                       wake_up(&cache->wait_queue);
+                       wake_up_all(&cache->wait_queue);
        }
        spin_unlock(&cache->lock);
 }
-- 
1.6.0.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ