mirror of
https://github.com/fail0verflow/switch-coreboot.git
synced 2025-05-04 01:39:18 -04:00
Move console/*.c into lib/ in order to simplify the directory structure.
Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de> Acked-by: Stefan Reinauer <stepan@coresystems.de> git-svn-id: svn://coreboot.org/repository/LinuxBIOSv3@315 f3766cd6-281f-0410-b1cd-43a5c92072e9
This commit is contained in:
parent
71ccb36afc
commit
9caaf62dd5
9 changed files with 168 additions and 197 deletions
1
Kconfig
1
Kconfig
|
@ -42,7 +42,6 @@ endmenu
|
|||
source mainboard/Kconfig
|
||||
source arch/Kconfig
|
||||
source lib/Kconfig
|
||||
source console/Kconfig
|
||||
source device/Kconfig
|
||||
|
||||
# These are used for internal purposes only.
|
||||
|
|
1
Makefile
1
Makefile
|
@ -107,7 +107,6 @@ CFLAGS += -nostdinc -isystem `$(CC) -print-file-name=include`
|
|||
|
||||
include lib/Makefile
|
||||
include device/Makefile
|
||||
include console/Makefile
|
||||
include mainboard/$(MAINBOARDDIR)/Makefile
|
||||
include northbridge/Makefile
|
||||
include southbridge/Makefile
|
||||
|
|
|
@ -62,8 +62,8 @@ $(obj)/linuxbios.bootblock: $(obj)/linuxbios.vpd $(obj)/stage0.init
|
|||
# initram module and the various stages and payload files.
|
||||
#
|
||||
|
||||
STAGE0_CONSOLE_OBJ = vtxprintf.o vsprintf.o console.o
|
||||
STAGE0_LIB_OBJ = uart8250.o mem.o elfboot.o lar.o delay.o
|
||||
STAGE0_LIB_OBJ = uart8250.o mem.o elfboot.o lar.o delay.o vtxprintf.o \
|
||||
vsprintf.o console.o
|
||||
STAGE0_ARCH_X86_OBJ = cachemain.o serial.o archelfboot.o speaker.o udelay_io.o mc146818rtc.o
|
||||
|
||||
ifeq ($(CONFIG_CAR_TYPE_I586),y)
|
||||
|
@ -73,8 +73,7 @@ else
|
|||
endif
|
||||
|
||||
|
||||
STAGE0_OBJ := $(patsubst %,$(obj)/console/%,$(STAGE0_CONSOLE_OBJ)) \
|
||||
$(patsubst %,$(obj)/lib/%,$(STAGE0_LIB_OBJ)) \
|
||||
STAGE0_OBJ := $(patsubst %,$(obj)/lib/%,$(STAGE0_LIB_OBJ)) \
|
||||
$(patsubst %,$(obj)/arch/x86/%,$(STAGE0_ARCH_X86_OBJ)) \
|
||||
$(patsubst %,$(obj)/arch/x86/%,$(STAGE0_CAR_OBJ))
|
||||
|
||||
|
|
165
console/Kconfig
165
console/Kconfig
|
@ -1,165 +0,0 @@
|
|||
menu "Console"
|
||||
|
||||
config CONSOLE
|
||||
bool "Console support"
|
||||
default y
|
||||
help
|
||||
Support for various types of (debugging) consoles.
|
||||
|
||||
choice
|
||||
prompt "Console log level"
|
||||
default CONSOLE_LOGLEVEL_8
|
||||
depends CONSOLE
|
||||
|
||||
config CONSOLE_LOGLEVEL_8
|
||||
bool "BIOS_SPEW"
|
||||
help
|
||||
Way too many details.
|
||||
|
||||
config CONSOLE_LOGLEVEL_7
|
||||
bool "BIOS_DEBUG"
|
||||
help
|
||||
Debug-level messages.
|
||||
|
||||
config CONSOLE_LOGLEVEL_6
|
||||
bool "BIOS_INFO"
|
||||
help
|
||||
Informational messages.
|
||||
|
||||
config CONSOLE_LOGLEVEL_5
|
||||
bool "BIOS_NOTICE"
|
||||
help
|
||||
Normal but significant conditions.
|
||||
|
||||
config CONSOLE_LOGLEVEL_4
|
||||
bool "BIOS_WARNING"
|
||||
help
|
||||
Warning conditions.
|
||||
|
||||
config CONSOLE_LOGLEVEL_3
|
||||
bool "BIOS_ERR"
|
||||
help
|
||||
Error conditions.
|
||||
|
||||
config CONSOLE_LOGLEVEL_2
|
||||
bool "BIOS_CRIT"
|
||||
help
|
||||
Critical conditions.
|
||||
|
||||
config CONSOLE_LOGLEVEL_1
|
||||
bool "BIOS_ALERT"
|
||||
help
|
||||
Action must be taken immediately.
|
||||
|
||||
config CONSOLE_LOGLEVEL_0
|
||||
bool "BIOS_EMERG"
|
||||
help
|
||||
System is unusable.
|
||||
|
||||
endchoice
|
||||
|
||||
config DEFAULT_CONSOLE_LOGLEVEL
|
||||
int
|
||||
default 0 if CONSOLE_LOGLEVEL_0
|
||||
default 1 if CONSOLE_LOGLEVEL_1
|
||||
default 2 if CONSOLE_LOGLEVEL_2
|
||||
default 3 if CONSOLE_LOGLEVEL_3
|
||||
default 4 if CONSOLE_LOGLEVEL_4
|
||||
default 5 if CONSOLE_LOGLEVEL_5
|
||||
default 6 if CONSOLE_LOGLEVEL_6
|
||||
default 7 if CONSOLE_LOGLEVEL_7
|
||||
default 8 if CONSOLE_LOGLEVEL_8
|
||||
help
|
||||
Map the log level config names to an integer.
|
||||
|
||||
config CONSOLE_SERIAL
|
||||
boolean "Serial console support"
|
||||
default y
|
||||
depends CONSOLE
|
||||
help
|
||||
Send LinuxBIOS output to serial console.
|
||||
|
||||
choice
|
||||
prompt "Serial console COM port"
|
||||
default CONSOLE_SERIAL_COM1
|
||||
depends CONSOLE_SERIAL
|
||||
|
||||
config CONSOLE_SERIAL_COM1
|
||||
bool "COM1/ttyS0"
|
||||
help
|
||||
Serial console on COM1/ttyS0.
|
||||
|
||||
config CONSOLE_SERIAL_COM2
|
||||
bool "COM2/ttyS1"
|
||||
help
|
||||
Serial console on COM2/ttyS1.
|
||||
|
||||
endchoice
|
||||
|
||||
choice
|
||||
prompt "Serial console speed"
|
||||
default CONSOLE_SERIAL_115200
|
||||
depends CONSOLE_SERIAL
|
||||
|
||||
config CONSOLE_SERIAL_115200
|
||||
bool "115200 bps"
|
||||
help
|
||||
Set serial console speed to 115200 bps.
|
||||
|
||||
config CONSOLE_SERIAL_57600
|
||||
bool "57600 bps"
|
||||
help
|
||||
Set serial console speed to 57600 bps.
|
||||
|
||||
config CONSOLE_SERIAL_38400
|
||||
bool "38400 bps"
|
||||
help
|
||||
Set serial console speed to 38400 bps.
|
||||
|
||||
config CONSOLE_SERIAL_19200
|
||||
bool "19200 bps"
|
||||
help
|
||||
Set serial console speed to 19200 bps.
|
||||
|
||||
config CONSOLE_SERIAL_9600
|
||||
bool "9600 bps"
|
||||
help
|
||||
Set serial console speed to 9600 bps.
|
||||
|
||||
endchoice
|
||||
|
||||
config CONSOLE_USB
|
||||
boolean "USB2 console support (EXPERIMENTAL)"
|
||||
depends CONSOLE && EXPERIMENTAL
|
||||
help
|
||||
Send LinuxBIOS output to USB2 (EHCI) console.
|
||||
|
||||
Note: This requires a USB2 controller which supports the EHCI
|
||||
Debug Port capability. Controllers which are known to work:
|
||||
|
||||
* 10b9:5239 ALi Corporation USB 2.0 (USB PCI card)
|
||||
* 10de:0088 NVIDIA MCP2A
|
||||
* 10de:005b NVIDIA CK804
|
||||
* 10de:036d NVIDIA MCP55
|
||||
* 8086:24dd Intel ICH5
|
||||
* 8086:265c Intel ICH6
|
||||
* 8086:268c Intel 631xESB/632xESB/3100
|
||||
* 8086:27cc Intel ICH7
|
||||
* 8086:2836 Intel ICH8
|
||||
* 8086:283a Intel ICH8
|
||||
|
||||
See http://linuxbios.org/EHCI_Debug_Port for an up-to-date list.
|
||||
|
||||
comment "Cosmetic console options"
|
||||
depends EXPERT && (CONSOLE_SERIAL || CONSOLE_USB)
|
||||
|
||||
config CONSOLE_PREFIX
|
||||
bool "Prefix all console output with '(LB)'"
|
||||
depends EXPERT && (CONSOLE_SERIAL || CONSOLE_USB)
|
||||
default n
|
||||
help
|
||||
When you enable this option, LinuxBIOS will prefix each line of
|
||||
console output with '(LB)'.
|
||||
|
||||
endmenu
|
||||
|
|
@ -1,26 +0,0 @@
|
|||
##
|
||||
## This file is part of the LinuxBIOS project.
|
||||
##
|
||||
## Copyright (C) 2007 coresystems GmbH
|
||||
## Written by Stefan Reinauer <stepan@coresystems.de> for coresystems GmbH.
|
||||
##
|
||||
## This program is free software; you can redistribute it and/or modify
|
||||
## it under the terms of the GNU General Public License as published by
|
||||
## the Free Software Foundation; either version 2 of the License, or
|
||||
## (at your option) any later version.
|
||||
##
|
||||
## This program is distributed in the hope that it will be useful,
|
||||
## but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
## GNU General Public License for more details.
|
||||
##
|
||||
## You should have received a copy of the GNU General Public License
|
||||
## along with this program; if not, write to the Free Software
|
||||
## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
##
|
||||
|
||||
$(obj)/console/%.o: $(src)/console/%.c
|
||||
$(Q)mkdir -p $(obj)/console
|
||||
$(Q)printf " CC $(subst $(shell pwd)/,,$(@))\n"
|
||||
$(Q)$(CC) $(INITCFLAGS) -c $< -o $@
|
||||
|
165
lib/Kconfig
165
lib/Kconfig
|
@ -61,3 +61,168 @@ endchoice
|
|||
|
||||
endmenu
|
||||
|
||||
menu "Console"
|
||||
|
||||
config CONSOLE
|
||||
bool "Console support"
|
||||
default y
|
||||
help
|
||||
Support for various types of (debugging) consoles.
|
||||
|
||||
choice
|
||||
prompt "Console log level"
|
||||
default CONSOLE_LOGLEVEL_8
|
||||
depends CONSOLE
|
||||
|
||||
config CONSOLE_LOGLEVEL_8
|
||||
bool "BIOS_SPEW"
|
||||
help
|
||||
Way too many details.
|
||||
|
||||
config CONSOLE_LOGLEVEL_7
|
||||
bool "BIOS_DEBUG"
|
||||
help
|
||||
Debug-level messages.
|
||||
|
||||
config CONSOLE_LOGLEVEL_6
|
||||
bool "BIOS_INFO"
|
||||
help
|
||||
Informational messages.
|
||||
|
||||
config CONSOLE_LOGLEVEL_5
|
||||
bool "BIOS_NOTICE"
|
||||
help
|
||||
Normal but significant conditions.
|
||||
|
||||
config CONSOLE_LOGLEVEL_4
|
||||
bool "BIOS_WARNING"
|
||||
help
|
||||
Warning conditions.
|
||||
|
||||
config CONSOLE_LOGLEVEL_3
|
||||
bool "BIOS_ERR"
|
||||
help
|
||||
Error conditions.
|
||||
|
||||
config CONSOLE_LOGLEVEL_2
|
||||
bool "BIOS_CRIT"
|
||||
help
|
||||
Critical conditions.
|
||||
|
||||
config CONSOLE_LOGLEVEL_1
|
||||
bool "BIOS_ALERT"
|
||||
help
|
||||
Action must be taken immediately.
|
||||
|
||||
config CONSOLE_LOGLEVEL_0
|
||||
bool "BIOS_EMERG"
|
||||
help
|
||||
System is unusable.
|
||||
|
||||
endchoice
|
||||
|
||||
config DEFAULT_CONSOLE_LOGLEVEL
|
||||
int
|
||||
default 0 if CONSOLE_LOGLEVEL_0
|
||||
default 1 if CONSOLE_LOGLEVEL_1
|
||||
default 2 if CONSOLE_LOGLEVEL_2
|
||||
default 3 if CONSOLE_LOGLEVEL_3
|
||||
default 4 if CONSOLE_LOGLEVEL_4
|
||||
default 5 if CONSOLE_LOGLEVEL_5
|
||||
default 6 if CONSOLE_LOGLEVEL_6
|
||||
default 7 if CONSOLE_LOGLEVEL_7
|
||||
default 8 if CONSOLE_LOGLEVEL_8
|
||||
help
|
||||
Map the log level config names to an integer.
|
||||
|
||||
config CONSOLE_SERIAL
|
||||
boolean "Serial console support"
|
||||
default y
|
||||
depends CONSOLE
|
||||
help
|
||||
Send LinuxBIOS output to serial console.
|
||||
|
||||
choice
|
||||
prompt "Serial console COM port"
|
||||
default CONSOLE_SERIAL_COM1
|
||||
depends CONSOLE_SERIAL
|
||||
|
||||
config CONSOLE_SERIAL_COM1
|
||||
bool "COM1/ttyS0"
|
||||
help
|
||||
Serial console on COM1/ttyS0.
|
||||
|
||||
config CONSOLE_SERIAL_COM2
|
||||
bool "COM2/ttyS1"
|
||||
help
|
||||
Serial console on COM2/ttyS1.
|
||||
|
||||
endchoice
|
||||
|
||||
choice
|
||||
prompt "Serial console speed"
|
||||
default CONSOLE_SERIAL_115200
|
||||
depends CONSOLE_SERIAL
|
||||
|
||||
config CONSOLE_SERIAL_115200
|
||||
bool "115200 bps"
|
||||
help
|
||||
Set serial console speed to 115200 bps.
|
||||
|
||||
config CONSOLE_SERIAL_57600
|
||||
bool "57600 bps"
|
||||
help
|
||||
Set serial console speed to 57600 bps.
|
||||
|
||||
config CONSOLE_SERIAL_38400
|
||||
bool "38400 bps"
|
||||
help
|
||||
Set serial console speed to 38400 bps.
|
||||
|
||||
config CONSOLE_SERIAL_19200
|
||||
bool "19200 bps"
|
||||
help
|
||||
Set serial console speed to 19200 bps.
|
||||
|
||||
config CONSOLE_SERIAL_9600
|
||||
bool "9600 bps"
|
||||
help
|
||||
Set serial console speed to 9600 bps.
|
||||
|
||||
endchoice
|
||||
|
||||
config CONSOLE_USB
|
||||
boolean "USB2 console support (EXPERIMENTAL)"
|
||||
depends CONSOLE && EXPERIMENTAL
|
||||
help
|
||||
Send LinuxBIOS output to USB2 (EHCI) console.
|
||||
|
||||
Note: This requires a USB2 controller which supports the EHCI
|
||||
Debug Port capability. Controllers which are known to work:
|
||||
|
||||
* 10b9:5239 ALi Corporation USB 2.0 (USB PCI card)
|
||||
* 10de:0088 NVIDIA MCP2A
|
||||
* 10de:005b NVIDIA CK804
|
||||
* 10de:036d NVIDIA MCP55
|
||||
* 8086:24dd Intel ICH5
|
||||
* 8086:265c Intel ICH6
|
||||
* 8086:268c Intel 631xESB/632xESB/3100
|
||||
* 8086:27cc Intel ICH7
|
||||
* 8086:2836 Intel ICH8
|
||||
* 8086:283a Intel ICH8
|
||||
|
||||
See http://linuxbios.org/EHCI_Debug_Port for an up-to-date list.
|
||||
|
||||
comment "Cosmetic console options"
|
||||
depends EXPERT && (CONSOLE_SERIAL || CONSOLE_USB)
|
||||
|
||||
config CONSOLE_PREFIX
|
||||
bool "Prefix all console output with '(LB)'"
|
||||
depends EXPERT && (CONSOLE_SERIAL || CONSOLE_USB)
|
||||
default n
|
||||
help
|
||||
When you enable this option, LinuxBIOS will prefix each line of
|
||||
console output with '(LB)'.
|
||||
|
||||
endmenu
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue