coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
hudson.h File Reference
#include <types.h>
#include <device/device.h>
Include dependency graph for hudson.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define PM_MMIO_BASE   0xfed80300
 
#define BIOSRAM_INDEX   0xcd4
 
#define BIOSRAM_DATA   0xcd5
 
#define PM_INDEX   0xcd6
 
#define PM_DATA   0xcd7
 
#define PM2_INDEX   0xcd0
 
#define PM2_DATA   0xcd1
 
#define PM_ACPI_MMIO_EN   0x24
 
#define PM_SERIRQ_CONF   0x54
 
#define PM_EVT_BLK   0x60
 
#define PM1_CNT_BLK   0x62
 
#define PM_TMR_BLK   0x64
 
#define PM_CPU_CTRL   0x66
 
#define PM_GPE0_BLK   0x68
 
#define PM_ACPI_SMI_CMD   0x6A
 
#define PM_ACPI_CONF   0x74
 
#define PM_PMIO_DEBUG   0xD2
 
#define PM_MANUAL_RESET   0xD3
 
#define PM_HUD_SD_FLASH_CTRL   0xE7
 
#define PM_YANG_SD_FLASH_CTRL   0xE8
 
#define PM_PCIB_CFG   0xEA
 
#define HUDSON_ACPI_IO_BASE   CONFIG_HUDSON_ACPI_IO_BASE
 
#define ACPI_PM_EVT_BLK   (HUDSON_ACPI_IO_BASE + 0x00) /* 4 bytes */
 
#define ACPI_PM1_CNT_BLK   (HUDSON_ACPI_IO_BASE + 0x04) /* 2 bytes */
 
#define ACPI_PM_TMR_BLK   (HUDSON_ACPI_IO_BASE + 0x18) /* 4 bytes */
 
#define ACPI_GPE0_BLK   (HUDSON_ACPI_IO_BASE + 0x10) /* 8 bytes */
 
#define ACPI_CPU_CONTROL   (HUDSON_ACPI_IO_BASE + 0x08) /* 6 bytes */
 
#define ACPI_SMI_CTL_PORT   0xb2
 
#define ACPI_SMI_CMD_CST_CONTROL   0xde
 
#define ACPI_SMI_CMD_PST_CONTROL   0xad
 
#define ACPI_SMI_CMD_DISABLE   0xbe
 
#define ACPI_SMI_CMD_ENABLE   0xef
 
#define ACPI_SMI_CMD_S4_REQ   0xc0
 
#define REV_HUDSON_A11   0x11
 
#define REV_HUDSON_A12   0x12
 
#define SPIROM_BASE_ADDRESS_REGISTER   0xA0
 
#define ROUTE_TPM_2_SPI   BIT(3)
 
#define SPI_ROM_ENABLE   0x02
 
#define SPI_BASE_ADDRESS   0xFEC10000
 
#define LPC_IO_PORT_DECODE_ENABLE   0x44
 
#define DECODE_ENABLE_PARALLEL_PORT0   BIT(0)
 
#define DECODE_ENABLE_PARALLEL_PORT1   BIT(1)
 
#define DECODE_ENABLE_PARALLEL_PORT2   BIT(2)
 
#define DECODE_ENABLE_PARALLEL_PORT3   BIT(3)
 
#define DECODE_ENABLE_PARALLEL_PORT4   BIT(4)
 
#define DECODE_ENABLE_PARALLEL_PORT5   BIT(5)
 
#define DECODE_ENABLE_SERIAL_PORT0   BIT(6)
 
#define DECODE_ENABLE_SERIAL_PORT1   BIT(7)
 
#define DECODE_ENABLE_SERIAL_PORT2   BIT(8)
 
#define DECODE_ENABLE_SERIAL_PORT3   BIT(9)
 
#define DECODE_ENABLE_SERIAL_PORT4   BIT(10)
 
#define DECODE_ENABLE_SERIAL_PORT5   BIT(11)
 
#define DECODE_ENABLE_SERIAL_PORT6   BIT(12)
 
#define DECODE_ENABLE_SERIAL_PORT7   BIT(13)
 
#define DECODE_ENABLE_AUDIO_PORT0   BIT(14)
 
#define DECODE_ENABLE_AUDIO_PORT1   BIT(15)
 
#define DECODE_ENABLE_AUDIO_PORT2   BIT(16)
 
#define DECODE_ENABLE_AUDIO_PORT3   BIT(17)
 
#define DECODE_ENABLE_MIDI_PORT0   BIT(18)
 
#define DECODE_ENABLE_MIDI_PORT1   BIT(19)
 
#define DECODE_ENABLE_MIDI_PORT2   BIT(20)
 
#define DECODE_ENABLE_MIDI_PORT3   BIT(21)
 
#define DECODE_ENABLE_MSS_PORT0   BIT(22)
 
#define DECODE_ENABLE_MSS_PORT1   BIT(23)
 
#define DECODE_ENABLE_MSS_PORT2   BIT(24)
 
#define DECODE_ENABLE_MSS_PORT3   BIT(25)
 
#define DECODE_ENABLE_FDC_PORT0   BIT(26)
 
#define DECODE_ENABLE_FDC_PORT1   BIT(27)
 
#define DECODE_ENABLE_GAME_PORT   BIT(28)
 
#define DECODE_ENABLE_KBC_PORT   BIT(29)
 
#define DECODE_ENABLE_ACPIUC_PORT   BIT(30)
 
#define DECODE_ENABLE_ADLIB_PORT   BIT(31)
 
#define LPC_IO_OR_MEM_DECODE_ENABLE   0x48
 
#define LPC_WIDEIO2_ENABLE   BIT(25)
 
#define LPC_WIDEIO1_ENABLE   BIT(24)
 
#define LPC_WIDEIO0_ENABLE   BIT(2)
 
#define LPC_WIDEIO_GENERIC_PORT   0x64
 
#define LPC_ALT_WIDEIO_RANGE_ENABLE   0x74
 
#define LPC_ALT_WIDEIO2_ENABLE   BIT(3)
 
#define LPC_ALT_WIDEIO1_ENABLE   BIT(2)
 
#define LPC_ALT_WIDEIO0_ENABLE   BIT(0)
 
#define LPC_TRUSTED_PLATFORM_MODULE   0x7c
 
#define TPM_12_EN   BIT(0)
 
#define TPM_LEGACY_EN   BIT(2)
 
#define LPC_WIDEIO2_GENERIC_PORT   0x90
 
#define SPI_CNTRL0   0x00
 
#define SPI_READ_MODE_MASK   (BIT(30) | BIT(29) | BIT(18))
 
#define SPI_READ_MODE_NOM   0x00000000
 
#define SPI_READ_MODE_DUAL112   ( BIT(29) )
 
#define SPI_READ_MODE_QUAD114   ( BIT(29) | BIT(18))
 
#define SPI_READ_MODE_DUAL122   (BIT(30) )
 
#define SPI_READ_MODE_QUAD144   (BIT(30) | BIT(18))
 
#define SPI_READ_MODE_NORMAL66   (BIT(30) | BIT(29) )
 
#define SPI_READ_MODE_FAST_HUDSON1   ( BIT(18))
 
#define SPI_READ_MODE_FAST   (BIT(30) | BIT(29) | BIT(18))
 
#define SPI_ARB_ENABLE   BIT(19)
 
#define SPI_CNTRL1   0x0c
 
#define SPI_CNTRL1_SPEED_MASK   (BIT(15) | BIT(14) | BIT(13) | BIT(12))
 
#define SPI_NORM_SPEED_SH   12
 
#define SPI_FAST_SPEED_SH   8
 
#define SPI100_ENABLE   0x20
 
#define SPI_USE_SPI100   BIT(0)
 
#define SPI100_SPEED_CONFIG   0x22
 
#define SPI_SPEED_66M   (0x0)
 
#define SPI_SPEED_33M   ( BIT(0))
 
