We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0a679a8 commit ab9af7fCopy full SHA for ab9af7f
blockdevice/stats.go
@@ -21,6 +21,7 @@ import (
21
"os"
22
"strings"
23
24
+ "github.com/prometheus/procfs/btrfs"
25
"github.com/prometheus/procfs/internal/fs"
26
"github.com/prometheus/procfs/internal/util"
27
)
@@ -210,7 +211,6 @@ const (
210
211
sysBlockDM = "dm"
212
sysUnderlyingDev = "slaves"
213
sysBlockSize = "size"
- sectorSize = 512
214
215
216
// FS represents the pseudo-filesystems proc and sys, which provides an
@@ -484,5 +484,5 @@ func (fs FS) SysBlockDeviceSize(device string) (uint64, error) {
484
if err != nil {
485
return 0, err
486
}
487
- return sectorSize * size, nil
+ return btrfs.SectorSize * size, nil
488
0 commit comments