1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-03-22 06:50:52 +03:00

label: use open_rw

Add missing declaration for label_scan_open_rw()
which has been already introduced without declaration
and use it for wiping LV.
This commit is contained in:
Zdenek Kabelac 2020-10-18 00:25:33 +02:00
parent 8792d417f3
commit ba7740df50
2 changed files with 3 additions and 1 deletions

View File

@ -118,6 +118,8 @@ void label_scan_confirm(struct device *dev);
int label_scan_setup_bcache(void);
int label_scan_open(struct device *dev);
int label_scan_open_excl(struct device *dev);
int label_scan_open_rw(struct device *dev);
int label_scan_pvscan_all(struct cmd_context *cmd, struct dm_list *scan_devs);
/*

View File

@ -7219,7 +7219,7 @@ int wipe_lv(struct logical_volume *lv, struct wipe_params wp)
return 0;
}
if (!label_scan_open(dev)) {
if (!label_scan_open_rw(dev)) {
log_error("Failed to open %s/%s for wiping and zeroing.", lv->vg->name, lv->name);
goto out;
}