#define SPI_SPEED_22M   ( BIT(1) )
 
#define SPI_SPEED_16M   ( BIT(1) | BIT(0))
 
#define SPI_SPEED_100M   (BIT(2) )
 
#define SPI_SPEED_800K   (BIT(2) | BIT(0))
 
#define SPI_NORM_SPEED_NEW_SH   12
 
#define SPI_FAST_SPEED_NEW_SH   8
 
#define SPI_ALT_SPEED_NEW_SH   4
 
#define SPI_TPM_SPEED_NEW_SH   0
 
#define SPI100_HOST_PREF_CONFIG   0x2c
 
#define SPI_RD4DW_EN_HOST   BIT(15)
 

Functions

static int hudson_sata_enable (void)
 
static int hudson_ide_enable (void)
 
void hudson_lpc_port80 (void)
 
void hudson_lpc_decode (void)
 
void hudson_pci_port80 (void)
 
void hudson_clk_output_48Mhz (void)
 
void hudson_read_mode (u32 mode)
 
void hudson_set_spi100 (u16 norm, u16 fast, u16 alt, u16 tpm)
 
void hudson_disable_4dw_burst (void)
 
void hudson_set_readspeed (u16 norm, u16 fast)
 
void lpc_wideio_512_window (uint16_t base)
 
void lpc_wideio_16_window (uint16_t base)
 
void hudson_tpm_decode_spi (void)
 
void hudson_enable (struct device *dev)
 
void s3_resume_init_data (void *FchParams)
 

Macro Definition Documentation

◆ ACPI_CPU_CONTROL

#define ACPI_CPU_CONTROL   (HUDSON_ACPI_IO_BASE + 0x08) /* 6 bytes */

Definition at line 43 of file hudson.h.

◆ ACPI_GPE0_BLK

#define ACPI_GPE0_BLK   (HUDSON_ACPI_IO_BASE + 0x10) /* 8 bytes */

Definition at line 42 of file hudson.h.

◆ ACPI_PM1_CNT_BLK

#define ACPI_PM1_CNT_BLK   (HUDSON_ACPI_IO_BASE + 0x04) /* 2 bytes */

Definition at line 40 of file hudson.h.

◆ ACPI_PM_EVT_BLK

#define ACPI_PM_EVT_BLK   (HUDSON_ACPI_IO_BASE + 0x00) /* 4 bytes */

Definition at line 39 of file hudson.h.

◆ ACPI_PM_TMR_BLK

#define ACPI_PM_TMR_BLK   (HUDSON_ACPI_IO_BASE + 0x18) /* 4 bytes */

Definition at line 41 of file hudson.h.

◆ ACPI_SMI_CMD_CST_CONTROL

#define ACPI_SMI_CMD_CST_CONTROL   0xde

Definition at line 46 of file hudson.h.

◆ ACPI_SMI_CMD_DISABLE

#define ACPI_SMI_CMD_DISABLE   0xbe

Definition at line 48 of file hudson.h.

◆ ACPI_SMI_CMD_ENABLE

#define ACPI_SMI_CMD_ENABLE   0xef

Definition at line 49 of file hudson.h.

◆ ACPI_SMI_CMD_PST_CONTROL

#define ACPI_SMI_CMD_PST_CONTROL   0xad

Definition at line 47 of file hudson.h.

◆ ACPI_SMI_CMD_S4_REQ

#define ACPI_SMI_CMD_S4_REQ   0xc0

Definition at line 50 of file hudson.h.

◆ ACPI_SMI_CTL_PORT

#define ACPI_SMI_CTL_PORT   0xb2

Definition at line 45 of file hudson.h.

◆ BIOSRAM_DATA

#define BIOSRAM_DATA   0xcd5

Definition at line 17 of file hudson.h.

◆ BIOSRAM_INDEX

#define BIOSRAM_INDEX   0xcd4

Definition at line 16 of file hudson.h.

◆ DECODE_ENABLE_ACPIUC_PORT

#define DECODE_ENABLE_ACPIUC_PORT   BIT(30)

Definition at line 91 of file hudson.h.

◆ DECODE_ENABLE_ADLIB_PORT

#define DECODE_ENABLE_ADLIB_PORT   BIT(31)

Definition at line 92 of file hudson.h.

◆ DECODE_ENABLE_AUDIO_PORT0

#define DECODE_ENABLE_AUDIO_PORT0   BIT(14)

Definition at line 75 of file hudson.h.

◆ DECODE_ENABLE_AUDIO_PORT1

#define DECODE_ENABLE_AUDIO_PORT1   BIT(15)

Definition at line 76 of file hudson.h.

◆ DECODE_ENABLE_AUDIO_PORT2

#define DECODE_ENABLE_AUDIO_PORT2   BIT(16)

Definition at line 77 of file hudson.h.

◆ DECODE_ENABLE_AUDIO_PORT3

#define DECODE_ENABLE_AUDIO_PORT3   BIT(17)

Definition at line 78 of file hudson.h.

◆ DECODE_ENABLE_FDC_PORT0

#define DECODE_ENABLE_FDC_PORT0   BIT(26)

Definition at line 87 of file hudson.h.

◆ DECODE_ENABLE_FDC_PORT1

#define DECODE_ENABLE_FDC_PORT1   BIT(27)

Definition at line 88 of file hudson.h.

◆ DECODE_ENABLE_GAME_PORT

#define DECODE_ENABLE_GAME_PORT   BIT(28)

Definition at line 89 of file hudson.h.

◆ DECODE_ENABLE_KBC_PORT

#define DECODE_ENABLE_KBC_PORT   BIT(29)

Definition at line 90 of file hudson.h.

◆ DECODE_ENABLE_MIDI_PORT0

#define DECODE_ENABLE_MIDI_PORT0   BIT(18)

Definition at line 79 of file hudson.h.

◆ DECODE_ENABLE_MIDI_PORT1

#define DECODE_ENABLE_MIDI_PORT1   BIT(19)

Definition at line 80 of file hudson.h.

◆ DECODE_ENABLE_MIDI_PORT2

#define DECODE_ENABLE_MIDI_PORT2   BIT(20)

Definition at line 81 of file hudson.h.

◆ DECODE_ENABLE_MIDI_PORT3

#define DECODE_ENABLE_MIDI_PORT3   BIT(21)

Definition at line 82 of file hudson.h.

◆ DECODE_ENABLE_MSS_PORT0

#define DECODE_ENABLE_MSS_PORT0   BIT(22)

Definition at line 83 of file hudson.h.

◆ DECODE_ENABLE_MSS_PORT1

#define DECODE_ENABLE_MSS_PORT1   BIT(23)

Definition at line 84 of file hudson.h.

◆ DECODE_ENABLE_MSS_PORT2

#define DECODE_ENABLE_MSS_PORT2   BIT(24)

Definition at line 85 of file hudson.h.

◆ DECODE_ENABLE_MSS_PORT3

#define DECODE_ENABLE_MSS_PORT3   BIT(25)

Definition at line 86 of file hudson.h.

◆ DECODE_ENABLE_PARALLEL_PORT0

#define DECODE_ENABLE_PARALLEL_PORT0   BIT(0)

Definition at line 61 of file hudson.h.

◆ DECODE_ENABLE_PARALLEL_PORT1

#define DECODE_ENABLE_PARALLEL_PORT1   BIT(1)

Definition at line 62 of file hudson.h.

◆ DECODE_ENABLE_PARALLEL_PORT2

#define DECODE_ENABLE_PARALLEL_PORT2   BIT(2)

Definition at line 63 of file hudson.h.

◆ DECODE_ENABLE_PARALLEL_PORT3

#define DECODE_ENABLE_PARALLEL_PORT3   BIT(3)

Definition at line 64 of file hudson.h.

◆ DECODE_ENABLE_PARALLEL_PORT4

#define DECODE_ENABLE_PARALLEL_PORT4   BIT(4)

Definition at line 65 of file hudson.h.

◆ DECODE_ENABLE_PARALLEL_PORT5

#define DECODE_ENABLE_PARALLEL_PORT5   BIT(5)

Definition at line 66 of file hudson.h.

◆ DECODE_ENABLE_SERIAL_PORT0

#define DECODE_ENABLE_SERIAL_PORT0   BIT(6)

Definition at line 67 of file hudson.h.

◆ DECODE_ENABLE_SERIAL_PORT1

#define DECODE_ENABLE_SERIAL_PORT1   BIT(7)

Definition at line 68 of file hudson.h.

◆ DECODE_ENABLE_SERIAL_PORT2

#define DECODE_ENABLE_SERIAL_PORT2   BIT(8)

Definition at line 69 of file hudson.h.

◆ DECODE_ENABLE_SERIAL_PORT3

#define DECODE_ENABLE_SERIAL_PORT3   BIT(9)

Definition at line 70 of file hudson.h.

◆ DECODE_ENABLE_SERIAL_PORT4

#define DECODE_ENABLE_SERIAL_PORT4   BIT(10)

Definition at line 71 of file hudson.h.

◆ DECODE_ENABLE_SERIAL_PORT5

#define DECODE_ENABLE_SERIAL_PORT5   BIT(11)

Definition at line 72 of file hudson.h.

◆ DECODE_ENABLE_SERIAL_PORT6

#define DECODE_ENABLE_SERIAL_PORT6   BIT(12)

Definition at line 73 of file hudson.h.

◆ DECODE_ENABLE_SERIAL_PORT7

#define DECODE_ENABLE_SERIAL_PORT7   BIT(13)

Definition at line 74 of file hudson.h.

◆ HUDSON_ACPI_IO_BASE

#define HUDSON_ACPI_IO_BASE   CONFIG_HUDSON_ACPI_IO_BASE

Definition at line 38 of file hudson.h.

◆ LPC_ALT_WIDEIO0_ENABLE

#define LPC_ALT_WIDEIO0_ENABLE   BIT(0)

Definition at line 104 of file hudson.h.

◆ LPC_ALT_WIDEIO1_ENABLE

#define LPC_ALT_WIDEIO1_ENABLE   BIT(2)

Definition at line 103 of file hudson.h.

◆ LPC_ALT_WIDEIO2_ENABLE

#define LPC_ALT_WIDEIO2_ENABLE   BIT(3)

Definition at line 102 of file hudson.h.

◆ LPC_ALT_WIDEIO_RANGE_ENABLE

#define LPC_ALT_WIDEIO_RANGE_ENABLE   0x74

Definition at line 101 of file hudson.h.

◆ LPC_IO_OR_MEM_DECODE_ENABLE

#define LPC_IO_OR_MEM_DECODE_ENABLE   0x48

Definition at line 94 of file hudson.h.

◆ LPC_IO_PORT_DECODE_ENABLE

#define LPC_IO_PORT_DECODE_ENABLE   0x44

Definition at line 60 of file hudson.h.

◆ LPC_TRUSTED_PLATFORM_MODULE

#define LPC_TRUSTED_PLATFORM_MODULE   0x7c

Definition at line 106 of file hudson.h.

◆ LPC_WIDEIO0_ENABLE

#define LPC_WIDEIO0_ENABLE   BIT(2)

Definition at line 97 of file hudson.h.

◆ LPC_WIDEIO1_ENABLE

#define LPC_WIDEIO1_ENABLE   BIT(24)

Definition at line 96 of file hudson.h.

◆ LPC_WIDEIO2_ENABLE

#define LPC_WIDEIO2_ENABLE   BIT(25)

Definition at line 95 of file hudson.h.

◆ LPC_WIDEIO2_GENERIC_PORT

#define LPC_WIDEIO2_GENERIC_PORT   0x90

Definition at line 110 of file hudson.h.

◆ LPC_WIDEIO_GENERIC_PORT

#define LPC_WIDEIO_GENERIC_PORT   0x64

Definition at line 99 of file hudson.h.

◆ PM1_CNT_BLK

#define PM1_CNT_BLK   0x62

Definition at line 26 of file hudson.h.

◆ PM2_DATA

#define PM2_DATA   0xcd1

Definition at line 21 of file hudson.h.

◆ PM2_INDEX

#define PM2_INDEX   0xcd0

Definition at line 20 of file hudson.h.

◆ PM_ACPI_CONF

#define PM_ACPI_CONF   0x74

Definition at line 31 of file hudson.h.

◆ PM_ACPI_MMIO_EN

#define PM_ACPI_MMIO_EN   0x24

Definition at line 23 of file hudson.h.

◆ PM_ACPI_SMI_CMD

#define PM_ACPI_SMI_CMD   0x6A

Definition at line 30 of file hudson.h.

◆ PM_CPU_CTRL

#define PM_CPU_CTRL   0x66

Definition at line 28 of file hudson.h.

◆ PM_DATA

#define PM_DATA   0xcd7

Definition at line 19 of file hudson.h.

◆ PM_EVT_BLK

#define PM_EVT_BLK   0x60

Definition at line 25 of file hudson.h.

◆ PM_GPE0_BLK

#define PM_GPE0_BLK   0x68

Definition at line 29 of file hudson.h.

◆ PM_HUD_SD_FLASH_CTRL

#define PM_HUD_SD_FLASH_CTRL   0xE7

Definition at line 34 of file hudson.h.

◆ PM_INDEX

#define PM_INDEX   0xcd6

Definition at line 18 of file hudson.h.

◆ PM_MANUAL_RESET

#define PM_MANUAL_RESET   0xD3

Definition at line 33 of file hudson.h.

◆ PM_MMIO_BASE

#define PM_MMIO_BASE   0xfed80300

Definition at line 13 of file hudson.h.

◆ PM_PCIB_CFG

#define PM_PCIB_CFG   0xEA

Definition at line 36 of file hudson.h.

◆ PM_PMIO_DEBUG

#define PM_PMIO_DEBUG   0xD2

Definition at line 32 of file hudson.h.

◆ PM_SERIRQ_CONF

#define PM_SERIRQ_CONF   0x54

Definition at line 24 of file hudson.h.

◆ PM_TMR_BLK

#define PM_TMR_BLK   0x64

Definition at line 27 of file hudson.h.

◆ PM_YANG_SD_FLASH_CTRL

#define PM_YANG_SD_FLASH_CTRL   0xE8

Definition at line 35 of file hudson.h.

◆ REV_HUDSON_A11

#define REV_HUDSON_A11   0x11

Definition at line 52 of file hudson.h.

◆ REV_HUDSON_A12

#define REV_HUDSON_A12   0x12

Definition at line 53 of file hudson.h.

◆ ROUTE_TPM_2_SPI

#define ROUTE_TPM_2_SPI   BIT(3)

Definition at line 56 of file hudson.h.

◆ SPI100_ENABLE

#define SPI100_ENABLE   0x20

Definition at line 132 of file hudson.h.

◆ SPI100_HOST_PREF_CONFIG

#define SPI100_HOST_PREF_CONFIG   0x2c

Definition at line 147 of file hudson.h.

◆ SPI100_SPEED_CONFIG

#define SPI100_SPEED_CONFIG   0x22

Definition at line 135 of file hudson.h.

◆ SPI_ALT_SPEED_NEW_SH

#define SPI_ALT_SPEED_NEW_SH   4

Definition at line 144 of file hudson.h.

◆ SPI_ARB_ENABLE

#define SPI_ARB_ENABLE   BIT(19)

Definition at line 124 of file hudson.h.

◆ SPI_BASE_ADDRESS

#define SPI_BASE_ADDRESS   0xFEC10000

Definition at line 58 of file hudson.h.

◆ SPI_CNTRL0

#define SPI_CNTRL0   0x00

Definition at line 112 of file hudson.h.

