physical

package
v2.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 26, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package physical facilitates communications with Intel® AMT devices to get the PhysicalMemory as a subclass of CIM_Chip, representing low level memory devices - SIMMS, DIMMs, raw memory chips, etc.

Index

Constants

View Source
const (
	CIM_PhysicalMemory  string = "CIM_PhysicalMemory"
	CIM_PhysicalPackage string = "CIM_PhysicalPackage"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Body

type Body struct {
	XMLName           xml.Name `xml:"Body"`
	PullResponse      PullResponse
	EnumerateResponse common.EnumerateResponse
	MemoryResponse    PhysicalMemory
}

Response Types

type Memory

type Memory struct {
	// contains filtered or unexported fields
}

func NewPhysicalMemoryWithClient

func NewPhysicalMemoryWithClient(wsmanMessageCreator *message.WSManMessageCreator, client client.WSMan) Memory

NewPhysicalMemory returns a new instance of the PhysicalMemory struct.

func (Memory) Enumerate

func (memory Memory) Enumerate() (response Response, err error)

Enumerate returns an enumeration context which is used in a subsequent Pull call

func (Memory) Pull

func (memory Memory) Pull(enumerationContext string) (response Response, err error)

Pull returns the instances of this class. An enumeration context provided by the Enumerate call is used as input.

type MemoryType

type MemoryType int

The type of PhysicalMemory. Synchronous DRAM is also known as SDRAM Cache DRAM is also known as CDRAM CDRAM is also known as Cache DRAM SDRAM is also known as Synchronous DRAM BRAM is also known as Block RAM

ValueMap={0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37..32567, 32568..65535}

Values={Unknown, Other, DRAM, Synchronous DRAM, Cache DRAM, EDO, EDRAM, VRAM, SRAM, RAM, ROM, Flash, EEPROM, FEPROM, EPROM, CDRAM, 3DRAM, SDRAM, SGRAM, RDRAM, DDR, DDR-2, BRAM, FB-DIMM, DDR3, FBD2, DDR4, LPDDR, LPDDR2, LPDDR3, LPDDR4, Logical non-volatile device, HBM (High Bandwidth Memory), HBM2 (High Bandwidth Memory Generation 2), DDR5, LPDDR5, HBM3 (High Bandwidth Memory Generation 3), DMTF Reserved, Vendor Reserved}

const (
	MemoryTypeUnknown MemoryType = iota
	MemoryTypeOther
	MemoryTypeDRAM
	MemoryTypeSynchronous_DRAM
	MemoryTypeCache_DRAM
	MemoryTypeEDO
	MemoryTypeEDRAM
	MemoryTypeVRAM
	MemoryTypeSRAM
	MemoryTypeRAM
	MemoryTypeROM
	MemoryTypeFlash
	MemoryTypeEEPROM
	MemoryTypeFEPROM
	MemoryTypeEPROM
	MemoryTypeCDRAM
	MemoryType3DRAM
	MemoryTypeSDRAM
	MemoryTypeSGRAM
	MemoryTypeRDRAM
	MemoryTypeDDR
	MemoryTypeDDR2
	MemoryTypeBRAM
	MemoryTypeFBDIMM
	MemoryTypeDDR3
	MemoryTypeFBD2
	MemoryTypeDDR4
	MemoryTypeLPDDR
	MemoryTypeLPDDR2
	MemoryTypeLPDDR3
	MemoryTypeLPDDR4
	MemoryTypeLogicalnonvolatiledevice
	MemoryTypeHBM
	MemoryTypeHBM2
	MemoryTypeDDR5
	MemoryTypeLPDDR5
	MemoryTypeHBM3
)

type Package

type Package struct {
	// contains filtered or unexported fields
}

func NewPhysicalPackageWithClient

func NewPhysicalPackageWithClient(wsmanMessageCreator *message.WSManMessageCreator, client client.WSMan) Package

NewPhysicalPackage returns a new instance of the PhysicalPackage struct.

func (Package) Enumerate

func (physicalPackage Package) Enumerate() (response Response, err error)

Enumerate returns an enumeration context which is used in a subsequent Pull call

func (Package) Pull

func (physicalPackage Package) Pull(enumerationContext string) (response Response, err error)

Pull returns the instances of this class. An enumeration context provided by the Enumerate call is used as input.

type PhysicalMemory

type PhysicalMemory struct {
	XMLName                    xml.Name                 `xml:"CIM_PhysicalMemory"`
	PartNumber                 string                   `xml:"PartNumber"`        // The part number assigned by the organization that is responsible for producing or manufacturing the PhysicalElement.
	SerialNumber               string                   `xml:"SerialNumber"`      // A manufacturer-allocated number used to identify the Physical Element.
	Manufacturer               string                   `xml:"Manufacturer"`      // The name of the organization responsible for producing the PhysicalElement. This organization might be the entity from whom the Element is purchased, but this is not necessarily true. The latter information is contained in the Vendor property of CIM_Product.
	ElementName                string                   `xml:"ElementName"`       // 'ElementName' is constant. In CIM_Chip instances its value is set to 'Managed System Memory Chip'.
	CreationClassName          string                   `xml:"CreationClassName"` // CreationClassName indicates the name of the class or the subclass used in the creation of an instance. When used with the other key properties of this class, this property allows all instances of this class and its subclasses to be uniquely identified.
	Tag                        string                   `xml:"Tag"`               // An arbitrary string that uniquely identifies the Physical Element and serves as the key of the Element. The Tag property can contain information such as asset tag or serial number data. The key for PhysicalElement is placed very high in the object hierarchy in order to independently identify the hardware or entity, regardless of physical placement in or on Cabinets, Adapters, and so on. For example, a hotswappable or removable component can be taken from its containing (scoping) Package and be temporarily unused. The object still continues to exist and can even be inserted into a different scoping container. Therefore, the key for Physical Element is an arbitrary string and is defined independently of any placement or location-oriented hierarchy.
	OperationalStatus          models.OperationalStatus `xml:"OperationalStatus"` // Indicates the current statuses of the element. Various operational statuses are defined.
	FormFactor                 int                      `xml:"FormFactor,omitempty"`
	MemoryType                 MemoryType               `xml:"MemoryType,omitempty"`                 // The type of PhysicalMemory. Synchronous DRAM is also known as SDRAM Cache DRAM is also known as CDRAM CDRAM is also known as Cache DRAM SDRAM is also known as Synchronous DRAM BRAM is also known as Block RAM
	Speed                      int                      `xml:"Speed,omitempty"`                      // The speed of the PhysicalMemory, in nanoseconds.
	Capacity                   int                      `xml:"Capacity,omitempty"`                   // The total capacity of this PhysicalMemory, in bytes.
	BankLabel                  string                   `xml:"BankLabel,omitempty"`                  // A string identifying the physically labeled bank where the Memory is located - for example, 'Bank 0' or 'Bank A'.
	ConfiguredMemoryClockSpeed int                      `xml:"ConfiguredMemoryClockSpeed,omitempty"` // The configured clock speed (in MHz) of PhysicalMemory.
	IsSpeedInMhz               bool                     `xml:"IsSpeedInMhz,omitempty"`               // The IsSpeedInMHz property is used to indicate if the Speed property or the MaxMemorySpeed contains the value of the memory speed. A value of TRUE shall indicate that the speed is represented by the MaxMemorySpeed property. A value of FALSE shall indicate that the speed is represented by the Speed property.
	MaxMemorySpeed             int                      `xml:"MaxMemorySpeed,omitempty"`             // The maximum speed (in MHz) of PhysicalMemory.
}

Response Types

type PullResponse

type PullResponse struct {
	XMLName xml.Name `xml:"PullResponse"`
	common.EnumerateResponse
	MemoryItems     []PhysicalMemory       `xml:"Items>CIM_PhysicalMemory"`
	PhysicalPackage []card.PackageResponse `xml:"Items>CIM_Card"` // This might need to be fixed if we get more than just CIM_Card back on a Pull call
}

Response Types

type Response

type Response struct {
	*client.Message
	XMLName xml.Name       `xml:"Envelope"`
	Header  message.Header `xml:"Header"`
	Body    Body           `xml:"Body"`
}

Response Types

func (*Response) JSON

func (r *Response) JSON() string

JSON marshals the type into JSON format

func (*Response) YAML

func (r *Response) YAML() string

YAML marshals the type into YAML format

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL