![]() |
coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
|
#include <amdblocks/pci_devs.h>
#include <device/pci_ops.h>
#include <soc/pci_devs.h>
#include <stdint.h>
Go to the source code of this file.
Macros | |
#define | BROADCAST_FABRIC_ID 0xff |
#define | D18F0_MMIO_BASE0 0x200 |
#define | D18F0_MMIO_LIMIT0 0x204 |
#define | D18F0_MMIO_SHIFT 16 |
#define | D18F0_MMIO_CTRL0 0x208 |
#define | DF_MMIO_DST_FABRIC_ID_SHIFT 4 |
#define | DF_MMIO_WE BIT(1) |
#define | DF_MMIO_RE BIT(0) |
#define | NB_MMIO_BASE(reg) ((reg) * 4 * sizeof(uint32_t) + D18F0_MMIO_BASE0) |
#define | NB_MMIO_LIMIT(reg) ((reg) * 4 * sizeof(uint32_t) + D18F0_MMIO_LIMIT0) |
#define | NB_MMIO_CONTROL(reg) ((reg) * 4 * sizeof(uint32_t) + D18F0_MMIO_CTRL0) |
Functions | |
uint32_t | data_fabric_read32 (uint8_t function, uint16_t reg, uint8_t instance_id) |
void | data_fabric_write32 (uint8_t function, uint16_t reg, uint8_t instance_id, uint32_t data) |
static __always_inline uint32_t | data_fabric_broadcast_read32 (uint8_t function, uint16_t reg) |
static __always_inline void | data_fabric_broadcast_write32 (uint8_t function, uint16_t reg, uint32_t data) |
void | data_fabric_print_mmio_conf (void) |
void | data_fabric_disable_mmio_reg (unsigned int reg) |
int | data_fabric_find_unused_mmio_reg (void) |
#define BROADCAST_FABRIC_ID 0xff |
Definition at line 11 of file data_fabric.h.
#define D18F0_MMIO_BASE0 0x200 |
Definition at line 14 of file data_fabric.h.
#define D18F0_MMIO_CTRL0 0x208 |
Definition at line 17 of file data_fabric.h.
#define D18F0_MMIO_LIMIT0 0x204 |
Definition at line 15 of file data_fabric.h.
#define D18F0_MMIO_SHIFT 16 |
Definition at line 16 of file data_fabric.h.
#define DF_MMIO_DST_FABRIC_ID_SHIFT 4 |
Definition at line 19 of file data_fabric.h.
#define DF_MMIO_RE BIT(0) |
Definition at line 21 of file data_fabric.h.
#define DF_MMIO_WE BIT(1) |
Definition at line 20 of file data_fabric.h.
#define NB_MMIO_BASE | ( | reg | ) | ((reg) * 4 * sizeof(uint32_t) + D18F0_MMIO_BASE0) |
Definition at line 24 of file data_fabric.h.
#define NB_MMIO_CONTROL | ( | reg | ) | ((reg) * 4 * sizeof(uint32_t) + D18F0_MMIO_CTRL0) |
Definition at line 26 of file data_fabric.h.
#define NB_MMIO_LIMIT | ( | reg | ) | ((reg) * 4 * sizeof(uint32_t) + D18F0_MMIO_LIMIT0) |
Definition at line 25 of file data_fabric.h.
|
static |
Definition at line 32 of file data_fabric.h.
References _SOC_DEV, DF_DEV, and pci_read_config32().
Referenced by data_fabric_print_mmio_conf(), data_fabric_read32(), data_fabric_set_mmio_np(), and is_mmio_reg_disabled().
|
static |
Definition at line 39 of file data_fabric.h.
References _SOC_DEV, DF_DEV, and pci_write_config32().
Referenced by data_fabric_disable_mmio_reg(), data_fabric_set_mmio_np(), and data_fabric_write32().
Definition at line 63 of file data_fabric_helper.c.
References data_fabric_broadcast_write32(), DF_MMIO_DST_FABRIC_ID_SHIFT, IOMS0_FABRIC_ID, NB_MMIO_BASE, NB_MMIO_CONTROL, and NB_MMIO_LIMIT.
Referenced by data_fabric_set_mmio_np().
int data_fabric_find_unused_mmio_reg | ( | void | ) |
Definition at line 77 of file data_fabric_helper.c.
References is_mmio_reg_disabled(), and NUM_NB_MMIO_REGS.
Referenced by data_fabric_set_mmio_np().
Definition at line 48 of file data_fabric_helper.c.
References BIOS_SPEW, data_fabric_broadcast_read32(), NB_MMIO_BASE, NB_MMIO_CONTROL, NB_MMIO_LIMIT, NUM_NB_MMIO_REGS, and printk.
Referenced by data_fabric_set_mmio_np().
Definition at line 24 of file data_fabric_helper.c.
References BROADCAST_FABRIC_ID, data_fabric_broadcast_read32(), data_fabric_set_indirect_address(), DF_FICAD_LO, pci_read_config32(), and SOC_DF_F4_DEV.
Referenced by gen_crat_memory_entries().
Definition at line 36 of file data_fabric_helper.c.
References BROADCAST_FABRIC_ID, data_fabric_broadcast_write32(), data_fabric_set_indirect_address(), DF_FICAD_LO, pci_write_config32(), and SOC_DF_F4_DEV.