Skip to content

Commit

Permalink
Merge pull request #9 from macpijan/logs-menu-merge_usb
Browse files Browse the repository at this point in the history
Restore logs, boot-menu-message, merge usb
  • Loading branch information
pietrushnic authored Aug 1, 2016
2 parents d1c4141 + 6e700a6 commit 9039bd4
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 13 deletions.
2 changes: 1 addition & 1 deletion src/mainboard/pcengines/apu2/boot-menu-message
Original file line number Diff line number Diff line change
@@ -1 +1 @@
PCengines Press F10 key now for boot menu:
Press F10 key now for boot menu, N for PXE boot
16 changes: 8 additions & 8 deletions src/mainboard/pcengines/apu2/bootorder_map
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
a USB 1 SS
b USB 2 SS
c USB 1 HS
d USB 2 HS
e SDCARD
f mSATA
g SATA
h iPXE
a USB 1 / USB 2 SS and HS
a USB 1 / USB 2 SS and HS
a USB 1 / USB 2 SS and HS
a USB 1 / USB 2 SS and HS
b SDCARD
c mSATA
d SATA
e iPXE
16 changes: 12 additions & 4 deletions src/mainboard/pcengines/apu2/mainboard.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@
#include <cbfs_core.h>
#include <spd_cache.h>

static bool check_console(void);

/**********************************************
* enable the dedicated function in mainboard.
**********************************************/
Expand All @@ -54,10 +56,14 @@ static void mainboard_enable(device_t dev)
{
struct device *sio_dev;

bool scon = check_console();
setup_bsp_ramtop();
u32 TOM1 = bsp_topmem() / (1024 *1024); // Tom1 in Mbyte
u32 TOM2 = ( bsp_topmem2() / (1024 *1024)) - 4 * 1024; // Tom2 in Mbyte
printk(BIOS_ERR, "%d MB", TOM1+TOM2);
if (scon) {
printk(BIOS_ALERT, CONFIG_MAINBOARD_PART_NUMBER "\n");
printk(BIOS_ALERT, "%d MB", TOM1+TOM2);
}

u8 spd_buffer[SPD_SIZE];
int index = 0;
Expand All @@ -66,13 +72,15 @@ static void mainboard_enable(device_t dev)

if ( ReadFchGpio(APU2_SPD_STRAP0_GPIO) ) index |= BIT0;
if ( ReadFchGpio(APU2_SPD_STRAP1_GPIO) ) index |= BIT1;

printk(BIOS_SPEW, "Reading SPD index %d to get ECC info \n", index);
if (read_spd_from_cbfs(spd_buffer, index) < 0)
spd_buffer[3]=3; // Indicate no ECC

if ( spd_buffer[3] == 8 ) printk(BIOS_ERR, " ECC");
printk(BIOS_ERR, " DRAM\n\n");
if (scon) {
if ( spd_buffer[3] == 8 ) printk(BIOS_ALERT, " ECC");
printk(BIOS_ALERT, " DRAM\n\n");
}

//
// Enable the RTC output
Expand Down

0 comments on commit 9039bd4

Please sign in to comment.