coreboot.git
12 years agoAdd -Werror to xcompile's testcc
Stefan Reinauer [Tue, 25 Oct 2011 19:28:40 +0000 (12:28 -0700)]
Add -Werror to xcompile's testcc

If -Werror is not specified, tests for certain compiler flags
will emit a warning, which makes the build break since we compile
with -Werror.

Change-Id: I7be56530ff9f94e5500bad226c83e47145a808d7
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/336
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoFix libpayload speaker driver
Stefan Reinauer [Tue, 25 Oct 2011 21:15:57 +0000 (14:15 -0700)]
Fix libpayload speaker driver

The frequency for the PC speaker has to be specified as
1193180 / frequency according to http://wiki.osdev.org/PC_Speaker

Change-Id: Iaca9d45807e080efe834611e719b350680b5fb90
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/337
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoX60: enable Cx power saving modes
Sven Schnelle [Sun, 23 Oct 2011 14:57:50 +0000 (16:57 +0200)]
X60: enable Cx power saving modes

Change-Id: Ib03d9aa77050edde2538b80b32158cb3f0610be6
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/331
Tested-by: build bot (Jenkins)
12 years agoT60: add _CST table
Sven Schnelle [Sat, 22 Oct 2011 11:41:28 +0000 (13:41 +0200)]
T60: add _CST table

Used by power management code to enable Cx powersaving modes.

Change-Id: I02c6b10762245bc48f21a341286236e203421de0
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/322
Tested-by: build bot (Jenkins)
12 years agoT60: enable C4onC3 mode
Sven Schnelle [Sun, 23 Oct 2011 14:36:22 +0000 (16:36 +0200)]
T60: enable C4onC3 mode

It is safe to enable this setting on these Boards.

Change-Id: Iaa7377117743d18a95c496c25abf9fb4a1b20ad9
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/330
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoT60: use ICS954309 clock driver
Sven Schnelle [Sun, 23 Oct 2011 13:54:31 +0000 (15:54 +0200)]
T60: use ICS954309 clock driver

Change-Id: I3f30fe601215784e1688c5ec51108dc0cf03e320
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/328
Tested-by: build bot (Jenkins)
12 years agoAdd driver for ICS954309 clock generator
Sven Schnelle [Sun, 23 Oct 2011 13:53:47 +0000 (15:53 +0200)]
Add driver for ICS954309 clock generator

Change-Id: Iac7e91cdd995dad1954eaa2d4dd52bffa293fc95
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/327
Tested-by: build bot (Jenkins)
12 years agoi82801gx: Add setting for C4onC3 mode
Sven Schnelle [Sun, 23 Oct 2011 14:35:01 +0000 (16:35 +0200)]
i82801gx: Add setting for C4onC3 mode

If this bit is set, ich7 will enter C4 mode if possible instead of
C3. See ich7 specification (LPC controller, Power management control
registers) for more details.

Change-Id: I352cccdbc51ff6269f153a4542c7ee1df0c01d22
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/329
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoSPEEDSTEP: write _CST tables
Sven Schnelle [Sat, 22 Oct 2011 11:41:16 +0000 (13:41 +0200)]
SPEEDSTEP: write _CST tables

Change-Id: Idb4b57044808918de343d31519768d0986840f01
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/321
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoACPI: Add function for writing _CST tables
Sven Schnelle [Fri, 21 Oct 2011 19:46:47 +0000 (21:46 +0200)]
ACPI: Add function for writing _CST tables

Change-Id: I4e16a0d37717c56a3529f9f9fdb05efec1d93f99
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/312
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agow83627hf: correct typo in ASL include, correct indexed registers and remove unneccesa...
Christoph Grenz [Wed, 19 Oct 2011 00:24:23 +0000 (02:24 +0200)]
w83627hf: correct typo in ASL include, correct indexed registers and remove unneccesary _PR0 defs

Correct a typo in devtree.asl which causes AML processors to fail executing
the DSDT with AE_NO_MEMORY or (in case of acpiexec) Divide By Zero.
Also removes an superfluous item in the register IndexField and removes
unneccessary _PR0 definitions which could confuse AML processors.

Change-Id: I02cb9ce4e8f2101cfff8cec4abba7e070fd66364
Signed-off-by: Christoph Grenz <christophg+cb@grenz-bonn.de>
Reviewed-on: http://review.coreboot.org/296
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoLenovo H8: Fix h8_set_audio_mute()
Sven Schnelle [Tue, 25 Oct 2011 13:29:47 +0000 (15:29 +0200)]
Lenovo H8: Fix h8_set_audio_mute()

Logic is inverted (if argument is true, one would expect that
mute is enabled) and the wrong bit was used (1 instead 0)

Change-Id: I71133ba639f1fb0d3c3582f16211dd266a11cc64
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/334
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoX60/T60: remove superflous h8_set_audio_mute()
Sven Schnelle [Tue, 25 Oct 2011 13:31:26 +0000 (15:31 +0200)]
X60/T60: remove superflous h8_set_audio_mute()

muting is handled by h8 code, no need to do it here.

Change-Id: I3f152e99f30701cd032b03105cbe3ae778865305
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/335
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoi82801gx: Add write and read/write block functions
Sven Schnelle [Sun, 23 Oct 2011 13:36:15 +0000 (15:36 +0200)]
i82801gx: Add write and read/write block functions

Change-Id: Icbfc47a8d7bfe1600e4212b26e99b2a604de9ef7
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/326
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoVarious fixes to cbfstool.
Stefan Reinauer [Fri, 21 Oct 2011 21:24:57 +0000 (14:24 -0700)]
Various fixes to cbfstool.

- add ntohll and htonll (as coreboot parses 64bit fields now)
- use the same byte swapping code across platforms
- detect endianess early
- fix lots of warnings
- Don't override CFLAGS in Makefile

Change-Id: Iaea02ff7a31ab6a95fd47858d0efd9af764a3e5f
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/313
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoi82801gx: Don't set I/O base address to static value
Sven Schnelle [Sun, 23 Oct 2011 13:30:29 +0000 (15:30 +0200)]
i82801gx: Don't set I/O base address to static value

Doing it this way will break all subsequent smbus calls, because
the smbus code still uses res->base, which points to the old base
address. Fix this by allocating a proper resource.

Change-Id: I0f3d8fba5f8e2db7fe4ca991ef2c345aff436ea4
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/325
Reviewed-by: Rudolf Marek <r.marek@assembler.cz>
Tested-by: build bot (Jenkins)
12 years agoFILO: Pass LIBCONFIG_PATH variable to FILOs make
Thomas Gstädtner [Fri, 21 Oct 2011 20:01:32 +0000 (22:01 +0200)]
FILO: Pass LIBCONFIG_PATH variable to FILOs make

This fixes the build for HEAD/master.
Current stable will not work, because it is too old for recent corboot.

Change-Id: I9dfd5de472d4f58f07147cb9b9bb0b543f228561
Signed-off-by: Thomas Gstädtner <thomas@gstaedtner.net>
Reviewed-on: http://review.coreboot.org/311
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoAllow XGCCPATH to be set on the make command line.
Marc Jones [Fri, 7 Oct 2011 23:20:30 +0000 (17:20 -0600)]
Allow XGCCPATH to be set on the make command line.

