diff options
author | Jan Kara <jack@suse.cz> | 2016-03-09 22:26:55 -0500 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2016-03-09 22:26:55 -0500 |
commit | 87d8a74b56746d4b6125602365b10995116afd00 (patch) | |
tree | 99d114c523b37787451f3f72af3d191c6d3b7961 | |
parent | 600be30a8bc1d405f791e01dbef84679e14529b8 (diff) | |
download | linux-87d8a74b56746d4b6125602365b10995116afd00.tar.bz2 |
ext4: fix setting of referenced bit in ext4_es_lookup_extent()
We were setting referenced bit on the extent structure we return from
ext4_es_lookup_extent() which is just a private structure on stack. Thus
setting had no effect. Set the bit in the structure in the status tree
instead.
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
-rw-r--r-- | fs/ext4/extents_status.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/ext4/extents_status.c b/fs/ext4/extents_status.c index ac748b3af1c1..e38b987ac7f5 100644 --- a/fs/ext4/extents_status.c +++ b/fs/ext4/extents_status.c @@ -823,8 +823,8 @@ out: es->es_lblk = es1->es_lblk; es->es_len = es1->es_len; es->es_pblk = es1->es_pblk; - if (!ext4_es_is_referenced(es)) - ext4_es_set_referenced(es); + if (!ext4_es_is_referenced(es1)) + ext4_es_set_referenced(es1); stats->es_stats_cache_hits++; } else { stats->es_stats_cache_misses++; |