https://github.com/torvalds/linux
Revision 0d200aefd4ac51787b6b80de1bb7ce93bccd59f6 authored by Joe Thornber on 03 July 2012, 11:55:31 UTC, committed by Alasdair G Kergon on 03 July 2012, 11:55:31 UTC
Userland sometimes sees a corrupt metadata block if metadata is changing
rapidly when a metadata snapshot is reserved for userland,  To make the
problem go away, commit before we take the metadata snapshot (which is a
sensible thing to do anyway).

The checksums mean userland spots this corruption immediately so there's
no risk of acting on incorrect data.  No corruption exists from the
kernel's point of view, and thin_check passes after pool shutdown.

I believe this is to do with shared blocks at the first level of the
{device, mapping} btree.  Prior to the metadata-snap support no sharing
at this level was possible, so this patch is only required after commit
cc8394d86f045b86ff303d3c9e4ce47d97148951 ("dm thin: provide userspace
access to pool metadata").

Signed-off-by: Joe Thornber <ejt@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Alasdair G Kergon <agk@redhat.com>
1 parent 6887a41
History
Tip revision: 0d200aefd4ac51787b6b80de1bb7ce93bccd59f6 authored by Joe Thornber on 03 July 2012, 11:55:31 UTC
dm thin: commit metadata before creating metadata snapshot
Tip revision: 0d200ae
File Mode Size
Kbuild -rw-r--r-- 239 bytes
ac97_codec.h -rw-r--r-- 28.1 KB
aci.h -rw-r--r-- 2.4 KB
ad1816a.h -rw-r--r-- 5.2 KB
ad1843.h -rw-r--r-- 1.5 KB
adau1373.h -rw-r--r-- 699 bytes
ak4113.h -rw-r--r-- 10.6 KB
ak4114.h -rw-r--r-- 9.9 KB
ak4117.h -rw-r--r-- 9.0 KB
ak4531_codec.h -rw-r--r-- 3.1 KB
ak4641.h -rw-r--r-- 622 bytes
ak4xxx-adda.h -rw-r--r-- 3.3 KB
alc5623.h -rw-r--r-- 497 bytes
asequencer.h -rw-r--r-- 24.2 KB
asound.h -rw-r--r-- 40.3 KB
asound_fm.h -rw-r--r-- 4.2 KB
asoundef.h -rw-r--r-- 16.7 KB
atmel-abdac.h -rw-r--r-- 626 bytes
atmel-ac97c.h -rw-r--r-- 1.4 KB
compress_driver.h -rw-r--r-- 5.7 KB
compress_offload.h -rw-r--r-- 5.4 KB
compress_params.h -rw-r--r-- 15.9 KB
control.h -rw-r--r-- 8.1 KB
core.h -rw-r--r-- 15.4 KB
cs4231-regs.h -rw-r--r-- 8.3 KB
cs4271.h -rw-r--r-- 774 bytes
cs42l52.h -rw-r--r-- 810 bytes
cs46xx.h -rw-r--r-- 72.0 KB
cs46xx_dsp_scb_types.h -rw-r--r-- 27.5 KB
cs46xx_dsp_spos.h -rw-r--r-- 6.1 KB
cs46xx_dsp_task_types.h -rw-r--r-- 7.1 KB
cs8403.h -rw-r--r-- 8.6 KB
cs8427.h -rw-r--r-- 10.3 KB
dmaengine_pcm.h -rw-r--r-- 1.7 KB
emu10k1.h -rw-r--r-- 104.7 KB
emu10k1_synth.h -rw-r--r-- 1.3 KB
emu8000.h -rw-r--r-- 4.0 KB
emu8000_reg.h -rw-r--r-- 10.2 KB
emux_legacy.h -rw-r--r-- 5.4 KB
emux_synth.h -rw-r--r-- 7.4 KB
es1688.h -rw-r--r-- 3.5 KB
gus.h -rw-r--r-- 20.2 KB
hda_hwdep.h -rw-r--r-- 1.4 KB
hdsp.h -rw-r--r-- 3.0 KB
hdspm.h -rw-r--r-- 5.3 KB
hwdep.h -rw-r--r-- 2.6 KB
i2c.h -rw-r--r-- 3.5 KB
info.h -rw-r--r-- 7.1 KB
initval.h -rw-r--r-- 2.8 KB
jack.h -rw-r--r-- 2.6 KB
l3.h -rw-r--r-- 287 bytes
max9768.h -rw-r--r-- 729 bytes
max98088.h -rw-r--r-- 1.3 KB
max98095.h -rw-r--r-- 1.5 KB
memalloc.h -rw-r--r-- 3.9 KB
minors.h -rw-r--r-- 4.3 KB
mixer_oss.h -rw-r--r-- 2.4 KB
mpu401.h -rw-r--r-- 4.5 KB
opl3.h -rw-r--r-- 12.4 KB
opl4.h -rw-r--r-- 1.1 KB
pcm-indirect.h -rw-r--r-- 5.6 KB
pcm.h -rw-r--r-- 37.4 KB
pcm_oss.h -rw-r--r-- 2.6 KB
pcm_params.h -rw-r--r-- 8.2 KB
pt2258.h -rw-r--r-- 1.2 KB
pxa2xx-lib.h -rw-r--r-- 1.7 KB
rawmidi.h -rw-r--r-- 6.1 KB
s3c24xx_uda134x.h -rw-r--r-- 212 bytes
saif.h -rw-r--r-- 466 bytes
sb.h -rw-r--r-- 11.0 KB
sb16_csp.h -rw-r--r-- 5.9 KB
seq_device.h -rw-r--r-- 2.5 KB
seq_kernel.h -rw-r--r-- 4.2 KB
seq_midi_emul.h -rw-r--r-- 7.3 KB
seq_midi_event.h -rw-r--r-- 2.2 KB
seq_oss.h -rw-r--r-- 2.9 KB
seq_oss_legacy.h -rw-r--r-- 1.0 KB
seq_virmidi.h -rw-r--r-- 2.7 KB
sfnt_info.h -rw-r--r-- 7.3 KB
sh_dac_audio.h -rw-r--r-- 587 bytes
sh_fsi.h -rw-r--r-- 2.0 KB
simple_card.h -rw-r--r-- 896 bytes
snd_wavefront.h -rw-r--r-- 5.5 KB
soc-dai.h -rw-r--r-- 8.6 KB
soc-dapm.h -rw-r--r-- 24.7 KB
soc-dpcm.h -rw-r--r-- 3.7 KB
soc.h -rw-r--r-- 36.3 KB
soundfont.h -rw-r--r-- 4.5 KB
sta32x.h -rw-r--r-- 912 bytes
tea575x-tuner.h -rw-r--r-- 2.2 KB
tea6330t.h -rw-r--r-- 1.1 KB
timer.h -rw-r--r-- 5.4 KB
tlv.h -rw-r--r-- 3.0 KB
tlv320aic32x4.h -rw-r--r-- 884 bytes
tlv320aic3x.h -rw-r--r-- 1.7 KB
tlv320dac33-plat.h -rw-r--r-- 720 bytes
tpa6130a2-plat.h -rw-r--r-- 900 bytes
trident.h -rw-r--r-- 13.9 KB
uda134x.h -rw-r--r-- 1.2 KB
uda1380.h -rw-r--r-- 481 bytes
util_mem.h -rw-r--r-- 2.3 KB
version.h -rw-r--r-- 87 bytes
vx_core.h -rw-r--r-- 15.6 KB
wavefront.h -rw-r--r-- 18.8 KB
wm1250-ev1.h -rw-r--r-- 656 bytes
wm2000.h -rw-r--r-- 695 bytes
wm2200.h -rw-r--r-- 919 bytes
wm5100.h -rw-r--r-- 1.2 KB
wm8903.h -rw-r--r-- 15.2 KB
wm8904.h -rw-r--r-- 7.4 KB
wm8955.h -rw-r--r-- 662 bytes
wm8960.h -rw-r--r-- 599 bytes
wm8962.h -rw-r--r-- 1.8 KB
wm8993.h -rw-r--r-- 1.1 KB
wm8996.h -rw-r--r-- 1.4 KB
wm9081.h -rw-r--r-- 661 bytes
wm9090.h -rw-r--r-- 780 bytes
wss.h -rw-r--r-- 8.5 KB
ymfpci.h -rw-r--r-- 11.4 KB

back to top