diff for duplicates of <4C46FD67.8070808@redhat.com> diff --git a/a/1.txt b/N1/1.txt index 4999624..4012b6b 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -29,22 +29,24 @@ More comments below. > > - spin_lock(&mb_cache_spinlock); > - list_for_each(l, &mb_cache_list) { -> - struct mb_cache *cache > - list_entry(l, struct mb_cache, c_cache_list); +> - struct mb_cache *cache = +> - list_entry(l, struct mb_cache, c_cache_list); > - mb_debug("cache %s (%d)", cache->c_name, > - atomic_read(&cache->c_entry_count)); > - count += atomic_read(&cache->c_entry_count); > - } > mb_debug("trying to free %d entries", nr_to_scan); -> - if (nr_to_scan = 0) { +> - if (nr_to_scan == 0) { > - spin_unlock(&mb_cache_spinlock); > + > + spin_lock(&mb_cache_spinlock); -> + if (nr_to_scan = 0) +> + if (nr_to_scan == 0) > goto out; > - } > + > while (nr_to_scan-- && !list_empty(&mb_cache_lru_list)) { -> struct mb_cache_entry *ce > list_entry(mb_cache_lru_list.next, +> struct mb_cache_entry *ce = +> list_entry(mb_cache_lru_list.next, > @@ -223,12 +217,18 @@ mb_cache_shrink_fn(int nr_to_scan, gfp_t gfp_mask) > list_move_tail(&ce->e_lru_list, &free_list); > __mb_cache_entry_unhash(ce); @@ -74,4 +76,10 @@ Did you test this patch? > + > return (count / 100) * sysctl_vfs_cache_pressure; > } -> +> + +-- +To unsubscribe, send a message with 'unsubscribe linux-mm' in +the body to majordomo@kvack.org. For more info on Linux MM, +see: http://www.linux-mm.org/ . +Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a> diff --git a/a/content_digest b/N1/content_digest index 37b7b3b..5929d1c 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,7 +1,7 @@ "ref\04C46D1C5.90200@gmail.com\0" "From\0Eric Sandeen <sandeen@redhat.com>\0" - "Subject\0Re: [PATCH] fix return value for mb_cache_shrink_fn when nr_to_scan\0" - "Date\0Wed, 21 Jul 2010 14:00:07 +0000\0" + "Subject\0Re: [PATCH] fix return value for mb_cache_shrink_fn when nr_to_scan > 0\0" + "Date\0Wed, 21 Jul 2010 09:00:07 -0500\0" "To\0Wang Sheng-Hui <crosslonelyover@gmail.com>\0" "Cc\0agruen@suse.de" hch@infradead.org @@ -43,22 +43,24 @@ "> \n" "> - spin_lock(&mb_cache_spinlock);\n" "> - list_for_each(l, &mb_cache_list) {\n" - "> - struct mb_cache *cache > - list_entry(l, struct mb_cache, c_cache_list);\n" + "> - struct mb_cache *cache =\n" + "> - list_entry(l, struct mb_cache, c_cache_list);\n" "> - mb_debug(\"cache %s (%d)\", cache->c_name,\n" "> - atomic_read(&cache->c_entry_count));\n" "> - count += atomic_read(&cache->c_entry_count);\n" "> - }\n" "> mb_debug(\"trying to free %d entries\", nr_to_scan);\n" - "> - if (nr_to_scan = 0) {\n" + "> - if (nr_to_scan == 0) {\n" "> - spin_unlock(&mb_cache_spinlock);\n" "> +\n" "> + spin_lock(&mb_cache_spinlock);\n" - "> + if (nr_to_scan = 0)\n" + "> + if (nr_to_scan == 0)\n" "> goto out;\n" "> - }\n" "> +\n" "> while (nr_to_scan-- && !list_empty(&mb_cache_lru_list)) {\n" - "> struct mb_cache_entry *ce > list_entry(mb_cache_lru_list.next,\n" + "> struct mb_cache_entry *ce =\n" + "> list_entry(mb_cache_lru_list.next,\n" "> @@ -223,12 +217,18 @@ mb_cache_shrink_fn(int nr_to_scan, gfp_t gfp_mask)\n" "> list_move_tail(&ce->e_lru_list, &free_list);\n" "> __mb_cache_entry_unhash(ce);\n" @@ -88,6 +90,12 @@ "> +\n" "> return (count / 100) * sysctl_vfs_cache_pressure;\n" "> }\n" - > + "> \n" + "\n" + "--\n" + "To unsubscribe, send a message with 'unsubscribe linux-mm' in\n" + "the body to majordomo@kvack.org. For more info on Linux MM,\n" + "see: http://www.linux-mm.org/ .\n" + "Don't email: <a href=mailto:\"dont@kvack.org\"> email@kvack.org </a>" -74833fc1b1cedef16f2984f8968c1d2858f0647d8d3e611708635cf853b18f5d +3e854cee815c5b49a0cb272a326b98b11ce830e04e23a9ddad99eafa5388d04f
diff --git a/a/1.txt b/N2/1.txt index 4999624..ebb4914 100644 --- a/a/1.txt +++ b/N2/1.txt @@ -29,22 +29,24 @@ More comments below. > > - spin_lock(&mb_cache_spinlock); > - list_for_each(l, &mb_cache_list) { -> - struct mb_cache *cache > - list_entry(l, struct mb_cache, c_cache_list); +> - struct mb_cache *cache = +> - list_entry(l, struct mb_cache, c_cache_list); > - mb_debug("cache %s (%d)", cache->c_name, > - atomic_read(&cache->c_entry_count)); > - count += atomic_read(&cache->c_entry_count); > - } > mb_debug("trying to free %d entries", nr_to_scan); -> - if (nr_to_scan = 0) { +> - if (nr_to_scan == 0) { > - spin_unlock(&mb_cache_spinlock); > + > + spin_lock(&mb_cache_spinlock); -> + if (nr_to_scan = 0) +> + if (nr_to_scan == 0) > goto out; > - } > + > while (nr_to_scan-- && !list_empty(&mb_cache_lru_list)) { -> struct mb_cache_entry *ce > list_entry(mb_cache_lru_list.next, +> struct mb_cache_entry *ce = +> list_entry(mb_cache_lru_list.next, > @@ -223,12 +217,18 @@ mb_cache_shrink_fn(int nr_to_scan, gfp_t gfp_mask) > list_move_tail(&ce->e_lru_list, &free_list); > __mb_cache_entry_unhash(ce); diff --git a/a/content_digest b/N2/content_digest index 37b7b3b..05f4a03 100644 --- a/a/content_digest +++ b/N2/content_digest @@ -1,7 +1,7 @@ "ref\04C46D1C5.90200@gmail.com\0" "From\0Eric Sandeen <sandeen@redhat.com>\0" - "Subject\0Re: [PATCH] fix return value for mb_cache_shrink_fn when nr_to_scan\0" - "Date\0Wed, 21 Jul 2010 14:00:07 +0000\0" + "Subject\0Re: [PATCH] fix return value for mb_cache_shrink_fn when nr_to_scan > 0\0" + "Date\0Wed, 21 Jul 2010 09:00:07 -0500\0" "To\0Wang Sheng-Hui <crosslonelyover@gmail.com>\0" "Cc\0agruen@suse.de" hch@infradead.org @@ -43,22 +43,24 @@ "> \n" "> - spin_lock(&mb_cache_spinlock);\n" "> - list_for_each(l, &mb_cache_list) {\n" - "> - struct mb_cache *cache > - list_entry(l, struct mb_cache, c_cache_list);\n" + "> - struct mb_cache *cache =\n" + "> - list_entry(l, struct mb_cache, c_cache_list);\n" "> - mb_debug(\"cache %s (%d)\", cache->c_name,\n" "> - atomic_read(&cache->c_entry_count));\n" "> - count += atomic_read(&cache->c_entry_count);\n" "> - }\n" "> mb_debug(\"trying to free %d entries\", nr_to_scan);\n" - "> - if (nr_to_scan = 0) {\n" + "> - if (nr_to_scan == 0) {\n" "> - spin_unlock(&mb_cache_spinlock);\n" "> +\n" "> + spin_lock(&mb_cache_spinlock);\n" - "> + if (nr_to_scan = 0)\n" + "> + if (nr_to_scan == 0)\n" "> goto out;\n" "> - }\n" "> +\n" "> while (nr_to_scan-- && !list_empty(&mb_cache_lru_list)) {\n" - "> struct mb_cache_entry *ce > list_entry(mb_cache_lru_list.next,\n" + "> struct mb_cache_entry *ce =\n" + "> list_entry(mb_cache_lru_list.next,\n" "> @@ -223,12 +217,18 @@ mb_cache_shrink_fn(int nr_to_scan, gfp_t gfp_mask)\n" "> list_move_tail(&ce->e_lru_list, &free_list);\n" "> __mb_cache_entry_unhash(ce);\n" @@ -90,4 +92,4 @@ "> }\n" > -74833fc1b1cedef16f2984f8968c1d2858f0647d8d3e611708635cf853b18f5d +db920e5910375bd666be5525e4fe33d522ddd2085e333b60c12aee87b438b8d7
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.