The xgcc toolchain may be moved by the user and passed in on the commandline. Updates the Makefile and the xcompile script.

Change-Id: I05797b2cabce39bdd7868c2515f30d34043fc8cc
Signed-off-by: Marc Jones <marcj303@gmail.com>
Reviewed-on: http://review.coreboot.org/318
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoconsole: support integrated 7-segment displays for POST codes
Christoph Grenz [Sun, 18 Sep 2011 20:54:51 +0000 (22:54 +0200)]
console: support integrated 7-segment displays for POST codes

Add a configuration option POST_PORT which defaults to 0x80 and
can be redefined by boards which have integrated POST displays
on another I/O port. Change post.c to output POST codes to this
port instead of 0x80 hardcoded.

Change-Id: I8f8e820f8c75641b35e7249bf622b63a3604b9f3
Signed-off-by: Christoph Grenz <christophg+cb@grenz-bonn.de>
Reviewed-on: http://review.coreboot.org/221
Tested-by: build bot (Jenkins)
Reviewed-by: Rudolf Marek <r.marek@assembler.cz>
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoSB800: Hide unused gpp ports
Kerry Sheh [Wed, 12 Oct 2011 04:06:23 +0000 (12:06 +0800)]
SB800: Hide unused gpp ports

Add configure option SB_GPP_UNHIDE_PORTS for mainboard
to hide/unhide the unused sb800 gpp ports.
Certain gpp port should be hidden, if no device was detected and
hotplug feature is disabled for such port.
Hidden unused ports makes lspci -vvv get more accurate information under Linux.
Test on avalue/eax-785e mainboard.

Change-Id: I1d7df0f2ab6ad69b1b99b8bf046411ae7cdb09c0
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/207
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoFix CMOS checksum calculation in libpayload.
Stefan Reinauer [Fri, 21 Oct 2011 21:37:52 +0000 (14:37 -0700)]
Fix CMOS checksum calculation in libpayload.

Change-Id: I64ea53fa098fbcfc76e0ebd5f049a2ee3d0a1024
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/314
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoAdd ifdtool, utility to read / modify Intel Firmware Descriptor images
Stefan Reinauer [Fri, 14 Oct 2011 19:49:41 +0000 (12:49 -0700)]
Add ifdtool, utility to read / modify Intel Firmware Descriptor images

Change-Id: Ie78b97bf573d238d0dff9a663e774deb1b7dea44
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/272
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agonvramtool: Fix CMOS checksum to match coreboot (and /dev/nvram)
Stefan Reinauer [Mon, 17 Oct 2011 15:58:27 +0000 (08:58 -0700)]
nvramtool: Fix CMOS checksum to match coreboot (and /dev/nvram)

Change-Id: I28b0dbad36403a31be83581107f40b3ca1332dcc
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/287
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoExtend coreboot table entry for serial ports
Stefan Reinauer [Wed, 22 Jun 2011 23:39:19 +0000 (16:39 -0700)]
Extend coreboot table entry for serial ports

Add information about memory mapped/io mapped base addresses.

and fix up libpayload to use the same structures

Signed-off-by: Stefan Reinauer <reinauer@google.com>
Change-Id: I5f7b5eda6063261b9acb7a46310172d4a5471dfb
Reviewed-on: http://review.coreboot.org/261
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoRemove redunancy in Kconfig
Kyösti Mälkki [Fri, 21 Oct 2011 15:41:44 +0000 (18:41 +0300)]
Remove redunancy in Kconfig

Socket Kconfig unconditionally selects CPU_INTEL_CORE.

Change-Id: I5eb7dd17047a2a031dd7345390d7f5f756055e18
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: http://review.coreboot.org/307
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoFILO: Change FILO Makefile.inc from SVN to GIT
Thomas Gstädtner [Fri, 21 Oct 2011 15:40:42 +0000 (17:40 +0200)]
FILO: Change FILO Makefile.inc from SVN to GIT

This commit replaces the old svn checkout code for the external FILO
payload with a git checkout for the new repo on gerrit.
The stable checkout is implemented similarly to the former SVN variant,
it checks out a specific commit (same commit as svn r136 which was
checked out before).
The HEAD checkout gets the master branch from
http://review.coreboot.org/p/filo.git
In future this should probably be changed to a stable tag or repo.
It is necessary to remove the old svn checkout by hand (or run
distclean), because I did not include code to remove an existing svn
FILO checkout.

Change-Id: I08a703f3428ae7b987f7079a4901be4cf6d7e505
Signed-off-by: Thomas Gstädtner <thomas@gstaedtner.net>
Reviewed-on: http://review.coreboot.org/308
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agolibpayload: fix bulk transfers on OHCI controllers
Patrick Georgi [Fri, 21 Oct 2011 13:45:09 +0000 (15:45 +0200)]
libpayload: fix bulk transfers on OHCI controllers

Time for the brown paper bag: OHCI controllers are not happy when
told to send data, but with obviously wrong addresses. It helps
to write the addresses into the data structures.

Change-Id: Ic0967dc8939e64af119cfb89400a045a2c077171
Signed-off-by: Patrick Georgi <patrick.georgi@secunet.com>
Reviewed-on: http://review.coreboot.org/306
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agosch: strip quotes around cmc.bin filename
Patrick Georgi [Fri, 21 Oct 2011 11:56:04 +0000 (13:56 +0200)]
sch: strip quotes around cmc.bin filename

This was mentioned several times already, how about we get it in?
It avoids cbfstool to fail because path/to/"file" doesn't work.

Change-Id: Ia01acbd78f81a5db890fd1573a2f3cbe1450562f
Signed-off-by: Patrick Georgi <patrick.georgi@secunet.com>
Reviewed-on: http://review.coreboot.org/305
Tested-by: build bot (Jenkins)
Reviewed-by: Peter Stuge <peter@stuge.se>
12 years agoUse ntohll where appropriate.
Stefan Reinauer [Mon, 17 Oct 2011 16:51:15 +0000 (09:51 -0700)]
Use ntohll where appropriate.

also clean out a local copy of ntohl in yabel.

Change-Id: Iffe85a53c9ea25abeb3ac663870eb7eb4874a704
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/288
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoAdd macros for 64bit byte order swapping
Stefan Reinauer [Fri, 14 Oct 2011 22:11:16 +0000 (15:11 -0700)]
Add macros for 64bit byte order swapping

Change-Id: Ic31ccd41ba3e0af7046eafc29221810d4cd196c8
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/275
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoT60: Add support for Ultrabay Legacy I/O devices (40Y8122)
Sven Schnelle [Sat, 15 Oct 2011 15:31:01 +0000 (17:31 +0200)]
T60: Add support for Ultrabay Legacy I/O devices (40Y8122)

Those modules have basically the same Super I/O capabilities as
the Docking station. Unfortunately, the Super I/O in the module
shares the same I/O address as the Docking station, so we're not
allowed to connect the LPC Docking Bus if such a module is present.

