RFC Initial PECI bus support
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 RFC Latest3 patches 3 repliesIn review
- v1 RFC3 patches 9 repliesSuperseded
Changes in v2 from the cover letter
- rename EndPt to EndPoint
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | hw/peci: add initial support for PECIMAINTAINERS hw/ hw/ +8 more | +625 | 1 reply | |
| 2/3 | hw/peci: add PECI support for NPCM7xx BMCsMAINTAINERS hw/ hw/ +5 more | +260 | 0 replies | |
| 3/3 | hw/peci: add support for EndPointConfig readshw/ hw/ include/ | +128 | 1 reply |
Reviews trailers per patch
All 3 patches have a Reviewed-by or Acked-by.
| Patch | Hao Wu | Patrick Venture | Peter Delevoryas |
|---|---|---|---|
| 1/3 | R-b | R-b | R-b |
| 2/3 | R-b | R-b | |
| 3/3 | R-b | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.
Cover letter [RFC PATCH v2 0/3] Initial PECI bus support
The Platform Environment Control Interface (PECI), is a way for Intel processors to communicate with management controllers.
This series of patches simulate some PECI subsystem functionality. This work is currently used against Nuvoton 7xx BMC, but it can easily be extended to support Aspeed BMCs. Most of the functionality is derived from PECI support in openbmc. See https://github.com/openbmc/libpeci
The main consumer of this work is openbmc, so functionality not exercised by the openbmc/libpeci is unlikely to be present here.
peci-core.c is an attempt to split out functionality defined by the spec. Anything that is not expected to change between BMC vendors.
The following commands have some support:
Ping()
GetDIB()
GetTemp()
~RdPkgConfig()
~RdEndPtConfig()To be implemented:
RdIAMSR()
RdPCIConfig()
RdPCIConfigLocal()
Currently, in the board file during bmc_init() one may specify defaults as follows:
static void my_machine_peci_init(NPCM7xxState *soc)
{
PECIBus *peci_bus = npcm7xx_peci_get_bus(soc);
DeviceState *dev;
/* per socket properties - both sockets are identical in this case */
PECIClientProperties peci_props = {
.cpu_family = FAM6_SAPPHIRE_RAPIDS_X,
.cpus = 56,
.dimms = 16
};
/* socket 0 - with example setting a few of the cpu and dimm temperatures in millidegrees */
dev = DEVICE(peci_add_client(peci_bus, 0x30, &peci_props));
object_property_set_uint(OBJECT(dev), "cpu_temp[0]", 30000, &error_abort);
object_property_set_uint(OBJECT(dev), "cpu_temp[2]", 35000, &error_abort);
object_property_set_uint(OBJECT(dev), "dimm_temp[1]", 40000, &error_abort);
object_property_set_uint(OBJECT(dev), "dimm_temp[8]", 36000, &error_abort);
/* socket 1 */
dev = DEVICE(peci_add_client(peci_bus, 0x31, &peci_props));
object_property_set_uint(OBJECT(dev), "cpu_temp[9]", 50000, &error_abort);
object_property_set_uint(OBJECT(dev), "dimm_temp[0]", 31000, &error_abort);
object_property_set_uint(OBJECT(dev), "dimm_temp[14]", 36000, &error_abort);
...
}This is something that can also be extended as other parameters arise that need to differ between platforms. So far you can have have different CPUs, DIMM counts, DIMM temperatures here. These fields can also be adjusted at runtime through qmp.
A lot of the registers are hard coded, see hw/peci/peci-client.c. I'd like to gauge interest in what potential users would like to be adjustable at runtime. I've not written QEMU models that read config files at runtime, something I'd appreciate guidance on.
Thanks all
Changes in v2:
- rename EndPt to EndPoint
Titus Rwantare (3):
hw/peci: add initial support for PECI
hw/peci: add PECI support for NPCM7xx BMCs
hw/peci: add support for EndPointConfig reads
MAINTAINERS | 8 + hw/Kconfig | 1 + hw/arm/Kconfig | 1 + hw/arm/npcm7xx.c | 9 + hw/meson.build | 1 + hw/peci/Kconfig | 2 + hw/peci/meson.build | 2 + hw/peci/npcm7xx_peci.c | 204 +++++++++++++++++++++++ hw/peci/peci-client.c | 293 +++++++++++++++++++++++++++++++++ hw/peci/peci-core.c | 222 +++++++++++++++++++++++++ hw/peci/trace-events | 10 ++ hw/peci/trace.h | 1 + include/hw/arm/npcm7xx.h | 2 + include/hw/peci/npcm7xx_peci.h | 37 +++++ include/hw/peci/peci.h | 217 ++++++++++++++++++++++++ meson.build | 1 + 16 files changed, 1011 insertions(+) create mode 100644 hw/peci/Kconfig create mode 100644 hw/peci/meson.build create mode 100644 hw/peci/npcm7xx_peci.c create mode 100644 hw/peci/peci-client.c create mode 100644 hw/peci/peci-core.c create mode 100644 hw/peci/trace-events create mode 100644 hw/peci/trace.h create mode 100644 include/hw/peci/npcm7xx_peci.h create mode 100644 include/hw/peci/peci.h
Signature · 1 line
2.37.3.968.ga6b4b080e4-goog