In the art of computing, diagnostic codes are transmitted From processors. In some configurations, diagnostic codes are transmitted using relatively low-level mechanisms that allow codes to be transmitted without reliance on other components of the computer system, such as display devices or network interfaces.
The Figures depict examples, implementations, and configurations of the invention, and not the invention itself.
In the foregoing description, numerous details are set forth to provide an understanding of the examples disclosed herein. However, it will be understood by those skilled in the art that the examples ma be practiced without these details. While a limited number of examples have been disclosed, those skilled in the art. will appreciate numerous modifications and variations therefrom. It is intended that the appended claims cover such modifications and variations as fall within the true spirit and scope of the examples.
The examples provided herein relate to a method of outputting diagnostic codes. The various diagnostic codes are associated with access operations performed to a storage device, and a diagnostic code capture module monitors access operations performed between a processor and the storage device and infers transmitted diagnostic codes from the monitored. access operations.
In the art of computing, input and output (I/O) operations are performed using a variety of methods. One method provided by ×86 processors produced by Intel Corporation, Advanced Micro Devices, Incorporated, and other vendors, is port-mapped I/O. In contrast to memory-mapped I/O, which shares a common address space with memory, port-mapped I/O has a separate address space reserved for I/O operations. Two ×86 instructions that utilize port-mapped I/O are the IN and OUT instructions.
As initialization of a computer system begins, typically various ISO devices have not been initialized. However, there is a still a desire to observe diagnostic codes as the computer system is initialized, which typically comprises executing boot code from system firmware stored in an electrically erasable programmable read-only memory (EEPROM). From the early days of ×86 computers, diagnostic codes have been transmitted by sending the codes to ports, such as ports 80, 84, and 85.
Such diagnostic codes continue to he used in modem computer system. For example, a ProLiant DL580 server, which is a product of Hewlett-Packard Corporation, can output diagnostic codes using Port 85. Codes having a format of 3×h indicate processor-related errors, codes having a format of 4×h indicate memory-related errors, and codes having a format of 6×h indicate expansion board-related errors. Additional codes are also defined.
Early ×86 computers typically had an Industry Standard Architecture (ISA) bus, and a diagnostic display/capture card could be inserted into an ISA slot to capture or display diagnostic codes transmitted via I/O port access instruction. Similar functionality was achieved using the Peripheral Component Interconnect (PCI) buses found on later computers. ISA and PCI buses are parallel buses that provide access to the port addressing space, so diagnostic codes transmitted via port addresses may be observed at any PCI or ISA slot.
More recently, ISA and PCI buses are being replaced by Peripheral Component Interconnect Express (PCIe) buses. PCIe buses are not well suited for outputting diagnostic codes using port addresses for several reasons. First, often the PCIe topology is not initialized when a computer system begins initialization, and accordingly it may not be possible to output a diagnostic code to an uninitialized PCIe channel. Second, PCIe is a point-to-point protocol that includes a routing component. While port-mapped transactions may typically be observed at all ISA and PCI slots, a PCIe channel must be configured to route the port-mapped transactions to at particular PCIe slot.
In 1998 Intel Corporation introduced the Low Pin Count (LPC) bus to support low-bandwidth devices, such as an interface to system firmware, and ISO devices such as serial and parallel ports, keyboards, mice, floppy disk controller, and the like. To software executing on a computer system, the UPC bus resembles and ISA bus, and the LPC bus helped facilitate the removal of ISA buses from computer systems while still supporting legacy devices designed to operate using ISA buses.
The LPC bus continues to be popular in modern computer systems, and the LPC bus provides an excellent observation point for monitoring diagnostic codes transmitted from the processor. Furthermore, the LPC bus is functional and exposes diagnostic codes as soon as the processor begins the initialization process.
While the LPC bus is still often provided in many modem computer systems, it is anticipated that the LPC bus will be eventually phased out. It is also anticipated that future computer systems will no longer contain buses that facilitate observation of codes transmitted by a processor using port-mapped I/O.
Examples disclosed herein provide for diagnostic codes to be observed from a bus that is easily monitored and is functional when a computer system begins initialization. The bus discussed in the examples below is the bus between the processor and the storage device that stores system firmware. Since firmware must be read when the processor is initialized (e.g., after a power on sequence or after a reset sequence), the bus coupled to the device that stores the firmware is typically available. Rather than using port-mapped I/O, the examples disclosed herein use access operations to the storage device to represent diagnostic codes, as will be described in greater detail below.
Processor 12 includes execution units and other processor logic 32, and memory controller 34. Note that there has been a trend to integrate memory controllers into processors, with the processors providing the various signals required to access memory modules. Memory controller 34 is coupled to memory modules 14, which may store executable code 36 that transmits diagnostic codes. Note that in
I/O hub 16 is coupled to user I/O 18, which represents all user I/O, such as input devices, display devices, audio devices, various ports (such as USB ports) and the like, I/O hub 16 is also coupled to network port 20, which couples computer system 10 to a network, and persistent, non-transitory storage 22, which stores program code and data.
Recently, SPI interfaces have been deployed as the primary interface for coupling a system firmware EEPROM to a processor. For example, I/O hubs provided as part of Intel Series 5 chipsets include a dedicated SPI flash port that may be coupled to a system firmware EEPROM. The SPI link is configured and active during initialization since one of the first tasks that must be performed is to read boot code stored in the EEPROM.
An SPI bus may consist of four wires. However, one of the wires is at “Slave Select” which allows a master device to select a slave device for communication, and if an SPI bus is only used for communication between a pair of devices, the “Slave Select” may be tied to an active state. The remaining signals are “Serial Clock” (SCLK), “Master Output, Slave Input” (MOSI), and “Master Input, Slave Output” (MISO). To monitor memory access transactions from processor 12 of
The SCLK and MOSI signals are provided to observation point 28, which may comprise as connector, as shown in
Module 30 includes diagnostic code inference unit 38, which monitors the SCLK and MOSI signals and infers diagnostic codes my monitoring transactions carried by these signals. After unit 38 identifies a diagnostic code transmitted by processor 12 of
Additional options for encoding diagnostic codes using memory access operations are discussed below with reference to
Note that diagnostic code capture module 30 may be provided with an initialization signal, such as a reset sequence of SPI link or an independent signal not shown in
Returning to encoding diagnostic codes in memory transactions,
Since diagnostic codes have defined associations with memory access operations, the memory locations used to encode diagnostic codes should not be used for other purposes. One way to achieve this is to define a memory range for diagnostic codes outside the range used to store code 36 in EEPROM 24. Note that the memory access operation needs to be visible at observation point 28, and caching in I/O hub 16 or processor 12 may prevent the memory access operations from being visible. One way to address this issue is to mark the address range used for diagnostic code associations as uncacheable. Another way to address this issue is to clear all caches which may be caching data from EEPROM 24 before transmitting a diagnostic code.
Also note that prefetching operations of processor 12 or I/O hub 16 may affect diagnostic code assignments. For example, if a read to a single memory location always results in reading 256 bytes, memory locations corresponding to diagnostic codes should he spaced at least 256 bytes apart in memory. For example, a read from memory location 0×FFFF—0000 could be interpreted as a legacy I/O mapped write of ×00 to port 0×84, and a memory read from location 0×FFFF—0100 could be interpreted as a legacy I/O mapped write of 0×01 to port 0×84.
Note that it is not necessary to reserve is separate address range for creating assignments between patterns and diagnostic codes. All that is necessary is that the access pattern be a pattern that would not occur during normal operation. For example, normally processor 12 would not read a single memory location multiple times. Similarly, normally processor 12 would not read a series of memory locations in reverse program order, or a series of unrelated memory locations. By associating unique access patterns with diagnostic codes, processor 12 may transmit diagnostic codes to module 30 without reserving a dedicated address range.
The examples above illustrate how prior art diagnostic code transmission techniques can be adapted to support emerging computer architectures that do not have legacy buses. Existing firmware routines are easily modified by searching for code segments that transmit diagnostic codes using port-mapped I/O, and replacing those code segments with code segments that perform memory access operations to the system firmware EEPROM, as described above. Furthermore, only two SPI signals need to be monitored, so the examples discussed above minimize connector costs and pin counts.
In the foregoing description, numerous details are set forth to provide an understanding of the examples disclosed herein. However, it will be understood by those skilled in the art that the examples may be practiced without these details. While as limited number of examples have been disclosed, those skilled in the art will appreciate numerous modifications and variations therefrom. It is intended that the appended claims cover such modifications and variations as fall within the true spirit and scope of the disclosed examples.
Filing Document | Filing Date | Country | Kind | 371c Date |
---|---|---|---|---|
PCT/US2011/045990 | 7/29/2011 | WO | 00 | 1/10/2014 |