◆ SPI_CNTRL1

#define SPI_CNTRL1   0x0c

Definition at line 126 of file hudson.h.

◆ SPI_CNTRL1_SPEED_MASK

#define SPI_CNTRL1_SPEED_MASK   (BIT(15) | BIT(14) | BIT(13) | BIT(12))

Definition at line 128 of file hudson.h.

◆ SPI_FAST_SPEED_NEW_SH

#define SPI_FAST_SPEED_NEW_SH   8

Definition at line 143 of file hudson.h.

◆ SPI_FAST_SPEED_SH

#define SPI_FAST_SPEED_SH   8

Definition at line 130 of file hudson.h.

◆ SPI_NORM_SPEED_NEW_SH

#define SPI_NORM_SPEED_NEW_SH   12

Definition at line 142 of file hudson.h.

◆ SPI_NORM_SPEED_SH

#define SPI_NORM_SPEED_SH   12

Definition at line 129 of file hudson.h.

◆ SPI_RD4DW_EN_HOST

#define SPI_RD4DW_EN_HOST   BIT(15)

Definition at line 148 of file hudson.h.

◆ SPI_READ_MODE_DUAL112

#define SPI_READ_MODE_DUAL112   ( BIT(29) )

Definition at line 116 of file hudson.h.

◆ SPI_READ_MODE_DUAL122

#define SPI_READ_MODE_DUAL122   (BIT(30) )

Definition at line 118 of file hudson.h.

◆ SPI_READ_MODE_FAST

#define SPI_READ_MODE_FAST   (BIT(30) | BIT(29) | BIT(18))

Definition at line 123 of file hudson.h.

◆ SPI_READ_MODE_FAST_HUDSON1

#define SPI_READ_MODE_FAST_HUDSON1   ( BIT(18))

Definition at line 122 of file hudson.h.

◆ SPI_READ_MODE_MASK

#define SPI_READ_MODE_MASK   (BIT(30) | BIT(29) | BIT(18))

Definition at line 113 of file hudson.h.

◆ SPI_READ_MODE_NOM

#define SPI_READ_MODE_NOM   0x00000000

Definition at line 115 of file hudson.h.

◆ SPI_READ_MODE_NORMAL66

#define SPI_READ_MODE_NORMAL66   (BIT(30) | BIT(29) )

Definition at line 120 of file hudson.h.

◆ SPI_READ_MODE_QUAD114

#define SPI_READ_MODE_QUAD114   ( BIT(29) | BIT(18))

Definition at line 117 of file hudson.h.

◆ SPI_READ_MODE_QUAD144

#define SPI_READ_MODE_QUAD144   (BIT(30) | BIT(18))

Definition at line 119 of file hudson.h.

◆ SPI_ROM_ENABLE

#define SPI_ROM_ENABLE   0x02

Definition at line 57 of file hudson.h.

◆ SPI_SPEED_100M

#define SPI_SPEED_100M   (BIT(2) )

Definition at line 140 of file hudson.h.

◆ SPI_SPEED_16M

#define SPI_SPEED_16M   ( BIT(1) | BIT(0))

Definition at line 139 of file hudson.h.

◆ SPI_SPEED_22M

#define SPI_SPEED_22M   ( BIT(1) )

Definition at line 138 of file hudson.h.

◆ SPI_SPEED_33M

#define SPI_SPEED_33M   ( BIT(0))

Definition at line 137 of file hudson.h.

◆ SPI_SPEED_66M

#define SPI_SPEED_66M   (0x0)

Definition at line 136 of file hudson.h.

◆ SPI_SPEED_800K

#define SPI_SPEED_800K   (BIT(2) | BIT(0))

Definition at line 141 of file hudson.h.

◆ SPI_TPM_SPEED_NEW_SH

#define SPI_TPM_SPEED_NEW_SH   0

Definition at line 145 of file hudson.h.

◆ SPI_USE_SPI100

#define SPI_USE_SPI100   BIT(0)

Definition at line 133 of file hudson.h.

