HomeFreeBSD

Fix a persistent L2ARC bug in l2arc_write_done()

Description

Fix a persistent L2ARC bug in l2arc_write_done()

In case l2arc_write_done() handles a zio that was not successful check
that the list of log block pointers is not empty when restoring them
in the device header. Otherwise zero them out. In any case perform the
actual write updating the device header after the zio of
l2arc_write_buffers() completes as l2arc_write_done() may have touched
the memory holding the log block pointers in the device header.

Reviewed-by: Serapheim Dimitropoulos <serapheim@delphix.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: George Amanakis <gamanakis@gmail.com>
Closes #10540
Closes #10543

Details

Provenance
g_amanakis_yahoo.comAuthored on Jul 10 2020, 9:10 PM
GitHub <noreply@github.com>Committed on Jul 10 2020, 9:10 PM
Parents
rGd2bce6d036b3: Add Makefile command to run checkbashisms on all /bin/sh scripts
Branches
Unknown
Tags
Unknown