mirror of
https://github.com/containers/podman.git
synced 2025-11-29 17:48:05 +08:00
fix(deps): update module github.com/crc-org/vfkit to v0.6.1
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
This commit is contained in:
14
vendor/github.com/power-devops/perfstat/lparstat.go
generated
vendored
14
vendor/github.com/power-devops/perfstat/lparstat.go
generated
vendored
@@ -1,3 +1,4 @@
|
||||
//go:build aix
|
||||
// +build aix
|
||||
|
||||
package perfstat
|
||||
@@ -6,11 +7,13 @@ package perfstat
|
||||
#cgo LDFLAGS: -lperfstat
|
||||
|
||||
#include <libperfstat.h>
|
||||
#include <sys/dr.h>
|
||||
*/
|
||||
import "C"
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"unsafe"
|
||||
)
|
||||
|
||||
func PartitionStat() (*PartitionConfig, error) {
|
||||
@@ -24,3 +27,14 @@ func PartitionStat() (*PartitionConfig, error) {
|
||||
return &p, nil
|
||||
|
||||
}
|
||||
|
||||
func LparInfo() (*PartitionInfo, error) {
|
||||
var pinfo C.lpar_info_format2_t
|
||||
|
||||
rc := C.lpar_get_info(C.LPAR_INFO_FORMAT2, unsafe.Pointer(&pinfo), C.sizeof_lpar_info_format2_t)
|
||||
if rc != 0 {
|
||||
return nil, fmt.Errorf("lpar_get_info() error")
|
||||
}
|
||||
p := lparinfo2partinfo(pinfo)
|
||||
return &p, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user