Merge pull request #34345 from kolyshkin/dm-nitpicks
graphdriver/devmapper nitpicks Upstream-commit: a9aa95ce133fe270db93cee4e59a23ca5a4d3558 Component: engine
This commit is contained in:
@ -1479,12 +1479,9 @@ func (devices *DeviceSet) closeTransaction() error {
|
||||
}
|
||||
|
||||
func determineDriverCapabilities(version string) error {
|
||||
/*
|
||||
* Driver version 4.27.0 and greater support deferred activation
|
||||
* feature.
|
||||
*/
|
||||
// Kernel driver version >= 4.27.0 support deferred removal
|
||||
|
||||
logrus.Debugf("devicemapper: driver version is %s", version)
|
||||
logrus.Debugf("devicemapper: kernel dm driver version is %s", version)
|
||||
|
||||
versionSplit := strings.Split(version, ".")
|
||||
major, err := strconv.Atoi(versionSplit[0])
|
||||
|
||||
@ -13,6 +13,7 @@ import (
|
||||
"golang.org/x/sys/unix"
|
||||
)
|
||||
|
||||
// Same as DM_DEVICE_* enum values from libdevmapper.h
|
||||
const (
|
||||
deviceCreate TaskType = iota
|
||||
deviceReload
|
||||
|
||||
@ -8,7 +8,7 @@ package devicemapper
|
||||
*/
|
||||
import "C"
|
||||
|
||||
// LibraryDeferredRemovalSupport is supported when statically linked.
|
||||
// LibraryDeferredRemovalSupport tells if the feature is enabled in the build
|
||||
const LibraryDeferredRemovalSupport = true
|
||||
|
||||
func dmTaskDeferredRemoveFct(task *cdmTask) int {
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
|
||||
package devicemapper
|
||||
|
||||
// LibraryDeferredRemovalSupport is not supported when statically linked.
|
||||
// LibraryDeferredRemovalSupport tells if the feature is enabled in the build
|
||||
const LibraryDeferredRemovalSupport = false
|
||||
|
||||
func dmTaskDeferredRemoveFct(task *cdmTask) int {
|
||||
|
||||
Reference in New Issue
Block a user