summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/configs/alt.h10
-rw-r--r--include/configs/blanche.h4
-rw-r--r--include/configs/condor.h13
-rw-r--r--include/configs/ebisu.h2
-rw-r--r--include/configs/falcon.h3
-rw-r--r--include/configs/genmai.h15
-rw-r--r--include/configs/gose.h10
-rw-r--r--include/configs/grpeach.h12
-rw-r--r--include/configs/koelsch.h12
-rw-r--r--include/configs/lager.h12
-rw-r--r--include/configs/porter.h12
-rw-r--r--include/configs/silk.h12
-rw-r--r--include/configs/stout.h12
-rw-r--r--include/configs/v3hsk.h13
-rw-r--r--include/dt-bindings/clock/xlnx-zynqmp-clk.h126
-rw-r--r--include/efi_api.h71
-rw-r--r--include/efi_config.h2
-rw-r--r--include/efi_loader.h19
-rw-r--r--include/fdt_support.h15
-rw-r--r--include/log.h2
-rw-r--r--include/ndisc.h2
-rw-r--r--include/net-common.h13
-rw-r--r--include/net-lwip.h16
-rw-r--r--include/part.h15
-rw-r--r--include/part_efi.h20
-rw-r--r--include/sata.h3
-rw-r--r--include/spl_gpio.h2
-rw-r--r--include/tca642x.h69
-rw-r--r--include/tpm-v2.h2
-rw-r--r--include/tsi148.h201
-rw-r--r--include/vsc9953.h2
-rw-r--r--include/zynqmp_firmware.h9
32 files changed, 195 insertions, 536 deletions
diff --git a/include/configs/alt.h b/include/configs/alt.h
index 8f03762583e..4c5d2de2bdf 100644
--- a/include/configs/alt.h
+++ b/include/configs/alt.h
@@ -20,16 +20,6 @@
#define RCAR_GEN2_SDRAM_SIZE (1024u * 1024 * 1024)
#define RCAR_GEN2_UBOOT_SDRAM_SIZE (512 * 1024 * 1024)
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x1
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-
#define CFG_EXTRA_ENV_SETTINGS \
"bootm_size=0x10000000\0" \
"usb_pgood_delay=2000\0"
diff --git a/include/configs/blanche.h b/include/configs/blanche.h
index d4e0f677e67..46521aa16bf 100644
--- a/include/configs/blanche.h
+++ b/include/configs/blanche.h
@@ -29,8 +29,4 @@
#define CFG_SYS_FLASH_BANKS_SIZES { (CFG_SYS_FLASH_SIZE) }
#endif
-/* Board Clock */
-
-/* ENV setting */
-
#endif /* __BLANCHE_H */
diff --git a/include/configs/condor.h b/include/configs/condor.h
index 50c8d173383..b340800cc11 100644
--- a/include/configs/condor.h
+++ b/include/configs/condor.h
@@ -11,17 +11,4 @@
#include "rcar-gen3-common.h"
-/* Environment compatibility */
-
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x1
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-/* XTAL_CLK : 33.33MHz */
-
#endif /* __CONDOR_H */
diff --git a/include/configs/ebisu.h b/include/configs/ebisu.h
index ad5944230a6..707e7c28d55 100644
--- a/include/configs/ebisu.h
+++ b/include/configs/ebisu.h
@@ -9,8 +9,6 @@
#ifndef __EBISU_H
#define __EBISU_H
-#undef DEBUG
-
#include "rcar-gen3-common.h"
/* Environment in eMMC, at the end of 2nd "boot sector" */
diff --git a/include/configs/falcon.h b/include/configs/falcon.h
index 0b62ff9fbe1..e1cace73550 100644
--- a/include/configs/falcon.h
+++ b/include/configs/falcon.h
@@ -11,7 +11,4 @@
#include "rcar-gen4-common.h"
-/* Board Clock */
-/* XTAL_CLK : 16.66MHz */
-
#endif /* __FALCON_H */
diff --git a/include/configs/genmai.h b/include/configs/genmai.h
new file mode 100644
index 00000000000..1d43f8e06af
--- /dev/null
+++ b/include/configs/genmai.h
@@ -0,0 +1,15 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Configuration settings for the Renesas GENMAI board
+ *
+ * Copyright (C) 2017-2019 Renesas Electronics
+ */
+
+#ifndef __GENMAI_H
+#define __GENMAI_H
+
+/* Internal RAM Size (RZ/A1=3M, RZ/A1M=5M, RZ/A1H=10M) */
+#define CFG_SYS_SDRAM_BASE 0x20000000
+#define CFG_SYS_SDRAM_SIZE (10 * 1024 * 1024)
+
+#endif /* __GENAMI_H */
diff --git a/include/configs/gose.h b/include/configs/gose.h
index 7ae0726518d..4a5954af76f 100644
--- a/include/configs/gose.h
+++ b/include/configs/gose.h
@@ -19,16 +19,6 @@
#define RCAR_GEN2_SDRAM_SIZE (1048u * 1024 * 1024)
#define RCAR_GEN2_UBOOT_SDRAM_SIZE (512u * 1024 * 1024)
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x1
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-
#define CFG_EXTRA_ENV_SETTINGS \
"bootm_size=0x10000000\0"
diff --git a/include/configs/grpeach.h b/include/configs/grpeach.h
index 8de4a36e931..e4564b67a79 100644
--- a/include/configs/grpeach.h
+++ b/include/configs/grpeach.h
@@ -8,20 +8,8 @@
#ifndef __GRPEACH_H
#define __GRPEACH_H
-/* Board Clock , P1 clock frequency (XTAL=13.33MHz) */
-
-/* Miscellaneous */
-
/* Internal RAM Size (RZ/A1=3M, RZ/A1M=5M, RZ/A1H=10M) */
#define CFG_SYS_SDRAM_BASE 0x20000000
#define CFG_SYS_SDRAM_SIZE (10 * 1024 * 1024)
-/* Network interface */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_MII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
#endif /* __GRPEACH_H */
diff --git a/include/configs/koelsch.h b/include/configs/koelsch.h
index d47d70178cc..c2713b77e0a 100644
--- a/include/configs/koelsch.h
+++ b/include/configs/koelsch.h
@@ -19,19 +19,7 @@
#define RCAR_GEN2_SDRAM_SIZE (2048u * 1024 * 1024)
#define RCAR_GEN2_UBOOT_SDRAM_SIZE (512 * 1024 * 1024)
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x1
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-
#define CFG_EXTRA_ENV_SETTINGS \
"bootm_size=0x10000000\0"
-/* SPL support */
-
#endif /* __KOELSCH_H */
diff --git a/include/configs/lager.h b/include/configs/lager.h
index 2577c7a7da6..13f327fabf2 100644
--- a/include/configs/lager.h
+++ b/include/configs/lager.h
@@ -20,19 +20,7 @@
#define RCAR_GEN2_SDRAM_SIZE (2048u * 1024 * 1024)
#define RCAR_GEN2_UBOOT_SDRAM_SIZE (512 * 1024 * 1024)
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x1
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-
#define CFG_EXTRA_ENV_SETTINGS \
"bootm_size=0x10000000\0"
-/* SPL support */
-
#endif /* __LAGER_H */
diff --git a/include/configs/porter.h b/include/configs/porter.h
index 2cb430be8b0..4612845db19 100644
--- a/include/configs/porter.h
+++ b/include/configs/porter.h
@@ -21,19 +21,7 @@
#define RCAR_GEN2_SDRAM_SIZE (2048u * 1024 * 1024)
#define RCAR_GEN2_UBOOT_SDRAM_SIZE (1024u * 1024 * 1024)
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x1
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-
#define CFG_EXTRA_ENV_SETTINGS \
"bootm_size=0x10000000\0"
-/* SPL support */
-
#endif /* __PORTER_H */
diff --git a/include/configs/silk.h b/include/configs/silk.h
index 7bed32d8553..09ef2a848bd 100644
--- a/include/configs/silk.h
+++ b/include/configs/silk.h
@@ -21,19 +21,7 @@
#define RCAR_GEN2_SDRAM_SIZE (1024u * 1024 * 1024)
#define RCAR_GEN2_UBOOT_SDRAM_SIZE (512 * 1024 * 1024)
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x1
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-
#define CFG_EXTRA_ENV_SETTINGS \
"bootm_size=0x10000000\0"
-/* SPL support */
-
#endif /* __SILK_H */
diff --git a/include/configs/stout.h b/include/configs/stout.h
index 1278ba63f4f..f98ebb324f3 100644
--- a/include/configs/stout.h
+++ b/include/configs/stout.h
@@ -25,19 +25,7 @@
/* SCIF */
#define CFG_SCIF_A
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x1
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RMII
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-
#define CFG_EXTRA_ENV_SETTINGS \
"bootm_size=0x10000000\0"
-/* SPL support */
-
#endif /* __STOUT_H */
diff --git a/include/configs/v3hsk.h b/include/configs/v3hsk.h
index 58c2e88c0b7..3298e627e53 100644
--- a/include/configs/v3hsk.h
+++ b/include/configs/v3hsk.h
@@ -12,17 +12,4 @@
#include "rcar-gen3-common.h"
-/* Environment compatibility */
-
-/* SH Ether */
-#define CFG_SH_ETHER_USE_PORT 0
-#define CFG_SH_ETHER_PHY_ADDR 0x0
-#define CFG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_RGMII_ID
-#define CFG_SH_ETHER_CACHE_WRITEBACK
-#define CFG_SH_ETHER_CACHE_INVALIDATE
-#define CFG_SH_ETHER_ALIGNE_SIZE 64
-
-/* Board Clock */
-/* XTAL_CLK : 33.33MHz */
-
#endif /* __V3HSK_H */
diff --git a/include/dt-bindings/clock/xlnx-zynqmp-clk.h b/include/dt-bindings/clock/xlnx-zynqmp-clk.h
deleted file mode 100644
index cdc4c0b9a37..00000000000
--- a/include/dt-bindings/clock/xlnx-zynqmp-clk.h
+++ /dev/null
@@ -1,126 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-/*
- * Xilinx Zynq MPSoC Firmware layer
- *
- * Copyright (C) 2014-2018 Xilinx, Inc.
- *
- */
-
-#ifndef _DT_BINDINGS_CLK_ZYNQMP_H
-#define _DT_BINDINGS_CLK_ZYNQMP_H
-
-#define IOPLL 0
-#define RPLL 1
-#define APLL 2
-#define DPLL 3
-#define VPLL 4
-#define IOPLL_TO_FPD 5
-#define RPLL_TO_FPD 6
-#define APLL_TO_LPD 7
-#define DPLL_TO_LPD 8
-#define VPLL_TO_LPD 9
-#define ACPU 10
-#define ACPU_HALF 11
-#define DBF_FPD 12
-#define DBF_LPD 13
-#define DBG_TRACE 14
-#define DBG_TSTMP 15
-#define DP_VIDEO_REF 16
-#define DP_AUDIO_REF 17
-#define DP_STC_REF 18
-#define GDMA_REF 19
-#define DPDMA_REF 20
-#define DDR_REF 21
-#define SATA_REF 22
-#define PCIE_REF 23
-#define GPU_REF 24
-#define GPU_PP0_REF 25
-#define GPU_PP1_REF 26
-#define TOPSW_MAIN 27
-#define TOPSW_LSBUS 28
-#define GTGREF0_REF 29
-#define LPD_SWITCH 30
-#define LPD_LSBUS 31
-#define USB0_BUS_REF 32
-#define USB1_BUS_REF 33
-#define USB3_DUAL_REF 34
-#define USB0 35
-#define USB1 36
-#define CPU_R5 37
-#define CPU_R5_CORE 38
-#define CSU_SPB 39
-#define CSU_PLL 40
-#define PCAP 41
-#define IOU_SWITCH 42
-#define GEM_TSU_REF 43
-#define GEM_TSU 44
-#define GEM0_TX 45
-#define GEM1_TX 46
-#define GEM2_TX 47
-#define GEM3_TX 48
-#define GEM0_RX 49
-#define GEM1_RX 50
-#define GEM2_RX 51
-#define GEM3_RX 52
-#define QSPI_REF 53
-#define SDIO0_REF 54
-#define SDIO1_REF 55
-#define UART0_REF 56
-#define UART1_REF 57
-#define SPI0_REF 58
-#define SPI1_REF 59
-#define NAND_REF 60
-#define I2C0_REF 61
-#define I2C1_REF 62
-#define CAN0_REF 63
-#define CAN1_REF 64
-#define CAN0 65
-#define CAN1 66
-#define DLL_REF 67
-#define ADMA_REF 68
-#define TIMESTAMP_REF 69
-#define AMS_REF 70
-#define PL0_REF 71
-#define PL1_REF 72
-#define PL2_REF 73
-#define PL3_REF 74
-#define WDT 75
-#define IOPLL_INT 76
-#define IOPLL_PRE_SRC 77
-#define IOPLL_HALF 78
-#define IOPLL_INT_MUX 79
-#define IOPLL_POST_SRC 80
-#define RPLL_INT 81
-#define RPLL_PRE_SRC 82
-#define RPLL_HALF 83
-#define RPLL_INT_MUX 84
-#define RPLL_POST_SRC 85
-#define APLL_INT 86
-#define APLL_PRE_SRC 87
-#define APLL_HALF 88
-#define APLL_INT_MUX 89
-#define APLL_POST_SRC 90
-#define DPLL_INT 91
-#define DPLL_PRE_SRC 92
-#define DPLL_HALF 93
-#define DPLL_INT_MUX 94
-#define DPLL_POST_SRC 95
-#define VPLL_INT 96
-#define VPLL_PRE_SRC 97
-#define VPLL_HALF 98
-#define VPLL_INT_MUX 99
-#define VPLL_POST_SRC 100
-#define CAN0_MIO 101
-#define CAN1_MIO 102
-#define ACPU_FULL 103
-#define GEM0_REF 104
-#define GEM1_REF 105
-#define GEM2_REF 106
-#define GEM3_REF 107
-#define GEM0_REF_UNG 108
-#define GEM1_REF_UNG 109
-#define GEM2_REF_UNG 110
-#define GEM3_REF_UNG 111
-#define LPD_WDT 112
-
-#endif
diff --git a/include/efi_api.h b/include/efi_api.h
index eb61eafa028..77a05f752e5 100644
--- a/include/efi_api.h
+++ b/include/efi_api.h
@@ -238,6 +238,10 @@ enum efi_reset_type {
EFI_GUID(0xcce33c35, 0x74ac, 0x4087, 0xbc, 0xe7, \
0x8b, 0x29, 0xb0, 0x2e, 0xeb, 0x27)
+#define EFI_DEBUG_IMAGE_INFO_TABLE_GUID \
+ EFI_GUID(0x49152e77, 0x1ada, 0x4764, 0xb7, 0xa2, \
+ 0x7a, 0xfe, 0xfe, 0xd9, 0x5e, 0x8b)
+
struct efi_conformance_profiles_table {
u16 version;
u16 number_of_profiles;
@@ -259,6 +263,22 @@ struct efi_capsule_result_variable_header {
efi_status_t capsule_status;
} __packed;
+/**
+ * struct efi_system_table_pointer - struct to store the pointer of system
+ * table.
+ * @signature: The signature of this struct.
+ * @efi_system_table_base: The physical address of System Table.
+ * @crc32: CRC32 checksum
+ *
+ * This struct is design for hardware debugger to search through memory to
+ * get the address of EFI System Table.
+ */
+struct efi_system_table_pointer {
+ u64 signature;
+ efi_physical_addr_t efi_system_table_base;
+ u32 crc32;
+};
+
struct efi_memory_range {
efi_physical_addr_t address;
u64 length;
@@ -558,6 +578,57 @@ struct efi_loaded_image {
efi_status_t (EFIAPI *unload)(efi_handle_t image_handle);
};
+#define EFI_DEBUG_IMAGE_INFO_UPDATE_IN_PROGRESS 0x01
+#define EFI_DEBUG_IMAGE_INFO_TABLE_MODIFIED 0x02
+
+#define EFI_DEBUG_IMAGE_INFO_TYPE_NORMAL 0x01
+
+/**
+ * struct efi_debug_image_info_normal - Store Debug Information for normal
+ * image.
+ * @image_info_type: the type of image info.
+ * @loaded_image_protocol_instance: the pointer to struct efi_loaded_image.
+ * @image_handle: the EFI handle of the image.
+ *
+ * This struct is created by efi_load_image() and store the information
+ * for debugging an normal image.
+ */
+struct efi_debug_image_info_normal {
+ u32 image_info_type;
+ struct efi_loaded_image *loaded_image_protocol_instance;
+ efi_handle_t image_handle;
+};
+
+/**
+ * union efi_debug_image_info - The union to store a pointer for EFI
+ * DEBUG IMAGE INFO.
+ * @image_info_type: the type of the image_info if it is not a normal image.
+ * @normal_image: The pointer to a normal image.
+ *
+ * This union is for a pointer that can point to the struct of normal_image.
+ * Or it points to an image_info_type.
+ */
+union efi_debug_image_info {
+ u32 *image_info_type;
+ struct efi_debug_image_info_normal *normal_image;
+};
+
+/**
+ * struct efi_debug_image_info_table_header - store the array of
+ * struct efi_debug_image_info.
+ * @update_status: Status to notify this struct is ready to use or not.
+ * @table_size: The number of elements of efi_debug_image_info_table.
+ * @efi_debug_image_info_table: The array of efi_debug_image_info.
+ *
+ * This struct stores the array of efi_debug_image_info. The
+ * number of elements is table_size.
+ */
+struct efi_debug_image_info_table_header {
+ volatile u32 update_status;
+ u32 table_size;
+ union efi_debug_image_info *efi_debug_image_info_table;
+};
+
#define EFI_DEVICE_PATH_PROTOCOL_GUID \
EFI_GUID(0x09576e91, 0x6d3f, 0x11d2, \
0x8e, 0x39, 0x00, 0xa0, 0xc9, 0x69, 0x72, 0x3b)
diff --git a/include/efi_config.h b/include/efi_config.h
index d7c1601137e..23211e799fc 100644
--- a/include/efi_config.h
+++ b/include/efi_config.h
@@ -82,6 +82,7 @@ struct eficonfig_item {
* @current_volume: pointer to the efi_simple_file_system_protocol
* @dp_volume: pointer to device path of the selected device
* @current_path: pointer to the selected file path string
+ * @uri: URI for HTTP Boot
* @filepath_list: list_head structure for file path list
* @file_selectred: flag indicates file selecting status
*/
@@ -89,6 +90,7 @@ struct eficonfig_select_file_info {
struct efi_simple_file_system_protocol *current_volume;
struct efi_device_path *dp_volume;
u16 *current_path;
+ u16 *uri;
struct list_head filepath_list;
bool file_selected;
};
diff --git a/include/efi_loader.h b/include/efi_loader.h
index 8fd09aad2d0..3e70ac07055 100644
--- a/include/efi_loader.h
+++ b/include/efi_loader.h
@@ -312,6 +312,8 @@ extern const struct efi_hii_config_routing_protocol efi_hii_config_routing;
extern const struct efi_hii_config_access_protocol efi_hii_config_access;
extern const struct efi_hii_database_protocol efi_hii_database;
extern const struct efi_hii_string_protocol efi_hii_string;
+/* structure for EFI_DEBUG_SUPPORT_PROTOCOL */
+extern struct efi_debug_image_info_table_header efi_m_debug_info_table_header;
uint16_t *efi_dp_str(struct efi_device_path *dp);
@@ -643,6 +645,13 @@ efi_status_t efi_tcg2_measure_dtb(void *dtb);
efi_status_t efi_root_node_register(void);
/* Called by bootefi to initialize runtime */
efi_status_t efi_initialize_system_table(void);
+/* Called by bootefi to initialize debug */
+efi_status_t efi_initialize_system_table_pointer(void);
+/* Called by efi_load_image for register debug info */
+efi_status_t efi_core_new_debug_image_info_entry(u32 image_info_type,
+ struct efi_loaded_image *loaded_image,
+ efi_handle_t image_handle);
+void efi_core_remove_debug_image_info_entry(efi_handle_t image_handle);
/* efi_runtime_detach() - detach unimplemented runtime functions */
void efi_runtime_detach(void);
/* efi_convert_pointer() - convert pointer to virtual address */
@@ -871,6 +880,16 @@ efi_status_t efi_next_variable_name(efi_uintn_t *size, u16 **buf,
#define efi_size_in_pages(size) (((size) + EFI_PAGE_MASK) >> EFI_PAGE_SHIFT)
/* Allocate boot service data pool memory */
void *efi_alloc(size_t len);
+/**
+ * efi_realloc() - reallocate boot services data pool memory
+ *
+ * Reallocate memory from pool for a new size and copy the data from old one.
+ *
+ * @ptr: pointer to the buffer
+ * @size: number of bytes to allocate
+ * Return: EFI status to indicate success or not
+ */
+efi_status_t efi_realloc(void **ptr, size_t len);
/* Allocate pages on the specified alignment */
void *efi_alloc_aligned_pages(u64 len, int memory_type, size_t align);
/* More specific EFI memory allocator, called by EFI payloads */
diff --git a/include/fdt_support.h b/include/fdt_support.h
index 049190cf3d7..47b8b63d13d 100644
--- a/include/fdt_support.h
+++ b/include/fdt_support.h
@@ -240,11 +240,16 @@ int board_rng_seed(struct abuf *buf);
*/
const char *board_fdt_chosen_bootargs(const struct fdt_property *fdt_ba);
-/*
- * The keystone2 SOC requires all 32 bit aliased addresses to be converted
- * to their 36 physical format. This has to happen after all fdt nodes
- * are added or modified by the image_setup_libfdt(). The ft_board_setup_ex()
- * called at the end of the image_setup_libfdt() is to do that convertion.
+/**
+ * ft_board_setup_ex() - Latest board-specific FDT changes
+ *
+ * @blob: FDT blob to update
+ * @bd: Pointer to board data
+ *
+ * Execute board-specific device tree modifications that must be the latest FDT
+ * changes and cannot be overwritten by other system fixups.
+ *
+ * This function is called if CONFIG_OF_BOARD_SETUP_EXTENDED is defined.
*/
void ft_board_setup_ex(void *blob, struct bd_info *bd);
diff --git a/include/log.h b/include/log.h
index dd44badc361..59c66eb7909 100644
--- a/include/log.h
+++ b/include/log.h
@@ -176,7 +176,7 @@ int _log_buffer(enum log_category_t cat, enum log_level_t level,
#define _LOG_MAX_LEVEL LOGL_INFO
#endif
-#define log_emer(_fmt...) log(LOG_CATEGORY, LOGL_EMERG, ##_fmt)
+#define log_emerg(_fmt...) log(LOG_CATEGORY, LOGL_EMERG, ##_fmt)
#define log_alert(_fmt...) log(LOG_CATEGORY, LOGL_ALERT, ##_fmt)
#define log_crit(_fmt...) log(LOG_CATEGORY, LOGL_CRIT, ##_fmt)
#define log_err(_fmt...) log(LOG_CATEGORY, LOGL_ERR, ##_fmt)
diff --git a/include/ndisc.h b/include/ndisc.h
index d0fe3acca4a..7d9e58aa1c2 100644
--- a/include/ndisc.h
+++ b/include/ndisc.h
@@ -10,8 +10,6 @@
#ifndef __NDISC_H__
#define __NDISC_H__
-#include <ndisc.h>
-
/* struct nd_msg - ICMPv6 Neighbour Discovery message format */
struct nd_msg {
struct icmp6hdr icmph;
diff --git a/include/net-common.h b/include/net-common.h
index c04f86bdfcc..1112af381a9 100644
--- a/include/net-common.h
+++ b/include/net-common.h
@@ -492,6 +492,17 @@ int dhcp_run(ulong addr, const char *fname, bool autoload);
int do_ping(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]);
/**
+ * do_sntp - Run the sntp command
+ *
+ * @cmdtp: Unused
+ * @flag: Command flags (CMD_FLAG_...)
+ * @argc: Number of arguments
+ * @argv: List of arguments
+ * Return: result (see enum command_ret_t)
+ */
+int do_sntp(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[]);
+
+/**
* do_tftpb - Run the tftpboot command
*
* @cmdtp: Command information for tftpboot
@@ -574,4 +585,6 @@ extern struct wget_http_info default_wget_info;
extern struct wget_http_info *wget_info;
int wget_request(ulong dst_addr, char *uri, struct wget_http_info *info);
+void net_sntp_set_rtc(u32 seconds);
+
#endif /* __NET_COMMON_H__ */
diff --git a/include/net-lwip.h b/include/net-lwip.h
index b762956e8fd..f54f23471f1 100644
--- a/include/net-lwip.h
+++ b/include/net-lwip.h
@@ -6,6 +6,20 @@
#include <lwip/ip4.h>
#include <lwip/netif.h>
+/* HTTPS authentication mode */
+enum auth_mode {
+ AUTH_NONE,
+ AUTH_OPTIONAL,
+ AUTH_REQUIRED,
+};
+
+extern char *cacert;
+extern size_t cacert_size;
+extern enum auth_mode cacert_auth_mode;
+extern bool cacert_initialized;
+
+int set_cacert_builtin(void);
+
enum proto_t {
TFTPGET
};
@@ -17,12 +31,14 @@ static inline int eth_is_on_demand_init(void)
int eth_init_state_only(void); /* Set active state */
+int net_lwip_dns_init(void);
int net_lwip_eth_start(void);
struct netif *net_lwip_new_netif(struct udevice *udev);
struct netif *net_lwip_new_netif_noip(struct udevice *udev);
void net_lwip_remove_netif(struct netif *netif);
struct netif *net_lwip_get_netif(void);
int net_lwip_rx(struct udevice *udev, struct netif *netif);
+int net_lwip_dns_resolve(char *name_or_ip, ip_addr_t *ip);
/**
* wget_validate_uri() - varidate the uri
diff --git a/include/part.h b/include/part.h
index 7075b2cb116..b772fb34c8a 100644
--- a/include/part.h
+++ b/include/part.h
@@ -8,7 +8,6 @@
#include <blk.h>
#include <u-boot/uuid.h>
-#include <linker_lists.h>
#include <linux/errno.h>
#include <linux/list.h>
@@ -647,6 +646,20 @@ int gpt_verify_partitions(struct blk_desc *desc,
*/
int get_disk_guid(struct blk_desc *desc, char *guid);
+/**
+ * part_get_gpt_pte() - Get the GPT partition table entry of a partition
+ *
+ * This function reads the GPT partition table entry (PTE) for a given
+ * block device and partition number.
+ *
+ * @desc: block device descriptor
+ * @part: partition number for which to return the PTE
+ * @gpt_e: GPT partition table entry
+ *
+ * Return: 0 on success, otherwise error
+ */
+int part_get_gpt_pte(struct blk_desc *desc, int part, gpt_entry *gpt_e);
+
#endif
#if CONFIG_IS_ENABLED(DOS_PARTITION)
diff --git a/include/part_efi.h b/include/part_efi.h
index 59b7895b8a2..fb402df6f13 100644
--- a/include/part_efi.h
+++ b/include/part_efi.h
@@ -138,4 +138,24 @@ typedef struct _legacy_mbr {
__le16 signature;
} __packed legacy_mbr;
+#define EFI_PARTITION_INFO_PROTOCOL_GUID \
+ EFI_GUID(0x8cf2f62c, 0xbc9b, 0x4821, 0x80, \
+ 0x8d, 0xec, 0x9e, 0xc4, 0x21, 0xa1, 0xa0)
+
+#define EFI_PARTITION_INFO_PROTOCOL_REVISION 0x0001000
+#define PARTITION_TYPE_OTHER 0x00
+#define PARTITION_TYPE_MBR 0x01
+#define PARTITION_TYPE_GPT 0x02
+
+struct efi_partition_info {
+ u32 revision;
+ u32 type;
+ u8 system;
+ u8 reserved[7];
+ union {
+ struct partition mbr;
+ gpt_entry gpt;
+ } info;
+} __packed;
+
#endif /* _DISK_PART_EFI_H */
diff --git a/include/sata.h b/include/sata.h
index 8414e77e42b..868e89464f0 100644
--- a/include/sata.h
+++ b/include/sata.h
@@ -1,6 +1,7 @@
#ifndef __SATA_H__
#define __SATA_H__
-#include <part.h>
+
+#include <stdbool.h>
int sata_probe(int devnum);
int sata_remove(int devnum);
diff --git a/include/spl_gpio.h b/include/spl_gpio.h
index b33261a6485..a8aed4d77b9 100644
--- a/include/spl_gpio.h
+++ b/include/spl_gpio.h
@@ -9,7 +9,7 @@
#ifndef __SPL_GPIO_H
#define __SPL_GPIO_H
-#include <asm/gpio.h>
+#include <linux/types.h>
/*
* The functions listed here should be implemented in the SoC GPIO driver.
diff --git a/include/tca642x.h b/include/tca642x.h
deleted file mode 100644
index c0a3cef5bd5..00000000000
--- a/include/tca642x.h
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright 2013 Texas Instruments, Inc.
- * Author: Dan Murphy <dmurphy@ti.com>
- *
- * Derived work from the pca953x.c driver
- *
- * 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., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-
-#ifndef __TCA642X_H_
-#define __TCA642X_H_
-
-#ifdef CONFIG_CMD_TCA642X
-enum {
- TCA642X_CMD_INFO,
- TCA642X_CMD_DEVICE,
- TCA642X_CMD_OUTPUT,
- TCA642X_CMD_INPUT,
- TCA642X_CMD_INVERT,
-};
-#endif
-
-#define TCA642X_OUT_LOW 0
-#define TCA642X_OUT_HIGH 1
-#define TCA642X_POL_NORMAL 0
-#define TCA642X_POL_INVERT 1
-#define TCA642X_DIR_OUT 0
-#define TCA642X_DIR_IN 1
-
-/* Default to an address that hopefully won't corrupt other i2c devices */
-#ifndef CFG_SYS_I2C_TCA642X_ADDR
-#define CFG_SYS_I2C_TCA642X_ADDR (~0)
-#endif
-
-/* Default to an address that hopefully won't corrupt other i2c devices */
-#ifndef CFG_SYS_I2C_TCA642X_BUS_NUM
-#define CFG_SYS_I2C_TCA642X_BUS_NUM (0)
-#endif
-
-struct tca642x_bank_info {
- uint8_t input_reg;
- uint8_t output_reg;
- uint8_t polarity_reg;
- uint8_t configuration_reg;
-};
-
-int tca642x_set_val(uchar chip, uint8_t gpio_bank,
- uint8_t reg_bit, uint8_t data);
-int tca642x_set_pol(uchar chip, uint8_t gpio_bank,
- uint8_t reg_bit, uint8_t data);
-int tca642x_set_dir(uchar chip, uint8_t gpio_bank,
- uint8_t reg_bit, uint8_t data);
-int tca642x_get_val(uchar chip, uint8_t gpio_bank);
-int tca642x_set_inital_state(uchar chip, struct tca642x_bank_info init_data[]);
-
-#endif /* __TCA642X_H_ */
diff --git a/include/tpm-v2.h b/include/tpm-v2.h
index ece422df0c7..f3eb2ef5643 100644
--- a/include/tpm-v2.h
+++ b/include/tpm-v2.h
@@ -20,6 +20,7 @@
#define __TPM_V2_H
#include <tpm-common.h>
+#include <linux/errno.h>
struct udevice;
@@ -266,6 +267,7 @@ enum tpm2_return_codes {
* TPM2 algorithms.
*/
enum tpm2_algorithms {
+ TPM2_ALG_INVAL = -EINVAL,
TPM2_ALG_SHA1 = 0x04,
TPM2_ALG_XOR = 0x0A,
TPM2_ALG_SHA256 = 0x0B,
diff --git a/include/tsi148.h b/include/tsi148.h
deleted file mode 100644
index a9f353b9080..00000000000
--- a/include/tsi148.h
+++ /dev/null
@@ -1,201 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0+ */
-/*
- * (C) Copyright 2009 Reinhard Arlt, reinhard.arlt@esd-electronics.com
- *
- * base on universe.h by
- *
- * (C) Copyright 2003 Stefan Roese, stefan.roese@esd-electronics.com
- */
-
-#ifndef _tsi148_h
-#define _tsi148_h
-
-#ifndef PCI_DEVICE_ID_TUNDRA_TSI148
-#define PCI_DEVICE_ID_TUNDRA_TSI148 0x0148
-#endif
-
-typedef struct _TSI148 TSI148;
-typedef struct _OUTBOUND OUTBOUND;
-typedef struct _INBOUND INBOUND;
-typedef struct _TDMA_CMD_PACKET TDMA_CMD_PACKET;
-
-struct _OUTBOUND {
- unsigned int otsau; /* 0x000 Outbound start upper */
- unsigned int otsal; /* 0x004 Outbouud start lower */
- unsigned int oteau; /* 0x008 Outbound end upper */
- unsigned int oteal; /* 0x00c Outbound end lower */
- unsigned int otofu; /* 0x010 Outbound translation upper */
- unsigned int otofl; /* 0x014 Outbound translation lower */
- unsigned int otbs; /* 0x018 Outbound translation 2eSST */
- unsigned int otat; /* 0x01c Outbound translation attr */
-};
-
-struct _INBOUND {
- unsigned int itsau; /* 0x000 inbound start upper */
- unsigned int itsal; /* 0x004 inbouud start lower */
- unsigned int iteau; /* 0x008 inbound end upper */
- unsigned int iteal; /* 0x00c inbound end lower */
- unsigned int itofu; /* 0x010 inbound translation upper */
- unsigned int itofl; /* 0x014 inbound translation lower */
- unsigned int itat; /* 0x018 inbound translation attr */
- unsigned int spare; /* 0x01c not used */
-};
-
-struct _TSI148 {
- unsigned int pci_id; /* 0x000 */
- unsigned int pci_csr; /* 0x004 */
- unsigned int pci_class; /* 0x008 */
- unsigned int pci_misc0; /* 0x00c */
- unsigned int pci_mbarl; /* 0x010 */
- unsigned int pci_mbarh; /* 0x014 */
- unsigned int spare0[(0x03c-0x018)/4]; /* 0x018 */
- unsigned int pci_misc1; /* 0x03c */
- unsigned int pci_pcixcap; /* 0x040 */
- unsigned int pci_pcixstat; /* 0x044 */
- unsigned int spare1[(0x100-0x048)/4]; /* 0x048 */
- OUTBOUND outbound[8]; /* 0x100 */
- unsigned int viack[8]; /* 0x204 */
- unsigned int rmwau; /* 0x220 */
- unsigned int rmwal; /* 0x224 */
- unsigned int rmwen; /* 0x228 */
- unsigned int rmwc; /* 0x22c */
- unsigned int rmws; /* 0x230 */
- unsigned int vmctrl; /* 0x234 */
- unsigned int vctrl; /* 0x238 */
- unsigned int vstat; /* 0x23c */
- unsigned int pcsr; /* 0x240 */
- unsigned int spare2[3]; /* 0x244 - 0x24c */
- unsigned int vmefl; /* 0x250 */
- unsigned int spare3[3]; /* 0x254 - 0x25c */
- unsigned int veau; /* 0x260 */
- unsigned int veal; /* 0x264 */
- unsigned int veat; /* 0x268 */
- unsigned int spare4[1]; /* 0x26c */
- unsigned int edpau; /* 0x270 */
- unsigned int edpal; /* 0x274 */
- unsigned int edpxa; /* 0x278 */
- unsigned int edpxs; /* 0x27c */
- unsigned int edpat; /* 0x280 */
- unsigned int spare5[31]; /* 0x284 - 0x2fc */
- INBOUND inbound[8]; /* 0x100 */
- unsigned int gbau; /* 0x400 */
- unsigned int gbal; /* 0x404 */
- unsigned int gcsrat; /* 0x408 */
- unsigned int cbau; /* 0x40c */
- unsigned int cbal; /* 0x410 */
- unsigned int crgat; /* 0x414 */
- unsigned int crou; /* 0x418 */
- unsigned int crol; /* 0x41c */
- unsigned int crat; /* 0x420 */
- unsigned int lmbau; /* 0x424 */
- unsigned int lmbal; /* 0x428 */
- unsigned int lmat; /* 0x42c */
- unsigned int r64bcu; /* 0x430 */
- unsigned int r64bcl; /* 0x434 */
- unsigned int bpgtr; /* 0x438 */
- unsigned int bpctr; /* 0x43c */
- unsigned int vicr; /* 0x440 */
- unsigned int spare6[1]; /* 0x444 */
- unsigned int inten; /* 0x448 */
- unsigned int inteo; /* 0x44c */
- unsigned int ints; /* 0x450 */
- unsigned int intc; /* 0x454 */
- unsigned int intm1; /* 0x458 */
- unsigned int intm2; /* 0x45c */
- unsigned int spare7[40]; /* 0x460 - 0x4fc */
- unsigned int dctl0; /* 0x500 */
- unsigned int dsta0; /* 0x504 */
- unsigned int dcsau0; /* 0x508 */
- unsigned int dcsal0; /* 0x50c */
- unsigned int dcdau0; /* 0x510 */
- unsigned int dcdal0; /* 0x514 */
- unsigned int dclau0; /* 0x518 */
- unsigned int dclal0; /* 0x51c */
- unsigned int dsau0; /* 0x520 */
- unsigned int dsal0; /* 0x524 */
- unsigned int ddau0; /* 0x528 */
- unsigned int ddal0; /* 0x52c */
- unsigned int dsat0; /* 0x530 */
- unsigned int ddat0; /* 0x534 */
- unsigned int dnlau0; /* 0x538 */
- unsigned int dnlal0; /* 0x53c */
- unsigned int dcnt0; /* 0x540 */
- unsigned int ddbs0; /* 0x544 */
- unsigned int r20[14]; /* 0x548 - 0x57c */
- unsigned int dctl1; /* 0x580 */
- unsigned int dsta1; /* 0x584 */
- unsigned int dcsau1; /* 0x588 */
- unsigned int dcsal1; /* 0x58c */
- unsigned int dcdau1; /* 0x590 */
- unsigned int dcdal1; /* 0x594 */
- unsigned int dclau1; /* 0x598 */
- unsigned int dclal1; /* 0x59c */
- unsigned int dsau1; /* 0x5a0 */
- unsigned int dsal1; /* 0x5a4 */
- unsigned int ddau1; /* 0x5a8 */
- unsigned int ddal1; /* 0x5ac */
- unsigned int dsat1; /* 0x5b0 */
- unsigned int ddat1; /* 0x5b4 */
- unsigned int dnlau1; /* 0x5b8 */
- unsigned int dnlal1; /* 0x5bc */
- unsigned int dcnt1; /* 0x5c0 */
- unsigned int ddbs1; /* 0x5c4 */
- unsigned int r21[14]; /* 0x5c8 - 0x5fc */
- unsigned int devi_veni_2; /* 0x600 */
- unsigned int gctrl_ga_revid; /* 0x604 */
- unsigned int semaphore0_1_2_3; /* 0x608 */
- unsigned int semaphore4_5_6_7; /* 0x60c */
- unsigned int mbox0; /* 0x610 */
- unsigned int mbox1; /* 0x614 */
- unsigned int mbox2; /* 0x618 */
- unsigned int mbox3; /* 0x61c */
- unsigned int r22[629]; /* 0x620 - 0xff0 */
- unsigned int csrbcr; /* 0xff4 */
- unsigned int csrbsr; /* 0xff8 */
- unsigned int cbar; /* 0xffc */
-};
-
-#define IRQ_VOWN 0x0001
-#define IRQ_VIRQ1 0x0002
-#define IRQ_VIRQ2 0x0004
-#define IRQ_VIRQ3 0x0008
-#define IRQ_VIRQ4 0x0010
-#define IRQ_VIRQ5 0x0020
-#define IRQ_VIRQ6 0x0040
-#define IRQ_VIRQ7 0x0080
-#define IRQ_DMA 0x0100
-#define IRQ_LERR 0x0200
-#define IRQ_VERR 0x0400
-#define IRQ_res 0x0800
-#define IRQ_IACK 0x1000
-#define IRQ_SWINT 0x2000
-#define IRQ_SYSFAIL 0x4000
-#define IRQ_ACFAIL 0x8000
-
-struct _TDMA_CMD_PACKET {
- unsigned int dctl; /* DMA Control */
- unsigned int dtbc; /* Transfer Byte Count */
- unsigned int dlv; /* PCI Address */
- unsigned int res1; /* Reserved */
- unsigned int dva; /* Vme Address */
- unsigned int res2; /* Reserved */
- unsigned int dcpp; /* Pointer to Numed Cmd Packet with rPN */
- unsigned int res3; /* Reserved */
-};
-
-#define VME_AM_A16 0x01
-#define VME_AM_A24 0x02
-#define VME_AM_A32 0x03
-#define VME_AM_Axx 0x03
-#define VME_AM_USR 0x04
-#define VME_AM_SUP 0x08
-#define VME_AM_DATA 0x10
-#define VME_AM_PROG 0x20
-#define VME_AM_Mxx (VME_AM_DATA | VME_AM_PROG)
-
-#define VME_FLAG_D8 0x01
-#define VME_FLAG_D16 0x02
-#define VME_FLAG_D32 0x03
-#define VME_FLAG_Dxx 0x03
-
-#endif
diff --git a/include/vsc9953.h b/include/vsc9953.h
index fd52c93044b..1a1455af4f9 100644
--- a/include/vsc9953.h
+++ b/include/vsc9953.h
@@ -8,8 +8,6 @@
#ifndef _VSC9953_H_
#define _VSC9953_H_
-#include <config.h>
-#include <miiphy.h>
#include <asm/types.h>
#include <linux/bitops.h>
diff --git a/include/zynqmp_firmware.h b/include/zynqmp_firmware.h
index dc06abc52fc..7ef8a58847f 100644
--- a/include/zynqmp_firmware.h
+++ b/include/zynqmp_firmware.h
@@ -8,6 +8,8 @@
#ifndef _ZYNQMP_FIRMWARE_H_
#define _ZYNQMP_FIRMWARE_H_
+#include <compiler.h>
+
enum pm_api_id {
PM_GET_API_VERSION = 1,
PM_SET_CONFIGURATION = 2,
@@ -512,4 +514,11 @@ struct zynqmp_ipi_msg {
#define PM_REG_PMC_GLOBAL_NODE 0x30000004
#define PMC_MULTI_BOOT_MODE_REG_OFFSET 0x4
+#define __data __section(".data")
+
+typedef int (*smc_call_handler_t)(u32 api_id, u32 arg0, u32 arg1, u32 arg2,
+ u32 arg3, u32 *ret_payload);
+
+extern smc_call_handler_t __data smc_call_handler;
+
#endif /* _ZYNQMP_FIRMWARE_H_ */