To be able to detect this device and use it as early console for
coreboot, we have to initialize the GPIO Controller before, as
this device is detected via GPIO06.

Change-Id: If7c38bb6797f76cf28f09f3614ab9a33878571fb
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/282
Tested-by: build bot (Jenkins)
12 years agoi82801dx: Replace romstage printk's
Kyösti Mälkki [Mon, 17 Oct 2011 14:37:45 +0000 (17:37 +0300)]
i82801dx: Replace romstage printk's

Patch is required to compile this with romcc.

Change-Id: I5c4c0f5b32e5edeb8c48d8455b3493ca79f8b452
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: http://review.coreboot.org/291
Tested-by: build bot (Jenkins)
Reviewed-by: Peter Stuge <peter@stuge.se>
12 years agoasrock/e350m1: Enable the superio ACPI device in devicetree.cb
Peter Stuge [Tue, 18 Oct 2011 03:10:36 +0000 (05:10 +0200)]
asrock/e350m1: Enable the superio ACPI device in devicetree.cb

This makes the power_on_after_fail NVRAM option work correctly.

Change-Id: I96f05f82d7f133b343cf8d4ef09db50a3db7a83d
Signed-off-by: Peter Stuge <peter@stuge.se>
Reviewed-on: http://review.coreboot.org/292
Tested-by: build bot (Jenkins)
12 years agoIOAPIC: fix bitmask
Kyösti Mälkki [Wed, 19 Oct 2011 04:23:51 +0000 (07:23 +0300)]
IOAPIC: fix bitmask

APIC ID is bits 27..24, not 19..16.

Change-Id: Ib53a480bf4328901094ca2c4713e8317321962a1
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: http://review.coreboot.org/299
Tested-by: build bot (Jenkins)
Reviewed-by: Peter Stuge <peter@stuge.se>
12 years agosconfig: check whether component directory actually exists
Stefan Reinauer [Fri, 14 Oct 2011 19:41:46 +0000 (12:41 -0700)]
sconfig: check whether component directory actually exists

and add drivers/generic/generic back (empty), since it is used by many
devicetree.cb files.

Without this patch typos in component names in devicetree.cb cause
the component to be silently ignored.

Change-Id: I3cfca2725816f0cd7d72139ae53af815009e8ab4
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/270
Tested-by: build bot (Jenkins)
Reviewed-by: Peter Stuge <peter@stuge.se>
12 years agoDrop eh_frame instead of moving it into the image.
Stefan Reinauer [Fri, 14 Oct 2011 17:29:21 +0000 (10:29 -0700)]
Drop eh_frame instead of moving it into the image.

That's what SeaBIOS does, too, and it works just fine.

Change-Id: I3e17c15848aca86f775fc86f4ad906c820625887
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/269
Tested-by: build bot (Jenkins)
Reviewed-by: Peter Stuge <peter@stuge.se>
12 years agoI945: replace #if defined() by #if
Sven Schnelle [Tue, 18 Oct 2011 05:58:10 +0000 (07:58 +0200)]
I945: replace #if defined() by #if

config.h defines also unset config options (as "0") so #ifdef
matches both settings, which isn't what we want.

Change-Id: I694e1b8a8ec4c20225d7af1a13a2a336f900e643
Signed-off-by: Sven Schnelle <svens@stackframe.org>
Reviewed-on: http://review.coreboot.org/293
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoAppend logical PME/GPIO device. Fix MPU device number.
Kyösti Mälkki [Sun, 16 Oct 2011 15:12:59 +0000 (18:12 +0300)]
Append logical PME/GPIO device. Fix MPU device number.

A mainboard may require configuration of the superio pins to fully
support some features. Things like A20# gate, leds, fans, infra-red
and bootstrap jumpers may be configured and controlled through the
logical PME device.

Change-Id: I6e77ff0295806ba3dff339013f73d99c2961388f
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: http://review.coreboot.org/289
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoActivate older Xeon P4 microcodes
Kyösti Mälkki [Mon, 17 Oct 2011 14:10:03 +0000 (17:10 +0300)]
Activate older Xeon P4 microcodes

As new microcode files were included, the table was not updated with
families 0f25 and 0f26.

Change-Id: I5bb8be9d7c37eb8406dcb48a4b933eab24639bda
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: http://review.coreboot.org/290
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoFix our CMOS checksum algorithm so it matches what /dev/nvram expects
Stefan Reinauer [Fri, 14 Oct 2011 22:24:03 +0000 (15:24 -0700)]
Fix our CMOS checksum algorithm so it matches what /dev/nvram expects

Our cmos checksum is inverted to what the Linux /dev/nvram device expects (and
BIOSes use). This makes it impossible to use /dev/nvram with coreboot. Fix it!

Change-Id: I239f7e3aca05d3691aee16490dd801df2ccaefd1
Signed-off-by: Vadim Bendebury <vbendeb@google.com>
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/279
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agorework RTC driver output to make it more consistent.
Stefan Reinauer [Fri, 14 Oct 2011 22:22:52 +0000 (15:22 -0700)]
rework RTC driver output to make it more consistent.

Also add a meaningful define (Not hooked up in Kconfig, that might
or might not follow)

Change-Id: I9cc4bca0d23d75e6a1d767932ec62e8c68b39d71
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/278
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agocbfstool: improve error messages
Stefan Reinauer [Fri, 14 Oct 2011 19:44:14 +0000 (12:44 -0700)]
cbfstool: improve error messages

If a file can't be added by cbfstool, print the type and name of the file
in the error message.

Change-Id: I369d6f5be09ec53ee5beea2cfea65a80407f0ba3
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/271
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoRe-worked devicetree.cb for DL145 G1
Oskar Enoksson [Tue, 4 Oct 2011 20:34:11 +0000 (22:34 +0200)]
Re-worked devicetree.cb for DL145 G1

After a lot of experimentation this commit improves some hardware
features that were not recognized or incorrectly configured before.
The only thing not tested is SCSI-option board (I dont have one).
Misleading errors in comments have been corrected.
(Note BTW that the DL145 G1 mainboard is identical to AMD Serenade
which was supported in early versions of coreboot but was dropped
for some reason.)

Signed-off-by: Oskar Enoksson <enok@lysator.liu.se>
Change-Id: Ibbd97fafad22196b1e18d0b257731490339f113e
Reviewed-on: http://review.coreboot.org/237
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoFixes several issues with amd k8 SSDT P-state generation
Oskar Enoksson [Thu, 6 Oct 2011 16:43:43 +0000 (18:43 +0200)]
Fixes several issues with amd k8 SSDT P-state generation

First issue fixed:
For multi-socket CPU the current implementation emitted
Processor objects for cores in the first CPU only. This
commit fixes the bug by really emitting one Processor
object for each core. However, the unlikely case of mixed
CPU models is still not handled correctly.

Second issue fixed:
One loop was wrong in case a processor in the table declares
no P-states at all. The rewritten loop is safe. Some possibly
dangerous array lengths were also fixed.

Third issue: on MP-boards the recommended ramp-voltage (RVO) is 0mV
according to the BKDG. The current implementation always set it
to 25mV. This commit selects 0 or 25mV depending on CONFIG_MAX_PHYSICAL_CPUS.

