Documentation ¶
Overview ¶
Package timerfd implements the semantics of Linux timerfd objects as described by timerfd_create(2).
Index ¶
- func NewFile(ctx context.Context, c ktime.Clock) *fs.File
- type TimerOperations
- func (t *TimerOperations) Clock() ktime.Clock
- func (t *TimerOperations) Destroy()
- func (t *TimerOperations) EventRegister(e *waiter.Entry, mask waiter.EventMask)
- func (t *TimerOperations) EventUnregister(e *waiter.Entry)
- func (t *TimerOperations) GetTime() (ktime.Time, ktime.Setting)
- func (t *TimerOperations) Notify(exp uint64, setting ktime.Setting) (ktime.Setting, bool)
- func (t *TimerOperations) PauseTimer()
- func (t *TimerOperations) Read(ctx context.Context, file *fs.File, dst usermem.IOSequence, offset int64) (int64, error)
- func (t *TimerOperations) Readiness(mask waiter.EventMask) waiter.EventMask
- func (t *TimerOperations) Release(context.Context)
- func (t *TimerOperations) ResumeTimer()
- func (t *TimerOperations) SetTime(s ktime.Setting) (ktime.Time, ktime.Setting)
- func (t *TimerOperations) StateFields() []string
- func (t *TimerOperations) StateLoad(stateSourceObject state.Source)
- func (t *TimerOperations) StateSave(stateSinkObject state.Sink)
- func (t *TimerOperations) StateTypeName() string
- func (t *TimerOperations) Write(context.Context, *fs.File, usermem.IOSequence, int64) (int64, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type TimerOperations ¶
type TimerOperations struct { fsutil.FileZeroSeek `state:"nosave"` fsutil.FileNotDirReaddir `state:"nosave"` fsutil.FileNoFsync `state:"nosave"` fsutil.FileNoIoctl `state:"nosave"` fsutil.FileNoMMap `state:"nosave"` fsutil.FileNoSplice `state:"nosave"` fsutil.FileNoopFlush `state:"nosave"` fsutil.FileUseInodeUnstableAttr `state:"nosave"` // contains filtered or unexported fields }
TimerOperations implements fs.FileOperations for timerfds.
+stateify savable
func (*TimerOperations) Clock ¶
func (t *TimerOperations) Clock() ktime.Clock
Clock returns the associated Timer's Clock.
func (*TimerOperations) Destroy ¶
func (t *TimerOperations) Destroy()
Destroy implements ktime.TimerListener.Destroy.
func (*TimerOperations) EventRegister ¶
func (t *TimerOperations) EventRegister(e *waiter.Entry, mask waiter.EventMask)
EventRegister implements waiter.Waitable.EventRegister.
func (*TimerOperations) EventUnregister ¶
func (t *TimerOperations) EventUnregister(e *waiter.Entry)
EventUnregister implements waiter.Waitable.EventUnregister.
func (*TimerOperations) GetTime ¶
func (t *TimerOperations) GetTime() (ktime.Time, ktime.Setting)
GetTime returns the associated Timer's setting and the time at which it was observed.
func (*TimerOperations) PauseTimer ¶
func (t *TimerOperations) PauseTimer()
PauseTimer pauses the associated Timer.
func (*TimerOperations) Read ¶
func (t *TimerOperations) Read(ctx context.Context, file *fs.File, dst usermem.IOSequence, offset int64) (int64, error)
Read implements fs.FileOperations.Read.
func (*TimerOperations) Readiness ¶
func (t *TimerOperations) Readiness(mask waiter.EventMask) waiter.EventMask
Readiness implements waiter.Waitable.Readiness.
func (*TimerOperations) Release ¶
func (t *TimerOperations) Release(context.Context)
Release implements fs.FileOperations.Release.
func (*TimerOperations) ResumeTimer ¶
func (t *TimerOperations) ResumeTimer()
ResumeTimer resumes the associated Timer.
func (*TimerOperations) SetTime ¶
SetTime atomically changes the associated Timer's setting, resets the number of expirations to 0, and returns the previous setting and the time at which it was observed.
func (*TimerOperations) StateFields ¶
func (t *TimerOperations) StateFields() []string
func (*TimerOperations) StateLoad ¶
func (t *TimerOperations) StateLoad(stateSourceObject state.Source)
func (*TimerOperations) StateSave ¶
func (t *TimerOperations) StateSave(stateSinkObject state.Sink)
func (*TimerOperations) StateTypeName ¶
func (t *TimerOperations) StateTypeName() string