Documentation ¶
Index ¶
- func DecodeKernelTaintsFromBitMask(bitmask uint64) []string
- func DecodeKernelTaintsFromLetters(letters string) []string
- func GetOtherTaintedBits(taintsMask uint64, taintedBitsByModules map[int]bool) []int
- func GetTaintMsg(bit int) string
- func GetTaintedBitsByModules(tainters map[string]string) (map[int]bool, error)
- func RemoveAllExceptNumbers(incomingStr string) string
- type KernelTaint
- type NodeTainted
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetOtherTaintedBits ¶
GetOtherTaintedBits helper function to get the tainted bits that are not related to any module.
func GetTaintMsg ¶
func GetTaintedBitsByModules ¶
GetTaintedBitsByModules helper function to gets, for each module, the taint bits from its taint letters.
func RemoveAllExceptNumbers ¶
Types ¶
type KernelTaint ¶
type NodeTainted ¶
type NodeTainted struct {
// contains filtered or unexported fields
}
NodeTainted holds information about tainted nodes.
func NewNodeTaintedTester ¶
func NewNodeTaintedTester(context *clientsholder.Context, node string) *NodeTainted
NewNodeTainted creates a new NodeTainted tester
func (*NodeTainted) GetKernelTaintsMask ¶
func (nt *NodeTainted) GetKernelTaintsMask() (uint64, error)
func (*NodeTainted) GetTainterModules ¶
func (nt *NodeTainted) GetTainterModules(allowList map[string]bool) (tainters map[string]string, taintBits map[int]bool, err error)
GetTainterModules runs a command in the node to get all the modules that have set a kernel taint bit. Returns:
- tainters: maps a module to a string of taints letters. Each letter maps to a single bit in the taint mask. Tainters that appear in the allowlist will not be added to this map.
- taintBits: bits (pos) of kernel taints caused by all modules (included the allowlisted ones).
Click to show internal directories.
Click to hide internal directories.