Fourth issue: If a processor without PowerNow! support was inserted in a
system with coreboot configured with SET_FIDVID then the boot process hanged
mysteriously and very early. Apparently because init_fidvid_ap tampers with
non-existing registers. This commit fixes the bug by bailing out
from init_fidvid_ap if PowerNow! capability is missing.

Signed-off-by: Oskar Enoksson <enok@lysator.liu.se>
Change-Id: I61f6e2210b84ccba33a36c5efc866447b7134417
Reviewed-on: http://review.coreboot.org/239
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoSMM: Move wbinvd after pmode jump
Stefan Reinauer [Sat, 15 Oct 2011 18:23:04 +0000 (11:23 -0700)]
SMM: Move wbinvd after pmode jump

According to Rudolf Marek putting a memory instruction between
the CR0 write and the jmp in protected mode switching might hang the
machine. Move it after the jmp.

There might be a better solution for this, such as enabling the cache, as
keeping it disabled does not prevent cache poisoning attacks, so there is no
real point.

However, Intel docs say that SMM code in ASEG is always running uncached, so
we might want to consider running SMM out of TSEG instead, as well.

Signed-off-by: Stefan Reinauer <reinauer@google.com>
Change-Id: Id396acf3c8a79a9f1abcc557af6e0cce099955ec
Reviewed-on: http://review.coreboot.org/283
Reviewed-by: Sven Schnelle <svens@stackframe.org>
Tested-by: build bot (Jenkins)
12 years agouse byteorder.h instead of implementing another byte swap function
Stefan Reinauer [Fri, 14 Oct 2011 22:19:21 +0000 (15:19 -0700)]
use byteorder.h instead of implementing another byte swap function

Change-Id: Id5fe7b597256ddf5d4ef408ec82cd94d84e7a0cd
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/277
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoAMD CPU and chipset fixes for compilation with gcc 4.6
Stefan Reinauer [Fri, 14 Oct 2011 00:04:02 +0000 (17:04 -0700)]
AMD CPU and chipset fixes for compilation with gcc 4.6

Change-Id: I05b08765b38d8d6cc9b7cbdaf87c127b33408c81
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/266
Tested-by: build bot (Jenkins)
Reviewed-by: Uwe Hermann <uwe@hermann-uwe.de>
12 years agouse acpi.h include instead of manually adding acpi_slp_type.
Stefan Reinauer [Fri, 14 Oct 2011 22:18:29 +0000 (15:18 -0700)]
use acpi.h include instead of manually adding acpi_slp_type.

Change-Id: I2a3aaf10e453fa6cce8a993356f2a0587178209a
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/276
Tested-by: build bot (Jenkins)
Reviewed-by: Uwe Hermann <uwe@hermann-uwe.de>
12 years agocbfs_and_run_core() is not part of the API, make it static.
Stefan Reinauer [Fri, 14 Oct 2011 21:50:19 +0000 (14:50 -0700)]
cbfs_and_run_core() is not part of the API, make it static.

It's only used in cbfs_and_run.c

Change-Id: Ibcfcefbeb0c5722eb3888f0d60127229a2badcf6
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/273
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
Tested-by: build bot (Jenkins)
12 years agoreformat Makefile.bootblock.inc (>80 lines per char)
Stefan Reinauer [Fri, 14 Oct 2011 22:09:25 +0000 (15:09 -0700)]
reformat Makefile.bootblock.inc (>80 lines per char)

Change-Id: I0ff02fa72ff5a14d8c166686bb3d66fe1e887ea4
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/274
Tested-by: build bot (Jenkins)
Reviewed-by: Uwe Hermann <uwe@hermann-uwe.de>
12 years agoFix AMD SB800 (cimx) southbridge code to compile with gcc 4.6
Stefan Reinauer [Fri, 14 Oct 2011 00:26:43 +0000 (17:26 -0700)]
Fix AMD SB800 (cimx) southbridge code to compile with gcc 4.6

Change-Id: I672135a9b6e3b641ceb655cb00d40ee760c17edc
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/268
Tested-by: build bot (Jenkins)
Reviewed-by: Uwe Hermann <uwe@hermann-uwe.de>
12 years agoFix compilation of AMD GX2 northbridge code with gcc 4.6
Stefan Reinauer [Fri, 14 Oct 2011 00:26:10 +0000 (17:26 -0700)]
Fix compilation of AMD GX2 northbridge code with gcc 4.6

Change-Id: I71d96b7cd36dd99a3590ec311c11f67f13012e68
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/267
Tested-by: build bot (Jenkins)
Reviewed-by: Uwe Hermann <uwe@hermann-uwe.de>
12 years agoFix compilation of VIA CN700 northbridge code with gcc 4.6
Stefan Reinauer [Fri, 14 Oct 2011 00:03:04 +0000 (17:03 -0700)]
Fix compilation of VIA CN700 northbridge code with gcc 4.6

Change-Id: Ia52d21c5c467ec08bc7b958ee1a8e37e7d3e025b
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/265
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agofix compilation of intel/sch northbridge code with gcc 4.6
Stefan Reinauer [Thu, 13 Oct 2011 23:53:11 +0000 (16:53 -0700)]
fix compilation of intel/sch northbridge code with gcc 4.6

Change-Id: I57804dff9e37f0127900ebb7a67118382944eb89
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/264
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoAdd eh_frame to rom section to fix compilation of coreboot with gcc 4.6
Stefan Reinauer [Thu, 13 Oct 2011 23:52:27 +0000 (16:52 -0700)]
Add eh_frame to rom section to fix compilation of coreboot with gcc 4.6

Change-Id: I347dd84a61244eed145c02a080309d5a34c5394a
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/263
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoPrevent build breakage without consoles enabled
Stefan Reinauer [Wed, 1 Jun 2011 21:04:50 +0000 (14:04 -0700)]
Prevent build breakage without consoles enabled

If all console types are disabled, coreboot will fail to compile because
static code is unused. This patch fixes the issue.

Signed-off-by: Stefan Reinauer <reinauer@google.com>
Change-Id: Ie9c8bf2a78e3aeba4c2908b06bc03f0f5af37db2
Reviewed-on: http://review.coreboot.org/260
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoLoad an IDT with NULL limit
Stefan Reinauer [Wed, 1 Jun 2011 21:01:46 +0000 (14:01 -0700)]
Load an IDT with NULL limit

Load an IDT with NULL limit to prevent the 16bit IDT being used
in protected mode before c_start.S sets up a 32bit IDT when entering
ram stage.

Signed-off-by: Stefan Reinauer <reinauer@google.com>
Change-Id: I8d048c894c863ac4971fcef8f065be6b899e1d3e
Reviewed-on: http://review.coreboot.org/259
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoFix compilation of x86emu with gcc 4.6.x
Stefan Reinauer [Tue, 4 Oct 2011 17:34:37 +0000 (10:34 -0700)]
Fix compilation of x86emu with gcc 4.6.x

gcc 4.6 complains about unused but set variables in x86emu.
Particularly some variables are always set but only used in
debug mode, or when FPU support is enabled.

