mirror of
https://github.com/fail0verflow/switch-coreboot.git
synced 2025-05-04 01:39:18 -04:00
- VIA VT8235: Do the shift in smbus_read_byte() as all other chipsets do. - spd.h: Move RC00-RC63 #defines here, they were duplicated in lots of romstage.c files and lots of spd_addr.h files. Don't even bother for those spd_addr.h which aren't even actually used, drop them right away. - Replace various 0x50 hardcoded numbers with DIMM0, 0x51 with DIMM1, and 0xa0 with (DIMM0 << 1) where appropriate. - Various debug.c files: Replace SMBUS_MEM_DEVICE_START with DIMM0, SMBUS_MEM_DEVICE_END with DIMM7, and drop useless SMBUS_MEM_DEVICE_INC. - VIA VX800: Drop unused SMBUS_ADDR_CH* #defines. - VIA VT8623: Do the shift in smbus_read_byte() as all other chipsets do. Then, replace 0xa0 (which now becomes 0x50) with DIMM0. - alix1c/romstage.c, alix2d/romstage.c: Adapt to recent bit shift changes. - Various files: Drop DIMM_SPD_BASE and/or replace it with DIMM0. Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de> Acked-by: Patrick Georgi <patrick@georgi-clan.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@6100 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
38 lines
731 B
C
38 lines
731 B
C
#include "raminit.h"
|
|
|
|
void dump_spd_registers(void)
|
|
{
|
|
#if CONFIG_DEBUG_RAM_SETUP
|
|
int i;
|
|
print_debug("\n");
|
|
for(i = 0; i < DIMM_SOCKETS; i++) {
|
|
unsigned device;
|
|
device = DIMM0 + i;
|
|
if (device) {
|
|
int j;
|
|
print_debug("dimm: ");
|
|
print_debug_hex8(i);
|
|
print_debug(".0: ");
|
|
print_debug_hex8(device);
|
|
for(j = 0; j < 256; j++) {
|
|
int status;
|
|
unsigned char byte;
|
|
if ((j & 0xf) == 0) {
|
|
print_debug("\n");
|
|
print_debug_hex8(j);
|
|
print_debug(": ");
|
|
}
|
|
status = smbus_read_byte(device, j);
|
|
if (status < 0) {
|
|
print_debug("bad device\n");
|
|
break;
|
|
}
|
|
byte = status & 0xff;
|
|
print_debug_hex8(byte);
|
|
print_debug_char(' ');
|
|
}
|
|
print_debug("\n");
|
|
}
|
|
}
|
|
#endif
|
|
}
|