@@ -766,7 +766,7 @@ func (devices *DeviceSet) createRegisterDevice(hash string) (*devInfo, error) {
766
766
if err := devicemapper .CreateDevice (devices .getPoolDevName (), deviceID ); err != nil {
767
767
if devicemapper .DeviceIDExists (err ) {
768
768
// Device ID already exists. This should not
769
- // happen. Now we have a mechianism to find
769
+ // happen. Now we have a mechanism to find
770
770
// a free device ID. So something is not right.
771
771
// Give a warning and continue.
772
772
logrus .Errorf ("Device ID %d exists in pool but it is supposed to be unused" , deviceID )
@@ -818,7 +818,7 @@ func (devices *DeviceSet) createRegisterSnapDevice(hash string, baseInfo *devInf
818
818
if err := devicemapper .CreateSnapDevice (devices .getPoolDevName (), deviceID , baseInfo .Name (), baseInfo .DeviceID ); err != nil {
819
819
if devicemapper .DeviceIDExists (err ) {
820
820
// Device ID already exists. This should not
821
- // happen. Now we have a mechianism to find
821
+ // happen. Now we have a mechanism to find
822
822
// a free device ID. So something is not right.
823
823
// Give a warning and continue.
824
824
logrus .Errorf ("Device ID %d exists in pool but it is supposed to be unused" , deviceID )
@@ -1749,7 +1749,7 @@ func (devices *DeviceSet) markForDeferredDeletion(info *devInfo) error {
1749
1749
1750
1750
info .Deleted = true
1751
1751
1752
- // save device metadata to refelect deleted state.
1752
+ // save device metadata to reflect deleted state.
1753
1753
if err := devices .saveMetadata (info ); err != nil {
1754
1754
info .Deleted = false
1755
1755
return err
@@ -1759,7 +1759,7 @@ func (devices *DeviceSet) markForDeferredDeletion(info *devInfo) error {
1759
1759
return nil
1760
1760
}
1761
1761
1762
- // Should be caled with devices.Lock() held.
1762
+ // Should be called with devices.Lock() held.
1763
1763
func (devices * DeviceSet ) deleteTransaction (info * devInfo , syncDelete bool ) error {
1764
1764
if err := devices .openTransaction (info .Hash , info .DeviceID ); err != nil {
1765
1765
logrus .Debugf ("Error opening transaction hash = %s deviceId = %d" , "" , info .DeviceID )
@@ -1805,7 +1805,7 @@ func (devices *DeviceSet) issueDiscard(info *devInfo) error {
1805
1805
// This is a workaround for the kernel not discarding block so
1806
1806
// on the thin pool when we remove a thinp device, so we do it
1807
1807
// manually.
1808
- // Even if device is deferred deleted, activate it and isue
1808
+ // Even if device is deferred deleted, activate it and issue
1809
1809
// discards.
1810
1810
if err := devices .activateDeviceIfNeeded (info , true ); err != nil {
1811
1811
return err
@@ -2131,7 +2131,7 @@ func (devices *DeviceSet) UnmountDevice(hash, mountPath string) error {
2131
2131
defer devices .Unlock ()
2132
2132
2133
2133
// If there are running containers when daemon crashes, during daemon
2134
- // restarting, it will kill running contaienrs and will finally call
2134
+ // restarting, it will kill running containers and will finally call
2135
2135
// Put() without calling Get(). So info.MountCount may become negative.
2136
2136
// if info.mountCount goes negative, we do the unmount and assign
2137
2137
// it to 0.
0 commit comments