Change-Id: Ic53bd2303171ab717eb2d2c0ed72744d3eb6989e
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/258
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoFix native x86 option rom initialization
Stefan Reinauer [Wed, 12 Oct 2011 21:35:54 +0000 (14:35 -0700)]
Fix native x86 option rom initialization

- Intel option roms want an initialized i8259 or they will
  throw an exception 6. This should be done in the southbridge
  code, but that is executed much later than the VGA init, so
  initialize the i8259 in src/devices/oprom/x86.c.
  In the long run this will allow getting rid of some of the
  ugly hacks in some AMD boards' romstage.c
- Don't overwrite the mode when copying mode info information back
  from 0x600.

Change-Id: Idb01f13dbcd736d8d830b222ffe1ea85799fcd9c
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/257
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agorefactor vesa mode setting code and bootsplash code
Stefan Reinauer [Wed, 12 Oct 2011 21:30:59 +0000 (14:30 -0700)]
refactor vesa mode setting code and bootsplash code

- adds possibility to set a vesa mode without showing a bootsplash
- make bootsplash / mode setting code available in real mode.

Change-Id: I0045c9d75757657f4ce531889593102ea1e39ce5
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/256
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoRefactor option rom initialization code in coreboot.
Stefan Reinauer [Wed, 12 Oct 2011 21:25:07 +0000 (14:25 -0700)]
Refactor option rom initialization code in coreboot.

- move int15 handler out of the generic code into the mainboard directories
  of those mainboards that actually use it.
- move vbe headers to vbe.h
- move function prototypes used in native oprom code to x86.h

Change-Id: Idfff5e804ea328f7b5feebac72497c97329320ee
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/255
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoEnable/fix compilation of i8254 code in ram stage.
Stefan Reinauer [Tue, 27 Sep 2011 23:26:05 +0000 (16:26 -0700)]
Enable/fix compilation of i8254 code in ram stage.

Change-Id: I3bbe795d8e6e576be9e94d6cd888e78a116ddbbd
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/254
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoUpdate "STABLE" SeaBIOS selection to release 1.6.3
Stefan Reinauer [Wed, 12 Oct 2011 21:05:49 +0000 (14:05 -0700)]
Update "STABLE" SeaBIOS selection to release 1.6.3

1.6.3 has a lot of benefits over the previous version, the two
most important being:
 - working AHCI support
 - compiles with gcc 4.6.x

Change-Id: Ie3a4d8f2624e0aa85e48ca09da53474c085838db
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/253
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoUse default table creator macro for all SSDTs
Stefan Reinauer [Wed, 12 Oct 2011 23:18:29 +0000 (01:18 +0200)]
Use default table creator macro for all SSDTs

Change-Id: I0c138ebfdc6d4d5ae7d3512b0dd68df20485690e
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/262
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoFix romstage creation with gcc 4.6 and CAR targets
Stefan Reinauer [Wed, 12 Oct 2011 19:54:08 +0000 (12:54 -0700)]
Fix romstage creation with gcc 4.6 and CAR targets

newer gcc versions generate ".section .text" instead of just ".text"
in their assembler output. This patch makes sure that we don't end up
with a superfluous ".section" that makes the build fail.

Add -Wno-unused-but-set-variable to CFLAGS if the flag exists.

Change-Id: I7f24c987433cc5886dde2af27498d3331cbda303
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/252
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agosiemens/sitemp_g1p1: Don't mess with virtual wire settings
Patrick Georgi [Thu, 6 Oct 2011 13:24:08 +0000 (15:24 +0200)]
siemens/sitemp_g1p1: Don't mess with virtual wire settings

That function broke SMP on Linux 2.4, now it works.

Change-Id: I4ddd25fef57bed64877959ca96cca68170042bca
Signed-off-by: Patrick Georgi <patrick.georgi@secunet.com>
Reviewed-on: http://review.coreboot.org/243
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agosiemens/sitemp_g1p1: Get rid of bus_isa and bus_type
Patrick Georgi [Thu, 6 Oct 2011 12:34:22 +0000 (14:34 +0200)]
siemens/sitemp_g1p1: Get rid of bus_isa and bus_type

Each variable is essentially unused or incorrect.

Change-Id: I4d2a10c9b45306ac6e6026a31765d3b912fd855c
Signed-off-by: Patrick Georgi <patrick.georgi@secunet.com>
Reviewed-on: http://review.coreboot.org/242
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoamd/sb600: Enable COM2 at all times in early setup
Patrick Georgi [Fri, 7 Oct 2011 12:43:27 +0000 (14:43 +0200)]
amd/sb600: Enable COM2 at all times in early setup

