IPMI(4)
π IPMI(4) β the Kernel Interfaces Manual page, but make it cute π
okay bestie, so you know how the kernel has a bunch of manual pages? this is one of them, from the Kernel Interfaces Manual section, and it's all about ipmi. buckle up π
β¨ NAME β¨
ipmi β the OpenIPMI compatible IPMI interface driver
like, that's the whole name section. short. iconic. we love a concise queen π
πΈ SYNOPSIS πΈ
device ipmi
okay so if you wanna manually specify I/O attachment in /boot/device.hints:
hint.ipmi.0.at="isa"
hint.ipmi.0.port="0xCA2"
hint.ipmi.0.spacing="8"
hint.ipmi.0.mode="KCS"
and if you wanna manually specify memory attachment in /boot/device.hints:
hint.ipmi.0.at="isa"
hint.ipmi.0.maddr="0xf0000000"
hint.ipmi.0.spacing="8"
hint.ipmi.0.mode="SMIC"
meaning of spacing, bestie:
8β 8 bit alignment16β 16 bit alignment32β 32 bit alignment
and here's the tea β: if the port and spacing aren't specified, the interface type default just gets used, no drama. and only specify either the port for I/O access or maddr for memory access. not both. pick a lane, babe π«Ά
π¦ DESCRIPTION π¦
so the IPMI β that's the Intelligent Platform Management Interface, yes the acronym is a mouthful β is a standard for monitoring system hardware. it lets generic code detect and monitor the sensors in a system. it's giving hands-off observability β¨
the IPMI standard offers watchdog support, an FRU database, and other support extensions too. and rn it's being adopted by the makers of many single board and embedded system manufacturers. slay.
the ipmi driver in FreeBSD is heavily adopted from the standard and the Linux driver β however, not all features described in the standard are supported. so like, temper your expectations a lil π
here's the fun part: the ipmi driver implements the power cycling option to shutdown(8), so you can actually power cycle the system. but!! the motherboard's BMC must support the chassis device and the optional power cycle subcomand of the chassis control command, as described in section 28.3 of the IPMI standard. the length of time the system is off will be at least one second, but may be longer if the power cycle interval has been set (see section 28.9). so don't be surprised if it takes a sec, fr fr π
π IOCTLS π
sending and receiving messages through the ipmi driver requires the use of ioctl(2). and why, you ask? because the data sent to and from the device is complex, bestie. it's giving "this needs its own syscall interface" π
the ioctl(2) command codes below are defined in <sys/ipmi.h>. and heads up: the third argument to ioctl(2) should be a pointer to the type indicated. don't forget that part, okay?
currently the following ioctls are supported:
IPMICTL_RECEIVE_MSG(struct ipmi_recv) β receive a message. possible error values:[EAGAIN]β no messages are in the process queue.[EFAULT]β an address supplied was invalid.[EMSGSIZE]β the address could not fit in the message buffer and will remain in the buffer.
IPMICTL_RECEIVE_MSG_TRUNC(struct ipmi_recv) β likeIPMICTL_RECEIVE_MSGbut if the message cannot fit into the buffer, it will truncate the contents instead of leaving the data in the buffer. it's giving "we tried, here's what fit" πIPMICTL_SEND_COMMAND(struct ipmi_req) β send a message to the interface. possible error values:[EFAULT]β an address supplied was invalid.[ENOMEM]β buffers could not be allowed for the command, out of memory.
IPMICTL_SET_MY_ADDRESS_CMD(unsigned int) β set the slave address for source messages.IPMICTL_GET_MY_ADDRESS_CMD(unsigned int) β get the slave address for source messages.IPMICTL_SET_MY_LUN_CMD(unsigned int) β set the slave LUN for source messages.IPMICTL_GET_MY_LUN_CMD(unsigned int) β get the slave LUN for source messages.
π Unimplemented Ioctls π
these ones exist but... they're not doing the thing yet. it's giving aspirational π
IPMICTL_REGISTER_FOR_CMD(struct ipmi_cmdspec) β register to receive a specific command. possible error values:[EFAULT]β an supplied address was invalid.[EBUSY]β the network function/command is already in use.[ENOMEM]β could not allocate memory.
IPMICTL_UNREGISTER_FOR_CMD(struct ipmi_cmdspec) β unregister to receive a specific command. possible error values:[EFAULT]β an address supplied was invalid.[ENOENT]β the network function/command was not found.
π Stub Only Ioctl π
just one lonely little stub, bestie. it's doing its best π«Ά
IPMICTL_SET_GETS_EVENTS_CMD(int) β set whether this interface receives events. possible error values:[EFAULT]β an address supplied was invalid.
π SEE ALSO π
go read these next, iykyk:
ioctl(2), watchdog(4), reboot(8), shutdown(8), watchdog(8), watchdogd(8), watchdog(9)
β HISTORY β
the ipmi driver first appeared in FreeBSD 6.2. a whole era π
π AUTHORS π
the ipmi driver was written by Doug Ambrisko <ambrisko@FreeBSD.org>.
this manual page was written by Tom Rhodes <trhodes@FreeBSD.org>.
thank you for your service, legends π
π BUGS π
not all features of the MontaVista driver are supported. so like, if something's missing, that's why π
currently, IPMB and BT modes are not implemented. no cap. they're just not there yet.
okay that's the whole page bestie!! every flag, every ioctl, every error code, every section β nothing skipped, periodt π β¨
and that's a wrap, my love π«Ά this page came to you from Debian, dated October 25, 2017 β so it's vintage, but the info still hits different. go forth and monitor those sensors, main character πΈππ
π¦ where this page comes from
- debian bookworm: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- debian trixie: freebsd-manpages 12.2-2 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu jammy: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu noble: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu questing: freebsd-manpages 12.2-2
- ubuntu resolute: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu stonking: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- Copyright (c) 2006 Tom Rhodes
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms