Skip to content

Commit

Permalink
Merge pull request #266 from dcantah/fix-memcomment
Browse files Browse the repository at this point in the history
cg1: Clarify MemoryEvent comments
  • Loading branch information
mxpv authored Jan 9, 2023
2 parents fc3b020 + 93f6c66 commit ed5fd67
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cgroup1/memory.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ type memoryThresholdEvent struct {
swap bool
}

// MemoryThresholdEvent returns a new memory threshold event to be used with RegisterMemoryEvent.
// MemoryThresholdEvent returns a new [MemoryEvent] representing the memory threshold set.
// If swap is true, the event will be registered using memory.memsw.usage_in_bytes
func MemoryThresholdEvent(threshold uint64, swap bool) MemoryEvent {
return &memoryThresholdEvent{
Expand Down Expand Up @@ -83,7 +83,7 @@ type memoryPressureEvent struct {
hierarchy EventNotificationMode
}

// MemoryPressureEvent returns a new memory pressure event to be used with RegisterMemoryEvent.
// MemoryPressureEvent returns a new [MemoryEvent] representing the memory pressure set.
func MemoryPressureEvent(pressureLevel MemoryPressureLevel, hierarchy EventNotificationMode) MemoryEvent {
return &memoryPressureEvent{
pressureLevel,
Expand Down

0 comments on commit ed5fd67

Please sign in to comment.