Merge branch '2021-08-31-kconfig-migrations-part2' into next
[platform/kernel/u-boot.git] / include / configs / x86-common.h
1 /* SPDX-License-Identifier: GPL-2.0+ */
2 /*
3  * Copyright (c) 2011 The Chromium OS Authors.
4  * (C) Copyright 2008
5  * Graeme Russ, graeme.russ@gmail.com.
6  */
7
8 #include <asm/ibmpc.h>
9
10 #ifndef __CONFIG_X86_COMMON_H
11 #define __CONFIG_X86_COMMON_H
12
13 /*
14  * High Level Configuration Options
15  * (easy to change)
16  */
17 #define CONFIG_PHYSMEM
18
19 #define CONFIG_SYS_BOOTM_LEN            (16 << 20)
20
21 /* SATA AHCI storage */
22 #ifdef CONFIG_SCSI_AHCI
23 #define CONFIG_LBA48
24 #define CONFIG_SYS_64BIT_LBA
25
26 #endif
27
28 /* Generic TPM interfaced through LPC bus */
29 #define CONFIG_TPM_TIS_BASE_ADDRESS        0xfed40000
30
31 /*-----------------------------------------------------------------------
32  * Real Time Clock Configuration
33  */
34 #define CONFIG_SYS_ISA_IO_BASE_ADDRESS  0
35 #define CONFIG_SYS_ISA_IO      CONFIG_SYS_ISA_IO_BASE_ADDRESS
36
37 /*-----------------------------------------------------------------------
38  * Serial Configuration
39  */
40 #define CONFIG_SYS_NS16550_PORT_MAPPED
41
42 #ifndef CONFIG_BOOTCOMMAND
43 #define CONFIG_BOOTCOMMAND      \
44         "ext2load scsi 0:3 01000000 /boot/vmlinuz; zboot 01000000"
45 #endif
46
47 #if defined(CONFIG_CMD_KGDB)
48 #define CONFIG_KGDB_BAUDRATE                    115200
49 #endif
50
51 /*
52  * Miscellaneous configurable options
53  */
54 #define CONFIG_SYS_CBSIZE                       512
55
56 /*-----------------------------------------------------------------------
57  * CPU Features
58  */
59
60 #define CONFIG_SYS_STACK_SIZE                   (32 * 1024)
61 #define CONFIG_SYS_MONITOR_BASE         CONFIG_SYS_TEXT_BASE
62
63 /*-----------------------------------------------------------------------
64  * Environment configuration
65  */
66
67 /*-----------------------------------------------------------------------
68  * PCI configuration
69  */
70 #define CONFIG_PCI_CONFIG_HOST_BRIDGE
71
72 /*-----------------------------------------------------------------------
73  * USB configuration
74  */
75
76 #define CONFIG_BOOTP_BOOTFILESIZE
77
78 /* Default environment */
79 #define CONFIG_ROOTPATH         "/opt/nfsroot"
80 #define CONFIG_HOSTNAME         "x86"
81 #define CONFIG_BOOTFILE         "bzImage"
82 #define CONFIG_RAMDISK_ADDR     0x4000000
83 #if defined(CONFIG_GENERATE_ACPI_TABLE) || defined(CONFIG_EFI_STUB)
84 #define CONFIG_OTHBOOTARGS      "othbootargs=\0"
85 #else
86 #define CONFIG_OTHBOOTARGS      "othbootargs=acpi=off\0"
87 #endif
88
89 #if defined(CONFIG_DISTRO_DEFAULTS)
90 #define DISTRO_BOOTENV          BOOTENV
91 #else
92 #define DISTRO_BOOTENV
93 #endif
94
95 #define CONFIG_EXTRA_ENV_SETTINGS                       \
96         DISTRO_BOOTENV                                  \
97         CONFIG_STD_DEVICES_SETTINGS                     \
98         "pciconfighost=1\0"                             \
99         "netdev=eth0\0"                                 \
100         "consoledev=ttyS0\0"                            \
101         CONFIG_OTHBOOTARGS                              \
102         "scriptaddr=0x7000000\0"                        \
103         "kernel_addr_r=0x1000000\0"                     \
104         "ramdisk_addr_r=0x4000000\0"                    \
105         "ramdiskfile=initramfs.gz\0"
106
107
108 #define RAMBOOTCOMMAND                          \
109         "setenv bootargs root=/dev/ram rw "             \
110         "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \
111         "console=$consoledev,$baudrate $othbootargs;"   \
112         "tftpboot $kernel_addr_r $bootfile;"            \
113         "tftpboot $ramdisk_addr_r $ramdiskfile;"        \
114         "zboot $kernel_addr_r 0 $ramdisk_addr_r $filesize"
115
116 #define NFSBOOTCOMMAND                          \
117         "setenv bootargs root=/dev/nfs rw "             \
118         "nfsroot=$serverip:$rootpath "                  \
119         "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \
120         "console=$consoledev,$baudrate $othbootargs;"   \
121         "tftpboot $kernel_addr_r $bootfile;"            \
122         "zboot $kernel_addr_r"
123
124
125 #endif  /* __CONFIG_H */