(samples uint)
| 83 | } |
| 84 | |
| 85 | func (dev *Device) readSysoffExtended(samples uint) (*PTPSysOffsetExtended, error) { |
| 86 | if isClockMonoRawSupported { |
| 87 | value, err := dev.readSysoffExtendedClockID(samples, unix.CLOCK_MONOTONIC_RAW) |
| 88 | if err == nil { |
| 89 | return value, nil |
| 90 | } |
| 91 | isClockMonoRawSupported = false |
| 92 | } |
| 93 | return dev.readSysoffExtendedClockID(samples, unix.CLOCK_REALTIME) |
| 94 | } |
| 95 | |
| 96 | func (dev *Device) readSysoffExtendedClockID(samples uint, clockid uint32) (*PTPSysOffsetExtended, error) { |
| 97 | value, err := unix.IoctlPtpSysOffsetExtendedClock(int(dev.Fd()), clockid, samples) |
no test coverage detected