mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 11:22:23 +00:00
Remove obsolete skipRoot flag in LXC driver
The lxcContainerMountAllFS method had a 'bool skipRoot' flag to control whether it mounts the / filesystem. Since removal of the non-pivot root container setup codepaths, this flag is obsolete as the only caller always passes 'true'. Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
parent
31453a837b
commit
7bb7510de7
@ -1333,16 +1333,14 @@ static int lxcContainerMountFS(virDomainFSDefPtr fs,
|
||||
|
||||
|
||||
static int lxcContainerMountAllFS(virDomainDefPtr vmDef,
|
||||
bool skipRoot,
|
||||
char *sec_mount_options)
|
||||
{
|
||||
size_t i;
|
||||
VIR_DEBUG("Mounting %d", skipRoot);
|
||||
VIR_DEBUG("Mounting all non-root filesystems");
|
||||
|
||||
/* Pull in rest of container's mounts */
|
||||
for (i = 0 ; i < vmDef->nfss ; i++) {
|
||||
if (skipRoot &&
|
||||
STREQ(vmDef->fss[i]->dst, "/"))
|
||||
if (STREQ(vmDef->fss[i]->dst, "/"))
|
||||
continue;
|
||||
|
||||
if (lxcContainerUnmountSubtree(vmDef->fss[i]->dst,
|
||||
@ -1353,7 +1351,7 @@ static int lxcContainerMountAllFS(virDomainDefPtr vmDef,
|
||||
return -1;
|
||||
}
|
||||
|
||||
VIR_DEBUG("Mounted all filesystems");
|
||||
VIR_DEBUG("Mounted all non-root filesystems");
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -1791,7 +1789,7 @@ static int lxcContainerSetupPivotRoot(virDomainDefPtr vmDef,
|
||||
goto cleanup;
|
||||
|
||||
/* Sets up any non-root mounts from guest config */
|
||||
if (lxcContainerMountAllFS(vmDef, true, sec_mount_options) < 0)
|
||||
if (lxcContainerMountAllFS(vmDef, sec_mount_options) < 0)
|
||||
goto cleanup;
|
||||
|
||||
/* Sets up any extra disks from guest config */
|
||||
|
Loading…
x
Reference in New Issue
Block a user