coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
mainboard.c File Reference
#include <device/device.h>
#include <libbdk-hal/bdk-config.h>
#include <libbdk-hal/bdk-twsi.h>
#include <soc/twsi.h>
#include <soc/gpio.h>
#include <delay.h>
#include <soc/uart.h>
#include <console/console.h>
#include <soc/clock.h>
#include <soc/timer.h>
#include <soc/cpu.h>
#include <soc/sdram.h>
Include dependency graph for mainboard.c:

Go to the source code of this file.

Functions

static void mainboard_print_info (void)
 
static void mainboard_init (struct device *dev)
 
static void mainboard_enable (struct device *dev)
 

Variables

const struct bdk_devicetree_key_value devtree []
 
struct chip_operations mainboard_ops
 

Function Documentation

◆ mainboard_enable()

static void mainboard_enable ( struct device dev)
static

The following hardware magically starts working after toggling GPIO_10_PHY_RESET_L:

  • SATA PHY
  • GBE PHY
  • XFI PHY
  • MMC

Definition at line 81 of file mainboard.c.

References bdk_twsix_write_ia(), devtree, gpio_output(), I2C_SPEED_STANDARD, device_operations::init, mainboard_init(), mainboard_print_info(), mdelay(), device::ops, twsi_init(), and udelay().

Here is the call graph for this function:

◆ mainboard_init()

static void mainboard_init ( struct device dev)
static

Definition at line 69 of file mainboard.c.

References NULL, soc_timer_init(), and start_cpu().

Referenced by mainboard_enable().

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

◆ mainboard_print_info()

static void mainboard_print_info ( void  )
static

Definition at line 20 of file mainboard.c.

References BIOS_INFO, cpu_get_num_available_cores(), gpio_strap_value(), printk, sdram_size_mb(), thunderx_get_core_clock(), thunderx_get_io_clock(), and thunderx_get_ref_clock().

Referenced by mainboard_enable().

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

Variable Documentation

◆ devtree

const struct bdk_devicetree_key_value devtree[]
extern

Definition at line 1 of file bdk_devicetree.c.

Referenced by mainboard_enable().

◆ mainboard_ops

struct chip_operations mainboard_ops
Initial value:
= {
.enable_dev = mainboard_enable,
}
static void mainboard_enable(struct device *dev)
Definition: mainboard.c:81

Definition at line 81 of file mainboard.c.