Skip to contentSkip to conversation

IPMI driver updates, part 2

PATCH New Corey Minyard 1 participant 1 message Feb 23, 2004

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 IPMI driver updates, part 2

It has been far too long since the last IPMI driver updates, but now all the planets have aligned and all the pieces I needed are in and all seem to be working. This update is coming as four parts that must be applied in order, but the later parts do not have to be applied for the former parts to work.

This second part adds the "System Interface" driver. The previous driver for system interfaces only supported the KCS interface, this driver supports all system interfaces defined in the IPMI standard. It also does a much better job of handling ACPI and SMBIOS tables for detecting IPMI system interfaces.

FYI, IPMI is a standard for monitoring and maintaining a system. It provides interfaces for detecting sensors (voltage, temperature, etc.) in the system and monitoring those sensors. Many systems have extended capabilities that allow IPMI to control the system, doing things like lighting leds and controlling hot-swap. This driver allows access to the IPMI system.

-Corey

Documentation/IPMI.txt +71 -3
diff -urN linux-a1/Documentation/IPMI.txt linux-a2/Documentation/IPMI.txt
@@ -40,8 +40,13 @@
 main menu.  This provides a socket interface to IPMI.  You may select
 both of these at the same time, they will both work together.
 
-There is also a KCS-only driver interface supplied, most IPMI systems
-support KCS, so you need taht.
+The driver interface depends on your hardware.  If you have a board
+with a standard interface (These will generally be either "KCS",
+"SMIC", or "BT", consult your hardware manual), choose the 'IPMI SI
+handler' option.
+
+There is also a KCS-only driver interface supplied, but it is
+depracated in favor of the SI interface.
 
 You should generally enable ACPI on your system, as systems with IPMI
 should have ACPI tables describing them.
@@ -84,8 +89,13 @@
 driver, each open file for this device ties in to the message handler
 as an IPMI user.
 
+ipmi_si_drv - A driver for various system interfaces.  This supports
+KCS, SMIC, and may support BT in the future.  Unless you have your own
+custom interface, you probably need to use this.
+
 ipmi_kcs_drv - A driver for the KCS SI.  Most systems have a KCS
-interface for IPMI.
+interface for IPMI.  This is deprecated, ipmi_si_drv supports KCS and
+SMIC interfaces.
 
 
 Much documentation for the interface is in the include files.  The
@@ -308,6 +318,64 @@
 that for more details.
 
 
+The SI Driver
+-------------
+
+The SI driver allows up to 4 KCS or SMIC interfaces to be configured
+in the system.  By default, scan the ACPI tables for interfaces, and
+if it doesn't find any the driver will attempt to register one KCS
+interface at the spec-specified I/O port 0xca2 without interrupts.
+You can change this at module load time (for a module) with:
+
+  insmod ipmi_si_drv.o si_type=<type1>,<type2>....
+       si_ports=<port1>,<port2>... si_addrs=<addr1>,<addr2>
+       si_irqs=<irq1>,<irq2>... si_trydefaults=[0|1]
+
+Each of these except si_trydefaults is a list, the first item for the
+first interface, second item for the second interface, etc.
+
+The si_type may be either "kcs", "smic", or "bt".  If you leave it blank, it
+defaults to "kcs".
+
+If you specify si_addrs as non-zero for an interface, the driver will
+use the memory address given as the address of the device.  This
+overrides si_ports.
+
+If you specify si_ports as non-zero for an interface, the driver will
+use the I/O port given as the device address.
+
+If you specify si_irqs as non-zero for an interface, the driver will
+attempt to use the given interrupt for the device.
+
+si_trydefaults sets whether the standard IPMI interface at 0xca2 and
+any interfaces specified by ACPE are tried.  By default, the driver
+tries it, set this value to zero to turn this off.
+
+When compiled into the kernel, the addresses can be specified on the
+kernel command line as:
+
+  ipmi_si=[<type>,]<bmc1>:<irq1>,[<type>,]<bmc2>:<irq2>....,[nodefault]
+
+The type is optional and may be either "kcs" for KCS, "smic" for
+SMIC, or "bt" for BT.  If not specified, it defaults to KCS.
+The <bmcx> values is either "p<port>" or "m<addr>" for port or memory
+addresses.  So for instance, a KCS interface at port 0xca2 using
+interrupt 9 and a SMIC memory interface at address 0xf9827341 with no
+interrupt would be specified "ipmi_si=k,p0xca2:9,s,m0xf9827341".  If you
+specify zero for in irq or don't specify it, the driver will run polled
+unless the software can detect the interrupt to use in the ACPI tables.
+
+By default, the driver will attempt to detect a KCS device at the
+spec-specified 0xca2 address and any address specified by ACPI.  If
+you want to turn this off, use the "nodefault" option.
+
+If you have high-res timers compiled into the kernel, the driver will
+use them to provide much better performance.  Note that if you do not
+have high-res timers enabled in the kernel and you don't have
+interrupts enabled, the driver will run VERY slowly.  Don't blame me,
+these interfaces suck.
+
+
 The KCS Driver
 --------------
 
drivers/char/ipmi/ipmi_bt_sm.c +511 -0

511 lines not on this page · raw message

drivers/char/ipmi/ipmi_si.c +2077 -0

2,077 lines not on this page · raw message

drivers/char/ipmi/ipmi_smic_sm.c +599 -0

319 lines not on this page · raw message

drivers/char/ipmi/Kconfig +11 -1
diff -urN linux-a1/drivers/char/ipmi/Kconfig linux-a2/drivers/char/ipmi/Kconfig

Lines of this file are not shown. View the raw message.

drivers/char/ipmi/Makefile +6 -0
diff -urN linux-a1/drivers/char/ipmi/Makefile linux-a2/drivers/char/ipmi/Makefile

Lines of this file are not shown. View the raw message.

The rest of this diff is not shown. View the raw message.

Part of the diff is not shown here. View the raw message.