Otherwise with a coreboot log on COM2 (which doesn't work) the boot
process takes eons.

Change-Id: I886f98b715c1f384c8693f2977671ff15897b5a5
Signed-off-by: Patrick Georgi <patrick.georgi@secunet.com>
Reviewed-on: http://review.coreboot.org/241
Reviewed-by: Marc Jones <marcj303@gmail.com>
Tested-by: build bot (Jenkins)
12 years agomptable: Refactor mptable generation some more
Patrick Georgi [Fri, 7 Oct 2011 21:01:55 +0000 (23:01 +0200)]
mptable: Refactor mptable generation some more

The last couple of lines of every mptable function were mostly
identical. Refactor into common code, a new function mptable_finalize.

Coccinelle script:
  @@
  identifier mc;
  @@
  (
  -mc->mpe_checksum = smp_compute_checksum(smp_next_mpc_entry(mc), mc->mpe_length);
  -mc->mpc_checksum = smp_compute_checksum(mc, mc->mpc_length);
  -printk(BIOS_DEBUG, "Wrote the mp table end at: %p - %p\n", mc, smp_next_mpe_entry(mc));
  -return smp_next_mpe_entry(mc);
  +return mptable_finalize(mc);
  |
  -mc->mpe_checksum = smp_compute_checksum(smp_next_mpc_entry(mc), mc->mpe_length);
  -mc->mpc_checksum = smp_compute_checksum(mc, mc->mpc_length);
  -return smp_next_mpe_entry(mc);
  +return mptable_finalize(mc);
  )

Change-Id: Ib2270d800bdd486c5eb49b328544d36bd2298c9e
Signed-off-by: Patrick Georgi <patrick@georgi-clan.de>
Reviewed-on: http://review.coreboot.org/246
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agomptable: Get rid of fixup_virtual_wire
Patrick Georgi [Fri, 7 Oct 2011 20:41:07 +0000 (22:41 +0200)]
mptable: Get rid of fixup_virtual_wire

As stated in some code files, fixup_virtual_wire was established
to avoid touching 200 invocations of the mptable code.

Let Coccinelle do it:
  @@
  type T;
  identifier v;
  @@
  -void fixup_virtual_wire(T v)
  -{ ... }

  @@
  expression A;
  identifier v;
  @@
  -v = smp_write_floating_table(A);
  +v = smp_write_floating_table(A, 0);

  @@
  expression A;
  identifier v;
  @@
  -v = smp_write_floating_table(A, 0);
  -fixup_virtual_wire(v);
  +v = smp_write_floating_table(A, 1);

Change-Id: Icad8a063380bf4726be7cebb414d13b574112b14
Signed-off-by: Patrick Georgi <patrick@georgi-clan.de>
Reviewed-on: http://review.coreboot.org/245
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agomptable: Refactor lintsrc generation
Patrick Georgi [Fri, 7 Oct 2011 19:42:52 +0000 (21:42 +0200)]
mptable: Refactor lintsrc generation

We copied pretty much the same code for generating mptable entries for
local interrupts (with some notable exceptions).
This change moves these lines into a generic function "mptable_lintsrc"
and makes use of it in many places.

The remaining uses of smp_write_lintsrc should be reviewed and replaced
by mptable_lintsrc calls where possible, and smp_write_lintsrc made static.

This patch was generated using Coccinelle:
  @@
  expression mc;
  expression isa_bus;
  @@
  -smp_write_lintsrc(mc, mp_ExtINT, MP_IRQ_TRIGGER_DEFAULT|MP_IRQ_POLARITY_DEFAULT, isa_bus, 0x0, MP_APIC_ALL, 0x0);
  -smp_write_lintsrc(mc, mp_NMI, MP_IRQ_TRIGGER_DEFAULT|MP_IRQ_POLARITY_DEFAULT, isa_bus, 0x0, MP_APIC_ALL, 0x1);
  +mptable_lintsrc(mc, isa_bus);

  @@
  expression mc;
  expression isa_bus;
  @@
  -smp_write_lintsrc(mc, mp_ExtINT, MP_IRQ_TRIGGER_EDGE|MP_IRQ_POLARITY_HIGH, isa_bus, 0x0, MP_APIC_ALL, 0x0);
  -smp_write_lintsrc(mc, mp_NMI, MP_IRQ_TRIGGER_EDGE|MP_IRQ_POLARITY_HIGH, isa_bus, 0x0, MP_APIC_ALL, 0x1);
  +mptable_lintsrc(mc, isa_bus);

  @m@
  identifier mc;
  expression BUS;
  @@
  -#define IO_LOCAL_INT(type, intr, apicid, pin) smp_write_lintsrc(mc, (type), MP_IRQ_TRIGGER_EDGE | MP_IRQ_POLARITY_HIGH, BUS, (intr), (apicid), (pin));
  ...
  -IO_LOCAL_INT(mp_ExtINT, 0x0, MP_APIC_ALL, 0x0);
  -IO_LOCAL_INT(mp_NMI, 0x0, MP_APIC_ALL, 0x1);
  +mptable_lintsrc(mc, BUS);

Change-Id: I97421f820cd039f5fd753cb0da5c1cca68819bb4
Signed-off-by: Patrick Georgi <patrick@georgi-clan.de>
Reviewed-on: http://review.coreboot.org/244
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoMake Asus A8V-E SE better ACPI citizen.
Rudolf Marek [Wed, 12 Oct 2011 20:11:40 +0000 (22:11 +0200)]
Make Asus A8V-E SE better ACPI citizen.

Use the SSDT autogen infrastructure to support the automatic reserved resources,
automatic P-state generation and automatic _CRS PCI0 method.

Change-Id: Ic56a92eeb70a0a2a2d6de2507009ec3a832c83b3
Signed-off-by: Rudolf Marek <r.marek@assembler.cz>
Reviewed-on: http://review.coreboot.org/251
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agow83627hf: ASL include containing virtual device tree of the SuperIO
Christoph Grenz [Sun, 18 Sep 2011 20:53:18 +0000 (22:53 +0200)]
w83627hf: ASL include containing virtual device tree of the SuperIO

Add a ACPI Source Language snippet to superio/w83627hf which maps the
SuperIO and most of the logical devices to PnP devices, exposing
configuration options and chip power management to the OS.
Written using the Winbond W83627HF/F datasheet.

Change-Id: I1108d29b341ef78fe7f1e574f98b680aada39daf
Signed-off-by: Christoph Grenz <christophg+cb@grenz-bonn.de>
Reviewed-on: http://review.coreboot.org/223
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoamdk8: ASL include for K8 temperature sensor support in ACPI
Christoph Grenz [Sun, 18 Sep 2011 21:20:55 +0000 (23:20 +0200)]
amdk8: ASL include for K8 temperature sensor support in ACPI

Add a ACPI Source Language snippet which if included as
shown in the comments in the file, exposes the 4 possible
temperature sensors in the CPU as ACPI thermal zones.

Change-Id: I94dd773108e348a0fdb9d2f8d6cfe415d5fa0339
Signed-off-by: Christoph Grenz <christophg+cb@grenz-bonn.de>
Reviewed-on: http://review.coreboot.org/222
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoSB800 RAID: add kconfig option RAID_MISC_ROM_POSITION
Kerry Sheh [Wed, 12 Oct 2011 03:42:59 +0000 (11:42 +0800)]
SB800 RAID: add kconfig option RAID_MISC_ROM_POSITION

SB800 RAID ROM require to put the misc ROM to specific position,
this patch enable user to put the RAID misc ROM to the right place
in the coreboot image.

Change-Id: I4fc64df8e091fb0cccd063826ab31a4f198942d1
Signed-off-by: Kerry She <kerry.she@amd.com>
Signed-off-by: Kerry She <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/249
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoSB800: Sata Enable bus master and enable ahci for AHCI/RAID mode
Kerry Sheh [Wed, 12 Oct 2011 03:42:59 +0000 (11:42 +0800)]
SB800: Sata Enable bus master and enable ahci for AHCI/RAID mode

In order to make sure AHCI/RAID ROM works correctly
For SB800_SATA_AHCI or SB800_SATA_RAID mode, SATA should
enable bus master and the ahci also should be enabled.

Change-Id: I9d9c557816d364d8373fe343860ad5fe45988200
Signed-off-by: Kerry She <kerry.she@amd.com>
Signed-off-by: Kerry She <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/248
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoavalue/eax-785e: Get SATA Mode from Kconfig option
Kerry Sheh [Tue, 11 Oct 2011 09:27:26 +0000 (17:27 +0800)]
avalue/eax-785e: Get SATA Mode from Kconfig option

Change-Id: I67aab3ba7de85337e2cf83b6d1be63cb04bf0fcd
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/233
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agosb800: Add Kconfig option ENABLE_IDE_COMBINED_MODE
Kerry Sheh [Tue, 11 Oct 2011 09:27:06 +0000 (17:27 +0800)]
sb800: Add Kconfig option ENABLE_IDE_COMBINED_MODE

Add this option to enable/disable SATA IDE Combined Mode feature

Change-Id: I1ab8acd27947a71baf954f44d0741f81f48e5541
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/231
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agopersimmon: complete the sb800 devicetree
Kerry Sheh [Tue, 11 Oct 2011 09:27:00 +0000 (17:27 +0800)]
persimmon: complete the sb800 devicetree

sb800 cimx entry sb_Before_Pci_Init was called in the device 16.2
enable_dev() function. If the devicetree don't have this device,
then sb_Before_Pci_Init will not get called.
So the missing sb800 USB3 devicees was add to the mainboard devicetree.
Because of no physical usb connector connected to USB3, the USB3 device setting was off.

Change-Id: If060ccb43df7fbe88bafc61e9e600a9120575437
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/232
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoDon't do a call as the first instruction in libpayload.
Marc Jones [Thu, 6 Oct 2011 22:38:35 +0000 (16:38 -0600)]
Don't do a call as the first instruction in libpayload.

Doing a call before the payload has set up its stack is risky. The stack may
not be in a favorable location. Normally this is not an issue with coreboot
or other well behaved callers.

Change-Id: Ie6f6748a471324b29ebad045c807dfc9f4b92034
Signed-off-by: Marc Jones <marcj303@gmail.com>
Reviewed-on: http://review.coreboot.org/240
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
12 years agoFixed broken MTRR for >4GB memory on AMD K8 fam 0fh rev <=E
Oskar Enoksson [Thu, 6 Oct 2011 16:21:19 +0000 (18:21 +0200)]
Fixed broken MTRR for >4GB memory on AMD K8 fam 0fh rev <=E

AMD K8 rev F and later implements a bit SYSCFG_MSR_TOM2WB to
mark dram memory above 4GB as WB. However, AMD K8
rev E and earlier don't implement this bit and therefore need
MTRR spanning dram memory above 4GB. The current implementation
of amd_setup_mtrrs never generate MTRR above 4GB.
This caused memory > 4GB not to be recognized in e.g. Linux on those
rev E or older platforms. This commit should fix that bug.

Signed-off-by: Oskar Enoksson <enok@lysator.liu.se>
Change-Id: Ie568a52a8eb355969c86964d5afc4692e60f69c1
Reviewed-on: http://review.coreboot.org/238
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agomainboard: complete the sb800 devicetree even device is off
Kerry Sheh [Mon, 10 Oct 2011 11:19:46 +0000 (19:19 +0800)]
mainboard: complete the sb800 devicetree even device is off

sb800 cimx entry sb_Before_Pci_Init was called in the device 16.2
enable_dev() function. If the devicetree don't have this device,
then sb_Before_Pci_Init will not get called.

Change-Id: I76ebad842e90b0f740abbec031165d7c39a80abf
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/230
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agosb800: sata combine mode configure fix
Kerry Sheh [Mon, 10 Oct 2011 10:23:49 +0000 (18:23 +0800)]
sb800: sata combine mode configure fix

Using micro CIMX_OPTION_ENABLED/CIMX_OPTION_DISABLED to
configure SataIdeCombinedMode is wrong.

sbPowerOnInit() use SataIdeCombinedMode to determine whether hide the IDE controller
  0: IDE controller is exposed and Combined Mode is enabled.
     SATA controller has control over Port0 through Port3,
     IDE controller has control over Port4 and Port5
  1: IDE controller is hidden and Combined Mode is disabled,
     SATA controller has full control of all 6 Ports when operating in non-IDE mode

Change-Id: I32e7101737f1dbfff49daa58670e6820b476b250
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/229
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agopersimmon: sb800 sata mode configure update
Kerry Sheh [Mon, 10 Oct 2011 10:13:51 +0000 (18:13 +0800)]
persimmon: sb800 sata mode configure update

persimmon configure sb800 sata mode according to the
southbridge kconfig selection.

Change-Id: I44a9c36ca68b4a0e1086f04c4338d3a5f536fdca
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/227
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agosb800: Add sata ahci/raid mode kconfig option
Kerry Sheh [Mon, 10 Oct 2011 09:17:39 +0000 (17:17 +0800)]
sb800: Add sata ahci/raid mode kconfig option

If sb800 sata was configured as ahci or raid mode,
give the option to add ROM files.

Change-Id: I87a7814930ce3a7c38cde1e235d151223eea2107
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/225
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agopci_ids: Add sb800 SATA device raid mode device id
Kerry Sheh [Thu, 22 Sep 2011 10:52:35 +0000 (18:52 +0800)]
pci_ids: Add sb800 SATA device raid mode device id

sb800 SATA device have different device id with different configure
mode, 4392h for RAID mode, 4393h for RAID5 mode

Change-Id: If54f7751f531c94ee725309a2a5c255390935ead
Signed-off-by: Kerry Sheh <kerry.she@amd.com>
Signed-off-by: Kerry Sheh <shekairui@gmail.com>
Reviewed-on: http://review.coreboot.org/226
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoTINY_BOOTBLOCK problem-fix on amdk8+amd8111 platforms
enok71 [Wed, 28 Sep 2011 14:55:59 +0000 (16:55 +0200)]
TINY_BOOTBLOCK problem-fix on amdk8+amd8111 platforms

The hp/dl145_g1 motherboard did not work since commit
1f7d3c5672ec90f8d71907b1a07c8a87fa461047 (svn 6124). That commit added
TINY_BOOTBLOCK for amd8111 southbridge. The result was that the boot process
stopped very early (no console output whatsoever). The same symptom was
reported on other AMDK8 based boards with amd8111 southbridge chips. This
commit seems to fix the bug. It adds a bootblock.c under
src/northbridge/amd/amdk8 that calls enumerate_ht_chains. Probably the
problem was that enum_ht_chains needs to be called before the southbridge
bootblock.c function, not after.

Change-Id: I74fb892aa39048e2d0e76c081b713f825d67f2d4
Signed-off-by: Oskar Enoksson <enok@lysator.liu.se>
Reviewed-on: http://review.coreboot.org/235
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoAdd AMD Family 10h PH-E0 support
QingPei Wang [Tue, 13 Sep 2011 10:04:22 +0000 (18:04 +0800)]
Add AMD Family 10h PH-E0 support

the patch file comes from
src/vendorcode/amd/agesa/f12/Proc/CPU/Family/0x10/RevE
/F10MicrocodePatch010000bf.c

Change-Id: If701c8a908edf1c486665d3ce4df65da0f65c802
Signed-off-by: QingPei Wang <wangqingpei@gmail.com>
Reviewed-on: http://review.coreboot.org/202
Tested-by: build bot (Jenkins)
Reviewed-by: Peter Stuge <peter@stuge.se>
12 years agomkelfImage: Use -fno-stack-protector if supported by gcc
Raymond Danks [Sun, 4 Sep 2011 03:45:38 +0000 (21:45 -0600)]
mkelfImage: Use -fno-stack-protector if supported by gcc

Gcc 4.1 comes with an SSP https://wiki.ubuntu.com/GccSsp
This is disabled to work around '__stack_chk_fail' symbol not found failures
http://www.coreboot.org/FAQ/Obsolete#How_do_I_fix_stack_chk_fail_errors.3F

The presence of -fno-stack-protector is tested for automatically by configure.

Change-Id: I28ef158829f5935f985cfd5a5440733685cf479a
Reported-by: Raymond Danks <raymonddanks@gmail.com>
Signed-off-by: Raymond Danks <raymonddanks@gmail.com>
Reviewed-on: http://review.coreboot.org/112
Tested-by: build bot (Jenkins)
Reviewed-by: Peter Stuge <peter@stuge.se>
12 years agoUse ACPI text fields consistently with all other boards
Stefan Reinauer [Tue, 20 Sep 2011 20:36:32 +0000 (22:36 +0200)]
Use ACPI text fields consistently with all other boards

LXBIOS and LXB-DSDT are not used in other parts of the tree.
Make names consistent across the tree.

Signed-off-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Change-Id: I91caeac09fd2401a36e53bd061d249b236a48e43
Reviewed-on: http://review.coreboot.org/224
Tested-by: build bot (Jenkins)
Reviewed-by: Peter Stuge <peter@stuge.se>
12 years agoPersimmon doesn't have HDMI so the GNB HD Audio should be disabled.
Marc Jones [Fri, 16 Sep 2011 23:06:17 +0000 (17:06 -0600)]
Persimmon doesn't have HDMI so the GNB HD Audio should be disabled.

Change-Id: Ic960fe09fbed2c8a31c7c9ac2c54f6c88efebed3
Signed-off-by: Marc Jones <marcj303@gmail.com>
Reviewed-on: http://review.coreboot.org/219
Reviewed-by: Frank Vibrans III <frank.vibrans@amd.com>
Tested-by: build bot (Jenkins)
12 years agoEnable SATA AHCI for faster boot with SeaBIOS.
Marc Jones [Fri, 16 Sep 2011 23:08:01 +0000 (17:08 -0600)]
Enable SATA AHCI for faster boot with SeaBIOS.

Change-Id: Ibd87422680350c112eabe1bb73b237031c3e9d6b
Signed-off-by: Marc Jones <marcj303@gmail.com>
Reviewed-on: http://review.coreboot.org/220
Tested-by: build bot (Jenkins)
Reviewed-by: Frank Vibrans III <frank.vibrans@amd.com>
12 years agoPersimmon updates for AMD F14 rev C0
efdesign98 [Thu, 15 Sep 2011 21:24:26 +0000 (15:24 -0600)]
Persimmon updates for AMD F14 rev C0

These are the changes for the AMD Persimmon mainboard
required to support the update of the AMD Family 14
cpu to rev C0.  There are many warning fixes; the agesa-
wrapper.c file has been changed to fix the amdinitlate
and amdlaterunaptask routines, and more.

Change-Id: I6de43379a2819cea5169db5f21d4841f9a4942a7
Signed-off-by: Frank Vibrans <frank.vibrans@amd.com>
Signed-off-by: efdesign98 <efdesign98@gmail.com>
Reviewed-on: http://review.coreboot.org/137
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoBuild warning fix for AMD Family 12
efdesign98 [Thu, 15 Sep 2011 17:24:29 +0000 (11:24 -0600)]
Build warning fix for AMD Family 12

This trivial change adds a prototype to an existing
header file to fix a build warning for the AMD family
12 cpus.

Change-Id: Ic666bfbef867d17607eaa0f59570aea987a31f93
Signed-off-by: Frank Vibrans <frank.vibrans@amd.com>
Signed-off-by: efdesign98 <efdesign98@gmail.com>
Reviewed-on: http://review.coreboot.org/218
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoAMD Inagua platform updates
efdesign98 [Thu, 15 Sep 2011 16:59:55 +0000 (10:59 -0600)]
AMD Inagua platform updates

These changes update the Inagua platform.  The changes
include modifying the Kconfig to suggest video bios
and ahci rom implementations, changing the dimm spd
code to use the correct bus addresses, cleaning up the
makefile a bit, and fixing a duplicate definition
warning associated with the BIOS_SIZE value.

Change-Id: Idab88dda48f08877dbbd2de3136bdf0e54e31247
Signed-off-by: Frank Vibrans <frank.vibrans@amd.com>
Signed-off-by: efdesign98 <efdesign98@gmail.com>
Reviewed-on: http://review.coreboot.org/136
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoAMD Torpedo platform updates
efdesign98 [Fri, 19 Aug 2011 20:25:48 +0000 (14:25 -0600)]
AMD Torpedo platform updates

This update fixes warnings and supports as necessary
the Agesa infrastructure changes required to support
the AMD Family 14 cpu update to rev C0.

Change-Id: Ib08b49695b925b81f796bf299141fe6f845fdef8
Signed-off-by: Frank Vibrans <frank.vibrans@amd.com>
Signed-off-by: efdesign98 <efdesign98@gmail.com>
Reviewed-on: http://review.coreboot.org/138
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoAMD Agesa macro expansion fix
efdesign98 [Thu, 15 Sep 2011 01:34:13 +0000 (19:34 -0600)]
AMD Agesa macro expansion fix

This change fixes the use of a macro that was
previously modified to fix a warning.  The macro
was used in a manner that doubly incremented a
pointer.  The pointer increment was removed from
the macro call and moved elsewhere.  In addition,
an unused macro was removed from both Family 12
and Family 14 code.

Change-Id: I577794bbc55d18f21170dda1d0bbdc6d776ce392
Signed-off-by: Frank Vibrans <frank.vibrans@amd.com>
Signed-off-by: efdesign98 <efdesign98@gmail.com>
Reviewed-on: http://review.coreboot.org/217
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
12 years agoAMD SB800 early console use fix
efdesign98 [Wed, 14 Sep 2011 22:22:31 +0000 (16:22 -0600)]
AMD SB800 early console use fix

This change removes printk's that occur before
console init is called.  In the best case, these
would cause an extremely slow boot, and in the
worst case would cause a complete post failure.

Change-Id: I50388e71225e95db602aa45835c39126c1c920a3
Signed-off-by: Frank Vibrans <frank.vibrans@amd.com>
Signed-off-by: efdesign98 <efdesign98@gmail.com>
Reviewed-on: http://review.coreboot.org/216
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>
12 years agoAMD Agesa changes to fix F14 boot issues
efdesign98 [Wed, 14 Sep 2011 21:52:09 +0000 (15:52 -0600)]
AMD Agesa changes to fix F14 boot issues

This collection of changes fixes a buffer addressing
issue by removing one level of indirection, fixes an
Agesa HT mailbox retrieval bug, and fixes a buffer
location-by-signature issue.

Change-Id: Ic8a8cb3f9abddd9ad59343a85dbbee5aa7633be3
Signed-off-by: Frank Vibrans <frank.vibrans@amd.com>
Signed-off-by: efdesign98 <efdesign98@gmail.com>
Reviewed-on: http://review.coreboot.org/215
Reviewed-by: Marc Jones <marcj303@gmail.com>
Tested-by: build bot (Jenkins)
12 years agoAMD F14 Northbridge updates
efdesign98 [Wed, 14 Sep 2011 19:47:17 +0000 (13:47 -0600)]
AMD F14 Northbridge updates

This change is warning and whitespace fixes in the
northbridge code for AMD Family 14 rev C0 cpu update.
This does not address warnings in the mainboard,
Agesa, Cimx, or southbridge code.

Change-Id: I7ee7018a292ebb2343c9b7986dd21227185879dc
Signed-off-by: Frank Vibrans <frank.vibrans@amd.com>
Signed-off-by: efdesign98 <efdesign98@gmail.com>
Reviewed-on: http://review.coreboot.org/134
Tested-by: build bot (Jenkins)
Reviewed-by: Marc Jones <marcj303@gmail.com>