crimson/os/seastore: initialize crc *after* read
authorSamuel Just <sjust@redhat.com>
Fri, 21 Aug 2020 20:15:21 +0000 (13:15 -0700)
committerSamuel Just <sjust@redhat.com>
Wed, 23 Sep 2020 22:13:51 +0000 (15:13 -0700)
commit05c62821d94471c1c13ddaf56991c046efc9318e
tree582e617e37fe8cd14c17f5528420b68df472f644
parent9016932fef255207c61e48621629b7d275970ec5
crimson/os/seastore: initialize crc *after* read

Previously, all extents ended up initialized to the same crc value
upon read -- the one for an empty buffer.  This bug wasn't detected
because an extent was always evicted and reread following the first
write and subsequently kept in cache once initially written.

Also, add crc to operator<< for extents.

Signed-off-by: Samuel Just <sjust@redhat.com>
src/crimson/os/seastore/cache.h
src/crimson/os/seastore/cached_extent.h