◆ SPIROM_BASE_ADDRESS_REGISTER

#define SPIROM_BASE_ADDRESS_REGISTER   0xA0

Definition at line 55 of file hudson.h.

◆ TPM_12_EN

#define TPM_12_EN   BIT(0)

Definition at line 107 of file hudson.h.

◆ TPM_LEGACY_EN

#define TPM_LEGACY_EN   BIT(2)

Definition at line 108 of file hudson.h.

Function Documentation

◆ hudson_clk_output_48Mhz()

void hudson_clk_output_48Mhz ( void  )

Definition at line 179 of file early_setup.c.

◆ hudson_disable_4dw_burst()

void hudson_disable_4dw_burst ( void  )

Definition at line 222 of file early_setup.c.

References base, hudson_spibase(), read16(), SPI100_HOST_PREF_CONFIG, SPI_RD4DW_EN_HOST, and write16().

Here is the call graph for this function:

◆ hudson_enable()

◆ hudson_ide_enable()

static int hudson_ide_enable ( void  )
inlinestatic

Definition at line 156 of file hudson.h.

◆ hudson_lpc_decode()

void hudson_lpc_decode ( void  )

Definition at line 68 of file early_setup.c.

References DECODE_ENABLE_SERIAL_PORT0, DECODE_ENABLE_SERIAL_PORT1, DECODE_ENABLE_SERIAL_PORT5, DECODE_ENABLE_SERIAL_PORT7, LPC_IO_PORT_DECODE_ENABLE, PCI_DEV, pci_write_config32(), pm_read8(), and pm_write8().

Referenced by bootblock_early_southbridge_init().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hudson_lpc_port80()

void hudson_lpc_port80 ( void  )

Definition at line 57 of file early_setup.c.

References PCI_DEV, pci_read_config8(), and pci_write_config8().

Referenced by bootblock_early_southbridge_init(), and bootblock_mainboard_early_init().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hudson_pci_port80()

void hudson_pci_port80 ( void  )

Definition at line 12 of file early_setup.c.

References PCI_DEV, pci_read_config8(), and pci_write_config8().

Referenced by bootblock_early_southbridge_init().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hudson_read_mode()

void hudson_read_mode ( u32  mode)

Definition at line 241 of file early_setup.c.

References base, hudson_spibase(), read32(), SPI_CNTRL0, SPI_READ_MODE_MASK, and write32().

Here is the call graph for this function:

◆ hudson_sata_enable()

static int hudson_sata_enable ( void  )
inlinestatic

Definition at line 150 of file hudson.h.

◆ hudson_set_readspeed()

void hudson_set_readspeed ( u16  norm,
u16  fast 
)

Definition at line 231 of file early_setup.c.

References base, hudson_spibase(), read16(), SPI_CNTRL1, SPI_CNTRL1_SPEED_MASK, SPI_FAST_SPEED_SH, SPI_NORM_SPEED_SH, and write16().

Here is the call graph for this function:

◆ hudson_set_spi100()

void hudson_set_spi100 ( u16  norm,
u16  fast,
u16  alt,
u16  tpm 
)

◆ hudson_tpm_decode_spi()

void hudson_tpm_decode_spi ( void  )

Definition at line 249 of file early_setup.c.

References PCI_DEV, pci_read_config32(), pci_write_config32(), ROUTE_TPM_2_SPI, and SPIROM_BASE_ADDRESS_REGISTER.

Here is the call graph for this function:

◆ lpc_wideio_16_window()

void lpc_wideio_16_window ( uint16_t  base)

Definition at line 173 of file early_setup.c.

References assert, base, IS_ALIGNED, and lpc_wideio_window().

Here is the call graph for this function:

◆ lpc_wideio_512_window()

void lpc_wideio_512_window ( uint16_t  base)

Definition at line 167 of file early_setup.c.

References assert, base, IS_ALIGNED, and lpc_wideio_window().

Here is the call graph for this function:

◆ s3_resume_init_data()

void s3_resume_init_data ( void FchParams)