New AMD code merged today to the mainline Linux 6.16 kernel that’s in-development is the introduction of the AMD-SBI driver/subsystem for primarily benefiting EPYC server platforms. AMD-SBI is for their Side-Band Interface also known as the Advanced Platform Management Link (APML).
This AMD-SBI code for Linux 6.16 is cleaning up existing AMD driver code within the kernel and making it more centralized and better positioned for enabling new functionality moving forward. That prior AMD SBI code was living within the hardware monitoring “HWMON” subsystem but now is moving to the more generic “char/misc” area of the Linux kernel.
AMD Linux engineer Akshay Gupta explained with the prior patch series working on this restructuring to form the AMD-SBI driver/subsystem:
“At present, sbrmi driver under hwmon subsystem, is probed as an i2c driver, fetches data using APML specified protocol and reports through hwmon power sensor.
AMD provides additional information using custom protocols, which cannot be enumerated as hwmon sensors. Hence, move the existing functionality from hwmon/ to misc/ and add support for following custom protocols
– read Processor feature capabilities and configuration information through side band.
– read Machine Check Architecture(MCA) registers over sideband. The information is accessed for range of MCA registers by passing register address and thread ID to the protocol.NOTE: AMD defines Advanced Platform Management Link (APML) interface which provides system management functionality access to the baseboard management controller (BMC).
This patchset is an attempt to keep all APML core functionality in one place, provide hwmon and IOCTL interface to user space.”
The now-merged documentation on the AMD-SBI code for the Linux kernel further sums up their Side-Band Interface:
“Some AMD Zen based processors supports system management functionality via side-band interface (SBI) called Advanced Platform Management Link (APML). APML is an I2C/I3C based 2-wire processor target interface. APML is used to communicate with the Remote Management Interface (SB Remote Management Interface (SB-RMI) and SB Temperature Sensor Interface (SB-TSI).
….
apml_sbrmi driver under the drivers/misc/amd-sbi creates miscdevice /dev/sbrmi-* to let user space programs run APML mailbox, CPUID,
MCAMSR and register xfer commands.”
The esmi_oob_library open-source user-space code is the APML library that will be able to the AMD-SBI kernel code. As part of that library is the apml_tool for user-space to also query various features.
The introduction of this new AMD-SBI driver and code restructuring is one of the main highlights of today’s char/misc merge.