diff options
Diffstat (limited to 'include')
455 files changed, 2104 insertions, 5921 deletions
diff --git a/include/asm-generic/global_data.h b/include/asm-generic/global_data.h index 16fd305a65c..104282bd479 100644 --- a/include/asm-generic/global_data.h +++ b/include/asm-generic/global_data.h @@ -244,6 +244,10 @@ struct global_data { * @fdt_size: space reserved for relocated device space */ unsigned long fdt_size; + /** + * @fdt_src: Source of FDT + */ + enum fdt_source_t fdt_src; #if CONFIG_IS_ENABLED(OF_LIVE) /** * @of_root: root node of the live tree @@ -512,6 +516,14 @@ static_assert(sizeof(struct global_data) == GD_SIZE); #define gd_acpi_ctx() NULL #endif +#if CONFIG_IS_ENABLED(MULTI_DTB_FIT) +#define gd_multi_dtb_fit() gd->multi_dtb_fit +#define gd_set_multi_dtb_fit(_dtb) gd->multi_dtb_fit = _dtb +#else +#define gd_multi_dtb_fit() NULL +#define gd_set_multi_dtb_fit(_dtb) +#endif + /** * enum gd_flags - global data flags * diff --git a/include/bedbug/bedbug.h b/include/bedbug/bedbug.h deleted file mode 100644 index 0c5d687f83e..00000000000 --- a/include/bedbug/bedbug.h +++ /dev/null @@ -1,40 +0,0 @@ -/* $Id$ */ - -#ifndef _BEDBUG_H -#define _BEDBUG_H - -#ifndef NULL -#define NULL 0 -#endif - -#define _USE_PROTOTYPES - -#ifndef isblank -#define isblank(c) isspace((int)(c)) -#endif - -#ifndef __P -#if defined(_USE_PROTOTYPES) && (defined(__STDC__) || defined(__cplusplus)) -#define __P(protos) protos /* full-blown ANSI C */ -#else -#define __P(protos) () /* traditional C preprocessor */ -#endif -#endif - -#endif /* _BEDBUG_H */ - - -/* - * Copyright (c) 2001 William L. Pitts - * All rights reserved. - * - * Redistribution and use in source and binary forms are freely - * permitted provided that the above copyright notice and this - * paragraph and the following disclaimer are duplicated in all - * such forms. - * - * This software is provided "AS IS" and without any express or - * implied warranties, including, without limitation, the implied - * warranties of merchantability and fitness for a particular - * purpose. - */ diff --git a/include/bedbug/ppc.h b/include/bedbug/ppc.h deleted file mode 100644 index 76d86fdbf76..00000000000 --- a/include/bedbug/ppc.h +++ /dev/null @@ -1,408 +0,0 @@ -/* $Id$ */ - -#ifndef _PPC_H -#define _PPC_H - -/*====================================================================== - * - * OPERANDS - * - *======================================================================*/ - -enum OP_FIELD { - O_AA = 1, O_BD, O_BI, O_BO, O_crbD, O_crbA, O_crbB, O_CRM, O_d, O_frC, O_frD, - O_frS, O_IMM, O_LI, O_LK, O_MB, O_ME, O_NB, O_OE, O_rA, O_rB, O_Rc, O_rD, - O_rS, O_SH, O_SIMM, O_SR, O_TO, O_UIMM, O_crfD, O_crfS, O_L, O_spr, O_tbr, - O_cr2 }; - -struct operand { - enum OP_FIELD field; /* The operand identifier from the - enum above */ - - char * name; /* Symbolic name of this operand */ - - unsigned int bits; /* The number of bits used by this - operand */ - - unsigned int shift; /* How far to the right the operand - should be shifted so that it is - aligned at the beginning of the - word */ - - unsigned int hint; /* A bitwise-inclusive-OR of the - values shown below. These are used - tell the disassembler how to print - this operand */ -}; - -/* Values for operand hint */ -#define OH_SILENT 0x01 /* dont print this operand */ -#define OH_ADDR 0x02 /* this operand is an address */ -#define OH_REG 0x04 /* this operand is a register */ -#define OH_SPR 0x08 /* this operand is an SPR */ -#define OH_TBR 0x10 /* this operand is a TBR */ -#define OH_OFFSET 0x20 /* this operand is an offset */ -#define OH_LITERAL 0x40 /* a literal string */ - - -/*====================================================================== - * - * OPCODES - * - *======================================================================*/ - -/* From the MPCxxx instruction set documentation, all instructions are - * 32 bits long and word aligned. Bits 0-5 always specify the primary - * opcode. Many instructions also have an extended opcode. - */ - -#define GET_OPCD(i) (((unsigned long)(i) >> 26) & 0x3f) -#define MAKE_OPCODE(i) ((((unsigned long)(i)) & 0x3f) << 26) - -/* The MPC860 User's Manual, Appendix D.4 contains the definitions of the - * instruction forms - */ - - -/*------------------------------------------------- - * I-Form Instructions: - * bX - *------------------------------------------------- - * OPCD | LI |AA|LK - *-------------------------------------------------*/ - -#define I_OPCODE(i,aa,lk) (MAKE_OPCODE(i) | (((aa) & 0x1) << 1) | ((lk) & 0x1)) -#define I_MASK I_OPCODE(0x3f,0x1,0x1) - - -/*------------------------------------------------- - * B-Form Instructions: - * bcX - *------------------------------------------------- - * OPCD | BO | BI | BD |AA|LK - *-------------------------------------------------*/ - -#define B_OPCODE(i,aa,lk) (MAKE_OPCODE(i) | (((aa) & 0x1) << 1) | ((lk) & 0x1)) -#define B_MASK B_OPCODE(0x3f,0x1,0x1) - - -/*------------------------------------------------- - * SC-Form Instructions: - * sc - *------------------------------------------------- - * OPCD | 00000 | 00000 | 00000000000000 |1|0 - *-------------------------------------------------*/ - -#define SC_OPCODE(i) (MAKE_OPCODE(i) | 0x2) -#define SC_MASK SC_OPCODE(0x3f) - - -/*------------------------------------------------- - * D-Form Instructions: - * addi addic addic. addis andi. andis. cmpi cmpli - * lbz lbzu lha lhau lhz lhzu lmw lwz lwzu mulli - * ori oris stb stbu sth sthu stmw stw stwu subfic - * twi xori xoris - *------------------------------------------------- - * OPCD | D | A | d - * OPCD | D | A | SIMM - * OPCD | S | A | d - * OPCD | S | A | UIMM - * OPCD |crfD|0|L| A | SIMM - * OPCD |crfD|0|L| A | UIMM - * OPCD | TO | A | SIMM - *-------------------------------------------------*/ - -#define D_OPCODE(i) MAKE_OPCODE(i) -#define D_MASK MAKE_OPCODE(0x3f) - - -/*------------------------------------------------- - * DS-Form Instructions: - * (none supported by MPC860) - *------------------------------------------------- - * OPCD | D | A | ds |XO - * OPCD | S | A | ds |XO - *-------------------------------------------------*/ - -#define DS_OPCODE(i,xo) (MAKE_OPCODE(i) | ((xo) & 0x3)) -#define DS_MASK DS_OPCODE(0x3f,0x1) - - -/*--------------------------------------------------- - * X-Form Instructions: - * andX andcX cmp cmpl cntlzwX dcbf dcbi dcbst dcbt - * dcbtst dcbz eciwx ecowx eieio eqvX extsbX extshX - * icbi lbzux lbxz lhaux lhax lhbrx lhzux lhxz lswi - * lswx lwarx lwbrx lwzux lwxz mcrfs mcrxr mfcr - * mfmsr mfsr mfsrin mtmsr mtsr mtsrin nandX norX - * orX orcX slwX srawX srawiX srwX stbux stbx - * sthbrx sthuxsthx stswi stswx stwbrx stwcx. stwux - * stwx sync tlbie tlbld tlbli tlbsync tw xorX - *--------------------------------------------------- - * OPCD | D | A | B | XO |0 - * OPCD | D | A | NB | XO |0 - * OPCD | D | 00000 | B | XO |0 - * OPCD | D | 00000 | 00000 | XO |0 - * OPCD | D |0| SR | 00000 | XO |0 - * OPCD | S | A | B | XO |Rc - * OPCD | S | A | B | XO |1 - * OPCD | S | A | B | XO |0 - * OPCD | S | A | NB | XO |0 - * OPCD | S | A | 00000 | XO |Rc - * OPCD | S | 00000 | B | XO |0 - * OPCD | S | 00000 | 00000 | XO |0 - * OPCD | S |0| SR | 00000 | XO |0 - * OPCD | S | A | SH | XO |Rc - * OPCD |crfD|0|L| A | SH | XO |0 - * OPCD |crfD |00| A | B | XO |0 - * OPCD |crfD |00|crfS |00| 00000 | XO |0 - * OPCD |crfD |00| 00000 | 00000 | XO |0 - * OPCD |crfD |00| 00000 | IMM |0| XO |Rc - * OPCD | TO | A | B | XO |0 - * OPCD | D | 00000 | B | XO |Rc - * OPCD | D | 00000 | 00000 | XO |Rc - * OPCD | crbD | 00000 | 00000 | XO |Rc - * OPCD | 00000 | A | B | XO |0 - * OPCD | 00000 | 00000 | B | XO |0 - * OPCD | 00000 | 00000 | 00000 | XO |0 - *---------------------------------------------------*/ - -#define X_OPCODE(i,xo,rc) (MAKE_OPCODE(i) | (((xo) & 0x3ff) << 1) | \ - ((rc) & 0x1)) -#define X_MASK X_OPCODE(0x3f,0x3ff,0x1) - - -/*--------------------------------------------------- - * XL-Form Instructions: - * bcctrX bclrX crand crandc creqv crnand crnor cror - * croc crxorisync mcrf rfi - *--------------------------------------------------- - * OPCD | BO | BI | 00000 | XO |LK - * OPCD | crbD | crbA | crbB | XO |0 - * OPCD |crfD |00|crfS |00| 00000 | XO |0 - * OPCD | 00000 | 00000 | 00000 | XO |0 - *---------------------------------------------------*/ - -#define XL_OPCODE(i,xo,lk) (MAKE_OPCODE(i) | (((xo) & 0x3ff) << 1) | \ - ((lk) & 0x1)) -#define XL_MASK XL_OPCODE(0x3f,0x3ff,0x1) - - -/*--------------------------------------------------- - * XFX-Form Instructions: - * mfspr mftb mtcrf mtspr - *--------------------------------------------------- - * OPCD | D | spr | XO |0 - * OPCD | D |0| CRM |0| XO |0 - * OPCD | S | spr | XO |0 - * OPCD | D | tbr | XO |0 - *---------------------------------------------------*/ - -#define XFX_OPCODE(i,xo,rc) (MAKE_OPCODE(i) | (((xo) & 0x3ff) << 1) | \ - ((rc) & 0x1)) -#define XFX_MASK XFX_OPCODE(0x3f,0x3ff,0x1) - - -/*--------------------------------------------------- - * XFL-Form Instructions: - * (none supported by MPC860) - *--------------------------------------------------- - * OPCD |0| FM |0| B | XO |0 - *---------------------------------------------------*/ - -#define XFL_OPCODE(i,xo,rc) (MAKE_OPCODE(i) | (((xo) & 0x3ff) << 1) | \ - ((rc) & 0x1)) -#define XFL_MASK XFL_OPCODE(0x3f,0x3ff,0x1) - - -/*--------------------------------------------------- - * XS-Form Instructions: - * (none supported by MPC860) - *--------------------------------------------------- - * OPCD | S | A | sh | XO |sh|LK - *---------------------------------------------------*/ - -#define XS_OPCODE(i,xo,rc) (MAKE_OPCODE(i) | (((xo) & 0x1ff) << 2) | \ - ((rc) & 0x1)) -#define XS_MASK XS_OPCODE(0x3f,0x1ff,0x1) - - -/*--------------------------------------------------- - * XO-Form Instructions: - * addX addcXaddeX addmeX addzeX divwX divwuX mulhwX - * mulhwuX mullwX negX subfX subfcX subfeX subfmeX - * subfzeX - *--------------------------------------------------- - * OPCD | D | A | B |OE| XO |Rc - * OPCD | D | A | B |0 | XO |Rc - * OPCD | D | A | 00000 |OE| XO |Rc - *---------------------------------------------------*/ - -#define XO_OPCODE(i,xo,oe,rc) (MAKE_OPCODE(i) | (((oe) & 0x1) << 10) | \ - (((xo) & 0x1ff) << 1) | ((rc) & 0x1)) -#define XO_MASK XO_OPCODE(0x3f,0x1ff,0x1,0x1) - - -/*--------------------------------------------------- - * A-Form Instructions: - * (none supported by MPC860) - *--------------------------------------------------- - * OPCD | D | A | B |00000| XO |Rc - * OPCD | D | A | B | C | XO |Rc - * OPCD | D | A | 00000 | C | XO |Rc - * OPCD | D | 00000 | B |00000| XO |Rc - *---------------------------------------------------*/ - -#define A_OPCODE(i,xo,rc) (MAKE_OPCODE(i) | (((xo) & 0x1f) << 1) | \ - ((rc) & 0x1)) -#define A_MASK A_OPCODE(0x3f,0x1f,0x1) - - -/*--------------------------------------------------- - * M-Form Instructions: - * rlwimiX rlwinmX rlwnmX - *--------------------------------------------------- - * OPCD | S | A | SH | MB | ME |Rc - * OPCD | S | A | B | MB | ME |Rc - *---------------------------------------------------*/ - -#define M_OPCODE(i,rc) (MAKE_OPCODE(i) | ((rc) & 0x1)) -#define M_MASK M_OPCODE(0x3f,0x1) - - -/*--------------------------------------------------- - * MD-Form Instructions: - * (none supported by MPC860) - *--------------------------------------------------- - * OPCD | S | A | sh | mb | XO |sh|Rc - * OPCD | S | A | sh | me | XO |sh|Rc - *---------------------------------------------------*/ - -#define MD_OPCODE(i,xo,rc) (MAKE_OPCODE(i) | (((xo) & 0x7) << 2) | \ - ((rc) & 0x1)) -#define MD_MASK MD_OPCODE(0x3f,0x7,0x1) - - -/*--------------------------------------------------- - * MDS-Form Instructions: - * (none supported by MPC860) - *--------------------------------------------------- - * OPCD | S | A | B | mb | XO |Rc - * OPCD | S | A | B | me | XO |Rc - *---------------------------------------------------*/ - -#define MDS_OPCODE(i,xo,rc) (MAKE_OPCODE(i) | (((xo) & 0xf) << 1) | \ - ((rc) & 0x1)) -#define MDS_MASK MDS_OPCODE(0x3f,0xf,0x1) - -#define INSTRUCTION( memaddr ) ntohl(*(unsigned long *)(memaddr)) - -#define MAX_OPERANDS 8 - -struct ppc_ctx; - -struct opcode { - unsigned long opcode; /* The complete opcode as produced by - one of the XXX_OPCODE macros above */ - - unsigned long mask; /* The mask to use on an instruction - before comparing with the opcode - field to see if it matches */ - - enum OP_FIELD fields[MAX_OPERANDS]; - /* An array defining the operands for - this opcode. The values of the - array are the operand identifiers */ - - int (*hfunc)(struct ppc_ctx *); - /* Address of a function to handle the given - mnemonic */ - - char * name; /* The symbolic name of this opcode */ - - unsigned int hint; /* A bitwise-inclusive-OR of the - values shown below. These are used - tell the disassembler how to print - some operands for this opcode */ -}; - -/* values for opcode hints */ -#define H_RELATIVE 0x1 /* The address operand is relative */ -#define H_IMM_HIGH 0x2 /* [U|S]IMM field shifted high */ -#define H_RA0_IS_0 0x4 /* If rA = 0 then treat as literal 0 */ - -struct ppc_ctx { - struct opcode * op; - unsigned long instr; - unsigned int flags; - int datalen; - char data[ 256 ]; - char radix_fmt[ 8 ]; - unsigned char * virtual; -}; - - -/*====================================================================== - * - * FUNCTIONS - * - *======================================================================*/ - -/* Values for flags as passed to various ppc routines */ -#define F_RADOCTAL 0x1 /* output radix = unsigned octal */ -#define F_RADUDECIMAL 0x2 /* output radix = unsigned decimal */ -#define F_RADSDECIMAL 0x4 /* output radix = signed decimal */ -#define F_RADHEX 0x8 /* output radix = unsigned hex */ -#define F_SIMPLE 0x10 /* use simplified mnemonics */ -#define F_SYMBOL 0x20 /* use symbol lookups for addresses */ -#define F_INSTR 0x40 /* output the raw instruction */ -#define F_LOCALMEM 0x80 /* retrieve opcodes from local memory - rather than from the HMI */ -#define F_LINENO 0x100 /* show line number info if available */ -#define F_VALIDONLY 0x200 /* cache: valid entries only */ - -/* Values for assembler error codes */ -#define E_ASM_BAD_OPCODE 1 -#define E_ASM_NUM_OPERANDS 2 -#define E_ASM_BAD_REGISTER 3 -#define E_ASM_BAD_SPR 4 -#define E_ASM_BAD_TBR 5 - -extern int disppc __P((unsigned char *,unsigned char *,int, - int (*)(const char *), unsigned long)); -extern int print_source_line __P((char *,char *,int, - int (*pfunc)(const char *))); -extern int find_next_address __P((unsigned char *,int,struct pt_regs *)); -extern int handle_bc __P((struct ppc_ctx *)); -extern unsigned long asmppc __P((unsigned long,char*,int*)); -extern char *asm_error_str __P((int)); - -/*====================================================================== - * - * GLOBAL VARIABLES - * - *======================================================================*/ - -extern struct operand operands[]; -extern const unsigned int n_operands; -extern struct opcode opcodes[]; -extern const unsigned int n_opcodes; - -#endif /* _PPC_H */ - - -/* - * Copyright (c) 2000 William L. Pitts and W. Gerald Hicks - * All rights reserved. - * - * Redistribution and use in source and binary forms are freely - * permitted provided that the above copyright notice and this - * paragraph and the following disclaimer are duplicated in all - * such forms. - * - * This software is provided "AS IS" and without any express or - * implied warranties, including, without limitation, the implied - * warranties of merchantability and fitness for a particular - * purpose. - */ diff --git a/include/bedbug/regs.h b/include/bedbug/regs.h deleted file mode 100644 index 304a336cc20..00000000000 --- a/include/bedbug/regs.h +++ /dev/null @@ -1,400 +0,0 @@ -/* $Id$ */ - -#ifndef _REGS_H -#define _REGS_H - -/* Special Purpose Registers */ - -#define SPR_CR -1 -#define SPR_MSR -2 - -#define SPR_XER 1 -#define SPR_LR 8 -#define SPR_CTR 9 -#define SPR_DSISR 18 -#define SPR_DAR 19 -#define SPR_DEC 22 -#define SPR_SRR0 26 -#define SPR_SRR1 27 -#define SPR_EIE 80 -#define SPR_EID 81 -#define SPR_CMPA 144 -#define SPR_CMPB 145 -#define SPR_CMPC 146 -#define SPR_CMPD 147 -#define SPR_ICR 148 -#define SPR_DER 149 -#define SPR_COUNTA 150 -#define SPR_COUNTB 151 -#define SPR_CMPE 152 -#define SPR_CMPF 153 -#define SPR_CMPG 154 -#define SPR_CMPH 155 -#define SPR_LCTRL1 156 -#define SPR_LCTRL2 157 -#define SPR_ICTRL 158 -#define SPR_BAR 159 -#define SPR_USPRG0 256 -#define SPR_SPRG4_RO 260 -#define SPR_SPRG5_RO 261 -#define SPR_SPRG6_RO 262 -#define SPR_SPRG7_RO 263 -#define SPR_SPRG0 272 -#define SPR_SPRG1 273 -#define SPR_SPRG2 274 -#define SPR_SPRG3 275 -#define SPR_SPRG4 276 -#define SPR_SPRG5 277 -#define SPR_SPRG6 278 -#define SPR_SPRG7 279 -#define SPR_EAR 282 /* MPC603e core */ -#define SPR_TBL 284 -#define SPR_TBU 285 -#define SPR_PVR 287 -#define SPR_IC_CST 560 -#define SPR_IC_ADR 561 -#define SPR_IC_DAT 562 -#define SPR_DC_CST 568 -#define SPR_DC_ADR 569 -#define SPR_DC_DAT 570 -#define SPR_DPDR 630 -#define SPR_IMMR 638 -#define SPR_MI_CTR 784 -#define SPR_MI_AP 786 -#define SPR_MI_EPN 787 -#define SPR_MI_TWC 789 -#define SPR_MI_RPN 790 -#define SPR_MD_CTR 792 -#define SPR_M_CASID 793 -#define SPR_MD_AP 794 -#define SPR_MD_EPN 795 -#define SPR_M_TWB 796 -#define SPR_MD_TWC 797 -#define SPR_MD_RPN 798 -#define SPR_M_TW 799 -#define SPR_MI_DBCAM 816 -#define SPR_MI_DBRAM0 817 -#define SPR_MI_DBRAM1 818 -#define SPR_MD_DBCAM 824 -#define SPR_MD_DBRAM0 825 -#define SPR_MD_DBRAM1 826 -#define SPR_ZPR 944 -#define SPR_PID 945 -#define SPR_CCR0 947 -#define SPR_IAC3 948 -#define SPR_IAC4 949 -#define SPR_DVC1 950 -#define SPR_DVC2 951 -#define SPR_SGR 953 -#define SPR_DCWR 954 -#define SPR_SLER 955 -#define SPR_SU0R 956 -#define SPR_DBCR1 957 -#define SPR_ICDBDR 979 -#define SPR_ESR 980 -#define SPR_DEAR 981 -#define SPR_EVPR 982 -#define SPR_TSR 984 -#define SPR_TCR 986 -#define SPR_PIT 987 -#define SPR_SRR2 990 -#define SPR_SRR3 991 -#define SPR_DBSR 1008 -#define SPR_DBCR0 1010 -#define SPR_IABR 1010 /* MPC603e core */ -#define SPR_IAC1 1012 -#define SPR_IAC2 1013 -#define SPR_DAC1 1014 -#define SPR_DAC2 1015 -#define SPR_DCCR 1018 -#define SPR_ICCR 1019 - -/* Bits for the DBCR0 register */ -#define DBCR0_EDM 0x80000000 -#define DBCR0_IDM 0x40000000 -#define DBCR0_RST 0x30000000 -#define DBCR0_IC 0x08000000 -#define DBCR0_BT 0x04000000 -#define DBCR0_EDE 0x02000000 -#define DBCR0_TDE 0x01000000 -#define DBCR0_IA1 0x00800000 -#define DBCR0_IA2 0x00400000 -#define DBCR0_IA12 0x00200000 -#define DBCR0_IA12X 0x00100000 -#define DBCR0_IA3 0x00080000 -#define DBCR0_IA4 0x00040000 -#define DBCR0_IA34 0x00020000 -#define DBCR0_IA34X 0x00010000 -#define DBCR0_IA12T 0x00008000 -#define DBCR0_IA34T 0x00004000 -#define DBCR0_FT 0x00000001 - -/* Bits for the DBCR1 register */ -#define DBCR1_D1R 0x80000000 -#define DBCR1_D2R 0x40000000 -#define DBCR1_D1W 0x20000000 -#define DBCR1_D2W 0x10000000 -#define DBCR1_D1S 0x0C000000 -#define DBCR1_D2S 0x03000000 -#define DBCR1_DA12 0x00800000 -#define DBCR1_DA12X 0x00400000 -#define DBCR1_DV1M 0x000C0000 -#define DBCR1_DV2M 0x00030000 -#define DBCR1_DV1BE 0x0000F000 -#define DBCR1_DV2BE 0x00000F00 - -/* - * DBSR bits which have conflicting definitions on true Book E versus PPC40x - */ -#ifdef CONFIG_BOOKE -#define DBSR_IA1 0x00800000 /* Instr Address Compare 1 Event */ -#define DBSR_IA2 0x00400000 /* Instr Address Compare 2 Event */ -#define DBSR_IA3 0x00200000 /* Instr Address Compare 3 Event */ -#define DBSR_IA4 0x00100000 /* Instr Address Compare 4 Event */ -#endif -#define DBSR_IA1 0x04000000 /* Instr Address Compare 1 Event */ -#define DBSR_IA2 0x02000000 /* Instr Address Compare 2 Event */ -#define DBSR_IA3 0x00080000 /* Instr Address Compare 3 Event */ -#define DBSR_IA4 0x00040000 /* Instr Address Compare 4 Event */ - -struct spr_info { - int spr_val; - char spr_name[ 10 ]; -}; - -extern struct spr_info spr_map[]; -extern const unsigned int n_sprs; - - -#define SET_REGISTER( str, val ) \ -({ unsigned long __value = (val); \ - asm volatile( str : : "r" (__value)); \ - __value; }) - -#define GET_REGISTER( str ) \ -({ unsigned long __value; \ - asm volatile( str : "=r" (__value) : ); \ - __value; }) - -#define GET_CR() GET_REGISTER( "mfcr %0" ) -#define SET_CR(val) SET_REGISTER( "mtcr %0", val ) -#define GET_MSR() GET_REGISTER( "mfmsr %0" ) -#define SET_MSR(val) SET_REGISTER( "mtmsr %0", val ) -#define GET_XER() GET_REGISTER( "mfspr %0,1" ) -#define SET_XER(val) SET_REGISTER( "mtspr 1,%0", val ) -#define GET_LR() GET_REGISTER( "mfspr %0,8" ) -#define SET_LR(val) SET_REGISTER( "mtspr 8,%0", val ) -#define GET_CTR() GET_REGISTER( "mfspr %0,9" ) -#define SET_CTR(val) SET_REGISTER( "mtspr 9,%0", val ) -#define GET_DSISR() GET_REGISTER( "mfspr %0,18" ) -#define SET_DSISR(val) SET_REGISTER( "mtspr 18,%0", val ) -#define GET_DAR() GET_REGISTER( "mfspr %0,19" ) -#define SET_DAR(val) SET_REGISTER( "mtspr 19,%0", val ) -#define GET_DEC() GET_REGISTER( "mfspr %0,22" ) -#define SET_DEC(val) SET_REGISTER( "mtspr 22,%0", val ) -#define GET_SRR0() GET_REGISTER( "mfspr %0,26" ) -#define SET_SRR0(val) SET_REGISTER( "mtspr 26,%0", val ) -#define GET_SRR1() GET_REGISTER( "mfspr %0,27" ) -#define SET_SRR1(val) SET_REGISTER( "mtspr 27,%0", val ) -#define GET_EIE() GET_REGISTER( "mfspr %0,80" ) -#define SET_EIE(val) SET_REGISTER( "mtspr 80,%0", val ) -#define GET_EID() GET_REGISTER( "mfspr %0,81" ) -#define SET_EID(val) SET_REGISTER( "mtspr 81,%0", val ) -#define GET_CMPA() GET_REGISTER( "mfspr %0,144" ) -#define SET_CMPA(val) SET_REGISTER( "mtspr 144,%0", val ) -#define GET_CMPB() GET_REGISTER( "mfspr %0,145" ) -#define SET_CMPB(val) SET_REGISTER( "mtspr 145,%0", val ) -#define GET_CMPC() GET_REGISTER( "mfspr %0,146" ) -#define SET_CMPC(val) SET_REGISTER( "mtspr 146,%0", val ) -#define GET_CMPD() GET_REGISTER( "mfspr %0,147" ) -#define SET_CMPD(val) SET_REGISTER( "mtspr 147,%0", val ) -#define GET_ICR() GET_REGISTER( "mfspr %0,148" ) -#define SET_ICR(val) SET_REGISTER( "mtspr 148,%0", val ) -#define GET_DER() GET_REGISTER( "mfspr %0,149" ) -#define SET_DER(val) SET_REGISTER( "mtspr 149,%0", val ) -#define GET_COUNTA() GET_REGISTER( "mfspr %0,150" ) -#define SET_COUNTA(val) SET_REGISTER( "mtspr 150,%0", val ) -#define GET_COUNTB() GET_REGISTER( "mfspr %0,151" ) -#define SET_COUNTB(val) SET_REGISTER( "mtspr 151,%0", val ) -#define GET_CMPE() GET_REGISTER( "mfspr %0,152" ) -#define SET_CMPE(val) SET_REGISTER( "mtspr 152,%0", val ) -#define GET_CMPF() GET_REGISTER( "mfspr %0,153" ) -#define SET_CMPF(val) SET_REGISTER( "mtspr 153,%0", val ) -#define GET_CMPG() GET_REGISTER( "mfspr %0,154" ) -#define SET_CMPG(val) SET_REGISTER( "mtspr 154,%0", val ) -#define GET_CMPH() GET_REGISTER( "mfspr %0,155" ) -#define SET_CMPH(val) SET_REGISTER( "mtspr 155,%0", val ) -#define GET_LCTRL1() GET_REGISTER( "mfspr %0,156" ) -#define SET_LCTRL1(val) SET_REGISTER( "mtspr 156,%0", val ) -#define GET_LCTRL2() GET_REGISTER( "mfspr %0,157" ) -#define SET_LCTRL2(val) SET_REGISTER( "mtspr 157,%0", val ) -#define GET_ICTRL() GET_REGISTER( "mfspr %0,158" ) -#define SET_ICTRL(val) SET_REGISTER( "mtspr 158,%0", val ) -#define GET_BAR() GET_REGISTER( "mfspr %0,159" ) -#define SET_BAR(val) SET_REGISTER( "mtspr 159,%0", val ) -#define GET_USPRG0() GET_REGISTER( "mfspr %0,256" ) -#define SET_USPRG0(val) SET_REGISTER( "mtspr 256,%0", val ) -#define GET_SPRG4_RO() GET_REGISTER( "mfspr %0,260" ) -#define SET_SPRG4_RO(val) SET_REGISTER( "mtspr 260,%0", val ) -#define GET_SPRG5_RO() GET_REGISTER( "mfspr %0,261" ) -#define SET_SPRG5_RO(val) SET_REGISTER( "mtspr 261,%0", val ) -#define GET_SPRG6_RO() GET_REGISTER( "mfspr %0,262" ) -#define SET_SPRG6_RO(val) SET_REGISTER( "mtspr 262,%0", val ) -#define GET_SPRG7_RO() GET_REGISTER( "mfspr %0,263" ) -#define SET_SPRG7_RO(val) SET_REGISTER( "mtspr 263,%0", val ) -#define GET_SPRG0() GET_REGISTER( "mfspr %0,272" ) -#define SET_SPRG0(val) SET_REGISTER( "mtspr 272,%0", val ) -#define GET_SPRG1() GET_REGISTER( "mfspr %0,273" ) -#define SET_SPRG1(val) SET_REGISTER( "mtspr 273,%0", val ) -#define GET_SPRG2() GET_REGISTER( "mfspr %0,274" ) -#define SET_SPRG2(val) SET_REGISTER( "mtspr 274,%0", val ) -#define GET_SPRG3() GET_REGISTER( "mfspr %0,275" ) -#define SET_SPRG3(val) SET_REGISTER( "mtspr 275,%0", val ) -#define GET_SPRG4() GET_REGISTER( "mfspr %0,276" ) -#define SET_SPRG4(val) SET_REGISTER( "mtspr 276,%0", val ) -#define GET_SPRG5() GET_REGISTER( "mfspr %0,277" ) -#define SET_SPRG5(val) SET_REGISTER( "mtspr 277,%0", val ) -#define GET_SPRG6() GET_REGISTER( "mfspr %0,278" ) -#define SET_SPRG6(val) SET_REGISTER( "mtspr 278,%0", val ) -#define GET_SPRG7() GET_REGISTER( "mfspr %0,279" ) -#define SET_SPRG7(val) SET_REGISTER( "mtspr 279,%0", val ) -#define GET_EAR() GET_REGISTER( "mfspr %0,282" ) -#define SET_EAR(val) SET_REGISTER( "mtspr 282,%0", val ) -#define GET_TBL() GET_REGISTER( "mfspr %0,284" ) -#define SET_TBL(val) SET_REGISTER( "mtspr 284,%0", val ) -#define GET_TBU() GET_REGISTER( "mfspr %0,285" ) -#define SET_TBU(val) SET_REGISTER( "mtspr 285,%0", val ) -#define GET_PVR() GET_REGISTER( "mfspr %0,287" ) -#define SET_PVR(val) SET_REGISTER( "mtspr 287,%0", val ) -#define GET_IC_CST() GET_REGISTER( "mfspr %0,560" ) -#define SET_IC_CST(val) SET_REGISTER( "mtspr 560,%0", val ) -#define GET_IC_ADR() GET_REGISTER( "mfspr %0,561" ) -#define SET_IC_ADR(val) SET_REGISTER( "mtspr 561,%0", val ) -#define GET_IC_DAT() GET_REGISTER( "mfspr %0,562" ) -#define SET_IC_DAT(val) SET_REGISTER( "mtspr 562,%0", val ) -#define GET_DC_CST() GET_REGISTER( "mfspr %0,568" ) -#define SET_DC_CST(val) SET_REGISTER( "mtspr 568,%0", val ) -#define GET_DC_ADR() GET_REGISTER( "mfspr %0,569" ) -#define SET_DC_ADR(val) SET_REGISTER( "mtspr 569,%0", val ) -#define GET_DC_DAT() GET_REGISTER( "mfspr %0,570" ) -#define SET_DC_DAT(val) SET_REGISTER( "mtspr 570,%0", val ) -#define GET_DPDR() GET_REGISTER( "mfspr %0,630" ) -#define SET_DPDR(val) SET_REGISTER( "mtspr 630,%0", val ) -#define GET_IMMR() GET_REGISTER( "mfspr %0,638" ) -#define SET_IMMR(val) SET_REGISTER( "mtspr 638,%0", val ) -#define GET_MI_CTR() GET_REGISTER( "mfspr %0,784" ) -#define SET_MI_CTR(val) SET_REGISTER( "mtspr 784,%0", val ) -#define GET_MI_AP() GET_REGISTER( "mfspr %0,786" ) -#define SET_MI_AP(val) SET_REGISTER( "mtspr 786,%0", val ) -#define GET_MI_EPN() GET_REGISTER( "mfspr %0,787" ) -#define SET_MI_EPN(val) SET_REGISTER( "mtspr 787,%0", val ) -#define GET_MI_TWC() GET_REGISTER( "mfspr %0,789" ) -#define SET_MI_TWC(val) SET_REGISTER( "mtspr 789,%0", val ) -#define GET_MI_RPN() GET_REGISTER( "mfspr %0,790" ) -#define SET_MI_RPN(val) SET_REGISTER( "mtspr 790,%0", val ) -#define GET_MD_CTR() GET_REGISTER( "mfspr %0,792" ) -#define SET_MD_CTR(val) SET_REGISTER( "mtspr 792,%0", val ) -#define GET_M_CASID() GET_REGISTER( "mfspr %0,793" ) -#define SET_M_CASID(val) SET_REGISTER( "mtspr 793,%0", val ) -#define GET_MD_AP() GET_REGISTER( "mfspr %0,794" ) -#define SET_MD_AP(val) SET_REGISTER( "mtspr ,794%0", val ) -#define GET_MD_EPN() GET_REGISTER( "mfspr %0,795" ) -#define SET_MD_EPN(val) SET_REGISTER( "mtspr 795,%0", val ) -#define GET_M_TWB() GET_REGISTER( "mfspr %0,796" ) -#define SET_M_TWB(val) SET_REGISTER( "mtspr 796,%0", val ) -#define GET_MD_TWC() GET_REGISTER( "mfspr %0,797" ) -#define SET_MD_TWC(val) SET_REGISTER( "mtspr 797,%0", val ) -#define GET_MD_RPN() GET_REGISTER( "mfspr %0,798" ) -#define SET_MD_RPN(val) SET_REGISTER( "mtspr 798,%0", val ) -#define GET_M_TW() GET_REGISTER( "mfspr %0,799" ) -#define SET_M_TW(val) SET_REGISTER( "mtspr 799,%0", val ) -#define GET_MI_DBCAM() GET_REGISTER( "mfspr %0,816" ) -#define SET_MI_DBCAM(val) SET_REGISTER( "mtspr 816,%0", val ) -#define GET_MI_DBRAM0() GET_REGISTER( "mfspr %0,817" ) -#define SET_MI_DBRAM0(val) SET_REGISTER( "mtspr 817,%0", val ) -#define GET_MI_DBRAM1() GET_REGISTER( "mfspr %0,818" ) -#define SET_MI_DBRAM1(val) SET_REGISTER( "mtspr 818,%0", val ) -#define GET_MD_DBCAM() GET_REGISTER( "mfspr %0,824" ) -#define SET_MD_DBCA(val) SET_REGISTER( "mtspr 824,%0", val ) -#define GET_MD_DBRAM0() GET_REGISTER( "mfspr %0,825" ) -#define SET_MD_DBRAM0(val) SET_REGISTER( "mtspr 825,%0", val ) -#define GET_MD_DBRAM1() GET_REGISTER( "mfspr %0,826" ) -#define SET_MD_DBRAM1(val) SET_REGISTER( "mtspr 826,%0", val ) -#define GET_ZPR() GET_REGISTER( "mfspr %0,944" ) -#define SET_ZPR(val) SET_REGISTER( "mtspr 944,%0", val ) -#define GET_PID() GET_REGISTER( "mfspr %0,945" ) -#define SET_PID(val) SET_REGISTER( "mtspr 945,%0", val ) -#define GET_CCR0() GET_REGISTER( "mfspr %0,947" ) -#define SET_CCR0(val) SET_REGISTER( "mtspr 947,%0", val ) -#define GET_IAC3() GET_REGISTER( "mfspr %0,948" ) -#define SET_IAC3(val) SET_REGISTER( "mtspr 948,%0", val ) -#define GET_IAC4() GET_REGISTER( "mfspr %0,949" ) -#define SET_IAC4(val) SET_REGISTER( "mtspr 949,%0", val ) -#define GET_DVC1() GET_REGISTER( "mfspr %0,950" ) -#define SET_DVC1(val) SET_REGISTER( "mtspr 950,%0", val ) -#define GET_DVC2() GET_REGISTER( "mfspr %0,951" ) -#define SET_DVC2(val) SET_REGISTER( "mtspr 951,%0", val ) -#define GET_SGR() GET_REGISTER( "mfspr %0,953" ) -#define SET_SGR(val) SET_REGISTER( "mtspr 953,%0", val ) -#define GET_DCWR() GET_REGISTER( "mfspr %0,954" ) -#define SET_DCWR(val) SET_REGISTER( "mtspr 954,%0", val ) -#define GET_SLER() GET_REGISTER( "mfspr %0,955" ) -#define SET_SLER(val) SET_REGISTER( "mtspr 955,%0", val ) -#define GET_SU0R() GET_REGISTER( "mfspr %0,956" ) -#define SET_SU0R(val) SET_REGISTER( "mtspr 956,%0", val ) -#define GET_DBCR1() GET_REGISTER( "mfspr %0,957" ) -#define SET_DBCR1(val) SET_REGISTER( "mtspr 957,%0", val ) -#define GET_ICDBDR() GET_REGISTER( "mfspr %0,979" ) -#define SET_ICDBDR(val) SET_REGISTER( "mtspr 979,%0", val ) -#define GET_ESR() GET_REGISTER( "mfspr %0,980" ) -#define SET_ESR(val) SET_REGISTER( "mtspr 980,%0", val ) -#define GET_DEAR() GET_REGISTER( "mfspr %0,981" ) -#define SET_DEAR(val) SET_REGISTER( "mtspr 981,%0", val ) -#define GET_EVPR() GET_REGISTER( "mfspr %0,982" ) -#define SET_EVPR(val) SET_REGISTER( "mtspr 982,%0", val ) -#define GET_TSR() GET_REGISTER( "mfspr %0,984" ) -#define SET_TSR(val) SET_REGISTER( "mtspr 984,%0", val ) -#define GET_TCR() GET_REGISTER( "mfspr %0,986" ) -#define SET_TCR(val) SET_REGISTER( "mtspr 986,%0", val ) -#define GET_PIT() GET_REGISTER( "mfspr %0,987" ) -#define SET_PIT(val) SET_REGISTER( "mtspr 987,%0", val ) -#define GET_SRR2() GET_REGISTER( "mfspr %0,990" ) -#define SET_SRR2(val) SET_REGISTER( "mtspr 990,%0", val ) -#define GET_SRR3() GET_REGISTER( "mfspr %0,991" ) -#define SET_SRR3(val) SET_REGISTER( "mtspr 991,%0", val ) -#define GET_DBSR() GET_REGISTER( "mfspr %0,1008" ) -#define SET_DBSR(val) SET_REGISTER( "mtspr 1008,%0", val ) -#define GET_DBCR0() GET_REGISTER( "mfspr %0,1010" ) -#define SET_DBCR0(val) SET_REGISTER( "mtspr 1010,%0", val ) -#define GET_IABR() GET_REGISTER( "mfspr %0,1010" ) -#define SET_IABR(val) SET_REGISTER( "mtspr 1010,%0", val ) -#define GET_IAC1() GET_REGISTER( "mfspr %0,1012" ) -#define SET_IAC1(val) SET_REGISTER( "mtspr 1012,%0", val ) -#define GET_IAC2() GET_REGISTER( "mfspr %0,1013" ) -#define SET_IAC2(val) SET_REGISTER( "mtspr 1013,%0", val ) -#define GET_DAC1() GET_REGISTER( "mfspr %0,1014" ) -#define SET_DAC1(val) SET_REGISTER( "mtspr 1014,%0", val ) -#define GET_DAC2() GET_REGISTER( "mfspr %0,1015" ) -#define SET_DAC2(val) SET_REGISTER( "mtspr 1015,%0", val ) -#define GET_DCCR() GET_REGISTER( "mfspr %0,1018" ) -#define SET_DCCR(val) SET_REGISTER( "mtspr 1018,%0", val ) -#define GET_ICCR() GET_REGISTER( "mfspr %0,1019" ) -#define SET_ICCR(val) SET_REGISTER( "mtspr 1019,%0", val ) - -#endif /* _REGS_H */ - - -/* - * Copyright (c) 2000 William L. Pitts and W. Gerald Hicks - * All rights reserved. - * - * Redistribution and use in source and binary forms are freely - * permitted provided that the above copyright notice and this - * paragraph and the following disclaimer are duplicated in all - * such forms. - * - * This software is provided "AS IS" and without any express or - * implied warranties, including, without limitation, the implied - * warranties of merchantability and fitness for a particular - * purpose. - */ diff --git a/include/bedbug/tables.h b/include/bedbug/tables.h deleted file mode 100644 index e675de3209f..00000000000 --- a/include/bedbug/tables.h +++ /dev/null @@ -1,601 +0,0 @@ -/* $Id$ */ - -#ifndef TABLES_H -#define TABLES_H - -/* This is only included by common/bedbug.c, and depends on the following - * files to already be included - * common.h - * bedbug/bedbug.h - * bedbug/ppc.h - * bedbug/regs.h - */ - -struct operand operands[] = { - /*Field Name Bits Shift Hint Position */ - /*----- ------ ----- ----- ---- ------------ */ - { O_AA, "O_AA", 1, 1, OH_SILENT }, /* 30 */ - { O_BD, "O_BD", 14, 2, OH_ADDR }, /* 16-29 */ - { O_BI, "O_BI", 5, 16, 0 }, /* 11-15 */ - { O_BO, "O_BO", 5, 21, 0 }, /* 6-10 */ - { O_crbD, "O_crbD", 5, 21, 0 }, /* 6-10 */ - { O_crbA, "O_crbA", 5, 16, 0 }, /* 11-15 */ - { O_crbB, "O_crbB", 5, 11, 0 }, /* 16-20 */ - { O_CRM, "O_CRM", 8, 12, 0 }, /* 12-19 */ - { O_d, "O_d", 15, 0, OH_OFFSET }, /* 16-31 */ - { O_frC, "O_frC", 5, 6, 0 }, /* 21-25 */ - { O_frD, "O_frD", 5, 21, 0 }, /* 6-10 */ - { O_frS, "O_frS", 5, 21, 0 }, /* 6-10 */ - { O_IMM, "O_IMM", 4, 12, 0 }, /* 16-19 */ - { O_LI, "O_LI", 24, 2, OH_ADDR }, /* 6-29 */ - { O_LK, "O_LK", 1, 0, OH_SILENT }, /* 31 */ - { O_MB, "O_MB", 5, 6, 0 }, /* 21-25 */ - { O_ME, "O_ME", 5, 1, 0 }, /* 26-30 */ - { O_NB, "O_NB", 5, 11, 0 }, /* 16-20 */ - { O_OE, "O_OE", 1, 10, OH_SILENT }, /* 21 */ - { O_rA, "O_rA", 5, 16, OH_REG }, /* 11-15 */ - { O_rB, "O_rB", 5, 11, OH_REG }, /* 16-20 */ - { O_Rc, "O_Rc", 1, 0, OH_SILENT }, /* 31 */ - { O_rD, "O_rD", 5, 21, OH_REG }, /* 6-10 */ - { O_rS, "O_rS", 5, 21, OH_REG }, /* 6-10 */ - { O_SH, "O_SH", 5, 11, 0 }, /* 16-20 */ - { O_SIMM, "O_SIMM", 16, 0, 0 }, /* 16-31 */ - { O_SR, "O_SR", 4, 16, 0 }, /* 12-15 */ - { O_TO, "O_TO", 5, 21, 0 }, /* 6-10 */ - { O_UIMM, "O_UIMM", 16, 0, 0 }, /* 16-31 */ - { O_crfD, "O_crfD", 3, 23, 0 }, /* 6- 8 */ - { O_crfS, "O_crfS", 3, 18, 0 }, /* 11-13 */ - { O_L, "O_L", 1, 21, 0 }, /* 10 */ - { O_spr, "O_spr", 10, 11, OH_SPR }, /* 11-20 */ - { O_tbr, "O_tbr", 10, 11, OH_TBR }, /* 11-20 */ - { O_cr2, "O_cr2", 0, 0, OH_LITERAL }, /* "cr2" */ -}; - -const unsigned int n_operands = sizeof(operands) / sizeof(operands[0]); - -/* A note about the fields array in the opcodes structure: - The operands are listed in the order they appear in the output. - - This table is arranged in numeric order of the opcode. Note that some - opcodes have defined bits in odd places so not all forms of a command - will be in the same place. This is done so that a binary search can be - done to find the opcodes. Note that table D.2 in the MPC860 User's - Manual "Instructions Sorted by Opcode" does not account for these - bit locations */ - -struct opcode opcodes[] = { - { D_OPCODE(3), D_MASK, {O_TO, O_rA, O_SIMM, 0}, - 0, "twi", 0 }, - { D_OPCODE(7), D_MASK, {O_rD, O_rA, O_SIMM, 0}, - 0, "mulli", 0 }, - { D_OPCODE(8), D_MASK, {O_rD, O_rA, O_SIMM, 0}, - 0, "subfic", 0 }, - { D_OPCODE(10), D_MASK, {O_crfD, O_L, O_rA, O_UIMM, 0}, - 0, "cmpli", 0 }, - { D_OPCODE(11), D_MASK, {O_crfD, O_L, O_rA, O_SIMM, 0}, - 0, "cmpi", 0 }, - { D_OPCODE(12), D_MASK, {O_rD, O_rA, O_SIMM, 0}, - 0, "addic", 0 }, - { D_OPCODE(13), D_MASK, {O_rD, O_rA, O_SIMM, 0}, - 0, "addic.", 0 }, - { D_OPCODE(14), D_MASK, {O_rD, O_rA, O_SIMM, 0}, - 0, "addi", H_RA0_IS_0 }, - { D_OPCODE(15), D_MASK, {O_rD, O_rA, O_SIMM, 0}, - 0, "addis", H_RA0_IS_0|H_IMM_HIGH }, - { B_OPCODE(16,0,0), B_MASK, {O_BO, O_BI, O_BD, O_AA, O_LK, 0}, - handle_bc, "bc", H_RELATIVE }, - { B_OPCODE(16,0,1), B_MASK, {O_BO, O_BI, O_BD, O_AA, O_LK, 0}, - 0, "bcl", H_RELATIVE }, - { B_OPCODE(16,1,0), B_MASK, {O_BO, O_BI, O_BD, O_AA, O_LK, 0}, - 0, "bca", 0 }, - { B_OPCODE(16,1,1), B_MASK, {O_BO, O_BI, O_BD, O_AA, O_LK, 0}, - 0, "bcla", 0 }, - { SC_OPCODE(17), SC_MASK, {0}, - 0, "sc", 0 }, - { I_OPCODE(18,0,0), I_MASK, {O_LI, O_AA, O_LK, 0}, - 0, "b", H_RELATIVE }, - { I_OPCODE(18,0,1), I_MASK, {O_LI, O_AA, O_LK, 0}, - 0, "bl", H_RELATIVE }, - { I_OPCODE(18,1,0), I_MASK, {O_LI, O_AA, O_LK, 0}, - 0, "ba", 0 }, - { I_OPCODE(18,1,1), I_MASK, {O_LI, O_AA, O_LK, 0}, - 0, "bla", 0 }, - { XL_OPCODE(19,0,0), XL_MASK, {O_crfD, O_crfS}, - 0, "mcrf", 0 }, - { XL_OPCODE(19,16,0), XL_MASK, {O_BO, O_BI, O_LK, 0}, - 0, "bclr", 0 }, - { XL_OPCODE(19,16,1), XL_MASK, {O_BO, O_BI, O_LK, 0}, - 0, "bclrl", 0 }, - { XL_OPCODE(19,33,0), XL_MASK, {O_crbD, O_crbA, O_crbB, 0}, - 0, "crnor", 0 }, - { XL_OPCODE(19,50,0), XL_MASK, {0}, - 0, "rfi", 0 }, - { XL_OPCODE(19,129,0), XL_MASK, {O_crbD, O_crbA, O_crbB, 0}, - 0, "crandc", 0 }, - { XL_OPCODE(19,150,0), XL_MASK, {0}, - 0, "isync", 0 }, - { XL_OPCODE(19,193,0), XL_MASK, {O_crbD, O_crbA, O_crbB, 0}, - 0, "crxor", 0 }, - { XL_OPCODE(19,225,0), XL_MASK, {O_crbD, O_crbA, O_crbB, 0}, - 0, "crnand", 0 }, - { XL_OPCODE(19,257,0), XL_MASK, {O_crbD, O_crbA, O_crbB, 0}, - 0, "crand", 0 }, - { XL_OPCODE(19,289,0), XL_MASK, {O_crbD, O_crbA, O_crbB, 0}, - 0, "creqv", 0 }, - { XL_OPCODE(19,417,0), XL_MASK, {O_crbD, O_crbA, O_crbB, 0}, - 0, "crorc", 0 }, - { XL_OPCODE(19,449,0), XL_MASK, {O_crbD, O_crbA, O_crbB, 0}, - 0, "cror", 0 }, - { XL_OPCODE(19,528,0), XL_MASK, {O_BO, O_BI, O_LK, 0}, - 0, "bcctr", 0 }, - { XL_OPCODE(19,528,1), XL_MASK, {O_BO, O_BI, O_LK, 0}, - 0, "bcctrl", 0 }, - { M_OPCODE(20,0), M_MASK, {O_rA, O_rS, O_SH, O_MB, O_ME, O_Rc, 0}, - 0, "rlwimi", 0 }, - { M_OPCODE(20,1), M_MASK, {O_rA, O_rS, O_SH, O_MB, O_ME, O_Rc, 0}, - 0, "rlwimi.", 0 }, - { M_OPCODE(21,0), M_MASK, {O_rA, O_rS, O_SH, O_MB, O_ME, O_Rc, 0}, - 0, "rlwinm", 0 }, - { M_OPCODE(21,1), M_MASK, {O_rA, O_rS, O_SH, O_MB, O_ME, O_Rc, 0}, - 0, "rlwinm.", 0 }, - { M_OPCODE(23,0), M_MASK, {O_rA, O_rS, O_rB, O_MB, O_ME, O_Rc, 0}, - 0, "rlwnm", 0 }, - { M_OPCODE(23,1), M_MASK, {O_rA, O_rS, O_rB, O_MB, O_ME, O_Rc, 0}, - 0, "rlwnm.", 0 }, - { D_OPCODE(24), D_MASK, {O_rA, O_rS, O_UIMM, 0}, - 0, "ori", 0 }, - { D_OPCODE(25), D_MASK, {O_rA, O_rS, O_UIMM, 0}, - 0, "oris", H_IMM_HIGH }, - { D_OPCODE(26), D_MASK, {O_rA, O_rS, O_UIMM, 0}, - 0, "xori", 0 }, - { D_OPCODE(27), D_MASK, {O_rA, O_rS, O_UIMM, 0}, - 0, "xoris", H_IMM_HIGH }, - { D_OPCODE(28), D_MASK, {O_rA, O_rS, O_UIMM, 0}, - 0, "andi.", 0 }, - { D_OPCODE(29), D_MASK, {O_rA, O_rS, O_UIMM, 0}, - 0, "andis.", H_IMM_HIGH }, - { X_OPCODE(31,0,0), X_MASK, {O_crfD, O_L, O_rA, O_rB, 0}, - 0, "cmp", 0 }, - { X_OPCODE(31,4,0), X_MASK, {O_TO, O_rA, O_rB, 0}, - 0, "tw", 0 }, - { XO_OPCODE(31,8,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfc", 0 }, - { XO_OPCODE(31,8,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfc.", 0 }, - { XO_OPCODE(31,10,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "addc", 0 }, - { XO_OPCODE(31,10,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "addc.", 0 }, - { XO_OPCODE(31,11,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_Rc, 0}, - 0, "mulhwu", 0 }, - { XO_OPCODE(31,11,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_Rc, 0}, - 0, "mulhwu.", 0 }, - { X_OPCODE(31,19,0), X_MASK, {O_rD, 0}, - 0, "mfcr", 0 }, - { X_OPCODE(31,20,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lwarx", H_RA0_IS_0 }, - { X_OPCODE(31,23,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lwzx", H_RA0_IS_0 }, - { X_OPCODE(31,24,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "slw", 0 }, - { X_OPCODE(31,24,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "slw.", 0 }, - { X_OPCODE(31,26,0), X_MASK, {O_rA, O_rS, O_Rc, 0 }, - 0, "cntlzw", 0 }, - { X_OPCODE(31,26,1), X_MASK, {O_rA, O_rS, O_Rc, 0}, - 0, "cntlzw.", 0 }, - { X_OPCODE(31,28,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "and", 0 }, - { X_OPCODE(31,28,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "and.", 0 }, - { X_OPCODE(31,32,0), X_MASK, {O_crfD, O_L, O_rA, O_rB, 0}, - 0, "cmpl", 0 }, - { XO_OPCODE(31,40,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subf", 0 }, - { XO_OPCODE(31,40,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subf.", 0 }, - { X_OPCODE(31,54,0), X_MASK, {O_rA, O_rB, 0}, - 0, "dcbst", H_RA0_IS_0 }, - { X_OPCODE(31,55,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lwzux", 0 }, - { X_OPCODE(31,60,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "andc", 0 }, - { X_OPCODE(31,60,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "andc.", 0 }, - { XO_OPCODE(31,75,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_Rc, 0}, - 0, "mulhw", 0 }, - { XO_OPCODE(31,75,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_Rc, 0}, - 0, "mulhw.", 0 }, - { X_OPCODE(31,83,0), X_MASK, {O_rD, 0}, - 0, "mfmsr", 0 }, - { X_OPCODE(31,86,0), X_MASK, {O_rA, O_rB, 0}, - 0, "dcbf", H_RA0_IS_0 }, - { X_OPCODE(31,87,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lbzx", H_RA0_IS_0 }, - { XO_OPCODE(31,104,0,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "neg", 0 }, - { XO_OPCODE(31,104,0,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "neg.", 0 }, - { X_OPCODE(31,119,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lbzux", 0 }, - { X_OPCODE(31,124,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "nor", 0 }, - { X_OPCODE(31,124,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "nor.", 0 }, - { XO_OPCODE(31,136,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfe", 0 }, - { XO_OPCODE(31,136,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfe.", 0 }, - { XO_OPCODE(31,138,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "adde", 0 }, - { XO_OPCODE(31,138,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "adde.", 0 }, - { XFX_OPCODE(31,144,0), XFX_MASK, {O_CRM, O_rS, 0}, - 0, "mtcrf", 0 }, - { X_OPCODE(31,146,0), X_MASK, {O_rS, 0}, - 0, "mtmsr", 0 }, - { X_OPCODE(31,150,1), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "stwcx.", 0 }, - { X_OPCODE(31,151,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "stwx", 0 }, - { X_OPCODE(31,183,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "stwux", 0 }, - { XO_OPCODE(31,200,0,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "subfze", 0 }, - { XO_OPCODE(31,200,0,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "subfze.", 0 }, - { XO_OPCODE(31,202,0,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "addze", 0 }, - { XO_OPCODE(31,202,0,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "addze.", 0 }, - { X_OPCODE(31,210,0), X_MASK, {O_SR, O_rS, 0}, - 0, "mtsr", 0 }, - { X_OPCODE(31,215,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "stbx", H_RA0_IS_0 }, - { XO_OPCODE(31,232,0,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "subfme", 0 }, - { XO_OPCODE(31,232,0,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "subfme.", 0 }, - { XO_OPCODE(31,234,0,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "addme", 0 }, - { XO_OPCODE(31,234,0,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "addme.", 0 }, - { XO_OPCODE(31,235,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "mullw", 0 }, - { XO_OPCODE(31,235,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "mullw.", 0 }, - { X_OPCODE(31,242,0), X_MASK, {O_rS, O_rB, 0}, - 0, "mtsrin", 0 }, - { X_OPCODE(31,246,0), X_MASK, {O_rA, O_rB, 0}, - 0, "dcbtst", H_RA0_IS_0 }, - { X_OPCODE(31,247,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "stbux", 0 }, - { XO_OPCODE(31,266,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "add", 0 }, - { XO_OPCODE(31,266,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "add.", 0 }, - { X_OPCODE(31,278,0), X_MASK, {O_rA, O_rB, 0}, - 0, "dcbt", H_RA0_IS_0 }, - { X_OPCODE(31,279,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lhzx", H_RA0_IS_0 }, - { X_OPCODE(31,284,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "eqv", 0 }, - { X_OPCODE(31,284,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "eqv.", 0 }, - { X_OPCODE(31,306,0), X_MASK, {O_rB, 0}, - 0, "tlbie", 0 }, - { X_OPCODE(31,310,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "eciwx", H_RA0_IS_0 }, - { X_OPCODE(31,311,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lhzux", 0 }, - { X_OPCODE(31,316,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "xor", 0 }, - { X_OPCODE(31,316,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "xor.", 0 }, - { XFX_OPCODE(31,339,0), XFX_MASK, {O_rD, O_spr, 0}, - 0, "mfspr", 0 }, - { X_OPCODE(31,343,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lhax", H_RA0_IS_0 }, - { X_OPCODE(31,370,0), X_MASK, {0}, - 0, "tlbia", 0 }, - { XFX_OPCODE(31,371,0), XFX_MASK, {O_rD, O_tbr, 0}, - 0, "mftb", 0 }, - { X_OPCODE(31,375,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lhaux", 0 }, - { X_OPCODE(31,407,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "sthx", H_RA0_IS_0 }, - { X_OPCODE(31,412,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "orc", 0 }, - { X_OPCODE(31,412,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "orc.", 0 }, - { X_OPCODE(31,438,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "ecowx", H_RA0_IS_0 }, - { X_OPCODE(31,439,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "sthux", 0 }, - { X_OPCODE(31,444,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "or", 0 }, - { X_OPCODE(31,444,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "or.", 0 }, - { XO_OPCODE(31,459,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "divwu", 0 }, - { XO_OPCODE(31,459,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "divwu.", 0 }, - { XFX_OPCODE(31,467,0), XFX_MASK, {O_spr, O_rS, 0}, - 0, "mtspr", 0 }, - { X_OPCODE(31,470,0), X_MASK, {O_rA, O_rB, 0}, - 0, "dcbi", H_RA0_IS_0 }, - { X_OPCODE(31,476,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "nand", 0 }, - { X_OPCODE(31,476,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc,0}, - 0, "nand.", 0 }, - { XO_OPCODE(31,491,0,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "divw", 0 }, - { XO_OPCODE(31,491,0,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "divw.", 0 }, - { X_OPCODE(31,512,0), X_MASK, {O_crfD, 0}, - 0, "mcrxr", 0 }, - { XO_OPCODE(31,8,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfco", 0 }, - { XO_OPCODE(31,8,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfco.", 0 }, - { XO_OPCODE(31,10,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "addco", 0 }, - { XO_OPCODE(31,10,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "addco.", 0 }, - { X_OPCODE(31,533,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lswx", H_RA0_IS_0 }, - { X_OPCODE(31,534,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lwbrx", H_RA0_IS_0 }, - { X_OPCODE(31,536,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "srw", 0 }, - { X_OPCODE(31,536,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "srw.", 0 }, - { XO_OPCODE(31,40,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfo", 0 }, - { XO_OPCODE(31,40,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfo.", 0 }, - { X_OPCODE(31,566,0), X_MASK, {0}, - 0, "tlbsync", 0 }, - { X_OPCODE(31,595,0), X_MASK, {O_rD, O_SR, 0}, - 0, "mfsr", 0 }, - { X_OPCODE(31,597,0), X_MASK, {O_rD, O_rA, O_NB, 0}, - 0, "lswi", H_RA0_IS_0 }, - { X_OPCODE(31,598,0), X_MASK, {0}, - 0, "sync", 0 }, - { XO_OPCODE(31,104,1,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "nego", 0 }, - { XO_OPCODE(31,104,1,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "nego.", 0 }, - { XO_OPCODE(31,136,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfeo", 0 }, - { XO_OPCODE(31,136,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "subfeo.", 0 }, - { XO_OPCODE(31,138,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "addeo", 0 }, - { XO_OPCODE(31,138,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "addeo.", 0 }, - { X_OPCODE(31,659,0), X_MASK, {O_rD, O_rB, 0}, - 0, "mfsrin", 0 }, - { X_OPCODE(31,661,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "stswx", H_RA0_IS_0 }, - { X_OPCODE(31,662,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "stwbrx", H_RA0_IS_0 }, - { XO_OPCODE(31,200,1,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "subfzeo", 0 }, - { XO_OPCODE(31,200,1,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "subfzeo.", 0 }, - { XO_OPCODE(31,202,1,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "addzeo", 0 }, - { XO_OPCODE(31,202,1,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "addzeo.", 0 }, - { X_OPCODE(31,725,0), X_MASK, {O_rS, O_rA, O_NB, 0}, - 0, "stswi", H_RA0_IS_0 }, - { XO_OPCODE(31,232,1,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "subfmeo", 0 }, - { XO_OPCODE(31,232,1,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "subfmeo.", 0 }, - { XO_OPCODE(31,234,1,0), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "addmeo", 0 }, - { XO_OPCODE(31,234,1,1), XO_MASK, {O_rD, O_rA, O_OE, O_Rc, 0}, - 0, "addmeo.", 0 }, - { XO_OPCODE(31,235,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "mullwo", 0 }, - { XO_OPCODE(31,235,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "mullwo.", 0 }, - { XO_OPCODE(31,266,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "addo", 0 }, - { XO_OPCODE(31,266,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "addo.", 0 }, - { X_OPCODE(31,790,0), X_MASK, {O_rD, O_rA, O_rB, 0}, - 0, "lhbrx", H_RA0_IS_0 }, - { X_OPCODE(31,792,0), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "sraw", 0 }, - { X_OPCODE(31,792,1), X_MASK, {O_rA, O_rS, O_rB, O_Rc, 0}, - 0, "sraw.", 0 }, - { X_OPCODE(31,824,0), X_MASK, {O_rA, O_rS, O_SH, O_Rc, 0}, - 0, "srawi", 0 }, - { X_OPCODE(31,824,1), X_MASK, {O_rA, O_rS, O_SH, O_Rc, 0}, - 0, "srawi.", 0 }, - { X_OPCODE(31,854,0), X_MASK, {0}, - 0, "eieio", 0 }, - { X_OPCODE(31,918,0), X_MASK, {O_rS, O_rA, O_rB, 0}, - 0, "sthbrx", H_RA0_IS_0 }, - { X_OPCODE(31,922,0), X_MASK, {O_rA, O_rS, O_Rc, 0}, - 0, "extsh", 0 }, - { X_OPCODE(31,922,1), X_MASK, {O_rA, O_rS, O_Rc, 0}, - 0, "extsh.", 0 }, - { X_OPCODE(31,954,0), X_MASK, {O_rA, O_rS, O_Rc, 0}, - 0, "extsb", 0 }, - { X_OPCODE(31,954,1), X_MASK, {O_rA, O_rS, O_Rc, 0}, - 0, "extsb.", 0 }, - { XO_OPCODE(31,459,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "divwuo", 0 }, - { XO_OPCODE(31,459,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "divwuo.", 0 }, - { X_OPCODE(31,978,0), X_MASK, {O_rB, 0}, - 0, "tlbld", 0 }, - { X_OPCODE(31,982,0), X_MASK, {O_rA, O_rB, 0}, - 0, "icbi", H_RA0_IS_0 }, - { XO_OPCODE(31,491,1,0), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "divwo", 0 }, - { XO_OPCODE(31,491,1,1), XO_MASK, {O_rD, O_rA, O_rB, O_OE, O_Rc, 0}, - 0, "divwo.", 0 }, - { X_OPCODE(31,1010,0), X_MASK, {O_rB, 0}, - 0, "tlbli", 0 }, - { X_OPCODE(31,1014,0), X_MASK, {O_rA, O_rB, 0}, - 0, "dcbz", H_RA0_IS_0 }, - { D_OPCODE(32), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lwz", H_RA0_IS_0 }, - { D_OPCODE(33), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lwzu", 0 }, - { D_OPCODE(34), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lbz", H_RA0_IS_0 }, - { D_OPCODE(35), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lbzu", 0 }, - { D_OPCODE(36), D_MASK, {O_rS, O_d, O_rA, 0}, - 0, "stw", H_RA0_IS_0 }, - { D_OPCODE(37), D_MASK, {O_rS, O_d, O_rA, 0}, - 0, "stwu", 0 }, - { D_OPCODE(38), D_MASK, {O_rS, O_d, O_rA, 0}, - 0, "stb", H_RA0_IS_0 }, - { D_OPCODE(39), D_MASK, {O_rS, O_d, O_rA, 0}, - 0, "stbu", 0 }, - { D_OPCODE(40), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lhz", H_RA0_IS_0 }, - { D_OPCODE(41), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lhzu", 0 }, - { D_OPCODE(42), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lha", H_RA0_IS_0 }, - { D_OPCODE(43), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lhau", 0 }, - { D_OPCODE(44), D_MASK, {O_rS, O_d, O_rA, 0}, - 0, "sth", H_RA0_IS_0 }, - { D_OPCODE(45), D_MASK, {O_rS, O_d, O_rA, 0}, - 0, "sthu", 0 }, - { D_OPCODE(46), D_MASK, {O_rD, O_d, O_rA, 0}, - 0, "lmw", H_RA0_IS_0 }, - { D_OPCODE(47), D_MASK, {O_rS, O_d, O_rA, 0}, - 0, "stmw", H_RA0_IS_0 }, -}; - -const unsigned int n_opcodes = sizeof(opcodes) / sizeof(opcodes[0]); - -struct spr_info spr_map[] = { - { SPR_XER, "XER" }, - { SPR_LR, "LR" }, - { SPR_CTR, "CTR" }, - { SPR_DSISR, "DSISR" }, - { SPR_DAR, "DAR" }, - { SPR_DEC, "DEC" }, - { SPR_SRR0, "SRR0" }, - { SPR_SRR1, "SRR1" }, - { SPR_EIE, "EIE" }, - { SPR_EID, "EID" }, - { SPR_CMPA, "CMPA" }, - { SPR_CMPB, "CMPB" }, - { SPR_CMPC, "CMPC" }, - { SPR_CMPD, "CMPD" }, - { SPR_ICR, "ICR" }, - { SPR_DER, "DER" }, - { SPR_COUNTA, "COUNTA" }, - { SPR_COUNTB, "COUNTB" }, - { SPR_CMPE, "CMPE" }, - { SPR_CMPF, "CMPF" }, - { SPR_CMPG, "CMPG" }, - { SPR_CMPH, "CMPH" }, - { SPR_LCTRL1, "LCTRL1" }, - { SPR_LCTRL2, "LCTRL2" }, - { SPR_ICTRL, "ICTRL" }, - { SPR_BAR, "BAR" }, - { SPR_USPRG0, "USPRG0" }, - { SPR_SPRG4_RO, "SPRG4_RO" }, - { SPR_SPRG5_RO, "SPRG5_RO" }, - { SPR_SPRG6_RO, "SPRG6_RO" }, - { SPR_SPRG7_RO, "SPRG7_RO" }, - { SPR_SPRG0, "SPRG0" }, - { SPR_SPRG1, "SPRG1" }, - { SPR_SPRG2, "SPRG2" }, - { SPR_SPRG3, "SPRG3" }, - { SPR_SPRG4, "SPRG4" }, - { SPR_SPRG5, "SPRG5" }, - { SPR_SPRG6, "SPRG6" }, - { SPR_SPRG7, "SPRG7" }, - { SPR_EAR, "EAR" }, - { SPR_TBL, "TBL" }, - { SPR_TBU, "TBU" }, - { SPR_IC_CST, "IC_CST" }, - { SPR_IC_ADR, "IC_ADR" }, - { SPR_IC_DAT, "IC_DAT" }, - { SPR_DC_CST, "DC_CST" }, - { SPR_DC_ADR, "DC_ADR" }, - { SPR_DC_DAT, "DC_DAT" }, - { SPR_DPDR, "DPDR" }, - { SPR_IMMR, "IMMR" }, - { SPR_MI_CTR, "MI_CTR" }, - { SPR_MI_AP, "MI_AP" }, - { SPR_MI_EPN, "MI_EPN" }, - { SPR_MI_TWC, "MI_TWC" }, - { SPR_MI_RPN, "MI_RPN" }, - { SPR_MD_CTR, "MD_CTR" }, - { SPR_M_CASID, "M_CASID" }, - { SPR_MD_AP, "MD_AP" }, - { SPR_MD_EPN, "MD_EPN" }, - { SPR_M_TWB, "M_TWB" }, - { SPR_MD_TWC, "MD_TWC" }, - { SPR_MD_RPN, "MD_RPN" }, - { SPR_M_TW, "M_TW" }, - { SPR_MI_DBCAM, "MI_DBCAM" }, - { SPR_MI_DBRAM0, "MI_DBRAM0" }, - { SPR_MI_DBRAM1, "MI_DBRAM1" }, - { SPR_MD_DBCAM, "MD_DBCAM" }, - { SPR_MD_DBRAM0, "MD_DBRAM0" }, - { SPR_MD_DBRAM1, "MD_DBRAM1" }, - { SPR_ZPR, "ZPR" }, - { SPR_PID, "PID" }, - { SPR_CCR0, "CCR0" }, - { SPR_IAC3, "IAC3" }, - { SPR_IAC4, "IAC4" }, - { SPR_DVC1, "DVC1" }, - { SPR_DVC2, "DVC2" }, - { SPR_SGR, "SGR" }, - { SPR_DCWR, "DCWR" }, - { SPR_SLER, "SLER" }, - { SPR_SU0R, "SU0R" }, - { SPR_DBCR1, "DBCR1" }, - { SPR_ICDBDR, "ICDBDR" }, - { SPR_ESR, "ESR" }, - { SPR_DEAR, "DEAR" }, - { SPR_EVPR, "EVPR" }, - { SPR_TSR, "TSR" }, - { SPR_TCR, "TCR" }, - { SPR_PIT, "PIT" }, - { SPR_SRR2, "SRR2" }, - { SPR_SRR3, "SRR3" }, - { SPR_DBSR, "DBSR" }, - { SPR_DBCR0, "DBCR0" }, - { SPR_IAC1, "IAC1" }, - { SPR_IAC2, "IAC2" }, - { SPR_DAC1, "DAC1" }, - { SPR_DAC2, "DAC2" }, - { SPR_DCCR, "DCCR" }, - { SPR_ICCR, "ICCR" }, -}; - -const unsigned int n_sprs = sizeof(spr_map) / sizeof(spr_map[0]); - -#endif - -/* - * Copyright (c) 2000 William L. Pitts and W. Gerald Hicks - * All rights reserved. - * - * Redistribution and use in source and binary forms are freely - * permitted provided that the above copyright notice and this - * paragraph and the following disclaimer are duplicated in all - * such forms. - * - * This software is provided "AS IS" and without any express or - * implied warranties, including, without limitation, the implied - * warranties of merchantability and fitness for a particular - * purpose. - */ diff --git a/include/bedbug/type.h b/include/bedbug/type.h deleted file mode 100644 index f7a719caf0a..00000000000 --- a/include/bedbug/type.h +++ /dev/null @@ -1,29 +0,0 @@ -#ifndef _TYPE_BEDBUG_H -#define _TYPE_BEDBUG_H - -struct cmd_tbl; - -/* Supporting routines */ -int bedbug_puts (const char *); -int bedbug_init(void); -void bedbug860_init (void); -void do_bedbug_breakpoint (struct pt_regs *); -void bedbug_main_loop (unsigned long, struct pt_regs *); - - -typedef struct { - int hw_debug_enabled; - int stopped; - int current_bp; - struct pt_regs *regs; - - void (*do_break)(struct cmd_tbl *cmd, int flags, int argc, - char *const argv[]); - void (*break_isr) (struct pt_regs *); - int (*find_empty) (void); - int (*set) (int, unsigned long); - int (*clear) (int); -} CPU_DEBUG_CTX; - - -#endif /* _TYPE_BEDBUG_H */ diff --git a/include/blk.h b/include/blk.h index f0cc7ca1a28..133204a82e1 100644 --- a/include/blk.h +++ b/include/blk.h @@ -34,9 +34,10 @@ enum if_type { IF_TYPE_SATA, IF_TYPE_HOST, IF_TYPE_NVME, - IF_TYPE_EFI, + IF_TYPE_EFI_LOADER, IF_TYPE_PVBLOCK, IF_TYPE_VIRTIO, + IF_TYPE_EFI_MEDIA, IF_TYPE_COUNT, /* Number of interface types */ }; @@ -370,6 +371,18 @@ int blk_create_devicef(struct udevice *parent, const char *drv_name, lbaint_t lba, struct udevice **devp); /** + * blk_probe_or_unbind() - Try to probe + * + * Try to probe the device, primarily for enumerating partitions. + * If it fails, the device itself is unbound since it means that it won't + * work any more. + * + * @dev: The device to probe + * Return: 0 if OK, -ve on error + */ +int blk_probe_or_unbind(struct udevice *dev); + +/** * blk_unbind_all() - Unbind all device of the given interface type * * The devices are removed and then unbound. diff --git a/include/bloblist.h b/include/bloblist.h index 9f007c7a94d..173129b0273 100644 --- a/include/bloblist.h +++ b/include/bloblist.h @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ +/* SPDX-License-Identifier: GPL-2.0+ BSD-3-Clause */ /* * This provides a standard way of passing information between boot phases * (TPL -> SPL -> U-Boot proper.) @@ -13,6 +13,8 @@ #ifndef __BLOBLIST_H #define __BLOBLIST_H +#include <mapmem.h> + enum { BLOBLIST_VERSION = 0, BLOBLIST_MAGIC = 0xb00757a3, @@ -23,23 +25,57 @@ enum { enum bloblist_tag_t { BLOBLISTT_NONE = 0, - /* Vendor-specific tags are permitted here */ - BLOBLISTT_EC_HOSTEVENT, /* Chromium OS EC host-event mask */ - BLOBLISTT_SPL_HANDOFF, /* Hand-off info from SPL */ - BLOBLISTT_VBOOT_CTX, /* Chromium OS verified boot context */ - BLOBLISTT_VBOOT_HANDOFF, /* Chromium OS internal handoff info */ + /* + * Standard area to allocate blobs used across firmware components, for + * things that are very commonly used, particularly in multiple + * projects. + */ + BLOBLISTT_AREA_FIRMWARE_TOP = 0x1, + + /* Standard area to allocate blobs used across firmware components */ + BLOBLISTT_AREA_FIRMWARE = 0x100, /* * Advanced Configuration and Power Interface Global Non-Volatile * Sleeping table. This forms part of the ACPI tables passed to Linux. */ - BLOBLISTT_ACPI_GNVS, - BLOBLISTT_INTEL_VBT, /* Intel Video-BIOS table */ - BLOBLISTT_TPM2_TCG_LOG, /* TPM v2 log space */ - BLOBLISTT_TCPA_LOG, /* TPM log space */ - BLOBLISTT_ACPI_TABLES, /* ACPI tables for x86 */ - BLOBLISTT_SMBIOS_TABLES, /* SMBIOS tables for x86 */ - - BLOBLISTT_COUNT + BLOBLISTT_ACPI_GNVS = 0x100, + BLOBLISTT_INTEL_VBT = 0x101, /* Intel Video-BIOS table */ + BLOBLISTT_TPM2_TCG_LOG = 0x102, /* TPM v2 log space */ + BLOBLISTT_TCPA_LOG = 0x103, /* TPM log space */ + BLOBLISTT_ACPI_TABLES = 0x104, /* ACPI tables for x86 */ + BLOBLISTT_SMBIOS_TABLES = 0x105, /* SMBIOS tables for x86 */ + BLOBLISTT_VBOOT_CTX = 0x106, /* Chromium OS verified boot context */ + + /* + * Project-specific tags are permitted here. Projects can be open source + * or not, but the format of the data must be fuily documented in an + * open source project, including all fields, bits, etc. Naming should + * be: BLOBLISTT_<project>_<purpose_here> + */ + BLOBLISTT_PROJECT_AREA = 0x8000, + BLOBLISTT_U_BOOT_SPL_HANDOFF = 0x8000, /* Hand-off info from SPL */ + + /* + * Vendor-specific tags are permitted here. Projects can be open source + * or not, but the format of the data must be fuily documented in an + * open source project, including all fields, bits, etc. Naming should + * be BLOBLISTT_<vendor>_<purpose_here> + */ + BLOBLISTT_VENDOR_AREA = 0xc000, + + /* Tags after this are not allocated for now */ + BLOBLISTT_EXPANSION = 0x10000, + + /* + * Tags from here are on reserved for private use within a single + * firmware binary (i.e. a single executable or phase of a project). + * These tags can be passed between binaries within a local + * implementation, but cannot be used in upstream code. Allocate a + * tag in one of the areas above if you want that. + * + * This area may move in future. + */ + BLOBLISTT_PRIVATE_AREA = 0xffff0000, }; /** @@ -50,8 +86,8 @@ enum bloblist_tag_t { * same place in memory as SPL and U-Boot execute, but it can be safely moved * around. * - * None of the bloblist structures contain pointers but it is possible to put - * pointers inside a bloblist record if desired. This is not encouraged, + * None of the bloblist headers themselves contain pointers but it is possible + * to put pointers inside a bloblist record if desired. This is not encouraged, * since it can make part of the bloblist inaccessible if the pointer is * no-longer valid. It is better to just store all the data inside a bloblist * record. @@ -59,11 +95,11 @@ enum bloblist_tag_t { * Each bloblist record is aligned to a 16-byte boundary and follows immediately * from the last. * + * @magic: BLOBLIST_MAGIC * @version: BLOBLIST_VERSION * @hdr_size: Size of this header, normally sizeof(struct bloblist_hdr). The * first bloblist_rec starts at this offset from the start of the header - * @flags: Space for BLOBLISTF_... flags (none yet) - * @magic: BLOBLIST_MAGIC + * @flags: Space for BLOBLISTF... flags (none yet) * @size: Total size of the bloblist (non-zero if valid) including this header. * The bloblist extends for this many bytes from the start of this header. * When adding new records, the bloblist can grow up to this size. @@ -74,14 +110,14 @@ enum bloblist_tag_t { * @chksum: CRC32 for the entire bloblist allocated area. Since any of the * blobs can be altered after being created, this checksum is only valid * when the bloblist is finalised before jumping to the next stage of boot. - * Note: @chksum is last to make it easier to exclude it from the checksum - * calculation. + * Note that chksum is last to make it easier to exclude it from the + * checksum calculation. */ struct bloblist_hdr { + u32 magic; u32 version; u32 hdr_size; u32 flags; - u32 magic; u32 size; u32 alloced; @@ -92,11 +128,11 @@ struct bloblist_hdr { /** * struct bloblist_rec - record for the bloblist * - * NOTE: Only exported for testing purposes. Do not use this struct. - * * The bloblist contains a number of records each consisting of this record * structure followed by the data contained. Each records is 16-byte aligned. * + * NOTE: Only exported for testing purposes. Do not use this struct. + * * @tag: Tag indicating what the record contains * @hdr_size: Size of this header, normally sizeof(struct bloblist_rec). The * record's data starts at this offset from the start of the record @@ -111,6 +147,35 @@ struct bloblist_rec { u32 spare; }; +/* access CONFIG_BLOBLIST_ADDR, dealing with it possibly not being defined */ +static inline ulong bloblist_addr(void) +{ +#ifdef CONFIG_BLOBLIST_FIXED + return CONFIG_BLOBLIST_ADDR; +#else + return 0; +#endif +} + +/** + * bloblist_check_magic() - return a bloblist if the magic matches + * + * @addr: Address to check + * Return: pointer to bloblist, if the magic matches, else NULL + */ +static inline void *bloblist_check_magic(ulong addr) +{ + u32 *ptr; + + if (!addr) + return NULL; + ptr = map_sysmem(addr, 0); + if (*ptr != BLOBLIST_MAGIC) + return NULL; + + return ptr; +} + /** * bloblist_find() - Find a blob * @@ -118,8 +183,8 @@ struct bloblist_rec { * * @tag: Tag to search for (enum bloblist_tag_t) * @size: Expected size of the blob, or 0 for any size - * @return pointer to blob if found, or NULL if not found, or a blob was found - * but it is the wrong size + * Return: pointer to blob if found, or NULL if not found, or a blob was found + * but it is the wrong size */ void *bloblist_find(uint tag, int size); @@ -135,8 +200,8 @@ void *bloblist_find(uint tag, int size); * @tag: Tag to add (enum bloblist_tag_t) * @size: Size of the blob * @align: Alignment of the blob (in bytes), 0 for default - * @return pointer to the newly added block, or NULL if there is not enough - * space for the blob + * Return: pointer to the newly added block, or NULL if there is not enough + * space for the blob */ void *bloblist_add(uint tag, int size, int align); @@ -149,8 +214,8 @@ void *bloblist_add(uint tag, int size, int align); * @size: Size of the blob * @blobp: Returns a pointer to blob on success * @align: Alignment of the blob (in bytes), 0 for default - * @return 0 if OK, -ENOSPC if it is missing and could not be added due to lack - * of space, or -ESPIPE it exists but has the wrong size + * Return: 0 if OK, -ENOSPC if it is missing and could not be added due to lack + * of space, or -ESPIPE it exists but has the wrong size */ int bloblist_ensure_size(uint tag, int size, int align, void **blobp); @@ -161,8 +226,8 @@ int bloblist_ensure_size(uint tag, int size, int align, void **blobp); * * @tag: Tag to add (enum bloblist_tag_t) * @size: Size of the blob - * @return pointer to blob, or NULL if it is missing and could not be added due - * to lack of space, or it exists but has the wrong size + * Return: pointer to blob, or NULL if it is missing and could not be added due + * to lack of space, or it exists but has the wrong size */ void *bloblist_ensure(uint tag, int size); @@ -174,8 +239,8 @@ void *bloblist_ensure(uint tag, int size); * @tag: Tag to add (enum bloblist_tag_t) * @sizep: Size of the blob to create; returns size of actual blob * @blobp: Returns a pointer to blob on success - * @return 0 if OK, -ENOSPC if it is missing and could not be added due to lack - * of space + * Return: 0 if OK, -ENOSPC if it is missing and could not be added due to lack + * of space */ int bloblist_ensure_size_ret(uint tag, int *sizep, void **blobp); @@ -187,8 +252,8 @@ int bloblist_ensure_size_ret(uint tag, int *sizep, void **blobp); * * @tag: Tag to add (enum bloblist_tag_t) * @new_size: New size of the blob (>0 to expand, <0 to contract) - * @return 0 if OK, -ENOSPC if the bloblist does not have enough space, -ENOENT - * if the tag is not found + * Return: 0 if OK, -ENOSPC if the bloblist does not have enough space, -ENOENT + * if the tag is not found */ int bloblist_resize(uint tag, int new_size); @@ -198,8 +263,8 @@ int bloblist_resize(uint tag, int new_size); * @addr: Address of bloblist * @size: Initial size for bloblist * @flags: Flags to use for bloblist - * @return 0 if OK, -EFAULT if addr is not aligned correctly, -ENOSPC is the - * area is not large enough + * Return: 0 if OK, -EFAULT if addr is not aligned correctly, -ENOSPC is the + * area is not large enough */ int bloblist_new(ulong addr, uint size, uint flags); @@ -208,11 +273,11 @@ int bloblist_new(ulong addr, uint size, uint flags); * * @addr: Address of bloblist * @size: Expected size of blobsize, or 0 to detect the size - * @return 0 if OK, -ENOENT if the magic number doesn't match (indicating that - * there problem is no bloblist at the given address), -EPROTONOSUPPORT - * if the version does not match, -EIO if the checksum does not match, - * -EFBIG if the expected size does not match the detected size, -ENOSPC - * if the size is not large enough to hold the headers + * Return: 0 if OK, -ENOENT if the magic number doesn't match (indicating that + * there problem is no bloblist at the given address), -EPROTONOSUPPORT + * if the version does not match, -EIO if the checksum does not match, + * -EFBIG if the expected size does not match the detected size, -ENOSPC + * if the size is not large enough to hold the headers */ int bloblist_check(ulong addr, uint size); @@ -222,7 +287,7 @@ int bloblist_check(ulong addr, uint size); * This sets the correct checksum for the bloblist. This ensures that the * bloblist will be detected correctly by the next phase of U-Boot. * - * @return 0 + * Return: 0 */ int bloblist_finish(void); @@ -238,6 +303,20 @@ int bloblist_finish(void); void bloblist_get_stats(ulong *basep, ulong *sizep, ulong *allocedp); /** + * bloblist_get_base() - Get the base address of the bloblist + * + * Return: base address of bloblist + */ +ulong bloblist_get_base(void); + +/** + * bloblist_get_size() - Get the size of the bloblist + * + * Return: the size in bytes + */ +ulong bloblist_get_size(void); + +/** * bloblist_show_stats() - Show information about the bloblist * * This shows useful information about the bloblist on the console @@ -255,7 +334,7 @@ void bloblist_show_list(void); * bloblist_tag_name() - Get the name for a tag * * @tag: Tag to check - * @return name of tag, or "invalid" if an invalid tag is provided + * Return: name of tag, or "invalid" if an invalid tag is provided */ const char *bloblist_tag_name(enum bloblist_tag_t tag); @@ -263,7 +342,7 @@ const char *bloblist_tag_name(enum bloblist_tag_t tag); * bloblist_reloc() - Relocate the bloblist and optionally resize it * * @to: Pointer to new bloblist location (must not overlap old location) - * @to:size: New size for bloblist (must be larger than from_size) + * @to_size: New size for bloblist (must be larger than from_size) * @from: Pointer to bloblist to relocate * @from_size: Size of bloblist to relocate */ @@ -272,8 +351,19 @@ void bloblist_reloc(void *to, uint to_size, void *from, uint from_size); /** * bloblist_init() - Init the bloblist system with a single bloblist * - * This uses CONFIG_BLOBLIST_ADDR and CONFIG_BLOBLIST_SIZE to set up a bloblist - * for use by U-Boot. + * This locates and sets up the blocklist for use. + * + * If CONFIG_BLOBLIST_FIXED is selected, it uses CONFIG_BLOBLIST_ADDR and + * CONFIG_BLOBLIST_SIZE to set up a bloblist for use by U-Boot. + * + * If CONFIG_BLOBLIST_ALLOC is selected, it allocates memory for a bloblist of + * size CONFIG_BLOBLIST_SIZE. + * + * If CONFIG_BLOBLIST_PASSAGE is selected, it uses the bloblist in the incoming + * standard passage. The size is detected automatically so CONFIG_BLOBLIST_SIZE + * can be 0. + * + * Return: 0 if OK, -ve on error */ int bloblist_init(void); diff --git a/include/clk.h b/include/clk.h index a928879b122..df5255e510e 100644 --- a/include/clk.h +++ b/include/clk.h @@ -389,7 +389,8 @@ int clk_free(struct clk *clk); * * @clk: A clock struct that was previously successfully requested by * clk_request/get_by_*(). - * @return clock rate in Hz, or -ve error code. + * @return clock rate in Hz on success, 0 for invalid clock, or -ve error code + * for other errors. */ ulong clk_get_rate(struct clk *clk); diff --git a/include/clock_legacy.h b/include/clock_legacy.h index 29261b680d0..efa483117da 100644 --- a/include/clock_legacy.h +++ b/include/clock_legacy.h @@ -22,4 +22,15 @@ unsigned long get_board_ddr_clk(void); #define get_board_ddr_clk() CONFIG_DDR_CLK_FREQ #endif +/* + * If we have CONFIG_DYNAMIC_SYS_CLK_FREQ then there will be an + * implentation of get_board_sys_clk() somewhere. Otherwise we have + * a static value to use now. + */ +#ifdef CONFIG_DYNAMIC_SYS_CLK_FREQ +unsigned long get_board_sys_clk(void); +#else +#define get_board_sys_clk() CONFIG_SYS_CLK_FREQ +#endif + #endif diff --git a/include/command.h b/include/command.h index 137cfbc3231..f8e07a591c6 100644 --- a/include/command.h +++ b/include/command.h @@ -45,7 +45,7 @@ struct cmd_tbl { char *const argv[]); char *usage; /* Usage message (short) */ #ifdef CONFIG_SYS_LONGHELP - char *help; /* Help message (long) */ + const char *help; /* Help message (long) */ #endif #ifdef CONFIG_AUTO_COMPLETE /* do auto completion on the arguments */ diff --git a/include/config_distro_bootcmd.h b/include/config_distro_bootcmd.h index 3f724aa10f4..2f90929178e 100644 --- a/include/config_distro_bootcmd.h +++ b/include/config_distro_bootcmd.h @@ -498,8 +498,4 @@ "run bootcmd_${target}; " \ "done\0" -#ifndef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND "run distro_bootcmd" -#endif - #endif /* _CONFIG_CMD_DISTRO_BOOTCMD_H */ diff --git a/include/configs/M5208EVBE.h b/include/configs/M5208EVBE.h index 6a69ac45aee..5ed624c7b76 100644 --- a/include/configs/M5208EVBE.h +++ b/include/configs/M5208EVBE.h @@ -15,7 +15,6 @@ */ #define CONFIG_SYS_UART_PORT (0) -#undef CONFIG_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 5000 #ifdef CONFIG_MCFFEC @@ -39,7 +38,6 @@ #define CONFIG_MCFTMR /* I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR #define CONFIG_UDP_CHECKSUM diff --git a/include/configs/M5235EVB.h b/include/configs/M5235EVB.h index 7421f3b7605..90f1664a5ae 100644 --- a/include/configs/M5235EVB.h +++ b/include/configs/M5235EVB.h @@ -20,7 +20,6 @@ #define CONFIG_SYS_UART_PORT (0) -#undef CONFIG_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 5000 /* timeout in milliseconds, max timeout is 6.71sec */ /* @@ -48,7 +47,6 @@ #define CONFIG_MCFTMR /* I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR #define CONFIG_SYS_I2C_PINMUX_REG (gpio->par_qspi) #define CONFIG_SYS_I2C_PINMUX_CLR ~(GPIO_PAR_FECI2C_SCL_MASK | GPIO_PAR_FECI2C_SDA_MASK) #define CONFIG_SYS_I2C_PINMUX_SET (GPIO_PAR_FECI2C_SCL_I2CSCL | GPIO_PAR_FECI2C_SDA_I2CSDA) diff --git a/include/configs/M5249EVB.h b/include/configs/M5249EVB.h index 7ee0ec6a4a8..00892ec44dc 100644 --- a/include/configs/M5249EVB.h +++ b/include/configs/M5249EVB.h @@ -21,8 +21,6 @@ #define CONFIG_SYS_UART_PORT (0) -#undef CONFIG_WATCHDOG - #undef CONFIG_MONITOR_IS_IN_RAM /* no pre-loader required!!! ;-) */ /* diff --git a/include/configs/M5253DEMO.h b/include/configs/M5253DEMO.h index e9a79229219..c5d8aa3edab 100644 --- a/include/configs/M5253DEMO.h +++ b/include/configs/M5253DEMO.h @@ -12,8 +12,6 @@ #define CONFIG_SYS_UART_PORT (0) -#undef CONFIG_WATCHDOG /* disable watchdog */ - /* Configuration for environment * Environment is embedded in u-boot in the second sector of the flash @@ -69,7 +67,6 @@ #define CONFIG_HOSTNAME "M5253DEMO" /* I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR #define CONFIG_SYS_I2C_PINMUX_REG (*(u32 *) (CONFIG_SYS_MBAR+0x19C)) #define CONFIG_SYS_I2C_PINMUX_CLR (0xFFFFE7FF) #define CONFIG_SYS_I2C_PINMUX_SET (0) diff --git a/include/configs/M5272C3.h b/include/configs/M5272C3.h index 1204aa07a9c..e814a2924c6 100644 --- a/include/configs/M5272C3.h +++ b/include/configs/M5272C3.h @@ -20,7 +20,6 @@ #define CONFIG_SYS_UART_PORT (0) -#undef CONFIG_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 10000 /* timeout in milliseconds */ #undef CONFIG_MONITOR_IS_IN_RAM /* define if monitor is started from a pre-loader */ @@ -146,26 +145,6 @@ CF_CACR_EUSP) /*----------------------------------------------------------------------- - * Memory bank definitions - */ -#define CONFIG_SYS_BR0_PRELIM 0xFFE00201 -#define CONFIG_SYS_OR0_PRELIM 0xFFE00014 -#define CONFIG_SYS_BR1_PRELIM 0 -#define CONFIG_SYS_OR1_PRELIM 0 -#define CONFIG_SYS_BR2_PRELIM 0x30000001 -#define CONFIG_SYS_OR2_PRELIM 0xFFF80000 -#define CONFIG_SYS_BR3_PRELIM 0 -#define CONFIG_SYS_OR3_PRELIM 0 -#define CONFIG_SYS_BR4_PRELIM 0 -#define CONFIG_SYS_OR4_PRELIM 0 -#define CONFIG_SYS_BR5_PRELIM 0 -#define CONFIG_SYS_OR5_PRELIM 0 -#define CONFIG_SYS_BR6_PRELIM 0 -#define CONFIG_SYS_OR6_PRELIM 0 -#define CONFIG_SYS_BR7_PRELIM 0x00000701 -#define CONFIG_SYS_OR7_PRELIM 0xFFC0007C - -/*----------------------------------------------------------------------- * Port configuration */ #define CONFIG_SYS_PACNT 0x00000000 diff --git a/include/configs/M5275EVB.h b/include/configs/M5275EVB.h index 8e03fc995f8..b18f0319b09 100644 --- a/include/configs/M5275EVB.h +++ b/include/configs/M5275EVB.h @@ -58,13 +58,10 @@ #endif /* I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR #define CONFIG_SYS_I2C_PINMUX_REG (gpio_reg->par_feci2c) #define CONFIG_SYS_I2C_PINMUX_CLR (0xFFF0) #define CONFIG_SYS_I2C_PINMUX_SET (0x000F) -#define CONFIG_BOOTCOMMAND "bootm ffe40000" - #ifdef CONFIG_MCFFEC # define CONFIG_NET_RETRY_COUNT 5 # define CONFIG_OVERWRITE_ETHADDR_ONCE diff --git a/include/configs/M53017EVB.h b/include/configs/M53017EVB.h index 7b33677c551..5db189ae2db 100644 --- a/include/configs/M53017EVB.h +++ b/include/configs/M53017EVB.h @@ -20,7 +20,6 @@ #define CONFIG_SYS_UART_PORT (0) -#undef CONFIG_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 5000 #define CONFIG_SYS_UNIFY_CACHE @@ -54,7 +53,6 @@ #define CONFIG_MCFTMR /* I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR #define CONFIG_UDP_CHECKSUM diff --git a/include/configs/M5329EVB.h b/include/configs/M5329EVB.h index 19d8cfe3217..f96f54ef65b 100644 --- a/include/configs/M5329EVB.h +++ b/include/configs/M5329EVB.h @@ -20,7 +20,6 @@ #define CONFIG_SYS_UART_PORT (0) -#undef CONFIG_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 5000 /* timeout in milliseconds, max timeout is 6.71sec */ #define CONFIG_SYS_UNIFY_CACHE @@ -48,7 +47,6 @@ #define CONFIG_MCFTMR /* I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR #define CONFIG_UDP_CHECKSUM @@ -137,10 +135,6 @@ # define CONFIG_SYS_NAND_SIZE 1 # define CONFIG_SYS_NAND_BASE_LIST { CONFIG_SYS_NAND_BASE } # define NAND_ALLOW_ERASE_ALL 1 -# define CONFIG_JFFS2_NAND 1 -# define CONFIG_JFFS2_DEV "nand0" -# define CONFIG_JFFS2_PART_SIZE (CONFIG_SYS_CS2_MASK & ~1) -# define CONFIG_JFFS2_PART_OFFSET 0x00000000 #endif #define CONFIG_SYS_FLASH_BASE CONFIG_SYS_CS0_BASE diff --git a/include/configs/M5373EVB.h b/include/configs/M5373EVB.h index e2ddc4893e7..b7906013e09 100644 --- a/include/configs/M5373EVB.h +++ b/include/configs/M5373EVB.h @@ -22,7 +22,6 @@ #define CONFIG_SYS_UART_PORT (0) -#undef CONFIG_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 3360 /* timeout in ms, max is 3.36 sec */ #define CONFIG_SYS_UNIFY_CACHE @@ -50,7 +49,6 @@ #define CONFIG_MCFTMR /* I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR #define CONFIG_UDP_CHECKSUM @@ -139,10 +137,6 @@ # define CONFIG_SYS_NAND_SIZE 1 # define CONFIG_SYS_NAND_BASE_LIST { CONFIG_SYS_NAND_BASE } # define NAND_ALLOW_ERASE_ALL 1 -# define CONFIG_JFFS2_NAND 1 -# define CONFIG_JFFS2_DEV "nand0" -# define CONFIG_JFFS2_PART_SIZE (CONFIG_SYS_CS2_MASK & ~1) -# define CONFIG_JFFS2_PART_OFFSET 0x00000000 #endif #define CONFIG_SYS_FLASH_BASE CONFIG_SYS_CS0_BASE diff --git a/include/configs/MPC837XERDB.h b/include/configs/MPC837XERDB.h index 72119a1cf04..9a34e5444b1 100644 --- a/include/configs/MPC837XERDB.h +++ b/include/configs/MPC837XERDB.h @@ -302,8 +302,6 @@ */ #define CONFIG_BOOTP_BOOTFILESIZE -#undef CONFIG_WATCHDOG /* watchdog disabled */ - #ifdef CONFIG_MMC #define CONFIG_FSL_ESDHC_PIN_MUX #define CONFIG_SYS_FSL_ESDHC_ADDR CONFIG_SYS_MPC83xx_ESDHC_ADDR @@ -326,7 +324,6 @@ */ #define CONFIG_HAS_FSL_DR_USB -#define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #define CONFIG_NETDEV "eth1" @@ -365,20 +362,4 @@ "$netdev:off " \ "root=$rootdev rw console=$console,$baudrate $othbootargs\0" -#define NFSBOOTCOMMAND \ - "setenv rootdev /dev/nfs;" \ - "run setbootargs;" \ - "run setipargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv rootdev /dev/ram;" \ - "run setbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - #endif /* __CONFIG_H */ diff --git a/include/configs/MPC8540ADS.h b/include/configs/MPC8540ADS.h index fe156e78157..84e05eafa61 100644 --- a/include/configs/MPC8540ADS.h +++ b/include/configs/MPC8540ADS.h @@ -26,8 +26,6 @@ #define CONFIG_HAS_FEC 1 /* 8540 has FEC */ #endif -#define CONFIG_SYS_PCI_64BIT 1 /* enable 64-bit PCI resources */ - /* * sysclk for MPC85xx * @@ -46,10 +44,6 @@ * Note that PCI-X won't work at 33MHz. */ -#ifndef CONFIG_SYS_CLK_FREQ -#define CONFIG_SYS_CLK_FREQ 33000000 -#endif - /* * These can be toggled for performance analysis, otherwise use default. */ @@ -90,9 +84,7 @@ #define CONFIG_SYS_LBC_SDRAM_SIZE 64 /* LBC SDRAM is 64MB */ #define CONFIG_SYS_FLASH_BASE 0xff000000 /* start of FLASH 16M */ -#define CONFIG_SYS_BR0_PRELIM 0xff001801 /* port size 32bit */ -#define CONFIG_SYS_OR0_PRELIM 0xff006ff7 /* 16MB Flash */ #define CONFIG_SYS_MAX_FLASH_BANKS 1 /* number of banks */ #define CONFIG_SYS_MAX_FLASH_SECT 64 /* sectors per device */ #undef CONFIG_SYS_FLASH_CHECKSUM @@ -131,8 +123,6 @@ * FIXME: the top 17 bits of BR2. */ -#define CONFIG_SYS_BR2_PRELIM 0xf0001861 - /* * The SDRAM size in MB, CONFIG_SYS_LBC_SDRAM_SIZE, is 64. * @@ -147,8 +137,6 @@ * 1111 1100 0000 0000 0110 1001 0000 0001 = fc006901 */ -#define CONFIG_SYS_OR2_PRELIM 0xfc006901 - #define CONFIG_SYS_LBC_LCRR 0x00030004 /* LB clock ratio reg */ #define CONFIG_SYS_LBC_LBCR 0x00000000 /* LB config reg */ #define CONFIG_SYS_LBC_LSRT 0x20000000 /* LB sdram refresh timer */ @@ -176,8 +164,6 @@ /* * 32KB, 8-bit wide for ADS config reg */ -#define CONFIG_SYS_BR4_PRELIM 0xf8000801 -#define CONFIG_SYS_OR4_PRELIM 0xffffe1f1 #define CONFIG_SYS_BCSR (CONFIG_SYS_BR4_PRELIM & 0xffff8000) #define CONFIG_SYS_INIT_RAM_LOCK 1 @@ -274,8 +260,6 @@ */ #define CONFIG_BOOTP_BOOTFILESIZE -#undef CONFIG_WATCHDOG /* watchdog disabled */ - /* * Miscellaneous configurable options */ @@ -317,23 +301,4 @@ "fdtaddr=400000\0" \ "fdtfile=your.fdt.dtb\0" -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND NFSBOOTCOMMAND - #endif /* __CONFIG_H */ diff --git a/include/configs/MPC8548CDS.h b/include/configs/MPC8548CDS.h index 5c54bad4964..f583aa8b36d 100644 --- a/include/configs/MPC8548CDS.h +++ b/include/configs/MPC8548CDS.h @@ -19,15 +19,12 @@ #define CONFIG_PCI1 /* PCI controller 1 */ #define CONFIG_PCIE1 /* PCIE controller 1 (slot 1) */ #undef CONFIG_PCI2 -#define CONFIG_SYS_PCI_64BIT 1 /* enable 64-bit PCI resources */ #define CONFIG_INTERRUPTS /* enable pci, srio, ddr interrupts */ #ifndef __ASSEMBLY__ #include <linux/stringify.h> -extern unsigned long get_clock_freq(void); #endif -#define CONFIG_SYS_CLK_FREQ get_clock_freq() /* sysclk for MPC85xx */ /* * These can be toggled for performance analysis, otherwise use default. @@ -134,14 +131,6 @@ extern unsigned long get_clock_freq(void); #define CONFIG_SYS_FLASH_BASE_PHYS CONFIG_SYS_FLASH_BASE #endif -#define CONFIG_SYS_BR0_PRELIM \ - (BR_PHYS_ADDR(CONFIG_SYS_FLASH_BASE_PHYS + 0x800000) | BR_PS_16 | BR_V) -#define CONFIG_SYS_BR1_PRELIM \ - (BR_PHYS_ADDR(CONFIG_SYS_FLASH_BASE_PHYS) | BR_PS_16 | BR_V) - -#define CONFIG_SYS_OR0_PRELIM 0xff806e65 -#define CONFIG_SYS_OR1_PRELIM 0xff806e65 - #define CONFIG_SYS_FLASH_BANKS_LIST \ {CONFIG_SYS_FLASH_BASE_PHYS + 0x800000, CONFIG_SYS_FLASH_BASE_PHYS} #define CONFIG_SYS_MAX_FLASH_BANKS 2 /* number of banks */ @@ -185,10 +174,6 @@ extern unsigned long get_clock_freq(void); * FIXME: the top 17 bits of BR2. */ -#define CONFIG_SYS_BR2_PRELIM \ - (BR_PHYS_ADDR(CONFIG_SYS_LBC_SDRAM_BASE_PHYS) \ - | BR_PS_32 | (3<<BR_MSEL_SHIFT) | BR_V) - /* * The SDRAM size in MB, CONFIG_SYS_LBC_SDRAM_SIZE, is 64. * @@ -203,8 +188,6 @@ extern unsigned long get_clock_freq(void); * 1111 1100 0000 0000 0110 1001 0000 0001 = fc006901 */ -#define CONFIG_SYS_OR2_PRELIM 0xfc006901 - #define CONFIG_SYS_LBC_LCRR 0x00030004 /* LB clock ratio reg */ #define CONFIG_SYS_LBC_LBCR 0x00000000 /* LB config reg */ #define CONFIG_SYS_LBC_LSRT 0x20000000 /* LB sdram refresh timer */ @@ -263,9 +246,6 @@ extern unsigned long get_clock_freq(void); #else #define CADMUS_BASE_ADDR_PHYS CADMUS_BASE_ADDR #endif -#define CONFIG_SYS_BR3_PRELIM \ - (BR_PHYS_ADDR(CADMUS_BASE_ADDR_PHYS) | BR_PS_8 | BR_V) -#define CONFIG_SYS_OR3_PRELIM 0xfff00ff7 #define CONFIG_SYS_INIT_RAM_LOCK 1 #define CONFIG_SYS_INIT_RAM_ADDR 0xe4010000 /* Initial RAM address */ @@ -401,8 +381,6 @@ extern unsigned long get_clock_freq(void); */ #define CONFIG_BOOTP_BOOTFILESIZE -#undef CONFIG_WATCHDOG /* watchdog disabled */ - /* * Miscellaneous configurable options */ @@ -457,23 +435,4 @@ extern unsigned long get_clock_freq(void); "fdtaddr=1e00000\0" \ "fdtfile=mpc8548cds.dtb\0" -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND NFSBOOTCOMMAND - #endif /* __CONFIG_H */ diff --git a/include/configs/MPC8560ADS.h b/include/configs/MPC8560ADS.h index dcd538fdf1a..b8a72d01dd8 100644 --- a/include/configs/MPC8560ADS.h +++ b/include/configs/MPC8560ADS.h @@ -27,7 +27,6 @@ * assume U-Boot is less than 0.5MB */ -#define CONFIG_SYS_PCI_64BIT 1 /* enable 64-bit PCI resources */ #define CONFIG_RESET_PHY_R 1 /* Call reset_phy() */ /* @@ -44,10 +43,6 @@ * in the README.mpc85xxads. */ -#ifndef CONFIG_SYS_CLK_FREQ -#define CONFIG_SYS_CLK_FREQ 33000000 -#endif - /* * These can be toggled for performance analysis, otherwise use default. */ @@ -90,9 +85,7 @@ #define CONFIG_SYS_LBC_SDRAM_SIZE 64 /* LBC SDRAM is 64MB */ #define CONFIG_SYS_FLASH_BASE 0xff000000 /* start of FLASH 16M */ -#define CONFIG_SYS_BR0_PRELIM 0xff001801 /* port size 32bit */ -#define CONFIG_SYS_OR0_PRELIM 0xff006ff7 /* 16MB Flash */ #define CONFIG_SYS_MAX_FLASH_BANKS 1 /* number of banks */ #define CONFIG_SYS_MAX_FLASH_SECT 64 /* sectors per device */ #undef CONFIG_SYS_FLASH_CHECKSUM @@ -131,8 +124,6 @@ * FIXME: the top 17 bits of BR2. */ -#define CONFIG_SYS_BR2_PRELIM 0xf0001861 - /* * The SDRAM size in MB, CONFIG_SYS_LBC_SDRAM_SIZE, is 64. * @@ -147,8 +138,6 @@ * 1111 1100 0000 0000 0110 1001 0000 0001 = fc006901 */ -#define CONFIG_SYS_OR2_PRELIM 0xfc006901 - #define CONFIG_SYS_LBC_LCRR 0x00030004 /* LB clock ratio reg */ #define CONFIG_SYS_LBC_LBCR 0x00000000 /* LB config reg */ #define CONFIG_SYS_LBC_LSRT 0x20000000 /* LB sdram refresh timer */ @@ -176,8 +165,6 @@ /* * 32KB, 8-bit wide for ADS config reg */ -#define CONFIG_SYS_BR4_PRELIM 0xf8000801 -#define CONFIG_SYS_OR4_PRELIM 0xffffe1f1 #define CONFIG_SYS_BCSR (CONFIG_SYS_BR4_PRELIM & 0xffff8000) #define CONFIG_SYS_INIT_RAM_LOCK 1 @@ -261,8 +248,6 @@ */ #define CONFIG_BOOTP_BOOTFILESIZE -#undef CONFIG_WATCHDOG /* watchdog disabled */ - /* * Miscellaneous configurable options */ @@ -305,23 +290,4 @@ "fdtaddr=400000\0" \ "fdtfile=mpc8560ads.dtb\0" -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND NFSBOOTCOMMAND - #endif /* __CONFIG_H */ diff --git a/include/configs/P1010RDB.h b/include/configs/P1010RDB.h index 1841eff69c7..6a9c86c9c4f 100644 --- a/include/configs/P1010RDB.h +++ b/include/configs/P1010RDB.h @@ -63,19 +63,16 @@ #define CONFIG_SYS_NAND_U_BOOT_SIZE ((768 << 10) - 0x2000) #define CONFIG_SYS_NAND_U_BOOT_DST (0x00200000 - CONFIG_SPL_MAX_SIZE) #define CONFIG_SYS_NAND_U_BOOT_START 0x00200000 -#define CONFIG_SYS_NAND_U_BOOT_OFFS 0 #else #ifdef CONFIG_TPL_BUILD #define CONFIG_SPL_FLUSH_IMAGE #define CONFIG_SPL_NAND_INIT #define CONFIG_SPL_COMMON_INIT_DDR #define CONFIG_SPL_MAX_SIZE (128 << 10) -#define CONFIG_TPL_TEXT_BASE 0xD0001000 #define CONFIG_SYS_MPC85XX_NO_RESETVEC #define CONFIG_SYS_NAND_U_BOOT_SIZE (576 << 10) #define CONFIG_SYS_NAND_U_BOOT_DST (0x11000000) #define CONFIG_SYS_NAND_U_BOOT_START (0x11000000) -#define CONFIG_SYS_NAND_U_BOOT_OFFS ((128 + 128) << 10) #elif defined(CONFIG_SPL_BUILD) #define CONFIG_SPL_INIT_MINIMAL #define CONFIG_SPL_NAND_MINIMAL @@ -84,7 +81,6 @@ #define CONFIG_SYS_NAND_U_BOOT_SIZE (128 << 10) #define CONFIG_SYS_NAND_U_BOOT_DST 0xD0000000 #define CONFIG_SYS_NAND_U_BOOT_START 0xD0000000 -#define CONFIG_SYS_NAND_U_BOOT_OFFS (128 << 10) #endif #define CONFIG_SPL_PAD_TO 0x20000 #define CONFIG_TPL_PAD_TO 0x20000 @@ -102,7 +98,7 @@ #endif #ifdef CONFIG_TPL_BUILD -#define CONFIG_SYS_MONITOR_BASE CONFIG_TPL_TEXT_BASE +#define CONFIG_SYS_MONITOR_BASE 0xD0001000 #elif defined(CONFIG_SPL_BUILD) #define CONFIG_SYS_MONITOR_BASE CONFIG_SPL_TEXT_BASE #else @@ -110,12 +106,10 @@ #endif /* High Level Configuration Options */ -#define CONFIG_SYS_HAS_SERDES /* common SERDES init code */ #if defined(CONFIG_PCI) #define CONFIG_PCIE1 /* PCIE controller 1 (slot 1) */ #define CONFIG_PCIE2 /* PCIE controller 2 (slot 2) */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ /* * PCI Windows @@ -152,8 +146,6 @@ #define CONFIG_PCI_SCAN_SHOW /* show pci devices on startup */ #endif -#define CONFIG_SYS_CLK_FREQ 66666666 /* SYSCLK for P1010 RDB */ - #define CONFIG_HWCONFIG /* * These can be toggled for performance analysis, otherwise use default. @@ -573,7 +565,6 @@ extern unsigned long get_sdram_size(void); #if defined(CONFIG_HAS_FSL_DR_USB) #ifdef CONFIG_USB_EHCI_HCD #define CONFIG_EHCI_HCD_INIT_AFTER_RESET -#define CONFIG_USB_EHCI_FSL #endif #endif @@ -597,8 +588,6 @@ extern unsigned long get_sdram_size(void); #define CONFIG_LOADS_ECHO /* echo on for serial download */ #define CONFIG_SYS_LOADS_BAUD_CHANGE /* allow baudrate change */ -#undef CONFIG_WATCHDOG /* watchdog disabled */ - #if defined(CONFIG_MMC) || defined(CONFIG_USB_EHCI_HCD) \ || defined(CONFIG_FSL_SATA) #endif @@ -681,16 +670,6 @@ extern unsigned long get_sdram_size(void); "i2c mw 19 1 4; i2c mw 19 3 f3; reset\0" #endif -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs; " \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND RAMBOOTCOMMAND - #include <asm/fsl_secure_boot.h> #endif /* __CONFIG_H */ diff --git a/include/configs/P2041RDB.h b/include/configs/P2041RDB.h index bf8a92c69b2..8ada25dcc7a 100644 --- a/include/configs/P2041RDB.h +++ b/include/configs/P2041RDB.h @@ -36,7 +36,6 @@ #define CONFIG_PCIE1 /* PCIE controller 1 */ #define CONFIG_PCIE2 /* PCIE controller 2 */ #define CONFIG_PCIE3 /* PCIE controller 3 */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ #define CONFIG_SYS_SRIO #define CONFIG_SRIO1 /* SRIO port 1 */ @@ -50,10 +49,8 @@ #endif #ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(unsigned long dummy); #include <linux/stringify.h> #endif -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk(0) /* * These can be toggled for performance analysis, otherwise use default. @@ -137,9 +134,6 @@ unsigned long get_board_sys_clk(unsigned long dummy); #define CPLD_BASE_PHYS CPLD_BASE #endif -#define CONFIG_SYS_BR3_PRELIM (BR_PHYS_ADDR(CPLD_BASE_PHYS) | BR_PS_8 | BR_V) -#define CONFIG_SYS_OR3_PRELIM 0xffffeff7 /* 32KB but only 4k mapped */ - #define PIXIS_LBMAP_SWITCH 7 #define PIXIS_LBMAP_MASK 0xf0 #define PIXIS_LBMAP_SHIFT 4 @@ -185,21 +179,6 @@ unsigned long get_board_sys_clk(unsigned long dummy); | OR_FCM_SCY_1 \ | OR_FCM_TRLX \ | OR_FCM_EHTR) - -#ifdef CONFIG_MTD_RAW_NAND -#define CONFIG_SYS_BR0_PRELIM CONFIG_SYS_NAND_BR_PRELIM /* NAND Base Address */ -#define CONFIG_SYS_OR0_PRELIM CONFIG_SYS_NAND_OR_PRELIM /* NAND Options */ -#define CONFIG_SYS_BR1_PRELIM CONFIG_SYS_FLASH_BR_PRELIM /* NOR Base Address */ -#define CONFIG_SYS_OR1_PRELIM CONFIG_SYS_FLASH_OR_PRELIM /* NOR Options */ -#else -#define CONFIG_SYS_BR0_PRELIM CONFIG_SYS_FLASH_BR_PRELIM /* NOR Base Address */ -#define CONFIG_SYS_OR0_PRELIM CONFIG_SYS_FLASH_OR_PRELIM /* NOR Options */ -#define CONFIG_SYS_BR1_PRELIM CONFIG_SYS_NAND_BR_PRELIM /* NAND Base Address */ -#define CONFIG_SYS_OR1_PRELIM CONFIG_SYS_NAND_OR_PRELIM /* NAND Options */ -#endif -#else -#define CONFIG_SYS_BR0_PRELIM CONFIG_SYS_FLASH_BR_PRELIM /* NOR Base Address */ -#define CONFIG_SYS_OR0_PRELIM CONFIG_SYS_FLASH_OR_PRELIM /* NOR Options */ #endif /* CONFIG_NAND_FSL_ELBC */ #define CONFIG_SYS_FLASH_EMPTY_INFO @@ -413,7 +392,6 @@ unsigned long get_board_sys_clk(unsigned long dummy); #define CONFIG_HAS_FSL_MPH_USB #if defined(CONFIG_HAS_FSL_DR_USB) || defined(CONFIG_HAS_FSL_MPH_USB) -#define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #endif @@ -464,32 +442,6 @@ unsigned long get_board_sys_clk(unsigned long dummy); "fdtfile=p2041rdb/p2041rdb.dtb\0" \ "bdev=sda3\0" -#define HDBOOT \ - "setenv bootargs root=/dev/$bdev rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND HDBOOT - #include <asm/fsl_secure_boot.h> #endif /* __CONFIG_H */ diff --git a/include/configs/SBx81LIFKW.h b/include/configs/SBx81LIFKW.h index bf9f26ea999..dbaffc635d2 100644 --- a/include/configs/SBx81LIFKW.h +++ b/include/configs/SBx81LIFKW.h @@ -6,25 +6,16 @@ #ifndef _CONFIG_SBX81LIFKW_H #define _CONFIG_SBX81LIFKW_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 1 /* CPU Core subversion */ -#define CONFIG_KW88F6281 1 /* SOC Name */ -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage.cfg - /* additions for new ARM relocation support */ #define CONFIG_SYS_SDRAM_BASE 0x00000000 #define CONFIG_KIRKWOOD_EGIGA_INIT /* Enable GbePort0/1 for kernel */ #define CONFIG_KIRKWOOD_PCIE_INIT /* Enable PCIE Port0 */ #define CONFIG_KIRKWOOD_RGMII_PAD_1V8 /* Set RGMII Pad voltage to 1.8V */ -#define CONFIG_KIRKWOOD_GPIO 1 /* * NS16550 Configuration */ -#define CONFIG_SYS_NS16550 #define CONFIG_SYS_NS16550_SERIAL #define CONFIG_SYS_NS16550_REG_SIZE (-4) #define CONFIG_SYS_NS16550_CLK CONFIG_SYS_TCLK @@ -61,7 +52,6 @@ * Ethernet Driver configuration */ #ifdef CONFIG_CMD_NET -#define CONFIG_MVGBE /* Enable kirkwood Gbe Controller Driver */ #define CONFIG_MVGBE_PORTS {1, 0} /* enable a single port */ #define CONFIG_PHY_BASE_ADR 0x01 #endif /* CONFIG_CMD_NET */ diff --git a/include/configs/SBx81LIFXCAT.h b/include/configs/SBx81LIFXCAT.h index 71394aea22c..bbd3ccc6d9d 100644 --- a/include/configs/SBx81LIFXCAT.h +++ b/include/configs/SBx81LIFXCAT.h @@ -6,25 +6,16 @@ #ifndef _CONFIG_SBX81LIFXCAT_H #define _CONFIG_SBX81LIFXCAT_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 1 /* CPU Core subversion */ -#define CONFIG_KW88F6281 1 /* SOC Name */ -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage.cfg - /* additions for new ARM relocation support */ #define CONFIG_SYS_SDRAM_BASE 0x00000000 #define CONFIG_KIRKWOOD_EGIGA_INIT /* Enable GbePort0/1 for kernel */ #define CONFIG_KIRKWOOD_PCIE_INIT /* Enable PCIE Port0 */ #define CONFIG_KIRKWOOD_RGMII_PAD_1V8 /* Set RGMII Pad voltage to 1.8V */ -#define CONFIG_KIRKWOOD_GPIO 1 /* * NS16550 Configuration */ -#define CONFIG_SYS_NS16550 #define CONFIG_SYS_NS16550_SERIAL #define CONFIG_SYS_NS16550_REG_SIZE (-4) #define CONFIG_SYS_NS16550_CLK CONFIG_SYS_TCLK @@ -66,7 +57,6 @@ * Ethernet Driver configuration */ #ifdef CONFIG_CMD_NET -#define CONFIG_MVGBE /* Enable kirkwood Gbe Controller Driver */ #define CONFIG_MVGBE_PORTS {1, 0} /* enable a single port */ #define CONFIG_PHY_BASE_ADR 0x01 #endif /* CONFIG_CMD_NET */ diff --git a/include/configs/T102xRDB.h b/include/configs/T102xRDB.h index 89bbeb77844..bf266623c90 100644 --- a/include/configs/T102xRDB.h +++ b/include/configs/T102xRDB.h @@ -41,7 +41,6 @@ #define CONFIG_SYS_NAND_U_BOOT_SIZE (768 << 10) #define CONFIG_SYS_NAND_U_BOOT_DST 0x30000000 #define CONFIG_SYS_NAND_U_BOOT_START 0x30000000 -#define CONFIG_SYS_NAND_U_BOOT_OFFS (256 << 10) #endif #ifdef CONFIG_SPIFLASH @@ -116,12 +115,6 @@ #define CONFIG_RESET_VECTOR_ADDRESS 0xfffffffc #endif -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - -#define CONFIG_SYS_CLK_FREQ 100000000 - /* * These can be toggled for performance analysis, otherwise use default. */ @@ -380,7 +373,6 @@ unsigned long get_board_sys_clk(void); #undef CONFIG_FSL_DIU_FB /* RDB doesn't support DIU */ #ifdef CONFIG_FSL_DIU_FB #define CONFIG_SYS_DIU_ADDR (CONFIG_SYS_CCSRBAR + 0x180000) -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS /* @@ -416,7 +408,6 @@ unsigned long get_board_sys_clk(void); #define CONFIG_PCIE1 /* PCIE controller 1 */ #define CONFIG_PCIE2 /* PCIE controller 2 */ #define CONFIG_PCIE3 /* PCIE controller 3 */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ #ifdef CONFIG_PCI /* controller 1, direct to uli, tgtid 3, Base address 20000 */ @@ -452,7 +443,6 @@ unsigned long get_board_sys_clk(void); #define CONFIG_HAS_FSL_DR_USB #ifdef CONFIG_HAS_FSL_DR_USB -#define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #endif @@ -580,25 +570,6 @@ unsigned long get_board_sys_clk(void); "fdtaddr=1e00000\0" \ "bdev=sda3\0" -#define LINUXBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "setenv ramdiskaddr 0x02000000;" \ - "setenv fdtaddr 0x00c00000;" \ - "setenv loadaddr 0x1000000;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define CONFIG_BOOTCOMMAND LINUXBOOTCOMMAND - #include <asm/fsl_secure_boot.h> #endif /* __T1024RDB_H */ diff --git a/include/configs/T104xRDB.h b/include/configs/T104xRDB.h index 48fc8a271c2..a1650f54306 100644 --- a/include/configs/T104xRDB.h +++ b/include/configs/T104xRDB.h @@ -40,7 +40,6 @@ #endif #define CONFIG_SYS_NAND_U_BOOT_DST 0x30000000 #define CONFIG_SYS_NAND_U_BOOT_START 0x30000000 -#define CONFIG_SYS_NAND_U_BOOT_OFFS (256 << 10) #endif #ifdef CONFIG_SPIFLASH @@ -85,8 +84,6 @@ #define CONFIG_PCIE3 /* PCIE controller 3 */ #define CONFIG_PCIE4 /* PCIE controller 4 */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ - #if defined(CONFIG_SPIFLASH) #elif defined(CONFIG_MTD_RAW_NAND) #ifdef CONFIG_NXP_ESBC @@ -95,8 +92,6 @@ #endif #endif -#define CONFIG_SYS_CLK_FREQ 100000000 - /* * These can be toggled for performance analysis, otherwise use default. */ @@ -367,7 +362,6 @@ #ifdef CONFIG_FSL_DIU_FB #define CONFIG_FSL_DIU_CH7301 #define CONFIG_SYS_DIU_ADDR (CONFIG_SYS_CCSRBAR + 0x180000) -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #endif #endif @@ -460,7 +454,6 @@ #ifdef CONFIG_HAS_FSL_DR_USB #ifdef CONFIG_USB_EHCI_HCD -#define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #endif #endif @@ -499,8 +492,6 @@ #define CONFIG_SYS_DPAA_FMAN #define CONFIG_SYS_DPAA_PME -#define CONFIG_U_QE - #define CONFIG_SYS_FDT_PAD (0x3000 + CONFIG_SYS_QE_FMAN_FW_LENGTH) #endif /* CONFIG_NOBQFMAN */ @@ -609,40 +600,6 @@ "fdtfile=" __stringify(FDTFILE) "\0" \ "bdev=sda3\0" -#define LINUXBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "setenv ramdiskaddr 0x02000000;" \ - "setenv fdtaddr 0x00c00000;" \ - "setenv loadaddr 0x1000000;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define HDBOOT \ - "setenv bootargs root=/dev/$bdev rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND LINUXBOOTCOMMAND - #include <asm/fsl_secure_boot.h> #endif /* __CONFIG_H */ diff --git a/include/configs/T208xQDS.h b/include/configs/T208xQDS.h index 78562bc08fb..aaea314e458 100644 --- a/include/configs/T208xQDS.h +++ b/include/configs/T208xQDS.h @@ -44,7 +44,6 @@ #define CONFIG_SYS_NAND_U_BOOT_SIZE (768 << 10) #define CONFIG_SYS_NAND_U_BOOT_DST 0x00200000 #define CONFIG_SYS_NAND_U_BOOT_START 0x00200000 -#define CONFIG_SYS_NAND_U_BOOT_OFFS (256 << 10) #endif #ifdef CONFIG_SPIFLASH @@ -94,12 +93,6 @@ #define CONFIG_MEM_INIT_VALUE 0xdeadbeef #endif -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() - /* * Config the L3 Cache as L3 SRAM */ @@ -360,12 +353,6 @@ unsigned long get_board_sys_clk(void); #define I2C_VOL_MONITOR_BUS_V_OVF 0x1 #define I2C_VOL_MONITOR_BUS_V_SHIFT 3 -#define CONFIG_VID_FLS_ENV "t208xqds_vdd_mv" -#ifndef CONFIG_SPL_BUILD -#define CONFIG_VID -#endif -#define CONFIG_VOL_MONITOR_IR36021_SET -#define CONFIG_VOL_MONITOR_IR36021_READ /* The lowest and highest voltage allowed for T208xQDS */ #define VDD_MV_MIN 819 #define VDD_MV_MAX 1212 @@ -420,7 +407,6 @@ unsigned long get_board_sys_clk(void); #define CONFIG_PCIE2 /* PCIE controller 2 */ #define CONFIG_PCIE3 /* PCIE controller 3 */ #define CONFIG_PCIE4 /* PCIE controller 4 */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ /* controller 1, direct to uli, tgtid 3, Base address 20000 */ #define CONFIG_SYS_PCIE1_MEM_VIRT 0x80000000 #define CONFIG_SYS_PCIE1_MEM_PHYS 0xc00000000ull @@ -517,7 +503,6 @@ unsigned long get_board_sys_clk(void); * USB */ #ifdef CONFIG_USB_EHCI_HCD -#define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #define CONFIG_HAS_FSL_DR_USB #endif @@ -614,40 +599,6 @@ unsigned long get_board_sys_clk(void); "cpu 7 release 0x01000000 - - -;" \ "go 0x01000000" -#define LINUXBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "setenv ramdiskaddr 0x02000000;" \ - "setenv fdtaddr 0x00c00000;" \ - "setenv loadaddr 0x1000000;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define HDBOOT \ - "setenv bootargs root=/dev/$bdev rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND LINUXBOOTCOMMAND - #include <asm/fsl_secure_boot.h> #endif /* __T208xQDS_H */ diff --git a/include/configs/T208xRDB.h b/include/configs/T208xRDB.h index 471ed94b804..467f6344faf 100644 --- a/include/configs/T208xRDB.h +++ b/include/configs/T208xRDB.h @@ -39,7 +39,6 @@ #define CONFIG_SYS_NAND_U_BOOT_SIZE (768 << 10) #define CONFIG_SYS_NAND_U_BOOT_DST 0x00200000 #define CONFIG_SYS_NAND_U_BOOT_START 0x00200000 -#define CONFIG_SYS_NAND_U_BOOT_OFFS (256 << 10) #endif #ifdef CONFIG_SPIFLASH @@ -89,12 +88,6 @@ #define CONFIG_MEM_INIT_VALUE 0xdeadbeef #endif -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - -#define CONFIG_SYS_CLK_FREQ 66660000 - /* * Config the L3 Cache as L3 SRAM */ @@ -312,12 +305,6 @@ unsigned long get_board_sys_clk(void); #define I2C_MUX_CH_VOL_MONITOR 0xa -#define CONFIG_VID_FLS_ENV "t208xrdb_vdd_mv" -#ifndef CONFIG_SPL_BUILD -#define CONFIG_VID -#endif -#define CONFIG_VOL_MONITOR_IR36021_SET -#define CONFIG_VOL_MONITOR_IR36021_READ /* The lowest and highest voltage allowed for T208xRDB */ #define VDD_MV_MIN 819 #define VDD_MV_MAX 1212 @@ -372,7 +359,6 @@ unsigned long get_board_sys_clk(void); #define CONFIG_PCIE2 /* PCIE controller 2 */ #define CONFIG_PCIE3 /* PCIE controller 3 */ #define CONFIG_PCIE4 /* PCIE controller 4 */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ /* controller 1, direct to uli, tgtid 3, Base address 20000 */ #define CONFIG_SYS_PCIE1_MEM_VIRT 0x80000000 #define CONFIG_SYS_PCIE1_MEM_PHYS 0xc00000000ull @@ -472,7 +458,6 @@ unsigned long get_board_sys_clk(void); * USB */ #ifdef CONFIG_USB_EHCI_HCD -#define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #define CONFIG_HAS_FSL_DR_USB #endif @@ -567,40 +552,6 @@ unsigned long get_board_sys_clk(void); "cpu 7 release 0x01000000 - - -;" \ "go 0x01000000" -#define LINUXBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "setenv ramdiskaddr 0x02000000;" \ - "setenv fdtaddr 0x00c00000;" \ - "setenv loadaddr 0x1000000;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define HDBOOT \ - "setenv bootargs root=/dev/$bdev rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND LINUXBOOTCOMMAND - #include <asm/fsl_secure_boot.h> #endif /* __T2080RDB_H */ diff --git a/include/configs/T4240RDB.h b/include/configs/T4240RDB.h index f6ccaf49521..2d632493c19 100644 --- a/include/configs/T4240RDB.h +++ b/include/configs/T4240RDB.h @@ -60,7 +60,6 @@ #define CONFIG_PCIE1 /* PCIE controller 1 */ #define CONFIG_PCIE2 /* PCIE controller 2 */ #define CONFIG_PCIE3 /* PCIE controller 3 */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ /* * These can be toggled for performance analysis, otherwise use default. @@ -225,12 +224,6 @@ "setenv bootargs config-addr=0x60000000; " \ "bootm 0x01000000 - 0x00f00000" -#define CONFIG_SYS_CLK_FREQ 66666666 - -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - /* * DDR Setup */ @@ -408,12 +401,6 @@ unsigned long get_board_sys_clk(void); #define I2C_VOL_MONITOR_BUS_V_OVF 0x1 #define I2C_VOL_MONITOR_BUS_V_SHIFT 3 -#define CONFIG_VID_FLS_ENV "t4240rdb_vdd_mv" -#ifndef CONFIG_SPL_BUILD -#define CONFIG_VID -#endif -#define CONFIG_VOL_MONITOR_IR36021_SET -#define CONFIG_VOL_MONITOR_IR36021_READ /* The lowest and highest voltage allowed for T4240RDB */ #define VDD_MV_MIN 819 #define VDD_MV_MAX 1212 @@ -498,7 +485,6 @@ unsigned long get_board_sys_clk(void); /* * USB */ -#define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #define CONFIG_HAS_FSL_DR_USB @@ -547,40 +533,6 @@ unsigned long get_board_sys_clk(void); "setenv bootargs config-addr=0x60000000; " \ "bootm 0x01000000 - 0x00f00000" -#define LINUXBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "setenv ramdiskaddr 0x02000000;" \ - "setenv fdtaddr 0x00c00000;" \ - "setenv loadaddr 0x1000000;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define HDBOOT \ - "setenv bootargs root=/dev/$bdev rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND LINUXBOOTCOMMAND - #include <asm/fsl_secure_boot.h> #endif /* __CONFIG_H */ diff --git a/include/configs/adp-ae3xx.h b/include/configs/adp-ae3xx.h index 973033d6b4d..58e85260489 100644 --- a/include/configs/adp-ae3xx.h +++ b/include/configs/adp-ae3xx.h @@ -17,8 +17,6 @@ #define CONFIG_SKIP_TRUNOFF_WATCHDOG -#define CONFIG_ARCH_MAP_SYSMEM - #define CONFIG_BOOTP_SERVERIP #ifdef CONFIG_SKIP_LOWLEVEL_INIT @@ -30,8 +28,7 @@ /* * Timer */ -#define CONFIG_SYS_CLK_FREQ 39062500 -#define VERSION_CLOCK CONFIG_SYS_CLK_FREQ +#define VERSION_CLOCK get_board_sys_clk() /* * Use Externel CLOCK or PCLK diff --git a/include/configs/adp-ag101p.h b/include/configs/adp-ag101p.h index f533ada73f4..1022764985a 100644 --- a/include/configs/adp-ag101p.h +++ b/include/configs/adp-ag101p.h @@ -15,8 +15,6 @@ */ #define CONFIG_USE_INTERRUPT -#define CONFIG_ARCH_MAP_SYSMEM - #define CONFIG_BOOTP_SERVERIP #ifndef CONFIG_SKIP_LOWLEVEL_INIT @@ -32,8 +30,7 @@ /* * Timer */ -#define CONFIG_SYS_CLK_FREQ 39062500 -#define VERSION_CLOCK CONFIG_SYS_CLK_FREQ +#define VERSION_CLOCK get_board_sys_clk() /* * Use Externel CLOCK or PCLK diff --git a/include/configs/alt.h b/include/configs/alt.h index 8456a6b2c33..37b5800d6ef 100644 --- a/include/configs/alt.h +++ b/include/configs/alt.h @@ -34,8 +34,6 @@ #define CONFIG_BITBANGMII_MULTI /* Board Clock */ -#define RMOBILE_XTAL_CLK 20000000u -#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK #define CONFIG_EXTRA_ENV_SETTINGS \ "bootm_size=0x10000000\0" \ diff --git a/include/configs/am335x_evm.h b/include/configs/am335x_evm.h index 7fb1b3a3e3f..0f340806efc 100644 --- a/include/configs/am335x_evm.h +++ b/include/configs/am335x_evm.h @@ -143,7 +143,10 @@ "if test $board_name = A335X_SK; then " \ "setenv fdtfile am335x-evmsk.dtb; fi; " \ "if test $board_name = A335_ICE; then " \ - "setenv fdtfile am335x-icev2.dtb; fi; " \ + "setenv fdtfile am335x-icev2.dtb; " \ + "if test $ice_mii = mii; then " \ + "setenv pxe_label_override Pruss; fi;" \ + "fi; " \ "if test $fdtfile = undefined; then " \ "echo WARNING: Could not determine device tree to use; fi; \0" \ "init_console=" \ diff --git a/include/configs/am335x_igep003x.h b/include/configs/am335x_igep003x.h index 339a975c74c..2cf77a67c0c 100644 --- a/include/configs/am335x_igep003x.h +++ b/include/configs/am335x_igep003x.h @@ -91,12 +91,6 @@ "echo WARNING: Could not determine device tree to use; fi; \0" #endif -#define CONFIG_BOOTCOMMAND \ - "run findfdt;" \ - "run mmcboot;" \ - "run nandboot;" \ - "run netboot;" - /* NS16550 Configuration */ #define CONFIG_SYS_NS16550_COM1 0x44e09000 /* UART0 */ diff --git a/include/configs/am335x_shc.h b/include/configs/am335x_shc.h index 584b0250c4c..c7a7a18dc85 100644 --- a/include/configs/am335x_shc.h +++ b/include/configs/am335x_shc.h @@ -139,64 +139,15 @@ #if defined CONFIG_SHC_NETBOOT /* Network Boot */ -# define CONFIG_BOOTCOMMAND \ - "run fusecmd; " \ - "if run netboot; then " \ - "echo Booting from network; " \ - "else " \ - "echo ERROR: Cannot boot from network!; " \ - "panic; " \ - "fi; " #elif defined CONFIG_SHC_SDBOOT /* !defined CONFIG_SHC_NETBOOT */ /* SD-Card Boot */ -# define CONFIG_BOOTCOMMAND \ - "if mmc dev 0; mmc rescan; then " \ - "run sd_setup; " \ - "else " \ - "echo ERROR: SD/MMC-Card not detected!; " \ - "panic; " \ - "fi; " \ - "if run loaduimage; then " \ - "echo Bootable SD/MMC-Card inserted, booting from it!; " \ - "run mmcboot; " \ - "else " \ - "echo ERROR: Unable to load uImage from SD/MMC-Card!; " \ - "panic; " \ - "fi; " #elif defined CONFIG_SHC_ICT /* ICT adapter boots only u-boot and does HW partitioning */ -# define CONFIG_BOOTCOMMAND \ - "if mmc dev 0; mmc rescan; then " \ - "run sd_setup; " \ - "else " \ - "echo ERROR: SD/MMC-Card not detected!; " \ - "panic; " \ - "fi; " \ - "run fusecmd; " #else /* !defined CONFIG_SHC_NETBOOT, !defined CONFIG_SHC_SDBOOT */ /* Regular Boot from internal eMMC */ -# define CONFIG_BOOTCOMMAND \ - "if mmc dev 1; mmc rescan; then " \ - "run emmc_setup; " \ - "else " \ - "echo ERROR: eMMC device not detected!; " \ - "panic; " \ - "fi; " \ - "if run loaduimage; then " \ - "run mmcboot; " \ - "else " \ - "echo ERROR Unable to load uImage from eMMC!; " \ - "echo Performing Rollback!; " \ - "setenv _active_ ${active_root}; " \ - "setenv _inactive_ ${inactive_root}; " \ - "setenv active_root ${_inactive_}; " \ - "setenv inactive_root ${_active_}; " \ - "saveenv; " \ - "reset; " \ - "fi; " #endif /* Regular Boot */ diff --git a/include/configs/am3517_evm.h b/include/configs/am3517_evm.h index bf01a777cce..f5f2b63b74e 100644 --- a/include/configs/am3517_evm.h +++ b/include/configs/am3517_evm.h @@ -90,25 +90,6 @@ "nand read ${fdtaddr} aa0000 80000; " \ "bootm ${loadaddr} - ${fdtaddr}\0" \ -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "echo SD/MMC found on device $mmcdev; " \ - "if run loadbootenv; then " \ - "run importbootenv; " \ - "fi; " \ - "echo Checking if uenvcmd is set ...; " \ - "if test -n $uenvcmd; then " \ - "echo Running uenvcmd ...; " \ - "run uenvcmd; " \ - "fi; " \ - "echo Running default loadimage ...; " \ - "setenv bootfile zImage; " \ - "if run loadimage; then " \ - "run loadfdt; " \ - "run mmcboot; " \ - "fi; " \ - "else run nandboot; fi" - /* Miscellaneous configurable options */ /* We set the max number of command args high to avoid HUSH bugs. */ diff --git a/include/configs/amcore.h b/include/configs/amcore.h index fd05ea69e3b..d813af17f74 100644 --- a/include/configs/amcore.h +++ b/include/configs/amcore.h @@ -13,7 +13,6 @@ #define CONFIG_MCFTMR #define CONFIG_SYS_UART_PORT 0 -#define CONFIG_BOOTCOMMAND "bootm ffc20000" #define CONFIG_EXTRA_ENV_SETTINGS \ "upgrade_uboot=loady; " \ "protect off 0xffc00000 0xffc1ffff; " \ diff --git a/include/configs/ap121.h b/include/configs/ap121.h index e23a7dc4956..70cd2eeaf97 100644 --- a/include/configs/ap121.h +++ b/include/configs/ap121.h @@ -20,10 +20,6 @@ #define CONFIG_SYS_INIT_SP_ADDR \ (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_RAM_SIZE - 1) -#define CONFIG_BOOTCOMMAND "sf probe;" \ - "mtdparts default;" \ - "bootm 0x9f650000" - /* Miscellaneous configurable options */ /* diff --git a/include/configs/ap143.h b/include/configs/ap143.h index 80b64da93ff..167cc47142c 100644 --- a/include/configs/ap143.h +++ b/include/configs/ap143.h @@ -25,10 +25,6 @@ */ #define CONFIG_SYS_NS16550_CLK 25000000 -#define CONFIG_BOOTCOMMAND "sf probe;" \ - "mtdparts default;" \ - "bootm 0x9f680000" - /* Miscellaneous configurable options */ /* diff --git a/include/configs/ap152.h b/include/configs/ap152.h index 762cc67aa6c..5bfca42156b 100644 --- a/include/configs/ap152.h +++ b/include/configs/ap152.h @@ -25,12 +25,6 @@ */ #define CONFIG_SYS_NS16550_CLK 25000000 -#define CONFIG_BOOTCOMMAND "sf probe;" \ - "mtdparts default;" \ - "bootm 0x9f060000" - -#define CONFIG_ENV_SPI_MAX_HZ 25000000 - /* Miscellaneous configurable options */ /* diff --git a/include/configs/apalis-imx8.h b/include/configs/apalis-imx8.h index 27007c57b3c..c2b0d6ff3e6 100644 --- a/include/configs/apalis-imx8.h +++ b/include/configs/apalis-imx8.h @@ -50,7 +50,7 @@ "mmcargs=setenv bootargs console=${console},${baudrate} " \ "root=PARTUUID=${uuid} rootwait " \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "netargs=setenv bootargs console=${console},${baudrate} " \ "root=/dev/nfs ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp" \ "\0" \ @@ -68,8 +68,6 @@ #define CONFIG_SYS_INIT_SP_ADDR 0x80200000 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - /* On Apalis iMX8 USDHC1 is eMMC, USDHC2 is 8-bit and USDHC3 is 4-bit MMC/SD */ #define CONFIG_SYS_FSL_USDHC_NUM 3 diff --git a/include/configs/apalis-imx8x.h b/include/configs/apalis-imx8x.h index 50dae2d8e05..402fed1bba3 100644 --- a/include/configs/apalis-imx8x.h +++ b/include/configs/apalis-imx8x.h @@ -77,7 +77,7 @@ "mmcargs=setenv bootargs ${consoleargs} " \ "root=PARTUUID=${uuid} rootwait " \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "netargs=setenv bootargs ${consoleargs} " \ "root=/dev/nfs ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp " \ "${vidargs}\0" \ @@ -99,8 +99,6 @@ /* Environment in eMMC, before config block at the end of 1st "boot sector" */ -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - /* On Apalis iMX8X USDHC1 is eMMC, USDHC2 is 4-bit SD */ #define CONFIG_SYS_FSL_USDHC_NUM 2 diff --git a/include/configs/apalis_imx6.h b/include/configs/apalis_imx6.h index dfed1615b9b..c165f618be9 100644 --- a/include/configs/apalis_imx6.h +++ b/include/configs/apalis_imx6.h @@ -45,8 +45,6 @@ #define CONFIG_USBD_HS /* Framebuffer and LCD */ -#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP diff --git a/include/configs/apple.h b/include/configs/apple.h index b1f60431746..3e5fb495f1a 100644 --- a/include/configs/apple.h +++ b/include/configs/apple.h @@ -3,10 +3,6 @@ #include <linux/sizes.h> -#define CONFIG_SYS_SDRAM_BASE 0x880000000 - -#define CONFIG_LNX_KRNL_IMG_TEXT_OFFSET_BASE CONFIG_SYS_TEXT_BASE - /* Environment */ #define ENV_DEVICE_SETTINGS \ "stdin=serial,usbkbd\0" \ diff --git a/include/configs/aristainetos2.h b/include/configs/aristainetos2.h index b73b0d5b92b..e6397378e45 100644 --- a/include/configs/aristainetos2.h +++ b/include/configs/aristainetos2.h @@ -443,7 +443,6 @@ /* Framebuffer */ /* check this console not needed, after test remove it */ #define CONFIG_IMX_VIDEO_SKIP -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_IMX6_PWM_PER_CLK 66000000 diff --git a/include/configs/armadillo-800eva.h b/include/configs/armadillo-800eva.h index 73f63c5a9f0..7714da40dc7 100644 --- a/include/configs/armadillo-800eva.h +++ b/include/configs/armadillo-800eva.h @@ -17,7 +17,7 @@ #define CONFIG_TMU_TIMER #define CONFIG_SYS_TIMER_COUNTS_DOWN #define CONFIG_SYS_TIMER_COUNTER (TMU_BASE + 0xc) /* TCNT0 */ -#define CONFIG_SYS_TIMER_RATE (CONFIG_SYS_CLK_FREQ / 4) +#define CONFIG_SYS_TIMER_RATE (get_board_sys_clk() / 4) /* STACK */ #define CONFIG_SYS_INIT_SP_ADDR 0xE8083000 @@ -72,7 +72,6 @@ #define CONFIG_BITBANGMII_MULTI /* Board Clock */ -#define CONFIG_SYS_CLK_FREQ 50000000 -#define CONFIG_SH_SCIF_CLK_FREQ CONFIG_SYS_CLK_FREQ +#define CONFIG_SH_SCIF_CLK_FREQ get_board_sys_clk() #endif /* __ARMADILLO_800EVA_H */ diff --git a/include/configs/aspeed-common.h b/include/configs/aspeed-common.h index 5177bf20fad..96526e1a75c 100644 --- a/include/configs/aspeed-common.h +++ b/include/configs/aspeed-common.h @@ -38,13 +38,4 @@ */ #define CONFIG_BOOTP_BOOTFILESIZE -/* - * Miscellaneous configurable options - */ - -#define CONFIG_EXTRA_ENV_SETTINGS \ - "verify=yes\0" \ - "spi_dma=yes\0" \ - "" - #endif /* __AST_COMMON_CONFIG_H */ diff --git a/include/configs/astro_mcf5373l.h b/include/configs/astro_mcf5373l.h index 36e351f3583..d87ca304e26 100644 --- a/include/configs/astro_mcf5373l.h +++ b/include/configs/astro_mcf5373l.h @@ -58,7 +58,6 @@ #define CONFIG_MCFTMR /* I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR /* * Defines processor clock - important for correct timings concerning serial @@ -91,7 +90,6 @@ */ #ifndef CONFIG_MONITOR_IS_IN_RAM -#define CONFIG_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 3355 /* timeout in milliseconds */ #endif @@ -140,18 +138,6 @@ * by external update.c; This is not included in mainline because * it needs non-blocking CFI routines. */ -#ifdef CONFIG_MONITOR_IS_IN_RAM -#define CONFIG_BOOTCOMMAND "" /* no autoboot in this case */ -#else -#if ASTRO_V532 -#define CONFIG_BOOTCOMMAND "protect off 0x80000 0x1ffffff;run env_check;"\ - "run xilinxload&&run alteraload&&bootm 0x80000;"\ - "update;reset" -#else -#define CONFIG_BOOTCOMMAND "protect off 0x80000 0x1ffffff;run env_check;"\ - "run xilinxload&&bootm 0x80000;update;reset" -#endif -#endif #define CONFIG_FPGA_COUNT 1 #define CONFIG_SYS_FPGA_PROG_FEEDBACK diff --git a/include/configs/at91-sama5_common.h b/include/configs/at91-sama5_common.h index 9a73e3afca5..b93c67be52a 100644 --- a/include/configs/at91-sama5_common.h +++ b/include/configs/at91-sama5_common.h @@ -21,31 +21,12 @@ #define CONFIG_BOOTP_BOOTFILESIZE #ifdef CONFIG_SD_BOOT -#define CONFIG_BOOTCOMMAND "if test ! -n ${dtb_name}; then " \ - "setenv dtb_name at91-${board_name}.dtb; " \ - "fi; " \ - "fatload mmc 0:1 0x21000000 ${dtb_name}; " \ - "fatload mmc 0:1 0x22000000 zImage; " \ - "bootz 0x22000000 - 0x21000000" - #else #ifdef CONFIG_NAND_BOOT /* u-boot env in nand flash */ -#define CONFIG_BOOTCOMMAND "nand read 0x21000000 0x180000 0x80000;" \ - "nand read 0x22000000 0x200000 0x600000;" \ - "bootz 0x22000000 - 0x21000000" #elif CONFIG_SPI_BOOT /* u-boot env in serial flash, by default is bus 0 and cs 0 */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x21000000 0x60000 0xc000; " \ - "sf read 0x22000000 0x6c000 0x394000; " \ - "bootz 0x22000000 - 0x21000000" -#elif CONFIG_QSPI_BOOT -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x21000000 0x180000 0x80000; " \ - "sf read 0x22000000 0x200000 0x600000; " \ - "bootz 0x22000000 - 0x21000000" #endif #endif diff --git a/include/configs/at91sam9260ek.h b/include/configs/at91sam9260ek.h index d09a5dbf10f..c9344e862ae 100644 --- a/include/configs/at91sam9260ek.h +++ b/include/configs/at91sam9260ek.h @@ -87,27 +87,13 @@ #ifdef CONFIG_SYS_USE_DATAFLASH_CS0 /* bootstrap + u-boot + env + linux in dataflash on CS0 */ -#define CONFIG_BOOTCOMMAND "sf probe 0:0; " \ - "sf read 0x22000000 0x84000 0x294000; " \ - "bootm 0x22000000" - -#elif CONFIG_SYS_USE_DATAFLASH_CS1 - -#define CONFIG_BOOTCOMMAND "sf probe 0:1; " \ - "sf read 0x22000000 0x84000 0x294000; " \ - "bootm 0x22000000" - #elif defined(CONFIG_SYS_USE_NANDFLASH) /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND "nand read 0x22000000 0x200000 0x300000; bootm" #else /* CONFIG_SYS_USE_MMC */ /* bootstrap + u-boot + env + linux in mmc */ /* For FAT system, most cases it should be in the reserved sector */ - -#define CONFIG_BOOTCOMMAND \ - "fatload mmc 0:1 0x22000000 uImage; bootm" #endif #endif diff --git a/include/configs/at91sam9261ek.h b/include/configs/at91sam9261ek.h index fb4695c1abf..7fce98f0038 100644 --- a/include/configs/at91sam9261ek.h +++ b/include/configs/at91sam9261ek.h @@ -90,21 +90,14 @@ #ifdef CONFIG_SYS_USE_DATAFLASH_CS0 /* bootstrap + u-boot + env + linux in dataflash on CS0 */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x22000000 0x84000 0x294000; " \ - "bootm 0x22000000" #elif CONFIG_SYS_USE_DATAFLASH_CS3 /* bootstrap + u-boot + env + linux in dataflash on CS3 */ -#define CONFIG_BOOTCOMMAND "sf probe 0:3; " \ - "sf read 0x22000000 0x84000 0x294000; " \ - "bootm 0x22000000" #else /* CONFIG_SYS_USE_NANDFLASH */ /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND "nand read 0x22000000 0x200000 0x300000; bootm" #endif #endif diff --git a/include/configs/at91sam9263ek.h b/include/configs/at91sam9263ek.h index e7fca468aa5..5aa9fee2e12 100644 --- a/include/configs/at91sam9263ek.h +++ b/include/configs/at91sam9263ek.h @@ -207,14 +207,10 @@ #ifdef CONFIG_SYS_USE_DATAFLASH /* bootstrap + u-boot + env + linux in dataflash on CS0 */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x22000000 0x84000 0x294000; " \ - "bootm 0x22000000" #elif CONFIG_SYS_USE_NANDFLASH /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND "nand read 0x22000000 0x200000 0x300000; bootm" #endif #endif diff --git a/include/configs/at91sam9m10g45ek.h b/include/configs/at91sam9m10g45ek.h index 500c9ae3951..973e8894d67 100644 --- a/include/configs/at91sam9m10g45ek.h +++ b/include/configs/at91sam9m10g45ek.h @@ -64,16 +64,8 @@ #ifdef CONFIG_NAND_BOOT /* bootstrap + u-boot + env in nandflash */ - -#define CONFIG_BOOTCOMMAND \ - "nand read 0x70000000 0x200000 0x300000;" \ - "bootm 0x70000000" #elif CONFIG_SD_BOOT /* bootstrap + u-boot + env + linux in mmc */ - -#define CONFIG_BOOTCOMMAND "fatload mmc 0:1 0x71000000 dtb; " \ - "fatload mmc 0:1 0x72000000 zImage; " \ - "bootz 0x72000000 - 0x71000000" #endif /* Defines for SPL */ diff --git a/include/configs/at91sam9n12ek.h b/include/configs/at91sam9n12ek.h index 43f98520722..f102dbe5c93 100644 --- a/include/configs/at91sam9n12ek.h +++ b/include/configs/at91sam9n12ek.h @@ -71,28 +71,10 @@ #ifdef CONFIG_SPI_BOOT /* bootstrap + u-boot + env + linux in dataflash on CS0 */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_nand};" \ - "sf probe 0; sf read 0x22000000 0x100000 0x300000; " \ - "bootm 0x22000000" #elif defined(CONFIG_NAND_BOOT) /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_nand};" \ - "nand read 0x21000000 0x180000 0x080000;" \ - "nand read 0x22000000 0x200000 0x400000;" \ - "bootm 0x22000000 - 0x21000000" - -#else /* CONFIG_SD_BOOT */ - -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_mmc};" \ - "fatload mmc 0:1 0x21000000 dtb;" \ - "fatload mmc 0:1 0x22000000 uImage;" \ - "bootm 0x22000000 - 0x21000000" - #endif /* SPL */ diff --git a/include/configs/at91sam9rlek.h b/include/configs/at91sam9rlek.h index c703276bcbc..5bc47d6442f 100644 --- a/include/configs/at91sam9rlek.h +++ b/include/configs/at91sam9rlek.h @@ -59,22 +59,13 @@ #ifdef CONFIG_SYS_USE_DATAFLASH /* bootstrap + u-boot + env + linux in dataflash on CS0 */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x22000000 0x84000 0x294000; " \ - "bootm 0x22000000" #elif CONFIG_SYS_USE_NANDFLASH /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND "nand read 0x22000000 0x200000 0x600000; " \ - "nand read 0x21000000 0x180000 0x80000; " \ - "bootz 0x22000000 - 0x21000000" #else /* CONFIG_SYS_USE_MMC */ /* bootstrap + u-boot + env + linux in mmc */ -#define CONFIG_BOOTCOMMAND "fatload mmc 0:1 0x21000000 at91sam9rlek.dtb; " \ - "fatload mmc 0:1 0x22000000 zImage; " \ - "bootz 0x22000000 - 0x21000000" #endif #endif diff --git a/include/configs/at91sam9x5ek.h b/include/configs/at91sam9x5ek.h index f15711ba2b1..e6d5b9925d3 100644 --- a/include/configs/at91sam9x5ek.h +++ b/include/configs/at91sam9x5ek.h @@ -62,20 +62,10 @@ #ifdef CONFIG_NAND_BOOT /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND "nand read " \ - "0x22000000 0x200000 0x600000; " \ - "nand read 0x21000000 0x180000 0x20000; " \ - "bootz 0x22000000 - 0x21000000" #elif defined(CONFIG_SPI_BOOT) /* bootstrap + u-boot + env + linux in spi flash */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x22000000 0x100000 0x300000; " \ - "bootm 0x22000000" #elif defined(CONFIG_SYS_USE_DATAFLASH) /* bootstrap + u-boot + env + linux in data flash */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x22000000 0x84000 0x294000; " \ - "bootm 0x22000000" #endif /* SPL */ diff --git a/include/configs/ax25-ae350.h b/include/configs/ax25-ae350.h index bf3f34e428f..1c3f957d324 100644 --- a/include/configs/ax25-ae350.h +++ b/include/configs/ax25-ae350.h @@ -119,12 +119,23 @@ /* Increase max gunzip size */ #define CONFIG_SYS_BOOTM_LEN (64 << 20) +/* Support autoboot from RAM (kernel image is loaded via debug port) */ +#define KERNEL_IMAGE_ADDR "0x2000000 " +#define BOOTENV_DEV_NAME_RAM(devtypeu, devtypel, instance) \ + "ram " +#define BOOTENV_DEV_RAM(devtypeu, devtypel, instance) \ + "bootcmd_ram=" \ + "booti " \ + KERNEL_IMAGE_ADDR \ + "- $fdtcontroladdr\0" + /* When we use RAM as ENV */ /* Enable distro boot */ #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 0) \ - func(DHCP, dhcp, na) + func(DHCP, dhcp, na) \ + func(RAM, ram, na) #include <config_distro_bootcmd.h> #define CONFIG_EXTRA_ENV_SETTINGS \ diff --git a/include/configs/baltos.h b/include/configs/baltos.h index 32f2174641a..f4ab6640cdc 100644 --- a/include/configs/baltos.h +++ b/include/configs/baltos.h @@ -185,15 +185,6 @@ /*DFUARGS*/ #endif -#define CONFIG_BOOTCOMMAND \ - "run findfdt; " \ - "run usbboot;" \ - "run mmcboot;" \ - "setenv mmcdev 1; " \ - "setenv bootpart 1:2; " \ - "run mmcboot;" \ - "run nandboot;" - /* NS16550 Configuration */ #define CONFIG_SYS_NS16550_COM1 0x44e09000 /* Base EVM has UART0 */ #define CONFIG_SYS_NS16550_COM2 0x48022000 /* UART1 */ diff --git a/include/configs/bcm_ns3.h b/include/configs/bcm_ns3.h index a57edf5238d..81b4218c888 100644 --- a/include/configs/bcm_ns3.h +++ b/include/configs/bcm_ns3.h @@ -44,7 +44,6 @@ /* Access eMMC Boot_1 and Boot_2 partitions */ /* enable 64-bit PCI resources */ -#define CONFIG_SYS_PCI_64BIT 1 #define CONSOLE_ARGS "console_args=console=ttyS0,115200n8\0" #define MAX_CPUS "max_cpus=maxcpus=8\0" @@ -277,12 +276,6 @@ "setenv bl_flash_pending_rfs_imgs;" \ "fi; \0" -#define CONFIG_BOOTCOMMAND "run flash_pending_rfs_imgs;" \ - "run fastboot_nitro && "\ - "run bootcmd_mmc_fits || "\ - "run bootcmd_usb || "\ - "run bootcmd_pxe" - /* Flashing commands */ #define TFTP_QSPI_PARAM \ "fip_qspi_addr=0x0\0"\ diff --git a/include/configs/bcmstb.h b/include/configs/bcmstb.h index e7f380b5155..98c815961c0 100644 --- a/include/configs/bcmstb.h +++ b/include/configs/bcmstb.h @@ -90,7 +90,6 @@ extern phys_addr_t prior_stage_fdt_address; /* * CONFIG_SYS_LOAD_ADDR - 1 MiB. */ -#define CONFIG_SYS_FDT_SAVE_ADDRESS 0x1f00000 #define CONFIG_SYS_CBSIZE 512 #define CONFIG_SYS_MAXARGS 32 @@ -104,7 +103,6 @@ extern phys_addr_t prior_stage_fdt_address; */ #define V_NS16550_CLK 81000000 -#define CONFIG_SYS_NS16550 #define CONFIG_SYS_NS16550_SERIAL #define CONFIG_SYS_NS16550_REG_SIZE (-4) #define CONFIG_SYS_NS16550_CLK V_NS16550_CLK @@ -126,8 +124,6 @@ extern phys_addr_t prior_stage_fdt_address; /* * Flash configuration. */ -#define CONFIG_SPI_FLASH_STMICRO -#define CONFIG_SPI_FLASH_MACRONIX /* * Filesystem configuration. diff --git a/include/configs/beacon-rzg2m.h b/include/configs/beacon-rzg2m.h index 18d442e06a6..7eaafb0d451 100644 --- a/include/configs/beacon-rzg2m.h +++ b/include/configs/beacon-rzg2m.h @@ -23,7 +23,7 @@ "boot_fdt=try\0" \ "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \ "initrd_addr=0x43800000\0" \ - "mmcdev=0\0" \ + "mmcdev=1\0" \ "mmcpart=1\0" \ "mmcrootpart=2\0" \ "finduuid=part uuid mmc ${mmcdev}:${mmcrootpart} uuid\0" \ @@ -67,18 +67,4 @@ "booti; " \ "fi;\0" -#undef CONFIG_BOOTCOMMAND - -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else booti ${loadaddr} - ${fdt_addr}; fi" - #endif /* __BEACON_RZG2M_H */ diff --git a/include/configs/bk4r1.h b/include/configs/bk4r1.h index c377094f11c..e0508b015e8 100644 --- a/include/configs/bk4r1.h +++ b/include/configs/bk4r1.h @@ -32,10 +32,6 @@ "preboot=" BK4_NET_INIT \ "if ${ncenable}; then run if_netconsole start_netconsole; fi\0" -/* BK4r1 boot command sets GPIO103/PTC30 to force USB hub out of reset*/ -#define BK4_BOOTCOMMAND "run set_gpio122; run set_gpio96; sf probe; " \ - "run manage_userdata; " - /* Enable PREBOOT variable */ /* Set ARP_TIMEOUT to 500ms */ @@ -76,7 +72,6 @@ #define CONFIG_BOARD_SIZE_LIMIT 520192 /* boot command, including the target-defined one if any */ -#define CONFIG_BOOTCOMMAND BK4_BOOTCOMMAND "run bootcmd_nand" /* Extra env settings (including the target-defined ones if any) */ #define CONFIG_EXTRA_ENV_SETTINGS \ diff --git a/include/configs/blanche.h b/include/configs/blanche.h index f048f158ed2..882b94f55a7 100644 --- a/include/configs/blanche.h +++ b/include/configs/blanche.h @@ -45,8 +45,6 @@ #endif /* Board Clock */ -#define RMOBILE_XTAL_CLK 20000000u -#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK /* ENV setting */ diff --git a/include/configs/broadcom_bcm963158.h b/include/configs/broadcom_bcm963158.h index de45f74923a..5aa784d88ca 100644 --- a/include/configs/broadcom_bcm963158.h +++ b/include/configs/broadcom_bcm963158.h @@ -28,7 +28,6 @@ #ifdef CONFIG_MTD_RAW_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 -#define CONFIG_SYS_NAND_SELF_INIT #endif /* CONFIG_MTD_RAW_NAND */ /* diff --git a/include/configs/broadcom_bcm968360bg.h b/include/configs/broadcom_bcm968360bg.h index 0391f062181..01bab046ddb 100644 --- a/include/configs/broadcom_bcm968360bg.h +++ b/include/configs/broadcom_bcm968360bg.h @@ -27,7 +27,6 @@ #ifdef CONFIG_MTD_RAW_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 -#define CONFIG_SYS_NAND_SELF_INIT #endif /* CONFIG_MTD_RAW_NAND */ /* diff --git a/include/configs/broadcom_bcm968380gerg.h b/include/configs/broadcom_bcm968380gerg.h index 866de2527d0..c1c1b37fabd 100644 --- a/include/configs/broadcom_bcm968380gerg.h +++ b/include/configs/broadcom_bcm968380gerg.h @@ -8,5 +8,4 @@ #ifdef CONFIG_MTD_RAW_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 -#define CONFIG_SYS_NAND_SELF_INIT #endif /* CONFIG_MTD_RAW_NAND */ diff --git a/include/configs/broadcom_bcm968580xref.h b/include/configs/broadcom_bcm968580xref.h index 179aa9d608c..ebfc2ecc0be 100644 --- a/include/configs/broadcom_bcm968580xref.h +++ b/include/configs/broadcom_bcm968580xref.h @@ -27,7 +27,6 @@ #ifdef CONFIG_MTD_RAW_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 -#define CONFIG_SYS_NAND_SELF_INIT #endif /* CONFIG_MTD_RAW_NAND */ /* diff --git a/include/configs/brxre1.h b/include/configs/brxre1.h index d9179760b92..d34d69778f1 100644 --- a/include/configs/brxre1.h +++ b/include/configs/brxre1.h @@ -53,8 +53,6 @@ BUR_COMMON_ENV \ " do run b_${target}; if test ${b_break} = 1; then; exit; fi; done\0" #endif /* !CONFIG_SPL_BUILD*/ -#define CONFIG_BOOTCOMMAND "mmc dev 1; run b_default" - /* Environment */ #endif /* __CONFIG_BRXRE1_H__ */ diff --git a/include/configs/capricorn-common.h b/include/configs/capricorn-common.h index 58ab1b7deed..1cde5f77f22 100644 --- a/include/configs/capricorn-common.h +++ b/include/configs/capricorn-common.h @@ -11,15 +11,12 @@ #include <asm/arch/imx-regs.h> #include "siemens-env-common.h" -#include "siemens-ccp-common.h" /* SPL config */ #ifdef CONFIG_SPL_BUILD #define CONFIG_SPL_MAX_SIZE (124 * 1024) #define CONFIG_SYS_MONITOR_LEN (1024 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x800 #define CONFIG_SPL_STACK 0x013E000 #define CONFIG_SPL_BSS_START_ADDR 0x00128000 @@ -35,9 +32,6 @@ #define CONFIG_FACTORYSET -#undef CONFIG_IDENT_STRING -#define CONFIG_IDENT_STRING GENERATE_CCP_VERSION("01", "07") - #define CONFIG_REMAKE_ELF /* ENET Config */ @@ -117,20 +111,11 @@ ENV_EMMC \ ENV_NET -#define CONFIG_BOOTCOMMAND \ - "if usrbutton; then " \ - "run flash_self_test; " \ - "reset; " \ - "fi;" \ - "run flash_self;" \ - "reset;" - /* Default location for tftp and bootm */ #define CONFIG_SYS_INIT_SP_ADDR 0x80200000 /* On CCP board, USDHC1 is for eMMC */ #define CONFIG_MMCROOT "/dev/mmcblk0p2" /* eMMC */ -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 #define CONFIG_SYS_SDRAM_BASE 0x80000000 #define PHYS_SDRAM_1 0x80000000 diff --git a/include/configs/cgtqmx8.h b/include/configs/cgtqmx8.h index 45235957b4d..d5549f62cee 100644 --- a/include/configs/cgtqmx8.h +++ b/include/configs/cgtqmx8.h @@ -14,8 +14,6 @@ #ifdef CONFIG_SPL_BUILD #define CONFIG_SPL_MAX_SIZE (124 * 1024) #define CONFIG_SYS_MONITOR_LEN (1024 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x800 #define CONFIG_SPL_STACK 0x013E000 #define CONFIG_SPL_BSS_START_ADDR 0x00128000 @@ -33,7 +31,6 @@ #define CONFIG_REMAKE_ELF /* Flat Device Tree Definitions */ -#define CONFIG_OF_BOARD_SETUP #define CONFIG_SYS_BOOTMAPSZ (256 << 20) #define CONFIG_SYS_FSL_ESDHC_ADDR 0 @@ -82,7 +79,7 @@ "boot_fdt=try\0" \ "fdt_file=imx8qm-cgt-qmx8.dtb\0" \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} root=${mmcroot} earlycon\0 " \ @@ -123,24 +120,10 @@ "booti; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else booti ${loadaddr} - ${fdt_addr}; fi" - /* Link Definitions */ #define CONFIG_SYS_INIT_SP_ADDR 0x80200000 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_MMCROOT "/dev/mmcblk1p2" /* USDHC2 */ #define CONFIG_SYS_FSL_USDHC_NUM 3 diff --git a/include/configs/chiliboard.h b/include/configs/chiliboard.h index 49a8d710318..afddedd2eb7 100644 --- a/include/configs/chiliboard.h +++ b/include/configs/chiliboard.h @@ -31,11 +31,6 @@ "nand read ${loadaddr} NAND.kernel; " \ "bootz ${loadaddr} - ${fdt_addr}\0" -#define CONFIG_BOOTCOMMAND \ - "run mmcboot; " \ - "run nandboot; " \ - "run netboot" - #define CONFIG_EXTRA_ENV_SETTINGS \ "loadaddr=0x82000000\0" \ "fdt_addr=0x87800000\0" \ diff --git a/include/configs/chromebook_coral.h b/include/configs/chromebook_coral.h index 4d44b3b8013..0eeea80b32f 100644 --- a/include/configs/chromebook_coral.h +++ b/include/configs/chromebook_coral.h @@ -10,19 +10,6 @@ #ifndef __CONFIG_H #define __CONFIG_H -#define CONFIG_BOOTCOMMAND \ - "tpm init; tpm startup TPM2_SU_CLEAR; " \ - "read mmc 0:2 100000 0 80; setexpr loader *001004f0; " \ - "setexpr size *00100518; setexpr blocks $size / 200; " \ - "read mmc 0:2 100000 80 $blocks; setexpr setup $loader - 1000; " \ - "setexpr cmdline_ptr $loader - 2000; " \ - "setexpr.s cmdline *$cmdline_ptr; " \ - "setexpr cmdline gsub %U \\\\${uuid}; " \ - "if part uuid mmc 0:2 uuid; then " \ - "zboot start 100000 0 0 0 $setup cmdline; " \ - "zboot load; zboot setup; zboot dump; zboot go;" \ - "fi" - #include <configs/x86-common.h> #include <configs/x86-chromebook.h> @@ -31,8 +18,6 @@ "stdout=vidconsole,serial\0" \ "stderr=vidconsole,serial\0" -#define CONFIG_TPL_TEXT_BASE 0xffff8000 - #define CONFIG_SYS_NS16550_MEM32 #undef CONFIG_SYS_NS16550_PORT_MAPPED diff --git a/include/configs/chromebook_samus.h b/include/configs/chromebook_samus.h index 2fe3e721993..9d5a63cabaa 100644 --- a/include/configs/chromebook_samus.h +++ b/include/configs/chromebook_samus.h @@ -23,6 +23,4 @@ "stdout=vidconsole,serial\0" \ "stderr=vidconsole,serial\0" -#define CONFIG_TPL_TEXT_BASE 0xfffd8000 - #endif /* __CONFIG_H */ diff --git a/include/configs/ci20.h b/include/configs/ci20.h index 0a7043a80c5..17954fe3aab 100644 --- a/include/configs/ci20.h +++ b/include/configs/ci20.h @@ -35,7 +35,6 @@ #define CONFIG_SYS_MAXARGS 32 /* Max number of command args */ #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE /* Boot argument buffer size */ -#define CONFIG_VERSION_VARIABLE /* U-BOOT version */ /* Miscellaneous configuration options */ #define CONFIG_SYS_BOOTM_LEN (64 << 20) @@ -50,6 +49,4 @@ #define CONFIG_SPL_START_S_PATH "arch/mips/mach-jz47xx" -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x1c /* 14 KiB offset */ - #endif /* __CONFIG_CI20_H__ */ diff --git a/include/configs/cl-som-imx7.h b/include/configs/cl-som-imx7.h index fdc84297c62..a5bf6ccbf40 100644 --- a/include/configs/cl-som-imx7.h +++ b/include/configs/cl-som-imx7.h @@ -30,7 +30,6 @@ #undef CONFIG_SYS_AUTOLOAD #undef CONFIG_EXTRA_ENV_SETTINGS -#undef CONFIG_BOOTCOMMAND #define CONFIG_SYS_AUTOLOAD "no" @@ -50,7 +49,7 @@ "fdtaddr=0x83000000\0" \ "mmcdev_def="__stringify(CONFIG_SYS_MMC_DEV)"\0" \ "usbdev_def="__stringify(CONFIG_SYS_USB_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "usbpart=" __stringify(CONFIG_SYS_USB_IMG_LOAD_PART) "\0" \ "doboot=bootz ${loadaddr} - ${fdtaddr}\0" \ "mmc_config=mmc dev ${mmcdev}; mmc rescan\0" \ @@ -86,11 +85,6 @@ "emmcbootscript=setenv mmcdev 1; setenv mmcblk 2; run mmcbootscript\0" \ "emmcboot=setenv mmcdev 1; setenv mmcblk 2; run mmcboot\0" \ -#define CONFIG_BOOTCOMMAND \ - "echo SD boot attempt ...; run sdbootscript; run sdboot; " \ - "echo eMMC boot attempt ...; run emmcbootscript; run emmcboot; " \ - "echo USB boot attempt ...; run usbbootscript; " - /* Physical Memory Map */ #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR diff --git a/include/configs/clearfog.h b/include/configs/clearfog.h index a30bca5147a..c9af5a40cec 100644 --- a/include/configs/clearfog.h +++ b/include/configs/clearfog.h @@ -53,7 +53,7 @@ /* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10) -#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - 0x0030) +#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + CONFIG_SPL_SIZE) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/cm_fx6.h b/include/configs/cm_fx6.h index d61d759092c..40bc8215480 100644 --- a/include/configs/cm_fx6.h +++ b/include/configs/cm_fx6.h @@ -13,7 +13,6 @@ #include "mx6_common.h" /* Machine config */ -#define CONFIG_SYS_LITTLE_ENDIAN /* MMC */ #define CONFIG_SYS_FSL_USDHC_NUM 3 @@ -177,7 +176,6 @@ /* Display */ #define CONFIG_IMX_HDMI -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO /* EEPROM */ diff --git a/include/configs/cm_t335.h b/include/configs/cm_t335.h index 4b6e391d576..7e187a4e869 100644 --- a/include/configs/cm_t335.h +++ b/include/configs/cm_t335.h @@ -55,18 +55,6 @@ "loaduimage=fatload mmc ${mmcdev} ${loadaddr} uImage\0" \ MMCARGS \ NANDARGS - -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loaduimage; then " \ - "run mmcboot; " \ - "else run nandboot; " \ - "fi; " \ - "fi; " \ - "else run nandboot; fi" #endif /* CONFIG_SPL_BUILD */ #define CONFIG_TIMESTAMP diff --git a/include/configs/cm_t43.h b/include/configs/cm_t43.h index e250dc92dda..2d09a6f4c75 100644 --- a/include/configs/cm_t43.h +++ b/include/configs/cm_t43.h @@ -78,18 +78,6 @@ "load mmc 1 ${fdtaddr} ${fdtfile} && " \ "bootz ${loadaddr} - ${fdtaddr}\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev 0; " \ - "if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "fi; " \ - "fi; " \ - "mmc dev 1; " \ - "if mmc rescan; then " \ - "run emmcboot; " \ - "fi;" - /* SPL defines. */ #define CONFIG_SYS_SPL_ARGS_ADDR (CONFIG_SYS_SDRAM_BASE + (128 << 20)) #define CONFIG_SYS_MONITOR_LEN (512 * 1024) diff --git a/include/configs/cobra5272.h b/include/configs/cobra5272.h index dbb47ccb2a7..3e19e99c248 100644 --- a/include/configs/cobra5272.h +++ b/include/configs/cobra5272.h @@ -54,7 +54,6 @@ */ #if 0 -#define CONFIG_WATCHDOG #define CONFIG_WATCHDOG_TIMEOUT 10000 /* timeout in milliseconds */ #endif @@ -124,7 +123,6 @@ u-boot: 'set' command */ #if 0 -#define CONFIG_BOOTCOMMAND "bootm 0xffe80000" /*Autoboto command, please enter a valid image address in flash */ /* User network settings */ @@ -247,36 +245,6 @@ enter a valid image address in flash */ CF_CACR_EUSP) /*----------------------------------------------------------------------- - * Memory bank definitions - * - * Please refer also to Motorola Coldfire user manual - Chapter XXX - * <http://e-www.motorola.com/files/dsp/doc/ref_manual/MCF5272UM.pdf> - */ -#define CONFIG_SYS_BR0_PRELIM 0xFFE00201 -#define CONFIG_SYS_OR0_PRELIM 0xFFE00014 - -#define CONFIG_SYS_BR1_PRELIM 0 -#define CONFIG_SYS_OR1_PRELIM 0 - -#define CONFIG_SYS_BR2_PRELIM 0 -#define CONFIG_SYS_OR2_PRELIM 0 - -#define CONFIG_SYS_BR3_PRELIM 0 -#define CONFIG_SYS_OR3_PRELIM 0 - -#define CONFIG_SYS_BR4_PRELIM 0 -#define CONFIG_SYS_OR4_PRELIM 0 - -#define CONFIG_SYS_BR5_PRELIM 0 -#define CONFIG_SYS_OR5_PRELIM 0 - -#define CONFIG_SYS_BR6_PRELIM 0 -#define CONFIG_SYS_OR6_PRELIM 0 - -#define CONFIG_SYS_BR7_PRELIM 0x00000701 -#define CONFIG_SYS_OR7_PRELIM 0xFF00007C - -/*----------------------------------------------------------------------- * LED config */ #define LED_STAT_0 0xffff /*all LEDs off*/ diff --git a/include/configs/colibri-imx6ull.h b/include/configs/colibri-imx6ull.h index 6b3e1c665a0..787fe33941b 100644 --- a/include/configs/colibri-imx6ull.h +++ b/include/configs/colibri-imx6ull.h @@ -72,7 +72,6 @@ #if defined(CONFIG_TARGET_COLIBRI_IMX6ULL_NAND) /* Run Distro Boot script if ubiboot fails */ -#define CONFIG_BOOTCOMMAND "run ubiboot || run distro_bootcmd;" #define DFU_ALT_NAND_INFO "imx6ull-bcb part 0,1;u-boot1 part 0,2;u-boot2 part 0,3;u-boot-env part 0,4;ubi partubi 0,5" #define MODULE_EXTRA_ENV_SETTINGS \ "dfu_alt_info=" DFU_ALT_NAND_INFO "\0" \ @@ -165,7 +164,6 @@ #if defined(CONFIG_DM_VIDEO) #define MXS_LCDIF_BASE MX6UL_LCDIF1_BASE_ADDR -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #endif diff --git a/include/configs/colibri-imx8x.h b/include/configs/colibri-imx8x.h index 82926afbdf6..01182505cc8 100644 --- a/include/configs/colibri-imx8x.h +++ b/include/configs/colibri-imx8x.h @@ -80,7 +80,7 @@ "mmcargs=setenv bootargs ${consoleargs} " \ "root=PARTUUID=${uuid} rootwait " \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "netargs=setenv bootargs ${consoleargs} " \ "root=/dev/nfs ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp " \ "${vidargs}\0" \ @@ -102,8 +102,6 @@ /* Environment in eMMC, before config block at the end of 1st "boot sector" */ -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - /* On Colibri iMX8X USDHC1 is eMMC, USDHC2 is 4-bit SD */ #define CONFIG_SYS_FSL_USDHC_NUM 2 diff --git a/include/configs/colibri_imx6.h b/include/configs/colibri_imx6.h index b103186bf46..c8e733bc366 100644 --- a/include/configs/colibri_imx6.h +++ b/include/configs/colibri_imx6.h @@ -35,8 +35,6 @@ #define CONFIG_USBD_HS /* Framebuffer and LCD */ -#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP diff --git a/include/configs/colibri_imx7.h b/include/configs/colibri_imx7.h index ac188ee3ac6..faf27ba4fa3 100644 --- a/include/configs/colibri_imx7.h +++ b/include/configs/colibri_imx7.h @@ -110,8 +110,6 @@ "run fdt_fixup && bootz ${kernel_addr_r} - ${fdt_addr_r}\0" \ #if defined(CONFIG_TARGET_COLIBRI_IMX7_NAND) -#define CONFIG_BOOTCOMMAND "run ubiboot ; echo ; echo ubiboot failed ; " \ - "run distro_bootcmd;" #define MODULE_EXTRA_ENV_SETTINGS \ "mtdparts=" CONFIG_MTDPARTS_DEFAULT "\0" \ UBI_BOOTCMD @@ -199,7 +197,6 @@ #define CONFIG_USBD_HS #if defined(CONFIG_DM_VIDEO) -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #endif diff --git a/include/configs/colibri_pxa270.h b/include/configs/colibri_pxa270.h index 08786765d5a..0be7f5a416d 100644 --- a/include/configs/colibri_pxa270.h +++ b/include/configs/colibri_pxa270.h @@ -12,21 +12,12 @@ /* * High Level Board Configuration Options */ -#define CONFIG_CPU_PXA27X 1 /* Marvell PXA270 CPU */ /* Avoid overwriting factory configuration block */ #define CONFIG_BOARD_SIZE_LIMIT 0x40000 /* * Environment settings */ -#define CONFIG_BOOTCOMMAND \ - "if fatload mmc 0 0xa0000000 uImage; then " \ - "bootm 0xa0000000; " \ - "fi; " \ - "if usb reset && fatload usb 0 0xa0000000 uImage; then " \ - "bootm 0xa0000000; " \ - "fi; " \ - "bootm 0xc0000;" #define CONFIG_TIMESTAMP /* diff --git a/include/configs/colibri_t20.h b/include/configs/colibri_t20.h index e947b58d96c..c377187b803 100644 --- a/include/configs/colibri_t20.h +++ b/include/configs/colibri_t20.h @@ -19,7 +19,6 @@ #define CONFIG_LCD_LOGO /* NAND support */ -#define CONFIG_TEGRA_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 #define UBOOT_UPDATE \ diff --git a/include/configs/colibri_vf.h b/include/configs/colibri_vf.h index 71fe768d679..62f85185b76 100644 --- a/include/configs/colibri_vf.h +++ b/include/configs/colibri_vf.h @@ -14,10 +14,7 @@ #include <asm/arch/imx-regs.h> #include <linux/sizes.h> -#define CONFIG_SYS_FSL_CLK - #ifdef CONFIG_VIDEO_FSL_DCU_FB -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_SYS_FSL_DCU_LE @@ -69,8 +66,6 @@ "ubi read ${fdt_addr_r} dtb && " \ "run fdt_fixup && bootz ${kernel_addr_r} - ${fdt_addr_r}\0" \ -#define CONFIG_BOOTCOMMAND "run ubiboot || run distro_bootcmd;" - #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 0) \ func(USB, usb, 0) \ diff --git a/include/configs/comtrend_vr3032u.h b/include/configs/comtrend_vr3032u.h index fc890af915a..ee29f702f8f 100644 --- a/include/configs/comtrend_vr3032u.h +++ b/include/configs/comtrend_vr3032u.h @@ -10,5 +10,4 @@ #ifdef CONFIG_MTD_RAW_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 -#define CONFIG_SYS_NAND_SELF_INIT #endif /* CONFIG_MTD_RAW_NAND */ diff --git a/include/configs/condor.h b/include/configs/condor.h index 36466f0f500..822ef7118e1 100644 --- a/include/configs/condor.h +++ b/include/configs/condor.h @@ -27,7 +27,6 @@ /* Board Clock */ /* XTAL_CLK : 33.33MHz */ -#define CONFIG_SYS_CLK_FREQ 33333333u /* Generic Timer Definitions (use in assembler source) */ #define COUNTER_FREQUENCY 0xFE502A /* 16.66MHz from CPclk */ diff --git a/include/configs/conga-qeval20-qa3-e3845.h b/include/configs/conga-qeval20-qa3-e3845.h index 01b67f7e2d8..6e819ad2553 100644 --- a/include/configs/conga-qeval20-qa3-e3845.h +++ b/include/configs/conga-qeval20-qa3-e3845.h @@ -21,12 +21,6 @@ #define VIDEO_IO_OFFSET 0 #define CONFIG_X86EMU_RAW_IO -#undef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND \ - "load scsi 0:2 03000000 /boot/vmlinuz-${kernel-ver}-generic;" \ - "load scsi 0:2 04000000 /boot/initrd.img-${kernel-ver}-generic;" \ - "run boot" - #undef CONFIG_EXTRA_ENV_SETTINGS #define CONFIG_EXTRA_ENV_SETTINGS \ "kernel-ver=4.4.0-22\0" \ diff --git a/include/configs/controlcenterdc.h b/include/configs/controlcenterdc.h index 5120c7b3777..ff385d9c6be 100644 --- a/include/configs/controlcenterdc.h +++ b/include/configs/controlcenterdc.h @@ -122,26 +122,6 @@ " gpio clear ${gpio1}; gpio set ${gpio2};" \ " fi; sleep 0.12; done\0" -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=${serverip}:${rootpath} " \ - "ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}:${netdev}:off " \ - "console=${consoledev},${baudrate} ${othbootargs}; " \ - "tftpboot ${bootfile_addr} ${bootfile}; " \ - "bootm ${bootfile_addr}" - -#define MMCBOOTCOMMAND \ - "setenv bootargs root=/dev/mmcblk0p3 rw rootwait " \ - "console=${consoledev},${baudrate} ${othbootargs}; " \ - "ext2load mmc 0:2 ${bootfile_addr} ${bootfile}; " \ - "bootm ${bootfile_addr}" - -#define CONFIG_BOOTCOMMAND \ - "if env exists keyprogram; then;" \ - " setenv keyprogram; run nfsboot;" \ - " fi;" \ - " run dobootfail" - /* * mv-common.h should be defined after CMD configs since it used them * to enable certain macros diff --git a/include/configs/coreboot.h b/include/configs/coreboot.h index 1cf5c037e85..d6d679fd7dd 100644 --- a/include/configs/coreboot.h +++ b/include/configs/coreboot.h @@ -10,6 +10,9 @@ #ifndef __CONFIG_H #define __CONFIG_H +#define SPLASH_SETTINGS "splashsource=virtio_fs\0" \ + "splashimage=0x1000000\0" + #include <configs/x86-common.h> #define CONFIG_SYS_MONITOR_LEN (1 << 20) diff --git a/include/configs/corenet_ds.h b/include/configs/corenet_ds.h index 1e55d5259d2..f6e0b2a7ea8 100644 --- a/include/configs/corenet_ds.h +++ b/include/configs/corenet_ds.h @@ -47,15 +47,12 @@ #define CONFIG_SYS_NUM_CPC CONFIG_SYS_NUM_DDR_CTLRS #define CONFIG_PCIE1 /* PCIE controller 1 */ #define CONFIG_PCIE2 /* PCIE controller 2 */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ #if defined(CONFIG_SPIFLASH) #elif defined(CONFIG_SDCARD) #define CONFIG_FSL_FIXED_MMC_LOCATION #endif -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() /* sysclk for MPC85xx */ - /* * These can be toggled for performance analysis, otherwise use default. */ @@ -128,10 +125,6 @@ #define CONFIG_SYS_FLASH_OR_PRELIM ((0xf8000ff7 & ~OR_GPCM_SCY & ~OR_GPCM_EHTR) \ | OR_GPCM_SCY_8 | OR_GPCM_EHTR_CLEAR) -#define CONFIG_SYS_BR1_PRELIM \ - (BR_PHYS_ADDR(CONFIG_SYS_FLASH_BASE_PHYS) | BR_PS_16 | BR_V) -#define CONFIG_SYS_OR1_PRELIM 0xf8000ff7 - #define PIXIS_BASE 0xffdf0000 /* PIXIS registers */ #ifdef CONFIG_PHYS_64BIT #define PIXIS_BASE_PHYS 0xfffdf0000ull @@ -139,9 +132,6 @@ #define PIXIS_BASE_PHYS PIXIS_BASE #endif -#define CONFIG_SYS_BR3_PRELIM (BR_PHYS_ADDR(PIXIS_BASE_PHYS) | BR_PS_8 | BR_V) -#define CONFIG_SYS_OR3_PRELIM 0xffffeff7 /* 32KB but only 4k mapped */ - #define PIXIS_LBMAP_SWITCH 7 #define PIXIS_LBMAP_MASK 0xf0 #define PIXIS_LBMAP_SHIFT 4 @@ -187,21 +177,6 @@ | OR_FCM_SCY_1 \ | OR_FCM_TRLX \ | OR_FCM_EHTR) - -#ifdef CONFIG_MTD_RAW_NAND -#define CONFIG_SYS_BR0_PRELIM CONFIG_SYS_NAND_BR_PRELIM /* NAND Base Address */ -#define CONFIG_SYS_OR0_PRELIM CONFIG_SYS_NAND_OR_PRELIM /* NAND Options */ -#define CONFIG_SYS_BR2_PRELIM CONFIG_SYS_FLASH_BR_PRELIM /* NOR Base Address */ -#define CONFIG_SYS_OR2_PRELIM CONFIG_SYS_FLASH_OR_PRELIM /* NOR Options */ -#else -#define CONFIG_SYS_BR0_PRELIM CONFIG_SYS_FLASH_BR_PRELIM /* NOR Base Address */ -#define CONFIG_SYS_OR0_PRELIM CONFIG_SYS_FLASH_OR_PRELIM /* NOR Options */ -#define CONFIG_SYS_BR2_PRELIM CONFIG_SYS_NAND_BR_PRELIM /* NAND Base Address */ -#define CONFIG_SYS_OR2_PRELIM CONFIG_SYS_NAND_OR_PRELIM /* NAND Options */ -#endif -#else -#define CONFIG_SYS_BR0_PRELIM CONFIG_SYS_FLASH_BR_PRELIM /* NOR Base Address */ -#define CONFIG_SYS_OR0_PRELIM CONFIG_SYS_FLASH_OR_PRELIM /* NOR Options */ #endif /* CONFIG_NAND_FSL_ELBC */ #define CONFIG_SYS_FLASH_EMPTY_INFO @@ -414,7 +389,6 @@ #define CONFIG_HAS_FSL_MPH_USB #if defined(CONFIG_HAS_FSL_DR_USB) || defined(CONFIG_HAS_FSL_MPH_USB) -#define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #endif @@ -469,32 +443,6 @@ "fdtfile=p4080ds/p4080ds.dtb\0" \ "bdev=sda3\0" -#define HDBOOT \ - "setenv bootargs root=/dev/$bdev rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr - $fdtaddr" - -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp $ramdiskaddr $ramdiskfile;" \ - "tftp $loadaddr $bootfile;" \ - "tftp $fdtaddr $fdtfile;" \ - "bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND HDBOOT - #include <asm/fsl_secure_boot.h> #endif /* __CONFIG_H */ diff --git a/include/configs/corvus.h b/include/configs/corvus.h index 882cb48ecaa..27284f79138 100644 --- a/include/configs/corvus.h +++ b/include/configs/corvus.h @@ -66,7 +66,6 @@ #define CONFIG_SYS_NAND_MASK_CLE (1 << 22) #define CONFIG_SYS_NAND_ENABLE_PIN AT91_PIN_PC14 #define CONFIG_SYS_NAND_READY_PIN AT91_PIN_PC8 -#define CONFIG_SYS_NAND_DRIVER_ECC_LAYOUT #endif /* Ethernet */ @@ -79,10 +78,6 @@ /* bootstrap + u-boot + env in nandflash */ -#define CONFIG_BOOTCOMMAND \ - "nand read 0x70000000 0x200000 0x300000;" \ - "bootm 0x70000000" - /* Defines for SPL */ #define CONFIG_SPL_MAX_SIZE (12 * SZ_1K) #define CONFIG_SPL_STACK (SZ_16K) diff --git a/include/configs/crs3xx-98dx3236.h b/include/configs/crs3xx-98dx3236.h index 27b45a7605d..4dbc7582669 100644 --- a/include/configs/crs3xx-98dx3236.h +++ b/include/configs/crs3xx-98dx3236.h @@ -11,7 +11,6 @@ */ #define CONFIG_SYS_BOOTM_LEN (64 * 1024 * 1024) /* 64 MB */ -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage.cfg /* Environment in SPI NOR flash */ diff --git a/include/configs/da850evm.h b/include/configs/da850evm.h index f7c5d400cf9..97c9276e0e2 100644 --- a/include/configs/da850evm.h +++ b/include/configs/da850evm.h @@ -18,7 +18,6 @@ * SoC Configuration */ #define CONFIG_SYS_EXCEPTION_VECTORS_HIGH -#define CONFIG_SYS_CLK_FREQ clk_get(DAVINCI_ARM_CLKID) #define CONFIG_SYS_OSCIN_FREQ 24000000 #define CONFIG_SYS_TIMERBASE DAVINCI_TIMER0_BASE #define CONFIG_SYS_HZ_CLOCK clk_get(DAVINCI_AUXCLK_CLKID) @@ -136,10 +135,6 @@ 59, 60, 61, 62, 63 } #define CONFIG_SYS_NAND_ECCSIZE 512 #define CONFIG_SYS_NAND_ECCBYTES 10 - -#ifndef CONFIG_SPL_BUILD -#define CONFIG_SYS_NAND_SELF_INIT -#endif #endif /* @@ -171,10 +166,6 @@ #define LINUX_BOOT_PARAM_ADDR (PHYS_SDRAM_1 + 0x100) #define CONFIG_HWCONFIG /* enable hwconfig */ -#define CONFIG_BOOTCOMMAND \ - "run envboot; " \ - "run mmcboot; " - #define DEFAULT_LINUX_BOOT_ENV \ "loadaddr=0xc0700000\0" \ "fdtaddr=0xc0600000\0" \ diff --git a/include/configs/dart_6ul.h b/include/configs/dart_6ul.h index dd1ba49788a..fcdf7e9251d 100644 --- a/include/configs/dart_6ul.h +++ b/include/configs/dart_6ul.h @@ -90,8 +90,6 @@ "fit_addr=0x82000000\0" \ ENV_MMC -#define CONFIG_BOOTCOMMAND "run mmc_mmc_fit" - #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 0) \ func(MMC, mmc, 1) \ diff --git a/include/configs/db-88f6720.h b/include/configs/db-88f6720.h index 19fc669f89d..16c83a88dac 100644 --- a/include/configs/db-88f6720.h +++ b/include/configs/db-88f6720.h @@ -32,22 +32,9 @@ */ #include "mv-common.h" -/* - * Memory layout while starting into the bin_hdr via the - * BootROM: - * - * 0x4000.4000 - 0x4003.4000 headers space (192KiB) - * 0x4000.4030 bin_hdr start address - * 0x4003.4000 - 0x4004.7c00 BootROM memory allocations (15KiB) - * 0x4007.fffc BootROM stack top - * - * The address space between 0x4007.fffc and 0x400f.fff is not locked in - * L2 cache thus cannot be used. - */ - /* SPL */ /* Defines for SPL */ -#define CONFIG_SPL_MAX_SIZE ((128 << 10) - 0x4030) +#define CONFIG_SPL_MAX_SIZE ((128 << 10) - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + (128 << 10)) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/db-88f6820-amc.h b/include/configs/db-88f6820-amc.h index 1f70c609d23..6538e66052a 100644 --- a/include/configs/db-88f6820-amc.h +++ b/include/configs/db-88f6820-amc.h @@ -41,7 +41,7 @@ /* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10) -#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - 0x0030) +#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + CONFIG_SPL_SIZE) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/db-88f6820-gp.h b/include/configs/db-88f6820-gp.h index 41dadfebb94..5f2611995d3 100644 --- a/include/configs/db-88f6820-gp.h +++ b/include/configs/db-88f6820-gp.h @@ -50,7 +50,7 @@ /* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10) -#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - 0x0030) +#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + CONFIG_SPL_SIZE) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/db-mv784mp-gp.h b/include/configs/db-mv784mp-gp.h index dbbc33ebf9c..449a56753b1 100644 --- a/include/configs/db-mv784mp-gp.h +++ b/include/configs/db-mv784mp-gp.h @@ -59,7 +59,7 @@ /* SPL */ /* Defines for SPL */ -#define CONFIG_SPL_MAX_SIZE ((128 << 10) - 0x4030) +#define CONFIG_SPL_MAX_SIZE ((128 << 10) - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + (128 << 10)) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/db-xc3-24g4xg.h b/include/configs/db-xc3-24g4xg.h index 6a4c5a7ab55..1d242bf4e65 100644 --- a/include/configs/db-xc3-24g4xg.h +++ b/include/configs/db-xc3-24g4xg.h @@ -6,12 +6,6 @@ #ifndef _CONFIG_DB_XC3_24G4G_H #define _CONFIG_DB_XC3_24G4G_H -/* - * High Level Configuration Options (easy to change) - */ - -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage.cfg - /* Environment in SPI NOR flash */ /* NAND */ diff --git a/include/configs/deneb.h b/include/configs/deneb.h index a33165c1caa..f155bb8bf50 100644 --- a/include/configs/deneb.h +++ b/include/configs/deneb.h @@ -9,9 +9,6 @@ #include "capricorn-common.h" -#undef CONFIG_IDENT_STRING -#define CONFIG_IDENT_STRING GENERATE_CCP_VERSION("01", "06") - /* DDR3 board total DDR is 2 GB */ #undef PHYS_SDRAM_1_SIZE #define PHYS_SDRAM_1_SIZE 0x80000000 /* 2 GB */ diff --git a/include/configs/devkit3250.h b/include/configs/devkit3250.h index 8e8ea56f3cf..1e24d05bfb8 100644 --- a/include/configs/devkit3250.h +++ b/include/configs/devkit3250.h @@ -28,7 +28,6 @@ /* * GPIO */ -#define CONFIG_LPC32XX_GPIO /* * Ethernet @@ -84,14 +83,6 @@ * Environment */ -#define CONFIG_BOOTCOMMAND \ - "dhcp; " \ - "tftp ${loadaddr} ${serverip}:${tftpdir}/${bootfile}; " \ - "tftp ${dtbaddr} ${serverip}:${tftpdir}/devkit3250.dtb; " \ - "setenv nfsargs ip=dhcp root=/dev/nfs nfsroot=${serverip}:${nfsroot},tcp; " \ - "setenv bootargs ${bootargs} ${nfsargs} ${userargs}; " \ - "bootm ${loadaddr} - ${dtbaddr}" - #define CONFIG_EXTRA_ENV_SETTINGS \ "autoload=no\0" \ "ethaddr=00:01:90:00:C0:81\0" \ diff --git a/include/configs/devkit8000.h b/include/configs/devkit8000.h index 591a33fca68..9282f837285 100644 --- a/include/configs/devkit8000.h +++ b/include/configs/devkit8000.h @@ -46,15 +46,6 @@ /* TWL4030 */ -/* Board NAND Info */ -#define CONFIG_JFFS2_NAND -/* nand device jffs2 lives on */ -#define CONFIG_JFFS2_DEV "nand0" -/* start of jffs2 partition */ -#define CONFIG_JFFS2_PART_OFFSET 0x680000 -#define CONFIG_JFFS2_PART_SIZE 0xf980000 /* size of jffs2 */ - /* partition */ - /* BOOTP/DHCP options */ #define CONFIG_BOOTP_NISDOMAIN #define CONFIG_BOOTP_BOOTFILESIZE @@ -126,8 +117,6 @@ "fi; " \ "else run nandboot; fi\0" -#define CONFIG_BOOTCOMMAND "run autoboot" - /* Boot Argument Buffer Size */ /* Defines for SPL */ diff --git a/include/configs/dfi-bt700.h b/include/configs/dfi-bt700.h index 6d0e68e5df1..53ed7de0720 100644 --- a/include/configs/dfi-bt700.h +++ b/include/configs/dfi-bt700.h @@ -26,12 +26,6 @@ #define VIDEO_IO_OFFSET 0 #define CONFIG_X86EMU_RAW_IO -#undef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND \ - "load scsi 0:1 03000000 /boot/vmlinuz-${kernel-ver}-generic;" \ - "load scsi 0:1 04000000 /boot/initrd.img-${kernel-ver}-generic;" \ - "run boot" - #undef CONFIG_EXTRA_ENV_SETTINGS #define CONFIG_EXTRA_ENV_SETTINGS \ "kernel-ver=4.4.0-24\0" \ diff --git a/include/configs/dh_imx6.h b/include/configs/dh_imx6.h index ee56eb691ad..8b8cd4c31b4 100644 --- a/include/configs/dh_imx6.h +++ b/include/configs/dh_imx6.h @@ -64,13 +64,6 @@ #endif #endif -/* Watchdog */ -#if defined(CONFIG_SPL_BUILD) -#undef CONFIG_WDT -#undef CONFIG_WATCHDOG -#define CONFIG_HW_WATCHDOG -#endif - #ifndef CONFIG_SPL_BUILD #define CONFIG_EXTRA_ENV_SETTINGS \ "console=ttymxc0,115200\0" \ @@ -84,8 +77,6 @@ "fdtfile=imx6q-dhcom-pdk2.dtb\0"\ BOOTENV -#define CONFIG_BOOTCOMMAND "run distro_bootcmd" - #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 0) \ func(MMC, mmc, 2) \ diff --git a/include/configs/display5.h b/include/configs/display5.h index 329a60f1d20..38ac8692892 100644 --- a/include/configs/display5.h +++ b/include/configs/display5.h @@ -56,16 +56,6 @@ #define CONFIG_SYS_FSL_ESDHC_ADDR 0 #define CONFIG_SYS_FSL_USDHC_NUM 2 -#ifndef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND "if run check_em_pad; then " \ - "run recovery;" \ - "else if test ${BOOT_FROM} = FACTORY; then " \ - "run factory_nfs;" \ - "else " \ - "run boot_mmc;" \ - "fi;fi" -#endif - #define PARTS_DEFAULT \ /* Linux partitions */ \ "partitions=" \ @@ -200,7 +190,6 @@ "altbootcmd=run recovery\0" \ "bootdelay=1\0" \ "baudrate=115200\0" \ - "bootcmd=" CONFIG_BOOTCOMMAND "\0" \ "ethact=FEC\0" \ "netdev=eth0\0" \ "boot_os=y\0" \ @@ -325,13 +314,6 @@ #define CONFIG_SYS_INIT_SP_ADDR \ (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET) -/* Watchdog */ -#if defined(CONFIG_SPL_BUILD) -#undef CONFIG_WDT -#undef CONFIG_WATCHDOG -#define CONFIG_HW_WATCHDOG -#endif - /* ENV config */ #ifdef CONFIG_ENV_IS_IN_SPI_FLASH /* The 0x120000 value corresponds to above SPI-NOR memory MAP */ diff --git a/include/configs/dns325.h b/include/configs/dns325.h index 18ff1bb9e58..0590704000e 100644 --- a/include/configs/dns325.h +++ b/include/configs/dns325.h @@ -12,12 +12,6 @@ #ifndef _CONFIG_DNS325_H #define _CONFIG_DNS325_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 /* CPU Core subversion */ -#define CONFIG_KW88F6281 /* SOC Name */ - #include "mv-common.h" /* Remove or override few declarations from mv-common.h */ @@ -32,7 +26,6 @@ /* * Enable GPI0 support */ -#define CONFIG_KIRKWOOD_GPIO /* * Environment variables configurations @@ -72,17 +65,4 @@ "setenv bootenvrootfstype ${nandrootfstype}; " \ "setenv bootenvloadimage ${nandloadimage}\0" -#define CONFIG_BOOTCOMMAND \ - "if test -n ${bootenv} && usb start; then " \ - "if run loadbootenv; then " \ - "echo Loaded environment ${bootenv} from usb;" \ - "run importbootenv;" \ - "fi;" \ - "if test -n ${bootenvcmd}; then " \ - "echo Running bootenvcmd ...;" \ - "run bootenvcmd;" \ - "fi;" \ - "fi;" \ - "run setnandbootenv subbootcmd;" - #endif /* _CONFIG_DNS325_H */ diff --git a/include/configs/dockstar.h b/include/configs/dockstar.h index 75a2476f5ef..0ad04eee1b7 100644 --- a/include/configs/dockstar.h +++ b/include/configs/dockstar.h @@ -12,12 +12,6 @@ #define _CONFIG_DOCKSTAR_H /* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 1 /* CPU Core subversion */ -#define CONFIG_KW88F6281 1 /* SOC Name */ - -/* * mv-common.h should be defined after CMD configs since it used them * to enable certain macros */ @@ -34,13 +28,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \ - "ubi part root; " \ - "ubifsmount ubi:root; " \ - "ubifsload 0x800000 ${kernel}; " \ - "ubifsload 0x1100000 ${initrd}; " \ - "bootm 0x800000 0x1100000" #define CONFIG_EXTRA_ENV_SETTINGS \ "console=console=ttyS0,115200\0" \ diff --git a/include/configs/draco.h b/include/configs/draco.h index 29ce3a59404..d3056081013 100644 --- a/include/configs/draco.h +++ b/include/configs/draco.h @@ -47,24 +47,6 @@ #ifndef CONFIG_RESTORE_FLASH /* set to negative value for no autoboot */ - -#define CONFIG_BOOTCOMMAND \ -"if dfubutton; then " \ - "run dfu_start; " \ - "reset; " \ -"fi;" \ -"run nand_boot;" \ -"run nand_boot_backup;" \ -"reset;" - -#else - -#define CONFIG_BOOTCOMMAND \ - "setenv autoload no; " \ - "dhcp; " \ - "if tftp 80000000 debrick.scr; then " \ - "source 80000000; " \ - "fi" #endif #endif /* CONFIG_SPL_BUILD */ #endif /* ! __CONFIG_DRACO_H */ diff --git a/include/configs/dreamplug.h b/include/configs/dreamplug.h index 5b71f70c94b..beea234d8dc 100644 --- a/include/configs/dreamplug.h +++ b/include/configs/dreamplug.h @@ -11,12 +11,7 @@ #ifndef _CONFIG_DREAMPLUG_H #define _CONFIG_DREAMPLUG_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_SHEEVA_88SV131 1 /* CPU Core subversion */ - -#include "mv-plug-common.h" +#include "mv-common.h" /* * Environment variables configurations @@ -30,11 +25,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND "setenv ethact ethernet-controller@72000; " \ - "${x_bootcmd_ethernet}; setenv ethact ethernet-controller@76000; " \ - "${x_bootcmd_ethernet}; ${x_bootcmd_usb}; ${x_bootcmd_kernel}; "\ - "setenv bootargs ${x_bootargs} ${x_bootargs_root}; " \ - "bootm 0x6400000;" #define CONFIG_EXTRA_ENV_SETTINGS \ "x_bootcmd_ethernet=ping 192.168.2.1\0" \ diff --git a/include/configs/ds109.h b/include/configs/ds109.h index 62fe1441210..8553ea0b95f 100644 --- a/include/configs/ds109.h +++ b/include/configs/ds109.h @@ -11,12 +11,7 @@ #ifndef _CONFIG_DS109_H #define _CONFIG_DS109_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_SHEEVA_88SV131 1 /* CPU Core subversion */ - -#include "mv-plug-common.h" +#include "mv-common.h" /* * Environment variables configurations @@ -30,10 +25,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND "setenv ethact egiga0; " \ - "${x_bootcmd_ethernet}; ${x_bootcmd_usb}; ${x_bootcmd_kernel}; "\ - "setenv bootargs ${x_bootargs} ${x_bootargs_root}; " \ - "bootm 0x6400000;" #define CONFIG_EXTRA_ENV_SETTINGS \ "x_bootcmd_ethernet=ping 192.168.1.2\0" \ diff --git a/include/configs/ds414.h b/include/configs/ds414.h index 1f2d2c5e446..dbccd46bbdb 100644 --- a/include/configs/ds414.h +++ b/include/configs/ds414.h @@ -45,7 +45,7 @@ /* SPL */ /* Defines for SPL */ -#define CONFIG_SPL_MAX_SIZE ((128 << 10) - 0x4030) +#define CONFIG_SPL_MAX_SIZE ((128 << 10) - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + (128 << 10)) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) @@ -58,11 +58,6 @@ #define CONFIG_SPL_BOOTROM_SAVE (CONFIG_SPL_STACK + 4) /* Default Environment */ -#define CONFIG_BOOTCOMMAND \ - "sf probe; " \ - "sf read ${loadaddr} 0xd0000 0x2d0000; " \ - "sf read ${ramdisk_addr_r} 0x3a0000 0x430000; " \ - "bootm ${loadaddr} ${ramdisk_addr_r}" #define CONFIG_EXTRA_ENV_SETTINGS \ "initrd_high=0xffffffff\0" \ diff --git a/include/configs/durian.h b/include/configs/durian.h index 1dec09b4cea..c0ea42e180a 100644 --- a/include/configs/durian.h +++ b/include/configs/durian.h @@ -16,7 +16,6 @@ #define CONFIG_SYS_INIT_SP_ADDR (0x88000000 - 0x100000) /* PCI CONFIG */ -#define CONFIG_SYS_PCI_64BIT 1 #define CONFIG_PCI_SCAN_SHOW /* SCSI */ diff --git a/include/configs/eagle.h b/include/configs/eagle.h index ee535042509..b8a7b5a9169 100644 --- a/include/configs/eagle.h +++ b/include/configs/eagle.h @@ -18,7 +18,6 @@ /* Board Clock */ /* XTAL_CLK : 33.33MHz */ -#define CONFIG_SYS_CLK_FREQ 33333333u /* Generic Timer Definitions (use in assembler source) */ #define COUNTER_FREQUENCY 0xFE502A /* 16.66MHz from CPclk */ diff --git a/include/configs/eb_cpu5282.h b/include/configs/eb_cpu5282.h index 1949c3f558f..62b62e07c56 100644 --- a/include/configs/eb_cpu5282.h +++ b/include/configs/eb_cpu5282.h @@ -18,8 +18,6 @@ #undef CONFIG_MONITOR_IS_IN_RAM /* starts uboot direct */ -#define CONFIG_BOOTCOMMAND "printenv" - /*----------------------------------------------------------------------* * Options * *----------------------------------------------------------------------*/ @@ -27,8 +25,6 @@ #define CONFIG_BOOT_RETRY_TIME -1 #define CONFIG_RESET_TO_RETRY -#define CONFIG_HW_WATCHDOG - #define STATUS_LED_ACTIVE 0 /*----------------------------------------------------------------------* @@ -189,8 +185,6 @@ * I2C */ -#define CONFIG_SYS_IMMR CONFIG_SYS_MBAR - #ifdef CONFIG_CMD_DATE #define CONFIG_RTC_DS1338 #define CONFIG_I2C_RTC_ADDR 0x68 diff --git a/include/configs/ebisu.h b/include/configs/ebisu.h index 48d4c8a9480..081d5e9aaa6 100644 --- a/include/configs/ebisu.h +++ b/include/configs/ebisu.h @@ -25,7 +25,6 @@ #define CONFIG_FLASH_SHOW_PROGRESS 45 #define CONFIG_SYS_FLASH_QUIET_TEST #define CONFIG_SYS_FLASH_BANKS_LIST { 0x08000000 } -#define CONFIG_SYS_FLASH_CFI #define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_MAX_FLASH_BANKS_DETECT 1 #define CONFIG_SYS_MAX_FLASH_SECT 256 diff --git a/include/configs/edison.h b/include/configs/edison.h index 3ec35db4bcf..02f33f3c29f 100644 --- a/include/configs/edison.h +++ b/include/configs/edison.h @@ -14,9 +14,6 @@ #define CONFIG_SYS_MAXARGS 128 #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE -/* Memory */ -#define CONFIG_PHYSMEM - #define CONFIG_SYS_STACK_SIZE (32 * 1024) #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE diff --git a/include/configs/edminiv2.h b/include/configs/edminiv2.h index 664d6d1f340..e20e058e0a3 100644 --- a/include/configs/edminiv2.h +++ b/include/configs/edminiv2.h @@ -28,9 +28,6 @@ * High Level Configuration Options (easy to change) */ -#define CONFIG_FEROCEON 1 /* CPU Core subversion */ -#define CONFIG_88F5182 1 /* SOC Name */ - #include <asm/arch/orion5x.h> /* * CLKs configurations @@ -113,8 +110,6 @@ */ #ifdef CONFIG_IDE #define __io -/* Needs byte-swapping for ATA data register */ -#define CONFIG_IDE_SWAP_IO /* Data, registers and alternate blocks are at the same offset */ #define CONFIG_SYS_ATA_DATA_OFFSET (0x0100) #define CONFIG_SYS_ATA_REG_OFFSET (0x0100) diff --git a/include/configs/efi-x86_app.h b/include/configs/efi-x86_app.h index 6061a6db0a4..33afb7ca0f9 100644 --- a/include/configs/efi-x86_app.h +++ b/include/configs/efi-x86_app.h @@ -10,8 +10,33 @@ #undef CONFIG_TPM_TIS_BASE_ADDRESS +/* + * Select the output device: Put an 'x' prefix before one of these to disable it + */ + +/* + * Video output - can normally continue after exit_boot_services has been + * called, since output to the display does not require EFI services at that + * point. U-Boot sets up the console memory and does its own drawing. + */ #define CONFIG_STD_DEVICES_SETTINGS "stdin=serial\0" \ "stdout=vidconsole\0" \ "stderr=vidconsole\0" +/* + * Serial output with no console. Run qemu with: + * + * -display none -serial mon:stdio + * + * This will hang or fail to output on the console after exit_boot_services is + * called. + */ +#define xCONFIG_STD_DEVICES_SETTINGS "stdin=serial\0" \ + "stdout=serial\0" \ + "stderr=serial\0" + +#undef CONFIG_BOOTCOMMAND + +#define CONFIG_BOOTCOMMAND "part list efi 0; fatls efi 0:1" + #endif diff --git a/include/configs/embestmx6boards.h b/include/configs/embestmx6boards.h index 9769155bca7..d001580d7dd 100644 --- a/include/configs/embestmx6boards.h +++ b/include/configs/embestmx6boards.h @@ -52,7 +52,6 @@ #endif /* Framebuffer */ -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP diff --git a/include/configs/etamin.h b/include/configs/etamin.h index 3ff86eed835..dc83ab71908 100644 --- a/include/configs/etamin.h +++ b/include/configs/etamin.h @@ -84,9 +84,6 @@ */ /* nedded by compliance test in read mode */ -#if defined(CONFIG_SPL_CMT) -#define CONFIG_SYS_DCACHE_OFF -#endif /* Define own nand partitions */ #define CONFIG_ENV_RANGE (4 * CONFIG_SYS_ENV_SECT_SIZE) @@ -166,26 +163,5 @@ CONFIG_ENV_SETTINGS_BUTTONS_AND_LEDS \ CONFIG_ENV_SETTINGS_V2 \ CONFIG_ENV_SETTINGS_NAND_V2 - -#ifndef CONFIG_RESTORE_FLASH - -#define CONFIG_BOOTCOMMAND \ -"if dfubutton; then " \ - "run dfu_start; " \ - "reset; " \ -"fi;" \ -"run nand_boot;" \ -"run nand_boot_backup;" \ -"reset;" - - -#else -#define CONFIG_BOOTCOMMAND \ - "setenv autoload no; " \ - "dhcp; " \ - "if tftp 80000000 debrick.scr; then " \ - "source 80000000; " \ - "fi" -#endif #endif /* CONFIG_SPL_BUILD */ #endif /* ! __CONFIG_ETAMIN_H */ diff --git a/include/configs/ethernut5.h b/include/configs/ethernut5.h index c0bdfd3f8f1..ccf615efa3d 100644 --- a/include/configs/ethernut5.h +++ b/include/configs/ethernut5.h @@ -54,9 +54,6 @@ #endif /* JFFS2 */ -#ifdef CONFIG_CMD_JFFS2 -#define CONFIG_JFFS2_NAND -#endif /* Ethernet */ #define CONFIG_NET_RETRY_COUNT 20 @@ -66,7 +63,6 @@ /* MMC */ #ifdef CONFIG_CMD_MMC -#define CONFIG_GENERIC_ATMEL_MCI #define CONFIG_SYS_MMC_CD_PIN AT91_PIO_PORTC, 8 #endif @@ -118,9 +114,6 @@ /* File systems */ /* Boot command */ -#define CONFIG_BOOTCOMMAND "sf probe 0:0; " \ - "sf read 0x22000000 0xc6000 0x294000; " \ - "bootm 0x22000000" /* Misc. u-boot settings */ diff --git a/include/configs/evb_ast2500.h b/include/configs/evb_ast2500.h index dc032c1a419..b109a151838 100644 --- a/include/configs/evb_ast2500.h +++ b/include/configs/evb_ast2500.h @@ -13,4 +13,8 @@ #define CONFIG_SYS_UBOOT_BASE CONFIG_SYS_TEXT_BASE +/* Misc */ +#define CONFIG_EXTRA_ENV_SETTINGS \ + "" + #endif /* __CONFIG_H */ diff --git a/include/configs/evb_ast2600.h b/include/configs/evb_ast2600.h index 177a52eb916..3c2155da46d 100644 --- a/include/configs/evb_ast2600.h +++ b/include/configs/evb_ast2600.h @@ -10,4 +10,15 @@ #define CONFIG_SYS_UBOOT_BASE CONFIG_SYS_TEXT_BASE +/* Misc */ +#define STR_HELPER(s) #s +#define STR(s) STR_HELPER(s) + +#define CONFIG_EXTRA_ENV_SETTINGS \ + "loadaddr=" STR(CONFIG_SYS_LOAD_ADDR) "\0" \ + "bootspi=fdt addr 20100000 && fdt header get fitsize totalsize && " \ + "cp.b 20100000 ${loadaddr} ${fitsize} && bootm; " \ + "echo Error loading kernel FIT image\0" \ + "" + #endif /* __CONFIG_H */ diff --git a/include/configs/evb_px30.h b/include/configs/evb_px30.h index 27201fcfd7c..53781ba7ae8 100644 --- a/include/configs/evb_px30.h +++ b/include/configs/evb_px30.h @@ -12,6 +12,4 @@ "stdout=serial,vidconsole\0" \ "stderr=serial,vidconsole\0" -#define CONFIG_SUPPORT_EMMC_RPMB - #endif diff --git a/include/configs/evb_rk3308.h b/include/configs/evb_rk3308.h index e8893eb7de8..0273e751ce6 100644 --- a/include/configs/evb_rk3308.h +++ b/include/configs/evb_rk3308.h @@ -8,8 +8,6 @@ #include <configs/rk3308_common.h> -#define CONFIG_SUPPORT_EMMC_RPMB - #define ROCKCHIP_DEVICE_SETTINGS \ "stdout=serial,vidconsole\0" \ "stderr=serial,vidconsole\0" diff --git a/include/configs/evb_rk3568.h b/include/configs/evb_rk3568.h index 2b255a11da2..a0f2383bf2f 100644 --- a/include/configs/evb_rk3568.h +++ b/include/configs/evb_rk3568.h @@ -8,8 +8,6 @@ #include <configs/rk3568_common.h> -#define CONFIG_SUPPORT_EMMC_RPMB - #define ROCKCHIP_DEVICE_SETTINGS \ "stdout=serial,vidconsole\0" \ "stderr=serial,vidconsole\0" diff --git a/include/configs/evb_rv1108.h b/include/configs/evb_rv1108.h index b742d98706b..13e3cb2ffeb 100644 --- a/include/configs/evb_rv1108.h +++ b/include/configs/evb_rv1108.h @@ -18,11 +18,4 @@ "serverip=172.16.12.69\0" \ "" -#undef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND \ - "sf probe;" \ - "sf read 0x62000000 0x140800 0x500000;" \ - "dcache off;" \ - "go 0x62000000" - #endif diff --git a/include/configs/exynos-common.h b/include/configs/exynos-common.h index 95aaa747e4b..eb2606905f8 100644 --- a/include/configs/exynos-common.h +++ b/include/configs/exynos-common.h @@ -19,8 +19,7 @@ /* Keep L2 Cache Disabled */ /* input clock of PLL: 24MHz input clock */ -#define CONFIG_SYS_CLK_FREQ 24000000 -#define COUNTER_FREQUENCY CONFIG_SYS_CLK_FREQ +#define COUNTER_FREQUENCY 24000000 /* select serial console configuration */ diff --git a/include/configs/exynos5-dt-common.h b/include/configs/exynos5-dt-common.h index cc9ffda669e..00b67787d9e 100644 --- a/include/configs/exynos5-dt-common.h +++ b/include/configs/exynos5-dt-common.h @@ -30,7 +30,4 @@ #define LCD_BPP LCD_COLOR16 #endif -/* Enable keyboard */ -#define CONFIG_KEYBOARD - #endif diff --git a/include/configs/exynos78x0-common.h b/include/configs/exynos78x0-common.h index 478a0c42b1d..8d3449f028c 100644 --- a/include/configs/exynos78x0-common.h +++ b/include/configs/exynos78x0-common.h @@ -67,23 +67,6 @@ #define PHYS_SDRAM_12 (CONFIG_SYS_SDRAM_BASE + (11 * SDRAM_BANK_SIZE)) #define PHYS_SDRAM_12_SIZE SDRAM_BANK_SIZE -#define CONFIG_DEBUG_UART_CLOCK 132710400 - -#define CONFIG_PREBOOT \ -"echo Read pressed buttons status;" \ -"KEY_VOLUMEUP=gpa20;" \ -"KEY_HOME=gpa17;" \ -"KEY_VOLUMEDOWN=gpa21;" \ -"KEY_POWER=gpa00;" \ -"PRESSED=0;" \ -"RELEASED=1;" \ -"if gpio input $KEY_VOLUMEUP; then setenv VOLUME_UP $PRESSED; " \ -"else setenv VOLUME_UP $RELEASED; fi;" \ -"if gpio input $KEY_VOLUMEDOWN; then setenv VOLUME_DOWN $PRESSED; " \ -"else setenv VOLUME_DOWN $RELEASED; fi;" \ -"if gpio input $KEY_HOME; then setenv HOME $PRESSED; else setenv HOME $RELEASED; fi;" \ -"if gpio input $KEY_POWER; then setenv POWER $PRESSED; else setenv POWER $RELEASED; fi;" - #ifndef MEM_LAYOUT_ENV_SETTINGS #define MEM_LAYOUT_ENV_SETTINGS \ "bootm_size=0x10000000\0" \ diff --git a/include/configs/falcon.h b/include/configs/falcon.h index d783faf180e..1d6a9b9b734 100644 --- a/include/configs/falcon.h +++ b/include/configs/falcon.h @@ -26,7 +26,6 @@ /* Board Clock */ /* XTAL_CLK : 16.66MHz */ -#define CONFIG_SYS_CLK_FREQ 16666666u /* Generic Timer Definitions (use in assembler source) */ #define COUNTER_FREQUENCY 0xFE502A /* 16.66MHz from CPclk */ diff --git a/include/configs/firefly_rk3308.h b/include/configs/firefly_rk3308.h index 3af24930431..28e3a547e33 100644 --- a/include/configs/firefly_rk3308.h +++ b/include/configs/firefly_rk3308.h @@ -8,8 +8,6 @@ #include <configs/rk3308_common.h> -#define CONFIG_SUPPORT_EMMC_RPMB - #define ROCKCHIP_DEVICE_SETTINGS \ "stdout=serial,vidconsole\0" \ "stderr=serial,vidconsole\0" diff --git a/include/configs/gazerbeam.h b/include/configs/gazerbeam.h index ec5fc156965..c7fdf7c6bb8 100644 --- a/include/configs/gazerbeam.h +++ b/include/configs/gazerbeam.h @@ -100,22 +100,4 @@ __stringify(CONFIG_SYS_MONITOR_BASE) " ${filesize}\0" \ "upd=run load update\0" \ -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftp ${kernel_addr} $bootfile;" \ - "tftp ${fdt_addr} $fdtfile;" \ - "bootm ${kernel_addr} - ${fdt_addr}" - -#define MMCBOOTCOMMAND \ - "setenv bootargs root=/dev/mmcblk0p3 rw rootwait " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "ext2load mmc 0:2 ${kernel_addr} $bootfile;" \ - "ext2load mmc 0:2 ${fdt_addr} $fdtfile;" \ - "bootm ${kernel_addr} - ${fdt_addr}" - -#define CONFIG_BOOTCOMMAND MMCBOOTCOMMAND - #endif /* __CONFIG_H */ diff --git a/include/configs/ge_b1x5v2.h b/include/configs/ge_b1x5v2.h index 1a5db248002..b4f94992e64 100644 --- a/include/configs/ge_b1x5v2.h +++ b/include/configs/ge_b1x5v2.h @@ -119,6 +119,4 @@ "run showsplashscreen; sleep 1; " \ "run doboot; run failbootcmd;\0" \ -#define CONFIG_BOOTCOMMAND "run tryboot;" - #endif /* __GE_B1X5V2_CONFIG_H */ diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 0eeffd46377..bde14a7b3da 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -98,15 +98,6 @@ "run doboot; " \ "run failbootcmd\0" \ -#define MMCBOOTCOMMAND \ - "run doquiet; " \ - "run tryboot; " \ - -#ifdef CONFIG_CMD_NFS -#define CONFIG_BOOTCOMMAND NETWORKBOOTCOMMAND -#else -#define CONFIG_BOOTCOMMAND MMCBOOTCOMMAND -#endif /* Physical Memory Map */ #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR diff --git a/include/configs/giedi.h b/include/configs/giedi.h index dabb1fb1713..19a795bcf86 100644 --- a/include/configs/giedi.h +++ b/include/configs/giedi.h @@ -9,9 +9,6 @@ #include "capricorn-common.h" -#undef CONFIG_IDENT_STRING -#define CONFIG_IDENT_STRING GENERATE_CCP_VERSION("01", "07") - /* DDR3 board total DDR is 1 GB */ #undef PHYS_SDRAM_1_SIZE #define PHYS_SDRAM_1_SIZE 0x40000000 /* 1 GB */ diff --git a/include/configs/goflexhome.h b/include/configs/goflexhome.h index 43027a506a5..90e37d98535 100644 --- a/include/configs/goflexhome.h +++ b/include/configs/goflexhome.h @@ -15,12 +15,6 @@ #define _CONFIG_GOFLEXHOME_H /* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 1 /* CPU Core subversion */ -#define CONFIG_KW88F6281 1 /* SOC Name */ - -/* * Default GPIO configuration and LED status */ #define GOFLEXHOME_OE_LOW (~(0)) @@ -49,12 +43,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \ - "ubi part root; " \ - "ubifsmount ubi:root; " \ - "ubifsload 0x800000 ${kernel}; " \ - "bootm 0x800000" #define CONFIG_EXTRA_ENV_SETTINGS \ "console=console=ttyS0,115200\0" \ diff --git a/include/configs/gose.h b/include/configs/gose.h index 60a89e00236..01657d7a669 100644 --- a/include/configs/gose.h +++ b/include/configs/gose.h @@ -30,8 +30,6 @@ #define CONFIG_BITBANGMII_MULTI /* Board Clock */ -#define RMOBILE_XTAL_CLK 20000000u -#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK #define CONFIG_EXTRA_ENV_SETTINGS \ "bootm_size=0x10000000\0" diff --git a/include/configs/grpeach.h b/include/configs/grpeach.h index 29a446c2f5d..fb01c5614b6 100644 --- a/include/configs/grpeach.h +++ b/include/configs/grpeach.h @@ -9,7 +9,6 @@ #define __GRPEACH_H /* Board Clock , P1 clock frequency (XTAL=13.33MHz) */ -#define CONFIG_SYS_CLK_FREQ 66666666 /* Miscellaneous */ #define CONFIG_SYS_PBSIZE 256 diff --git a/include/configs/guruplug.h b/include/configs/guruplug.h index 8de888fe7e0..25c5a97c69d 100644 --- a/include/configs/guruplug.h +++ b/include/configs/guruplug.h @@ -9,20 +9,7 @@ #ifndef _CONFIG_GURUPLUG_H #define _CONFIG_GURUPLUG_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_SHEEVA_88SV131 1 /* CPU Core subversion */ - -/* - * Standard filesystems - */ - -/* - * mv-plug-common.h should be defined after CMD configs since it used them - * to enable certain macros - */ -#include "mv-plug-common.h" +#include "mv-common.h" /* * Environment variables configurations @@ -40,15 +27,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \ - "ubi part root; " \ - "ubifsmount ubi:rootfs; " \ - "ubifsload 0x800000 ${kernel}; " \ - "ubifsload 0x700000 ${fdt}; " \ - "ubifsumount; " \ - "fdt addr 0x700000; fdt resize; fdt chosen; " \ - "bootz 0x800000 - 0x700000" #define CONFIG_EXTRA_ENV_SETTINGS \ "console=console=ttyS0,115200\0" \ diff --git a/include/configs/gw_ventana.h b/include/configs/gw_ventana.h index abceffb4220..513b2d46798 100644 --- a/include/configs/gw_ventana.h +++ b/include/configs/gw_ventana.h @@ -72,7 +72,6 @@ #define CONFIG_USBD_HS /* Framebuffer and LCD */ -#define CONFIG_VIDEO_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP #define CONFIG_VIDEO_BMP_LOGO @@ -254,10 +253,4 @@ "fi\0" #endif -#define CONFIG_BOOTCOMMAND \ - "for btype in ${bootdevs}; do " \ - "echo; echo Attempting ${btype} boot...; " \ - "if run ${btype}_boot; then; fi; " \ - "done" - #endif /* __CONFIG_H */ diff --git a/include/configs/harmony.h b/include/configs/harmony.h index 5a1e72c5373..879bd5c9539 100644 --- a/include/configs/harmony.h +++ b/include/configs/harmony.h @@ -24,7 +24,6 @@ #endif /* NAND support */ -#define CONFIG_TEGRA_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 /* Environment in NAND (which is 512M), aligned to start of last sector */ diff --git a/include/configs/helios4.h b/include/configs/helios4.h index 56d35d6fdbc..de1ebbf3751 100644 --- a/include/configs/helios4.h +++ b/include/configs/helios4.h @@ -53,7 +53,7 @@ /* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10) -#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - 0x0030) +#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + CONFIG_SPL_SIZE) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/ib62x0.h b/include/configs/ib62x0.h index 4bd3494f108..9783fd89ec0 100644 --- a/include/configs/ib62x0.h +++ b/include/configs/ib62x0.h @@ -8,12 +8,6 @@ #ifndef _CONFIG_IB62x0_H #define _CONFIG_IB62x0_H -/* - * High level configuration options - */ -#define CONFIG_FEROCEON_88FR131 /* CPU Core subversion */ -#define CONFIG_KW88F6281 /* SOC Name */ - #include "mv-common.h" /* @@ -23,15 +17,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \ - "ubi part root; " \ - "ubifsmount ubi:rootfs; " \ - "ubifsload 0x800000 ${kernel}; " \ - "ubifsload 0x700000 ${fdt}; " \ - "ubifsumount; " \ - "fdt addr 0x700000; fdt resize; fdt chosen; " \ - "bootz 0x800000 - 0x700000" #define CONFIG_EXTRA_ENV_SETTINGS \ "console=console=ttyS0,115200\0" \ @@ -59,11 +44,4 @@ #define CONFIG_SYS_ATA_IDE1_OFFSET MV_SATA_PORT1_OFFSET #endif /* CONFIG_IDE */ -/* - * RTC driver configuration - */ -#ifdef CONFIG_CMD_DATE -#define CONFIG_RTC_MV -#endif /* CONFIG_CMD_DATE */ - #endif /* _CONFIG_IB62x0_H */ diff --git a/include/configs/iconnect.h b/include/configs/iconnect.h index 1a716dfbe91..f1aad1efde6 100644 --- a/include/configs/iconnect.h +++ b/include/configs/iconnect.h @@ -8,12 +8,6 @@ #ifndef _CONFIG_ICONNECT_H #define _CONFIG_ICONNECT_H -/* - * High level configuration options - */ -#define CONFIG_FEROCEON_88FR131 /* CPU Core subversion */ -#define CONFIG_KW88F6281 /* SOC Name */ - #include "mv-common.h" /* @@ -23,12 +17,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \ - "ubi part rootfs; " \ - "ubifsmount ubi:rootfs; " \ - "ubifsload 0x800000 ${kernel}; " \ - "bootm 0x800000" #define CONFIG_EXTRA_ENV_SETTINGS \ "console=console=ttyS0,115200\0" \ diff --git a/include/configs/ids8313.h b/include/configs/ids8313.h index 370f7ed2bcb..206a57a6532 100644 --- a/include/configs/ids8313.h +++ b/include/configs/ids8313.h @@ -153,7 +153,6 @@ /* * HW-Watchdog */ -#define CONFIG_WATCHDOG 1 #define CONFIG_SYS_WATCHDOG_VALUE 0xFFFF /* @@ -232,12 +231,8 @@ #define CONFIG_LOADS_ECHO #define CONFIG_TIMESTAMP -#define CONFIG_BOOTCOMMAND "run boot_cramfs" #undef CONFIG_SYS_LOADS_BAUD_CHANGE -#define CONFIG_JFFS2_NAND -#define CONFIG_JFFS2_DEV "0" - /* mtdparts command line support */ #define CONFIG_EXTRA_ENV_SETTINGS \ @@ -272,14 +267,6 @@ "mtdparts=" CONFIG_MTDPARTS_DEFAULT "\0" \ "\0" -#define NFSBOOTCOMMAND \ - "setenv rootdev /dev/nfs;" \ - "run setipargs;run addmtd;" \ - "tftp ${loadaddr} ${bootfile};" \ - "tftp ${fdtaddr} ${fdtfile};" \ - "fdt addr ${fdtaddr};" \ - "bootm ${loadaddr} - ${fdtaddr}" - /* UBI Support */ #endif /* __CONFIG_H */ diff --git a/include/configs/imx27lite-common.h b/include/configs/imx27lite-common.h index c289d694e9b..dffe175f50a 100644 --- a/include/configs/imx27lite-common.h +++ b/include/configs/imx27lite-common.h @@ -103,7 +103,6 @@ #define CONFIG_MXC_NAND_REGS_BASE 0xd8000000 #define CONFIG_SYS_MAX_NAND_DEVICE 1 #define CONFIG_SYS_NAND_BASE 0xd8000000 -#define CONFIG_JFFS2_NAND #define CONFIG_MXC_NAND_HWECC /* diff --git a/include/configs/imx6-engicam.h b/include/configs/imx6-engicam.h index fed6545fdf9..b22b2fd4a3b 100644 --- a/include/configs/imx6-engicam.h +++ b/include/configs/imx6-engicam.h @@ -96,8 +96,6 @@ "run nandboot; " \ "fi\0" -#define CONFIG_BOOTCOMMAND "run $modeboot" - /* Miscellaneous configurable options */ #ifdef CONFIG_MX6UL @@ -156,7 +154,6 @@ #ifdef CONFIG_VIDEO_IPUV3 # define CONFIG_IMX_VIDEO_SKIP -# define CONFIG_VIDEO_LOGO # define CONFIG_VIDEO_BMP_LOGO #endif diff --git a/include/configs/imx6_logic.h b/include/configs/imx6_logic.h index 766562676cc..7e56c8ee215 100644 --- a/include/configs/imx6_logic.h +++ b/include/configs/imx6_logic.h @@ -108,8 +108,6 @@ "fi; " \ "fi; " \ "else run netboot; fi" -#define CONFIG_BOOTCOMMAND \ - "run autoboot" #define CONFIG_ARP_TIMEOUT 200UL diff --git a/include/configs/imx7-cm.h b/include/configs/imx7-cm.h index 01f87329292..261ed900fee 100644 --- a/include/configs/imx7-cm.h +++ b/include/configs/imx7-cm.h @@ -16,7 +16,6 @@ #undef CONFIG_SYS_AUTOLOAD #undef CONFIG_EXTRA_ENV_SETTINGS -#undef CONFIG_BOOTCOMMAND /* * Use: @@ -33,7 +32,7 @@ "fdt_file=imx7-cm.dtb\0" \ "fdt_addr=0x83000000\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ "root=${mmcroot}\0" \ @@ -70,8 +69,6 @@ "bootz ${loadaddr} - ${fdt_addr}; " \ "\0" -#define CONFIG_BOOTCOMMAND "run boot${boot-mode}" - /* Physical Memory Map */ #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR @@ -88,7 +85,6 @@ #define CONFIG_SYS_FSL_ESDHC_ADDR USDHC1_BASE_ADDR #define CONFIG_SYS_FSL_USDHC_NUM 2 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 #define CONFIG_MMCROOT "/dev/mmcblk0p2" /* USDHC1 */ /* USB Configs */ diff --git a/include/configs/imx8mm-cl-iot-gate.h b/include/configs/imx8mm-cl-iot-gate.h index 6868b804849..991839c0bcd 100644 --- a/include/configs/imx8mm-cl-iot-gate.h +++ b/include/configs/imx8mm-cl-iot-gate.h @@ -14,8 +14,6 @@ #define CONFIG_SYS_BOOTM_LEN (32 * SZ_1M) #define CONFIG_SPL_MAX_SIZE (148 * 1024) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -81,7 +79,7 @@ "initrd_addr=0x43800000\0" \ "bootm_size=0x10000000\0" \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console} root=${mmcroot}\0 " \ @@ -125,20 +123,6 @@ "fi; " \ "fi;\0" -#ifndef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "fi;" -#endif - /* Link Definitions */ #define CONFIG_SYS_INIT_RAM_ADDR 0x40000000 @@ -168,8 +152,6 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_ETHPRIME "FEC" #define CONFIG_FEC_XCV_TYPE RGMII diff --git a/include/configs/imx8mm_beacon.h b/include/configs/imx8mm_beacon.h index 2bdcc0ab725..77f062474dd 100644 --- a/include/configs/imx8mm_beacon.h +++ b/include/configs/imx8mm_beacon.h @@ -11,8 +11,6 @@ #define CONFIG_SPL_MAX_SIZE (148 * 1024) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -40,7 +38,7 @@ "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \ "initrd_addr=0x43800000\0" \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "finduuid=part uuid mmc ${mmcdev}:2 uuid\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate}" \ @@ -80,18 +78,6 @@ "fi; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "fi;" - /* Link Definitions */ #define CONFIG_SYS_INIT_RAM_ADDR 0x40000000 @@ -105,9 +91,6 @@ #define PHYS_SDRAM 0x40000000 #define PHYS_SDRAM_SIZE 0x80000000 /* 2GB DDR */ -#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM -#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + (PHYS_SDRAM_SIZE >> 1)) - #define CONFIG_MXC_UART_BASE UART2_BASE_ADDR /* Monitor Command Prompt */ @@ -120,7 +103,6 @@ /* USDHC */ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 /* FEC*/ #define CONFIG_ETHPRIME "FEC" diff --git a/include/configs/imx8mm_evk.h b/include/configs/imx8mm_evk.h index 167ca19f210..c7022ef0f7f 100644 --- a/include/configs/imx8mm_evk.h +++ b/include/configs/imx8mm_evk.h @@ -13,8 +13,6 @@ #define CONFIG_SYS_BOOTM_LEN (64 * SZ_1M) #define CONFIG_SPL_MAX_SIZE (148 * 1024) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -53,7 +51,7 @@ "fdtfile=imx8mm-evk.dtb\0" \ "initrd_addr=0x43800000\0" \ "bootm_size=0x10000000\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ /* Link Definitions */ @@ -85,8 +83,6 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_ETHPRIME "FEC" #define CONFIG_FEC_XCV_TYPE RGMII diff --git a/include/configs/imx8mm_icore_mx8mm.h b/include/configs/imx8mm_icore_mx8mm.h index 4b22ba10a02..d75fcf747e4 100644 --- a/include/configs/imx8mm_icore_mx8mm.h +++ b/include/configs/imx8mm_icore_mx8mm.h @@ -12,8 +12,6 @@ #define CONFIG_SPL_MAX_SIZE (148 * 1024) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -30,9 +28,6 @@ # define CONFIG_SPL_ABORT_ON_RAW_IMAGE #endif /* CONFIG_SPL_BUILD */ -#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM -#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + (PHYS_SDRAM_SIZE >> 1)) - #ifndef CONFIG_SPL_BUILD #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 2) \ @@ -71,10 +66,6 @@ #define PHYS_SDRAM_SIZE SZ_2G /* 2GB DDR */ #define CONFIG_SYS_BOOTM_LEN SZ_256M -#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM -#define CONFIG_SYS_MEMTEST_END \ - (CONFIG_SYS_MEMTEST_START + (PHYS_SDRAM_SIZE >> 1)) - /* UART */ #define CONFIG_MXC_UART_BASE UART2_BASE_ADDR @@ -88,6 +79,5 @@ /* USDHC */ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 #endif /* __IMX8MM_ICORE_MX8MM_H */ diff --git a/include/configs/imx8mm_venice.h b/include/configs/imx8mm_venice.h index f8d41425c6f..7ab11cc8fb1 100644 --- a/include/configs/imx8mm_venice.h +++ b/include/configs/imx8mm_venice.h @@ -11,8 +11,6 @@ #define CONFIG_SPL_MAX_SIZE (148 * 1024) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -105,7 +103,6 @@ /* USDHC */ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 /* FEC */ #define CONFIG_ETHPRIME "eth0" diff --git a/include/configs/imx8mn_beacon.h b/include/configs/imx8mn_beacon.h index f89836cd2a8..28435359739 100644 --- a/include/configs/imx8mn_beacon.h +++ b/include/configs/imx8mn_beacon.h @@ -11,9 +11,6 @@ #define CONFIG_SPL_MAX_SIZE (148 * SZ_1K) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 -#define CONFIG_SYS_MMCSD_FS_BOOT_PARTITION 1 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -46,7 +43,7 @@ "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \ "initrd_addr=0x43800000\0" \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "finduuid=part uuid mmc ${mmcdev}:2 uuid\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console} " \ @@ -95,18 +92,6 @@ "run loadramdisk; run ramargs; " \ "booti ${loadaddr} ${ramdisk_addr} ${fdt_addr} ${optargs}\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else booti ${loadaddr} - ${fdt_addr}; fi" - /* Link Definitions */ #define CONFIG_SYS_INIT_RAM_ADDR 0x40000000 @@ -136,7 +121,6 @@ /* USDHC */ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 /* ENET Config */ #if defined(CONFIG_FEC_MXC) diff --git a/include/configs/imx8mn_evk.h b/include/configs/imx8mn_evk.h index ab893214921..142fc3e4fff 100644 --- a/include/configs/imx8mn_evk.h +++ b/include/configs/imx8mn_evk.h @@ -14,8 +14,6 @@ #define CONFIG_SPL_MAX_SIZE (148 * 1024) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -52,7 +50,7 @@ "fdtfile=" CONFIG_DEFAULT_FDT_FILE "\0" \ "initrd_addr=0x43800000\0" \ "bootm_size=0x10000000\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ /* Link Definitions */ @@ -84,6 +82,4 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #endif diff --git a/include/configs/imx8mp_evk.h b/include/configs/imx8mp_evk.h index 30cce1a49e2..b810a558adf 100644 --- a/include/configs/imx8mp_evk.h +++ b/include/configs/imx8mp_evk.h @@ -14,8 +14,6 @@ #define CONFIG_SPL_MAX_SIZE (152 * 1024) #define CONFIG_SYS_MONITOR_LEN (512 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) #ifdef CONFIG_SPL_BUILD @@ -67,7 +65,7 @@ "fdtfile=" CONFIG_DEFAULT_FDT_FILE "\0" \ "initrd_addr=0x43800000\0" \ "bootm_size=0x10000000\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ /* Link Definitions */ @@ -100,6 +98,4 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #endif diff --git a/include/configs/imx8mq_cm.h b/include/configs/imx8mq_cm.h index 7206c08a8c9..b099004937d 100644 --- a/include/configs/imx8mq_cm.h +++ b/include/configs/imx8mq_cm.h @@ -14,8 +14,6 @@ #define CONFIG_SPL_MAX_SIZE (124 * 1024) #define CONFIG_SYS_MONITOR_LEN (512 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #ifdef CONFIG_SPL_BUILD #define CONFIG_SPL_STACK 0x187FF0 @@ -61,7 +59,7 @@ "fdt_file=imx8mq-cm.dtb\0" \ "initrd_addr=0x43800000\0" \ "bootm_size=0x10000000\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ /* Link Definitions */ @@ -91,6 +89,4 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #endif diff --git a/include/configs/imx8mq_evk.h b/include/configs/imx8mq_evk.h index 49a9526d96e..6e1d387e2b1 100644 --- a/include/configs/imx8mq_evk.h +++ b/include/configs/imx8mq_evk.h @@ -14,8 +14,6 @@ #define CONFIG_SPL_MAX_SIZE (124 * 1024) #define CONFIG_SYS_MONITOR_LEN (512 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #ifdef CONFIG_SPL_BUILD /*#define CONFIG_ENABLE_DDR_TRAINING_DEBUG*/ @@ -72,7 +70,7 @@ "fdt_file=imx8mq-evk.dtb\0" \ "initrd_addr=0x43800000\0" \ "bootm_size=0x10000000\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ /* Link Definitions */ @@ -102,10 +100,4 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - -#define CONFIG_MXC_GPIO - -#define CONFIG_OF_SYSTEM_SETUP - #endif diff --git a/include/configs/imx8mq_phanbell.h b/include/configs/imx8mq_phanbell.h index 0366c113e3d..1668ca8acf3 100644 --- a/include/configs/imx8mq_phanbell.h +++ b/include/configs/imx8mq_phanbell.h @@ -11,8 +11,6 @@ #define CONFIG_SPL_MAX_SIZE (172 * 1024) #define CONFIG_SYS_MONITOR_LEN (512 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #ifdef CONFIG_SPL_BUILD /*#define CONFIG_ENABLE_DDR_TRAINING_DEBUG*/ @@ -62,7 +60,7 @@ "initrd_addr=0x43800000\0" \ "initrd_high=0xffffffffffffffff\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console} root=${mmcroot}\0 " \ @@ -103,18 +101,6 @@ "booti; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else booti ${loadaddr} - ${fdt_addr}; fi" - /* Link Definitions */ #define CONFIG_SYS_INIT_RAM_ADDR 0x40000000 @@ -130,10 +116,6 @@ #define PHYS_SDRAM 0x40000000 #define PHYS_SDRAM_SIZE 0x40000000 /* 1GB DDR */ -#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM -#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + \ - (PHYS_SDRAM_SIZE >> 1)) - #define CONFIG_MXC_UART_BASE UART1_BASE_ADDR /* Monitor Command Prompt */ @@ -146,10 +128,4 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - -#define CONFIG_MXC_GPIO - -#define CONFIG_OF_SYSTEM_SETUP - #endif diff --git a/include/configs/imx8qm_mek.h b/include/configs/imx8qm_mek.h index 11b5c16e37e..884d741789f 100644 --- a/include/configs/imx8qm_mek.h +++ b/include/configs/imx8qm_mek.h @@ -15,8 +15,6 @@ #ifdef CONFIG_SPL_BUILD #define CONFIG_SPL_MAX_SIZE (124 * 1024) #define CONFIG_SYS_MONITOR_LEN (1024 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x800 #define CONFIG_SPL_STACK 0x013E000 #define CONFIG_SPL_BSS_START_ADDR 0x00128000 @@ -33,9 +31,6 @@ #define CONFIG_REMAKE_ELF -/* Flat Device Tree Definitions */ -#define CONFIG_OF_BOARD_SETUP - #define CONFIG_SYS_FSL_ESDHC_ADDR 0 #define USDHC1_BASE_ADDR 0x5B010000 #define USDHC2_BASE_ADDR 0x5B020000 @@ -60,7 +55,7 @@ "initrd_addr=0x83800000\0" \ "initrd_high=0xffffffffffffffff\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console} root=${mmcroot}\0 " \ @@ -121,33 +116,12 @@ "fi;" \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if test ${sec_boot} = yes; then " \ - "if run loadcntr; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "fi; " \ - "else booti ${loadaddr} - ${fdt_addr}; fi" - /* Link Definitions */ #define CONFIG_SYS_INIT_SP_ADDR 0x80200000 /* Default environment is in SD */ -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - /* On LPDDR4 board, USDHC1 is for eMMC, USDHC2 is for SD on CPU board */ #define CONFIG_MMCROOT "/dev/mmcblk1p2" /* USDHC2 */ #define CONFIG_SYS_FSL_USDHC_NUM 2 diff --git a/include/configs/imx8qm_rom7720.h b/include/configs/imx8qm_rom7720.h index 2c80f268a41..1a553510f6d 100644 --- a/include/configs/imx8qm_rom7720.h +++ b/include/configs/imx8qm_rom7720.h @@ -64,7 +64,7 @@ "fdt_file=imx8qm-rom7720-a1.dtb\0" \ "initrd_addr=0x83800000\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} root=${mmcroot} earlycon\0 " \ @@ -105,33 +105,10 @@ "booti; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else booti ${loadaddr} - ${fdt_addr}; fi" - /* Link Definitions */ #define CONFIG_SYS_INIT_SP_ADDR 0x80200000 -/* Default environment is in SD */ - -#ifdef CONFIG_QSPI_BOOT -#define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED -#endif - -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - /* On LPDDR4 board, USDHC1 is for eMMC, USDHC2 is for SD on CPU board, * USDHC3 is for SD on base board On DDR4 board, USDHC1 is mux for NAND, * USDHC2 is for SD, USDHC3 is for SD on base board diff --git a/include/configs/imx8qxp_mek.h b/include/configs/imx8qxp_mek.h index f59a9ef5e2c..3900ef1b500 100644 --- a/include/configs/imx8qxp_mek.h +++ b/include/configs/imx8qxp_mek.h @@ -13,8 +13,6 @@ #ifdef CONFIG_SPL_BUILD #define CONFIG_SPL_MAX_SIZE (124 * 1024) #define CONFIG_SYS_MONITOR_LEN (1024 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x800 #define CONFIG_SPL_STACK 0x013E000 #define CONFIG_SPL_BSS_START_ADDR 0x00128000 @@ -31,9 +29,6 @@ #define CONFIG_REMAKE_ELF -/* Flat Device Tree Definitions */ -#define CONFIG_OF_BOARD_SETUP - #define CONFIG_SYS_FSL_ESDHC_ADDR 0 #define USDHC1_BASE_ADDR 0x5B010000 #define USDHC2_BASE_ADDR 0x5B020000 @@ -58,7 +53,7 @@ "initrd_addr=0x83800000\0" \ "initrd_high=0xffffffffffffffff\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} root=${mmcroot}\0 " \ @@ -119,33 +114,12 @@ "fi;" \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if test ${sec_boot} = yes; then " \ - "if run loadcntr; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "fi; " \ - "else booti ${loadaddr} - ${fdt_addr}; fi" - /* Link Definitions */ #define CONFIG_SYS_INIT_SP_ADDR 0x80200000 /* Default environment is in SD */ -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - /* On LPDDR4 board, USDHC1 is for eMMC, USDHC2 is for SD on CPU board */ #define CONFIG_MMCROOT "/dev/mmcblk1p2" /* USDHC2 */ #define CONFIG_SYS_FSL_USDHC_NUM 2 diff --git a/include/configs/imx8ulp_evk.h b/include/configs/imx8ulp_evk.h index 501f465b9e7..6b25b485dec 100644 --- a/include/configs/imx8ulp_evk.h +++ b/include/configs/imx8ulp_evk.h @@ -12,9 +12,6 @@ #define CONFIG_SYS_BOOTM_LEN (SZ_64M) #define CONFIG_SPL_MAX_SIZE (148 * 1024) #define CONFIG_SYS_MONITOR_LEN (512 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 -#define CONFIG_SYS_MMCSD_FS_BOOT_PARTITION 1 #define CONFIG_SYS_UBOOT_BASE (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) #ifdef CONFIG_SPL_BUILD @@ -64,7 +61,7 @@ "fdtfile=imx8ulp-evk.dtb\0" \ "initrd_addr=0x83800000\0" \ "bootm_size=0x10000000\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ /* Link Definitions */ diff --git a/include/configs/imxrt1020-evk.h b/include/configs/imxrt1020-evk.h index 64c0f5eaf0b..79feab389e3 100644 --- a/include/configs/imxrt1020-evk.h +++ b/include/configs/imxrt1020-evk.h @@ -11,7 +11,6 @@ #define CONFIG_SYS_INIT_SP_ADDR 0x20240000 -#define CONFIG_SYS_FSL_ERRATUM_ESDHC135 1 #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE 1 #define PHYS_SDRAM 0x80000000 diff --git a/include/configs/imxrt1050-evk.h b/include/configs/imxrt1050-evk.h index 99d25c1e6ef..b507895a0d8 100644 --- a/include/configs/imxrt1050-evk.h +++ b/include/configs/imxrt1050-evk.h @@ -11,7 +11,6 @@ #define CONFIG_SYS_INIT_SP_ADDR 0x20280000 -#define CONFIG_SYS_FSL_ERRATUM_ESDHC135 1 #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE 1 #define PHYS_SDRAM 0x80000000 @@ -22,7 +21,6 @@ DMAMEM_SZ_ALL) #ifdef CONFIG_DM_VIDEO -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_EXTRA_ENV_SETTINGS \ diff --git a/include/configs/integratorap.h b/include/configs/integratorap.h index 2f8ac20a76e..6d7d798fd6c 100644 --- a/include/configs/integratorap.h +++ b/include/configs/integratorap.h @@ -24,8 +24,6 @@ */ #define CONFIG_BOOTP_BOOTFILESIZE -#define CONFIG_BOOTCOMMAND "" - /* Flash settings */ #define CONFIG_SYS_FLASH_SIZE 0x02000000 /* 32 MiB */ #define CONFIG_SYS_MAX_FLASH_SECT 128 diff --git a/include/configs/integratorcp.h b/include/configs/integratorcp.h index c4203ce57e1..3ff7bb933c4 100644 --- a/include/configs/integratorcp.h +++ b/include/configs/integratorcp.h @@ -27,7 +27,6 @@ #define CONFIG_SMC91111_BASE 0xC8000000 #undef CONFIG_SMC91111_EXT_PHY -#define CONFIG_BOOTCOMMAND "tftpboot ; bootm" #define CONFIG_SERVERIP 192.168.1.100 #define CONFIG_IPADDR 192.168.1.104 #define CONFIG_BOOTFILE "uImage" diff --git a/include/configs/k2g_evm.h b/include/configs/k2g_evm.h index 56dd9c72d94..294ce4662e2 100644 --- a/include/configs/k2g_evm.h +++ b/include/configs/k2g_evm.h @@ -50,27 +50,6 @@ "get_mon_mmc=load mmc ${bootpart} ${addr_mon} ${bootdir}/${name_mon}\0"\ "name_fs=arago-base-tisdk-image-k2g-evm.cpio\0" -#ifndef CONFIG_TI_SECURE_DEVICE -#define CONFIG_BOOTCOMMAND \ - "run findfdt; " \ - "run envboot; " \ - "run init_${boot}; " \ - "run get_mon_${boot} run_mon; " \ - "run set_name_pmmc get_pmmc_${boot} run_pmmc; " \ - "run get_kern_${boot}; " \ - "run init_fw_rd_${boot}; " \ - "run get_fdt_${boot}; " \ - "run run_kern" -#else -#define CONFIG_BOOTCOMMAND \ - "run findfdt; " \ - "run envboot; " \ - "run run_mon_hs; " \ - "run init_${boot}; " \ - "run get_fit_${boot}; " \ - "bootm ${addr_fit}#${name_fdt}" -#endif - /* NAND Configuration */ #define CONFIG_SYS_NAND_PAGE_2K diff --git a/include/configs/khadas-vim3_android.h b/include/configs/khadas-vim3_android.h new file mode 100644 index 00000000000..da6adf6c413 --- /dev/null +++ b/include/configs/khadas-vim3_android.h @@ -0,0 +1,50 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* + * Configuration for the khadas VIM3 Android + * + * Copyright (C) 2021 Baylibre, SAS + * Author: Guillaume LA ROQUE <glaroque@baylibre.com> + */ + +#ifndef __CONFIG_H +#define __CONFIG_H + +#define LOGO_UUID "43a3305d-150f-4cc9-bd3b-38fca8693846;" +#define ROOT_UUID "ddb8c3f6-d94d-4394-b633-3134139cc2e0;" + +#if defined(CONFIG_CMD_AB_SELECT) +#define PARTS_DEFAULT \ + "uuid_disk=${uuid_gpt_disk};" \ + "name=logo,start=512K,size=2M,uuid=" LOGO_UUID \ + "name=misc,size=512K,uuid=${uuid_gpt_misc};" \ + "name=dtbo_a,size=8M,uuid=${uuid_gpt_dtbo_a};" \ + "name=dtbo_b,size=8M,uuid=${uuid_gpt_dtbo_b};" \ + "name=vbmeta_a,size=512K,uuid=${uuid_gpt_vbmeta_a};" \ + "name=vbmeta_b,size=512K,uuid=${uuid_gpt_vbmeta_b};" \ + "name=boot_a,size=32M,bootable,uuid=${uuid_gpt_boot_a};" \ + "name=boot_b,size=32M,bootable,uuid=${uuid_gpt_boot_b};" \ + "name=super,size=3072M,uuid=${uuid_gpt_super};" \ + "name=userdata,size=11282M,uuid=${uuid_gpt_userdata};" \ + "name=rootfs,size=-,uuid=" ROOT_UUID +#else +#define PARTS_DEFAULT \ + "uuid_disk=${uuid_gpt_disk};" \ + "name=logo,start=512K,size=2M,uuid=" LOGO_UUID \ + "name=misc,size=512K,uuid=${uuid_gpt_misc};" \ + "name=dtbo,size=8M,uuid=${uuid_gpt_dtbo};" \ + "name=vbmeta,size=512K,uuid=${uuid_gpt_vbmeta};" \ + "name=boot,size=32M,bootable,uuid=${uuid_gpt_boot};" \ + "name=recovery,size=32M,uuid=${uuid_gpt_recovery};" \ + "name=cache,size=256M,uuid=${uuid_gpt_cache};" \ + "name=super,size=1792M,uuid=${uuid_gpt_super};" \ + "name=userdata,size=12786M,uuid=${uuid_gpt_userdata};" \ + "name=rootfs,size=-,uuid=" ROOT_UUID +#endif + +#define EXTRA_ANDROID_ENV_SETTINGS \ + "board=vim3\0" \ + "board_name=vim3\0" \ + +#include <configs/meson64_android.h> + +#endif /* __CONFIG_H */ diff --git a/include/configs/khadas-vim3l_android.h b/include/configs/khadas-vim3l_android.h new file mode 100644 index 00000000000..b1768e2d821 --- /dev/null +++ b/include/configs/khadas-vim3l_android.h @@ -0,0 +1,50 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* + * Configuration for the khadas VIM3L Android + * + * Copyright (C) 2021 Baylibre, SAS + * Author: Guillaume LA ROQUE <glaroque@baylibre.com> + */ + +#ifndef __CONFIG_H +#define __CONFIG_H + +#define LOGO_UUID "43a3305d-150f-4cc9-bd3b-38fca8693846;" +#define ROOT_UUID "ddb8c3f6-d94d-4394-b633-3134139cc2e0;" + +#if defined(CONFIG_CMD_AB_SELECT) +#define PARTS_DEFAULT \ + "uuid_disk=${uuid_gpt_disk};" \ + "name=logo,start=512K,size=2M,uuid=" LOGO_UUID \ + "name=misc,size=512K,uuid=${uuid_gpt_misc};" \ + "name=dtbo_a,size=8M,uuid=${uuid_gpt_dtbo_a};" \ + "name=dtbo_b,size=8M,uuid=${uuid_gpt_dtbo_b};" \ + "name=vbmeta_a,size=512K,uuid=${uuid_gpt_vbmeta_a};" \ + "name=vbmeta_b,size=512K,uuid=${uuid_gpt_vbmeta_b};" \ + "name=boot_a,size=32M,bootable,uuid=${uuid_gpt_boot_a};" \ + "name=boot_b,size=32M,bootable,uuid=${uuid_gpt_boot_b};" \ + "name=super,size=3072M,uuid=${uuid_gpt_super};" \ + "name=userdata,size=11282M,uuid=${uuid_gpt_userdata};" \ + "name=rootfs,size=-,uuid=" ROOT_UUID +#else +#define PARTS_DEFAULT \ + "uuid_disk=${uuid_gpt_disk};" \ + "name=logo,start=512K,size=2M,uuid=" LOGO_UUID \ + "name=misc,size=512K,uuid=${uuid_gpt_misc};" \ + "name=dtbo,size=8M,uuid=${uuid_gpt_dtbo};" \ + "name=vbmeta,size=512K,uuid=${uuid_gpt_vbmeta};" \ + "name=boot,size=32M,bootable,uuid=${uuid_gpt_boot};" \ + "name=recovery,size=32M,uuid=${uuid_gpt_recovery};" \ + "name=cache,size=256M,uuid=${uuid_gpt_cache};" \ + "name=super,size=1792M,uuid=${uuid_gpt_super};" \ + "name=userdata,size=12786M,uuid=${uuid_gpt_userdata};" \ + "name=rootfs,size=-,uuid=" ROOT_UUID +#endif + +#define EXTRA_ANDROID_ENV_SETTINGS \ + "board=vim3l\0" \ + "board_name=vim3l\0" \ + +#include <configs/meson64_android.h> + +#endif /* __CONFIG_H */ diff --git a/include/configs/km/km-mpc8309.h b/include/configs/km/km-mpc8309.h index 869bd9b30a9..98204bd3c69 100644 --- a/include/configs/km/km-mpc8309.h +++ b/include/configs/km/km-mpc8309.h @@ -5,12 +5,6 @@ #define CONFIG_KM_DEF_ARCH "arch=ppc_82xx\0" -/* - * System Clock Setup - */ -#define CONFIG_SYS_CLK_FREQ 66000000 -#define CONFIG_83XX_PCICLK 66000000 - /* QE microcode/firmware address */ /* between the u-boot partition and env */ diff --git a/include/configs/km/km-mpc832x.h b/include/configs/km/km-mpc832x.h index de6e7daf066..888bb2981f7 100644 --- a/include/configs/km/km-mpc832x.h +++ b/include/configs/km/km-mpc832x.h @@ -1,15 +1,4 @@ /* - * High Level Configuration Options - */ -#define CONFIG_KM8321 /* Keymile PBEC8321 board specific */ - -/* - * System Clock Setup - */ -#define CONFIG_SYS_CLK_FREQ 66000000 -#define CONFIG_83XX_PCICLK 66000000 - -/* * System IO Config */ #define CONFIG_SYS_SICRL SICRL_IRQ_CKS @@ -69,6 +58,3 @@ #define CONFIG_SYS_KMBEC_FPGA_BASE 0xE8000000 #define CONFIG_SYS_KMBEC_FPGA_SIZE 128 - -/* EEprom support */ -#define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1 diff --git a/include/configs/km/km_arm.h b/include/configs/km/km_arm.h index cca624ea3e1..a485c3ac6d1 100644 --- a/include/configs/km/km_arm.h +++ b/include/configs/km/km_arm.h @@ -19,12 +19,6 @@ #ifndef _CONFIG_KM_ARM_H #define _CONFIG_KM_ARM_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 /* CPU Core subversion */ -#define CONFIG_KW88F6281 /* SOC Name */ - #define CONFIG_NAND_ECC_BCH /* include common defines/options for all Keymile boards */ @@ -74,7 +68,6 @@ #undef CONFIG_I2C_MVTWSI #define CONFIG_SYS_I2C_INIT_BOARD -#define CONFIG_KIRKWOOD_GPIO /* Enable GPIO Support */ #define CONFIG_SYS_NUM_I2C_BUSES 6 #define CONFIG_SYS_I2C_MAX_HOPS 1 #define CONFIG_SYS_I2C_BUSES { {0, {I2C_NULL_HOP} }, \ diff --git a/include/configs/km/pg-wcom-ls102xa.h b/include/configs/km/pg-wcom-ls102xa.h index 743d09e9c4d..ba0e4dd5c6a 100644 --- a/include/configs/km/pg-wcom-ls102xa.h +++ b/include/configs/km/pg-wcom-ls102xa.h @@ -6,8 +6,6 @@ #ifndef __CONFIG_PG_WCOM_LS102XA_H #define __CONFIG_PG_WCOM_LS102XA_H -#define CONFIG_SYS_FSL_CLK - /* include common defines/options for all Keymile boards */ #include "keymile-common.h" @@ -18,8 +16,6 @@ CONFIG_KM_PHRAM + \ CONFIG_KM_RESERVED_PRAM) >> 10) -#define CONFIG_SYS_CLK_FREQ 66666666 - #define PHYS_SDRAM 0x80000000 #define PHYS_SDRAM_SIZE (1u * 1024 * 1024 * 1024) @@ -40,7 +36,6 @@ * IFC Definitions */ /* NOR Flash Definitions */ -#define CONFIG_FSL_IFC #define CONFIG_SYS_FLASH_BASE 0x60000000 #define CONFIG_SYS_FLASH_BASE_PHYS CONFIG_SYS_FLASH_BASE diff --git a/include/configs/km_kirkwood.h b/include/configs/km_kirkwood.h index 82c2a129223..e58a69501b3 100644 --- a/include/configs/km_kirkwood.h +++ b/include/configs/km_kirkwood.h @@ -34,8 +34,6 @@ /* KM_KIRKWOOD_128M16 */ #elif defined(CONFIG_KM_KIRKWOOD_128M16) #define CONFIG_HOSTNAME "km_kirkwood_128m16" -#undef CONFIG_SYS_KWD_CONFIG -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage_128M16_1.cfg #define CONFIG_KM_DISABLE_PCIE /* KM_NUSA */ @@ -43,21 +41,14 @@ #define CONFIG_HOSTNAME "kmnusa" -#undef CONFIG_SYS_KWD_CONFIG -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage_128M16_1.cfg - /* KMCOGE5UN */ #elif defined(CONFIG_KM_COGE5UN) -#undef CONFIG_SYS_KWD_CONFIG -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage_256M8_1.cfg #define CONFIG_HOSTNAME "kmcoge5un" #define CONFIG_KM_DISABLE_PCIE /* KM_SUSE2 */ #elif defined(CONFIG_KM_SUSE2) #define CONFIG_HOSTNAME "kmsuse2" -#undef CONFIG_SYS_KWD_CONFIG -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage_128M16_1.cfg #define CONFIG_KM_UBI_PART_BOOT_OPTS ",2048" #define CONFIG_SYS_NAND_NO_SUBPAGE_WRITE #else diff --git a/include/configs/kmcent2.h b/include/configs/kmcent2.h index 4dbd53c3877..98e572397b5 100644 --- a/include/configs/kmcent2.h +++ b/include/configs/kmcent2.h @@ -141,14 +141,11 @@ #define CONFIG_SYS_FSL_CPC /* Corenet Platform Cache */ #define CONFIG_SYS_NUM_CPC CONFIG_SYS_NUM_DDR_CTLRS #define CONFIG_PCIE1 /* PCIE controller 1 */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ /* Environment in parallel NOR-Flash */ #define CONFIG_ENV_TOTAL_SIZE 0x040000 #define ENV_DEL_ADDR 0xebf00000 /*direct for newenv*/ -#define CONFIG_SYS_CLK_FREQ 66666666 - /* * These can be toggled for performance analysis, otherwise use default. */ @@ -362,7 +359,6 @@ * Retain non-DM serial port for debug purposes. */ #if !defined(CONFIG_DM_SERIAL) -#define CONFIG_CONS_INDEX 1 #define CONFIG_SYS_NS16550_SERIAL #define CONFIG_SYS_NS16550_REG_SIZE 1 #define CONFIG_SYS_NS16550_CLK (get_bus_freq(0) / 2) diff --git a/include/configs/kmcoge5ne.h b/include/configs/kmcoge5ne.h index 60fe4ae3839..8f4685c271c 100644 --- a/include/configs/kmcoge5ne.h +++ b/include/configs/kmcoge5ne.h @@ -24,12 +24,6 @@ #include "km/km-mpc83xx.h" #include "km/km-mpc8360.h" -/* - * System Clock Setup - */ -#define CONFIG_SYS_CLK_FREQ 66000000 -#define CONFIG_83XX_PCICLK 66000000 - /** * KMCOGE5NE has 512 MB RAM */ diff --git a/include/configs/koelsch.h b/include/configs/koelsch.h index 65a38c5757b..eca8998a515 100644 --- a/include/configs/koelsch.h +++ b/include/configs/koelsch.h @@ -30,8 +30,6 @@ #define CONFIG_BITBANGMII_MULTI /* Board Clock */ -#define RMOBILE_XTAL_CLK 20000000u -#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK #define CONFIG_EXTRA_ENV_SETTINGS \ "bootm_size=0x10000000\0" diff --git a/include/configs/kontron-sl-mx6ul.h b/include/configs/kontron-sl-mx6ul.h index 34304f91028..2bac0008e25 100644 --- a/include/configs/kontron-sl-mx6ul.h +++ b/include/configs/kontron-sl-mx6ul.h @@ -59,7 +59,6 @@ #ifdef CONFIG_FSL_USDHC #define CONFIG_SYS_FSL_ESDHC_ADDR USDHC1_BASE_ADDR #define CONFIG_SYS_FSL_USDHC_NUM 2 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 #endif #define CONFIG_EXTRA_ENV_SETTINGS \ diff --git a/include/configs/kontron_sl28.h b/include/configs/kontron_sl28.h index 4152851ba41..448749a7f81 100644 --- a/include/configs/kontron_sl28.h +++ b/include/configs/kontron_sl28.h @@ -30,10 +30,6 @@ /* early stack pointer */ #define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_FSL_OCRAM_BASE + 0xeff0) -/* memtest command */ -#define CONFIG_SYS_MEMTEST_START 0x80000000 -#define CONFIG_SYS_MEMTEST_END 0x9fffffff - /* SMP */ #define CPU_RELEASE_ADDR secondary_boot_addr @@ -46,8 +42,7 @@ /* serial port */ #define CONFIG_SYS_NS16550_CLK (get_bus_freq(0) / 2) -#define CONFIG_SYS_CLK_FREQ 100000000 -#define COUNTER_FREQUENCY_REAL (CONFIG_SYS_CLK_FREQ / 4) +#define COUNTER_FREQUENCY_REAL (get_board_sys_clk() / 4) /* ethernet */ #define CONFIG_SYS_RX_ETH_BUFFER 8 diff --git a/include/configs/kp_imx53.h b/include/configs/kp_imx53.h index c1db6eace1a..0983d40ec41 100644 --- a/include/configs/kp_imx53.h +++ b/include/configs/kp_imx53.h @@ -10,8 +10,6 @@ #include <asm/arch/imx-regs.h> #include <linux/sizes.h> -#define CONFIG_SYS_FSL_CLK - /* USB Configs */ #define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW) #define CONFIG_MXC_USB_FLAGS 0 @@ -56,8 +54,6 @@ "bootm ${loadaddr}#${fit_config}\0" \ BOOTENV -#define CONFIG_BOOTCOMMAND "run usbupd; run distro_bootcmd" - #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 0) \ func(DHCP, dhcp, na) diff --git a/include/configs/kp_imx6q_tpc.h b/include/configs/kp_imx6q_tpc.h index 3061c96e76b..c53808558f9 100644 --- a/include/configs/kp_imx6q_tpc.h +++ b/include/configs/kp_imx6q_tpc.h @@ -82,8 +82,6 @@ "bootm ${loadaddr}#${fit_config}\0" \ BOOTENV -#define CONFIG_BOOTCOMMAND "run usbupd; run distro_bootcmd" - #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 0) \ func(MMC, mmc, 1) \ diff --git a/include/configs/kzm9g.h b/include/configs/kzm9g.h index c3f690c7d70..1eb6dafe203 100644 --- a/include/configs/kzm9g.h +++ b/include/configs/kzm9g.h @@ -68,9 +68,8 @@ /* Clock */ #define CONFIG_GLOBAL_TIMER -#define CONFIG_SYS_CLK_FREQ (48000000) #define CONFIG_SYS_CPU_CLK (1196000000) -#define CONFIG_SH_SCIF_CLK_FREQ CONFIG_SYS_CLK_FREQ +#define CONFIG_SH_SCIF_CLK_FREQ get_board_sys_clk() #define TMU_CLK_DIVIDER (4) /* 4 (default), 16, 64, 256 or 1024 */ #define CONFIG_NFS_TIMEOUT 10000UL diff --git a/include/configs/lacie_kw.h b/include/configs/lacie_kw.h index 146d8ad6372..046f1888cb1 100644 --- a/include/configs/lacie_kw.h +++ b/include/configs/lacie_kw.h @@ -6,35 +6,6 @@ #ifndef _CONFIG_LACIE_KW_H #define _CONFIG_LACIE_KW_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 /* CPU Core subversion */ -/* SoC name */ -#if defined(CONFIG_NETSPACE_LITE_V2) || defined(CONFIG_NETSPACE_MINI_V2) -#define CONFIG_KW88F6192 -#else -#define CONFIG_KW88F6281 -#endif - -/* - * SDRAM configuration - */ - -/* - * Different SDRAM configuration and size for some of the boards derived - * from the Network Space v2 - */ -#if defined(CONFIG_INETSPACE_V2) -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage-is2.cfg -#elif defined(CONFIG_NETSPACE_LITE_V2) || defined(CONFIG_NETSPACE_MINI_V2) -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage-ns2l.cfg -#endif - -/* - * mv-common.h should be defined after CMD configs since it used them - * to enable certain macros - */ #include "mv-common.h" /* Remove or override few declarations from mv-common.h */ @@ -70,7 +41,6 @@ /* * Enable GPI0 support */ -#define CONFIG_KIRKWOOD_GPIO /* * Enable I2C support @@ -97,9 +67,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND \ - "dhcp && run netconsole; " \ - "if run usbload || run diskload; then bootm; fi" #define CONFIG_EXTRA_ENV_SETTINGS \ "stdin=serial\0" \ diff --git a/include/configs/lager.h b/include/configs/lager.h index c5001e3ec75..4c291aa89be 100644 --- a/include/configs/lager.h +++ b/include/configs/lager.h @@ -31,8 +31,6 @@ #define CONFIG_BITBANGMII_MULTI /* Board Clock */ -#define RMOBILE_XTAL_CLK 20000000u -#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK #define CONFIG_EXTRA_ENV_SETTINGS \ "bootm_size=0x10000000\0" diff --git a/include/configs/legoev3.h b/include/configs/legoev3.h index 69281792019..b912db11d00 100644 --- a/include/configs/legoev3.h +++ b/include/configs/legoev3.h @@ -18,7 +18,6 @@ * SoC Configuration */ #define CONFIG_SYS_EXCEPTION_VECTORS_HIGH -#define CONFIG_SYS_CLK_FREQ clk_get(DAVINCI_ARM_CLKID) #define CONFIG_SYS_OSCIN_FREQ 24000000 #define CONFIG_SYS_TIMERBASE DAVINCI_TIMER0_BASE #define CONFIG_SYS_HZ_CLOCK clk_get(DAVINCI_AUXCLK_CLKID) @@ -61,32 +60,6 @@ #define LINUX_BOOT_PARAM_ADDR (PHYS_SDRAM_1 + 0x100) #define CONFIG_HWCONFIG /* enable hwconfig */ #define CONFIG_SETUP_INITRD_TAG -#define CONFIG_BOOTCOMMAND \ - "if mmc rescan; then " \ - "if run loadbootscr; then " \ - "run bootscript; " \ - "else " \ - "if run loadbootenv; then " \ - "echo Loaded env from ${bootenvfile};" \ - "run importbootenv;" \ - "fi;" \ - "if test -n $uenvcmd; then " \ - "echo Running uenvcmd...;" \ - "run uenvcmd;" \ - "fi;" \ - "if run loadimage; then " \ - "run mmcargs; " \ - "if run loadfdt; then " \ - "echo Using ${fdtfile}...;" \ - "run fdtfixup; " \ - "run fdtboot; "\ - "fi; " \ - "run mmcboot; " \ - "fi; " \ - "fi; " \ - "fi; "\ - "run flashargs; " \ - "run flashboot" #define CONFIG_EXTRA_ENV_SETTINGS \ "bootenvfile=uEnv.txt\0" \ "fdtfile=da850-lego-ev3.dtb\0" \ diff --git a/include/configs/liteboard.h b/include/configs/liteboard.h index d74b2bb9606..3a8dd475b26 100644 --- a/include/configs/liteboard.h +++ b/include/configs/liteboard.h @@ -23,8 +23,6 @@ #define CONFIG_SYS_FSL_ESDHC_ADDR USDHC1_BASE_ADDR #endif -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_EXTRA_ENV_SETTINGS \ "script=boot.scr\0" \ "image=zImage\0" \ @@ -36,7 +34,7 @@ "boot_fdt=try\0" \ "ip_dyn=yes\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ @@ -87,19 +85,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev};" \ - "if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* Miscellaneous configurable options */ /* Physical Memory Map */ diff --git a/include/configs/ls1012a2g5rdb.h b/include/configs/ls1012a2g5rdb.h index 44f9da73063..bda4283ef5a 100644 --- a/include/configs/ls1012a2g5rdb.h +++ b/include/configs/ls1012a2g5rdb.h @@ -14,8 +14,6 @@ #define CONFIG_SYS_SDRAM_SIZE 0x40000000 /* SATA */ -#define CONFIG_LIBATA -#define CONFIG_SCSI_AHCI #define CONFIG_SCSI_AHCI_PLAT #define CONFIG_SYS_SATA AHCI_BASE_ADDR @@ -74,16 +72,10 @@ "$kernelheader_size && esbc_validate ${kernelheader_addr_r}; " \ "bootm $load_addr#$board\0" -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #undef QSPI_NOR_BOOTCOMMAND #define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \ "env exists secureboot && esbc_halt;" -#else -#if defined(CONFIG_QSPI_BOOT) || defined(CONFIG_SD_BOOT_QSPI) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \ - "env exists secureboot && esbc_halt;" -#endif #endif #define DEFAULT_PFE_MDIO_NAME "PFE_MDIO" diff --git a/include/configs/ls1012a_common.h b/include/configs/ls1012a_common.h index 4e654ca14ea..5d561009c56 100644 --- a/include/configs/ls1012a_common.h +++ b/include/configs/ls1012a_common.h @@ -10,8 +10,6 @@ #include <asm/arch/stream_id_lsch2.h> #include <linux/sizes.h> -#define CONFIG_SYS_CLK_FREQ 125000000 - #ifdef CONFIG_TFABOOT #define CONFIG_SYS_INIT_SP_ADDR CONFIG_SYS_TEXT_BASE #else @@ -45,11 +43,6 @@ /* I2C */ /* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif #define CONFIG_SYS_NS16550_SERIAL #define CONFIG_SYS_NS16550_REG_SIZE 1 @@ -78,15 +71,10 @@ "kernel_size=0x2800000\0" \ "bootm_size=0x10000000\0" \ -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #define QSPI_NOR_BOOTCOMMAND "sf probe 0:0; sf read $kernel_load "\ "$kernel_start $kernel_size && "\ "bootm $kernel_load" -#else -#define CONFIG_BOOTCOMMAND "sf probe 0:0; sf read $kernel_load "\ - "$kernel_start $kernel_size && "\ - "bootm $kernel_load" #endif /* Monitor Command Prompt */ diff --git a/include/configs/ls1012afrdm.h b/include/configs/ls1012afrdm.h index 2711f651d71..ef57cf6aaa3 100644 --- a/include/configs/ls1012afrdm.h +++ b/include/configs/ls1012afrdm.h @@ -54,12 +54,9 @@ "sf probe && sf read $load_addr " \ "$kernel_addr $kernel_size && bootm $load_addr#$board\0" -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #undef QSPI_NOR_BOOTCOMMAND #define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd;run qspi_bootcmd" -#else -#define CONFIG_BOOTCOMMAND "run distro_bootcmd;run qspi_bootcmd" #endif #endif /* __LS1012ARDB_H__ */ diff --git a/include/configs/ls1012afrwy.h b/include/configs/ls1012afrwy.h index f8b386125cc..c61865ccd4e 100644 --- a/include/configs/ls1012afrwy.h +++ b/include/configs/ls1012afrwy.h @@ -8,9 +8,6 @@ #include "ls1012a_common.h" -#undef CONFIG_SYS_BOARD -#define CONFIG_SYS_BOARD "ls1012afrwy" - /* Board Rev*/ #define BOARD_REV_A_B 0x0 #define BOARD_REV_C 0x00080000 @@ -92,14 +89,10 @@ " && esbc_validate ${kernelheader_addr_r};" \ "bootm $load_addr#$BOARD\0" -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #undef QSPI_NOR_BOOTCOMMAND #define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd; run sd_bootcmd; "\ "env exists secureboot && esbc_halt;" -#else -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run sd_bootcmd; "\ - "env exists secureboot && esbc_halt;" #endif #include <asm/fsl_secure_boot.h> diff --git a/include/configs/ls1012aqds.h b/include/configs/ls1012aqds.h index a5900f226c9..cbcb3f72a56 100644 --- a/include/configs/ls1012aqds.h +++ b/include/configs/ls1012aqds.h @@ -75,19 +75,16 @@ DSPI_CTAR_PASC(0) | DSPI_CTAR_PDT(0) | \ DSPI_CTAR_CSSCK(2) | DSPI_CTAR_ASC(0) | \ DSPI_CTAR_DT(0)) -#define CONFIG_SPI_FLASH_SST /* cs1 */ #define CONFIG_SYS_DSPI_CTAR2 (DSPI_CTAR_TRSZ(7) | DSPI_CTAR_PCSSCK_1CLK |\ DSPI_CTAR_PASC(0) | DSPI_CTAR_PDT(0) | \ DSPI_CTAR_CSSCK(0) | DSPI_CTAR_ASC(0) | \ DSPI_CTAR_DT(0)) -#define CONFIG_SPI_FLASH_STMICRO /* cs2 */ #define CONFIG_SYS_DSPI_CTAR3 (DSPI_CTAR_TRSZ(7) | DSPI_CTAR_PCSSCK_1CLK |\ DSPI_CTAR_PASC(0) | DSPI_CTAR_PDT(0) | \ DSPI_CTAR_CSSCK(2) | DSPI_CTAR_ASC(0) | \ DSPI_CTAR_DT(0)) -#define CONFIG_SPI_FLASH_EON /* cs3 */ #define CONFIG_PCIE1 /* PCIE controller 1 */ @@ -138,14 +135,10 @@ "$kernelheader_size && esbc_validate ${kernelheader_addr_r}; " \ "bootm $load_addr#$board\0" -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #undef QSPI_NOR_BOOTCOMMAND #define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; "\ "env exists secureboot && esbc_halt;" -#else -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; "\ - "env exists secureboot && esbc_halt;" #endif #include <asm/fsl_secure_boot.h> diff --git a/include/configs/ls1012ardb.h b/include/configs/ls1012ardb.h index c8a2f120dca..c9a152e08a2 100644 --- a/include/configs/ls1012ardb.h +++ b/include/configs/ls1012ardb.h @@ -92,14 +92,10 @@ "$kernelheader_size && esbc_validate ${kernelheader_addr_r}; " \ "bootm $load_addr#$board\0" -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #undef QSPI_NOR_BOOTCOMMAND #define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; "\ "env exists secureboot && esbc_halt;" -#else -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; "\ - "env exists secureboot && esbc_halt;" #endif #include <asm/fsl_secure_boot.h> diff --git a/include/configs/ls1021aiot.h b/include/configs/ls1021aiot.h index 222caa161d0..7b4044fba72 100644 --- a/include/configs/ls1021aiot.h +++ b/include/configs/ls1021aiot.h @@ -9,13 +9,9 @@ #define CONFIG_ARMV7_SECURE_BASE OCRAM_BASE_S_ADDR -#define CONFIG_SYS_FSL_CLK - #define CONFIG_SYS_INIT_RAM_ADDR OCRAM_BASE_ADDR #define CONFIG_SYS_INIT_RAM_SIZE OCRAM_SIZE -#define CONFIG_SYS_CLK_FREQ 100000000 - /* * DDR: 800 MHz ( 1600 MT/s data rate ) */ @@ -48,8 +44,6 @@ #define SDRAM_CFG_BI 0x00000001 #ifdef CONFIG_SD_BOOT -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0xe8 - #define CONFIG_SPL_MAX_SIZE 0x1a000 #define CONFIG_SPL_STACK 0x1001d000 #define CONFIG_SPL_PAD_TO 0x1c000 @@ -100,9 +94,6 @@ CONFIG_SYS_SCSI_MAX_LUN) /* SPI */ -#if defined(CONFIG_QSPI_BOOT) || defined(CONFIG_SD_BOOT_QSPI) -#define CONFIG_SPI_FLASH_SPANSION -#endif /* * eTSEC @@ -174,9 +165,6 @@ #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE #endif -#define CONFIG_OF_BOARD_SETUP -#define CONFIG_OF_STDOUT_VIA_ALIAS - #include <asm/fsl_secure_boot.h> #endif diff --git a/include/configs/ls1021aqds.h b/include/configs/ls1021aqds.h index 27b97ffd2fb..7edb5c61808 100644 --- a/include/configs/ls1021aqds.h +++ b/include/configs/ls1021aqds.h @@ -9,22 +9,13 @@ #define CONFIG_ARMV7_SECURE_BASE OCRAM_BASE_S_ADDR -#define CONFIG_SYS_FSL_CLK - #define CONFIG_DEEP_SLEEP #define CONFIG_SYS_INIT_RAM_ADDR OCRAM_BASE_ADDR #define CONFIG_SYS_INIT_RAM_SIZE OCRAM_SIZE -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - #if defined(CONFIG_QSPI_BOOT) || defined(CONFIG_SD_BOOT_QSPI) -#define CONFIG_SYS_CLK_FREQ 100000000 #define CONFIG_QIXIS_I2C_ACCESS -#else -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() #endif #ifdef CONFIG_SD_BOOT @@ -76,7 +67,6 @@ unsigned long get_board_sys_clk(void); * IFC Definitions */ #if !defined(CONFIG_QSPI_BOOT) && !defined(CONFIG_SD_BOOT_QSPI) -#define CONFIG_FSL_IFC #define CONFIG_SYS_FLASH_BASE 0x60000000 #define CONFIG_SYS_FLASH_BASE_PHYS CONFIG_SYS_FLASH_BASE @@ -298,11 +288,6 @@ unsigned long get_board_sys_clk(void); */ /* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif /* EEPROM */ #define CONFIG_SYS_I2C_EEPROM_NXID @@ -323,7 +308,6 @@ unsigned long get_board_sys_clk(void); * Video */ #ifdef CONFIG_VIDEO_FSL_DCU_FB -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_FSL_DIU_CH7301 diff --git a/include/configs/ls1021atsn.h b/include/configs/ls1021atsn.h index f70b6e94c07..5f6c2a00370 100644 --- a/include/configs/ls1021atsn.h +++ b/include/configs/ls1021atsn.h @@ -8,8 +8,6 @@ #define CONFIG_ARMV7_SECURE_BASE OCRAM_BASE_S_ADDR -#define CONFIG_SYS_FSL_CLK - #define CONFIG_DEEP_SLEEP #define CONFIG_SYS_INIT_RAM_ADDR OCRAM_BASE_ADDR @@ -18,8 +16,6 @@ /* XHCI Support - enabled by default */ #define CONFIG_USB_MAX_CONTROLLER_COUNT 1 -#define CONFIG_SYS_CLK_FREQ 100000000 - #define DDR_SDRAM_CFG 0x470c0008 #define DDR_CS0_BNDS 0x008000bf #define DDR_CS0_CONFIG 0x80014302 @@ -75,7 +71,6 @@ #endif /* ifdef CONFIG_U_BOOT_HDR_SIZE */ #endif -#define CONFIG_NR_DRAM_BANKS 1 #define PHYS_SDRAM 0x80000000 #define PHYS_SDRAM_SIZE (1u * 1024 * 1024 * 1024) diff --git a/include/configs/ls1021atwr.h b/include/configs/ls1021atwr.h index c099629607f..d4c6f4fcf85 100644 --- a/include/configs/ls1021atwr.h +++ b/include/configs/ls1021atwr.h @@ -9,15 +9,11 @@ #define CONFIG_ARMV7_SECURE_BASE OCRAM_BASE_S_ADDR -#define CONFIG_SYS_FSL_CLK - #define CONFIG_DEEP_SLEEP #define CONFIG_SYS_INIT_RAM_ADDR OCRAM_BASE_ADDR #define CONFIG_SYS_INIT_RAM_SIZE OCRAM_SIZE -#define CONFIG_SYS_CLK_FREQ 100000000 - #define DDR_SDRAM_CFG 0x470c0008 #define DDR_CS0_BNDS 0x008000bf #define DDR_CS0_CONFIG 0x80014302 @@ -89,7 +85,6 @@ * IFC Definitions */ #if !defined(CONFIG_QSPI_BOOT) && !defined(CONFIG_SD_BOOT_QSPI) -#define CONFIG_FSL_IFC #define CONFIG_SYS_FLASH_BASE 0x60000000 #define CONFIG_SYS_FLASH_BASE_PHYS CONFIG_SYS_FLASH_BASE @@ -191,11 +186,6 @@ */ /* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif /* EEPROM */ #define CONFIG_SYS_I2C_EEPROM_NXID @@ -209,7 +199,6 @@ * Video */ #ifdef CONFIG_VIDEO_FSL_DCU_FB -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_FSL_DCU_SII9022A @@ -378,18 +367,6 @@ "bootm $load_addr#$board\0" #endif -#undef CONFIG_BOOTCOMMAND -#if defined(CONFIG_QSPI_BOOT) || defined(CONFIG_SD_BOOT_QSPI) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \ - "env exists secureboot && esbc_halt" -#elif defined(CONFIG_SD_BOOT) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run sd_bootcmd; " \ - "env exists secureboot && esbc_halt;" -#else -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run nor_bootcmd;" \ - "env exists secureboot && esbc_halt;" -#endif - /* * Miscellaneous configurable options */ diff --git a/include/configs/ls1028a_common.h b/include/configs/ls1028a_common.h index 1401264f931..f47bc739843 100644 --- a/include/configs/ls1028a_common.h +++ b/include/configs/ls1028a_common.h @@ -7,7 +7,6 @@ #define __L1028A_COMMON_H #define CONFIG_REMAKE_ELF -#define CONFIG_MP #include <asm/arch/stream_id_lsch3.h> #include <asm/arch/config.h> @@ -32,11 +31,6 @@ #define COUNTER_FREQUENCY 25000000 /* 25MHz */ /* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif /* I2C */ @@ -60,8 +54,6 @@ func(DHCP, dhcp, na) #include <config_distro_bootcmd.h> -#undef CONFIG_BOOTCOMMAND - #define XSPI_NOR_BOOTCOMMAND \ "run xspi_hdploadcmd; run distro_bootcmd; run xspi_bootcmd; " \ "env exists secureboot && esbc_halt;;" diff --git a/include/configs/ls1028aqds.h b/include/configs/ls1028aqds.h index fe20363e690..8e3bd7790fe 100644 --- a/include/configs/ls1028aqds.h +++ b/include/configs/ls1028aqds.h @@ -8,8 +8,7 @@ #include "ls1028a_common.h" -#define CONFIG_SYS_CLK_FREQ 100000000 -#define COUNTER_FREQUENCY_REAL (CONFIG_SYS_CLK_FREQ / 4) +#define COUNTER_FREQUENCY_REAL (get_board_sys_clk() / 4) /* DDR */ #define CONFIG_DIMM_SLOTS_PER_CTLR 2 diff --git a/include/configs/ls1028ardb.h b/include/configs/ls1028ardb.h index 348db1e2f8c..5ce9ebbae93 100644 --- a/include/configs/ls1028ardb.h +++ b/include/configs/ls1028ardb.h @@ -8,8 +8,7 @@ #include "ls1028a_common.h" -#define CONFIG_SYS_CLK_FREQ 100000000 -#define COUNTER_FREQUENCY_REAL (CONFIG_SYS_CLK_FREQ / 4) +#define COUNTER_FREQUENCY_REAL (get_board_sys_clk() / 4) #define CONFIG_SYS_RTC_BUS_NUM 0 diff --git a/include/configs/ls1043a_common.h b/include/configs/ls1043a_common.h index bdf1b434aca..3b4f822ecff 100644 --- a/include/configs/ls1043a_common.h +++ b/include/configs/ls1043a_common.h @@ -112,17 +112,11 @@ #endif /* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif /* IFC */ #ifndef SPL_NO_IFC #if defined(CONFIG_TFABOOT) || \ (!defined(CONFIG_QSPI_BOOT) && !defined(CONFIG_SD_BOOT_QSPI)) -#define CONFIG_FSL_IFC /* * CONFIG_SYS_FLASH_BASE has the final address (core view) * CONFIG_SYS_FLASH_BASE_PHYS has the final address (IFC view) @@ -154,13 +148,6 @@ #endif /* DSPI */ -#ifndef SPL_NO_DSPI -#ifdef CONFIG_FSL_DSPI -#define CONFIG_SPI_FLASH_STMICRO /* cs0 */ -#define CONFIG_SPI_FLASH_SST /* cs1 */ -#define CONFIG_SPI_FLASH_EON /* cs2 */ -#endif -#endif /* FMan ucode */ #ifndef SPL_NO_FMAN @@ -261,7 +248,6 @@ "bootm $load_addr#$board\0" -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \ "env exists secureboot && esbc_halt;" @@ -271,17 +257,6 @@ "env exists secureboot && esbc_halt;" #define IFC_NAND_BOOTCOMMAND "run distro_bootcmd; run nand_bootcmd; " \ "env exists secureboot && esbc_halt;" -#else -#if defined(CONFIG_QSPI_BOOT) || defined(CONFIG_SD_BOOT_QSPI) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \ - "env exists secureboot && esbc_halt;" -#elif defined(CONFIG_SD_BOOT) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run sd_bootcmd; " \ - "env exists secureboot && esbc_halt;" -#else -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run nor_bootcmd; " \ - "env exists secureboot && esbc_halt;" -#endif #endif #endif diff --git a/include/configs/ls1043aqds.h b/include/configs/ls1043aqds.h index ee5660571e5..80eff7b1a90 100644 --- a/include/configs/ls1043aqds.h +++ b/include/configs/ls1043aqds.h @@ -8,12 +8,6 @@ #include "ls1043a_common.h" -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() - #define CONFIG_LAYERSCAPE_NS_ACCESS #define CONFIG_DIMM_SLOTS_PER_CTLR 1 @@ -330,12 +324,6 @@ unsigned long get_board_sys_clk(void); #define I2C_VOL_MONITOR_BUS_V_OVF 0x1 #define I2C_VOL_MONITOR_BUS_V_SHIFT 3 -#define CONFIG_VID_FLS_ENV "ls1043aqds_vdd_mv" -#ifndef CONFIG_SPL_BUILD -#define CONFIG_VID -#endif -#define CONFIG_VOL_MONITOR_IR36021_SET -#define CONFIG_VOL_MONITOR_INA220 /* The lowest and highest voltage allowed for LS1043AQDS */ #define VDD_MV_MIN 819 #define VDD_MV_MAX 1212 diff --git a/include/configs/ls1043ardb.h b/include/configs/ls1043ardb.h index 0d071c4ab74..7b6d19374e7 100644 --- a/include/configs/ls1043ardb.h +++ b/include/configs/ls1043ardb.h @@ -8,8 +8,6 @@ #include "ls1043a_common.h" -#define CONFIG_SYS_CLK_FREQ 100000000 - #define CONFIG_LAYERSCAPE_NS_ACCESS #define CONFIG_DIMM_SLOTS_PER_CTLR 1 diff --git a/include/configs/ls1046a_common.h b/include/configs/ls1046a_common.h index 515f4209bb9..d07d27d1f5c 100644 --- a/include/configs/ls1046a_common.h +++ b/include/configs/ls1046a_common.h @@ -110,11 +110,6 @@ #endif /* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif /* I2C */ diff --git a/include/configs/ls1046afrwy.h b/include/configs/ls1046afrwy.h index 5b78c5f7ab6..14ad84a1ef4 100644 --- a/include/configs/ls1046afrwy.h +++ b/include/configs/ls1046afrwy.h @@ -8,8 +8,6 @@ #include "ls1046a_common.h" -#define CONFIG_SYS_CLK_FREQ 100000000 - #define CONFIG_LAYERSCAPE_NS_ACCESS #define CONFIG_DIMM_SLOTS_PER_CTLR 1 @@ -17,8 +15,6 @@ #define CONFIG_SYS_UBOOT_BASE 0x40100000 -/* IFC */ -#define CONFIG_FSL_IFC /* * NAND Flash Definitions */ @@ -109,7 +105,6 @@ #endif -#undef CONFIG_BOOTCOMMAND #define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \ "env exists secureboot && esbc_halt;;" #define SD_BOOTCOMMAND "run distro_bootcmd;run sd_bootcmd; " \ diff --git a/include/configs/ls1046aqds.h b/include/configs/ls1046aqds.h index 8bc09d00668..97bf4182be1 100644 --- a/include/configs/ls1046aqds.h +++ b/include/configs/ls1046aqds.h @@ -8,12 +8,6 @@ #include "ls1046a_common.h" -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() - #define CONFIG_LAYERSCAPE_NS_ACCESS #define CONFIG_DIMM_SLOTS_PER_CTLR 1 @@ -43,7 +37,6 @@ unsigned long get_board_sys_clk(void); /* IFC */ #if !defined(CONFIG_QSPI_BOOT) && !defined(CONFIG_SD_BOOT_QSPI) -#define CONFIG_FSL_IFC /* * CONFIG_SYS_FLASH_BASE has the final address (core view) * CONFIG_SYS_FLASH_BASE_PHYS has the final address (IFC view) @@ -339,12 +332,6 @@ unsigned long get_board_sys_clk(void); #define I2C_VOL_MONITOR_BUS_V_OVF 0x1 #define I2C_VOL_MONITOR_BUS_V_SHIFT 3 -#define CONFIG_VID_FLS_ENV "ls1046aqds_vdd_mv" -#ifndef CONFIG_SPL_BUILD -#define CONFIG_VID -#endif -#define CONFIG_VOL_MONITOR_IR36021_SET -#define CONFIG_VOL_MONITOR_INA220 /* The lowest and highest voltage allowed for LS1046AQDS */ #define VDD_MV_MIN 819 #define VDD_MV_MAX 1212 @@ -362,7 +349,6 @@ unsigned long get_board_sys_clk(void); * Environment */ -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #define IFC_NAND_BOOTCOMMAND "run distro_bootcmd; run nand_bootcmd; " \ "env exists secureboot && esbc_halt;;" @@ -372,20 +358,6 @@ unsigned long get_board_sys_clk(void); "env exists secureboot && esbc_halt;;" #define SD_BOOTCOMMAND "run distro_bootcmd; run sd_bootcmd; " \ "env exists secureboot && esbc_halt;;" -#else -#if defined(CONFIG_QSPI_BOOT) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run nor_bootcmd; " \ - "env exists secureboot && esbc_halt;;" -#elif defined(CONFIG_NAND_BOOT) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run nand_bootcmd; " \ - "env exists secureboot && esbc_halt;;" -#elif defined(CONFIG_SD_BOOT) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run sd_bootcmd; " \ - "env exists secureboot && esbc_halt;;" -#else -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run nor_bootcmd; " \ - "env exists secureboot && esbc_halt;;" -#endif #endif #include <asm/fsl_secure_boot.h> diff --git a/include/configs/ls1046ardb.h b/include/configs/ls1046ardb.h index d06f3380a78..8ed1dceb234 100644 --- a/include/configs/ls1046ardb.h +++ b/include/configs/ls1046ardb.h @@ -9,8 +9,6 @@ #include "ls1046a_common.h" -#define CONFIG_SYS_CLK_FREQ 100000000 - #define CONFIG_LAYERSCAPE_NS_ACCESS #define CONFIG_DIMM_SLOTS_PER_CTLR 1 @@ -27,14 +25,6 @@ #define CONFIG_SYS_SPL_ARGS_ADDR 0x90000000 #endif -#ifndef SPL_NO_IFC -/* IFC */ -#define CONFIG_FSL_IFC -/* - * NAND Flash Definitions - */ -#endif - #define CONFIG_SYS_NAND_BASE 0x7e800000 #define CONFIG_SYS_NAND_BASE_PHYS CONFIG_SYS_NAND_BASE @@ -145,20 +135,11 @@ #endif #ifndef SPL_NO_MISC -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \ "env exists secureboot && esbc_halt;;" #define SD_BOOTCOMMAND "run distro_bootcmd;run sd_bootcmd; " \ "env exists secureboot && esbc_halt;" -#else -#if defined(CONFIG_QSPI_BOOT) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \ - "env exists secureboot && esbc_halt;;" -#elif defined(CONFIG_SD_BOOT) -#define CONFIG_BOOTCOMMAND "run distro_bootcmd;run sd_bootcmd; " \ - "env exists secureboot && esbc_halt;" -#endif #endif #endif diff --git a/include/configs/ls1088a_common.h b/include/configs/ls1088a_common.h index c816ee16f2a..2e52108c23e 100644 --- a/include/configs/ls1088a_common.h +++ b/include/configs/ls1088a_common.h @@ -49,11 +49,6 @@ #define CPU_RELEASE_ADDR secondary_boot_addr /* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif /* I2C */ @@ -63,11 +58,6 @@ #define CONFIG_SYS_NS16550_REG_SIZE 1 #define CONFIG_SYS_NS16550_CLK (get_bus_freq(0) / 2) -#if !defined(SPL_NO_IFC) || defined(CONFIG_TARGET_LS1088AQDS) -/* IFC */ -#define CONFIG_FSL_IFC -#endif - /* * During booting, IFC is mapped at the region of 0x30000000. * But this region is limited to 256MB. To accommodate NOR, promjet @@ -173,25 +163,6 @@ unsigned long long get_qixis_addr(void); "console=ttyAMA0,38400n8\0" \ "mcinitcmd=fsl_mc start mc 0x580a00000" \ " 0x580e00000 \0" - -#ifndef CONFIG_TFABOOT -#if defined(CONFIG_QSPI_BOOT) -#define CONFIG_BOOTCOMMAND "sf probe 0:0;" \ - "sf read 0x80001000 0xd00000 0x100000;"\ - " fsl_mc lazyapply dpl 0x80001000 &&" \ - " sf read $kernel_load $kernel_start" \ - " $kernel_size && bootm $kernel_load" -#elif defined(CONFIG_SD_BOOT) -#define CONFIG_BOOTCOMMAND "mmcinfo;mmc read 0x80001000 0x6800 0x800;"\ - " fsl_mc lazyapply dpl 0x80001000 &&" \ - " mmc read $kernel_load $kernel_start" \ - " $kernel_size && bootm $kernel_load" -#else /* NOR BOOT*/ -#define CONFIG_BOOTCOMMAND "fsl_mc lazyapply dpl 0x580d00000 &&" \ - " cp.b $kernel_start $kernel_load" \ - " $kernel_size && bootm $kernel_load" -#endif -#endif /* CONFIG_TFABOOT */ #endif /* Monitor Command Prompt */ diff --git a/include/configs/ls1088aqds.h b/include/configs/ls1088aqds.h index d001acfd68a..5912fe95ccf 100644 --- a/include/configs/ls1088aqds.h +++ b/include/configs/ls1088aqds.h @@ -8,22 +8,14 @@ #include "ls1088a_common.h" - -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - #if defined(CONFIG_QSPI_BOOT) || defined(CONFIG_SD_BOOT_QSPI) #define CONFIG_QIXIS_I2C_ACCESS #define SYS_NO_FLASH - -#define CONFIG_SYS_CLK_FREQ 100000000 #else #define CONFIG_QIXIS_I2C_ACCESS -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() #endif -#define COUNTER_FREQUENCY_REAL (CONFIG_SYS_CLK_FREQ/4) +#define COUNTER_FREQUENCY_REAL (get_board_sys_clk()/4) #define COUNTER_FREQUENCY 25000000 /* 25MHz */ #define CONFIG_DIMM_SLOTS_PER_CTLR 1 @@ -298,16 +290,10 @@ unsigned long get_board_sys_clk(void); #define I2C_VOL_MONITOR_BUS_V_SHIFT 3 #define I2C_SVDD_MONITOR_ADDR 0x4F -#define CONFIG_VID_FLS_ENV "ls1088aqds_vdd_mv" -#define CONFIG_VID - /* The lowest and highest voltage allowed for LS1088AQDS */ #define VDD_MV_MIN 819 #define VDD_MV_MAX 1212 -#define CONFIG_VOL_MONITOR_LTC3882_SET -#define CONFIG_VOL_MONITOR_LTC3882_READ - #define PWM_CHANNEL0 0x0 /* @@ -321,9 +307,6 @@ unsigned long get_board_sys_clk(void); #define CONFIG_SYS_EEPROM_BUS_NUM 0 #ifdef CONFIG_FSL_DSPI -#define CONFIG_SPI_FLASH_STMICRO -#define CONFIG_SPI_FLASH_SST -#define CONFIG_SPI_FLASH_EON #if !defined(CONFIG_TFABOOT) && \ !defined(CONFIG_QSPI_BOOT) && !defined(CONFIG_SD_BOOT_QSPI) #endif diff --git a/include/configs/ls1088ardb.h b/include/configs/ls1088ardb.h index 6ad1fea3c83..400b8adb24c 100644 --- a/include/configs/ls1088ardb.h +++ b/include/configs/ls1088ardb.h @@ -16,7 +16,6 @@ #define SYS_NO_FLASH #endif -#define CONFIG_SYS_CLK_FREQ 100000000 #define COUNTER_FREQUENCY_REAL 25000000 /* 25MHz */ #define COUNTER_FREQUENCY 25000000 /* 25MHz */ @@ -197,16 +196,10 @@ #define I2C_VOL_MONITOR_BUS_V_SHIFT 3 #define I2C_SVDD_MONITOR_ADDR 0x4F -#define CONFIG_VID_FLS_ENV "ls1088ardb_vdd_mv" -#define CONFIG_VID - /* The lowest and highest voltage allowed for LS1088ARDB */ #define VDD_MV_MIN 819 #define VDD_MV_MAX 1212 -#define CONFIG_VOL_MONITOR_LTC3882_SET -#define CONFIG_VOL_MONITOR_LTC3882_READ - #define PWM_CHANNEL0 0x0 /* @@ -424,7 +417,6 @@ "bootm $load_addr#$BOARD\0" #endif /* CONFIG_TFABOOT */ -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_TFABOOT #define QSPI_NOR_BOOTCOMMAND \ "sf read 0x80001000 0xd00000 0x100000;" \ @@ -446,26 +438,8 @@ #else #if defined(CONFIG_QSPI_BOOT) /* Try to boot an on-QSPI kernel first, then do normal distro boot */ -#define CONFIG_BOOTCOMMAND \ - "sf read 0x80001000 0xd00000 0x100000;" \ - "env exists mcinitcmd && env exists secureboot " \ - " && sf read 0x806C0000 0x6C0000 0x100000 " \ - "&& esbc_validate 0x806C0000;env exists mcinitcmd " \ - "&& fsl_mc lazyapply dpl 0x80001000;" \ - "run distro_bootcmd;run qspi_bootcmd;" \ - "env exists secureboot && esbc_halt;" /* Try to boot an on-SD kernel first, then do normal distro boot */ -#elif defined(CONFIG_SD_BOOT) -#define CONFIG_BOOTCOMMAND \ - "env exists mcinitcmd && mmcinfo; " \ - "mmc read 0x80001000 0x6800 0x800; " \ - "env exists mcinitcmd && env exists secureboot " \ - " && mmc read 0x806C0000 0x3600 0x20 " \ - "&& esbc_validate 0x806C0000;env exists mcinitcmd " \ - "&& fsl_mc lazyapply dpl 0x80001000;" \ - "run distro_bootcmd;run sd_bootcmd;" \ - "env exists secureboot && esbc_halt;" #endif #endif /* CONFIG_TFABOOT */ diff --git a/include/configs/ls2080a_common.h b/include/configs/ls2080a_common.h index 6d9ae9d987e..eea6ce53db5 100644 --- a/include/configs/ls2080a_common.h +++ b/include/configs/ls2080a_common.h @@ -61,11 +61,6 @@ #define COUNTER_FREQUENCY 25000000 /* 25MHz */ /* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif /* I2C */ @@ -74,9 +69,6 @@ #define CONFIG_SYS_NS16550_REG_SIZE 1 #define CONFIG_SYS_NS16550_CLK (get_serial_clock()) -/* IFC */ -#define CONFIG_FSL_IFC - /* * During booting, IFC is mapped at the region of 0x30000000. * But this region is limited to 256MB. To accommodate NOR, promjet @@ -170,19 +162,6 @@ unsigned long long get_qixis_addr(void); "mcinitcmd=fsl_mc start mc 0x580a00000" \ " 0x580e00000 \0" -#ifndef CONFIG_TFABOOT -#ifdef CONFIG_SD_BOOT -#define CONFIG_BOOTCOMMAND "mmc read 0x80200000 0x6800 0x800;"\ - " fsl_mc apply dpl 0x80200000 &&" \ - " mmc read $kernel_load $kernel_start" \ - " $kernel_size && bootm $kernel_load" -#else -#define CONFIG_BOOTCOMMAND "fsl_mc apply dpl 0x580d00000 &&" \ - " cp.b $kernel_start $kernel_load" \ - " $kernel_size && bootm $kernel_load" -#endif -#endif - /* Monitor Command Prompt */ #define CONFIG_SYS_CBSIZE 512 /* Console I/O Buffer Size */ #define CONFIG_SYS_MAXARGS 64 /* max command args */ diff --git a/include/configs/ls2080aqds.h b/include/configs/ls2080aqds.h index e67dee0f00b..b0a05dd8071 100644 --- a/include/configs/ls2080aqds.h +++ b/include/configs/ls2080aqds.h @@ -9,18 +9,13 @@ #include "ls2080a_common.h" -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - #ifdef CONFIG_FSL_QSPI #define CONFIG_QIXIS_I2C_ACCESS #define CONFIG_SYS_I2C_IFDR_DIV 0x7e #endif #define CONFIG_SYS_I2C_FPGA_ADDR 0x66 -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() -#define COUNTER_FREQUENCY_REAL (CONFIG_SYS_CLK_FREQ/4) +#define COUNTER_FREQUENCY_REAL (get_board_sys_clk()/4) #define CONFIG_MEM_INIT_VALUE 0xdeadbeef #define SPD_EEPROM_ADDRESS1 0x51 @@ -256,15 +251,7 @@ unsigned long get_board_sys_clk(void); #define I2C_MUX_CH_DEFAULT 0x8 /* SPI */ -#ifdef CONFIG_FSL_DSPI -#define CONFIG_SPI_FLASH_STMICRO -#define CONFIG_SPI_FLASH_SST -#define CONFIG_SPI_FLASH_EON -#endif -#ifdef CONFIG_FSL_QSPI -#define CONFIG_SPI_FLASH_SPANSION -#endif /* * Verify QSPI when boot from NAND, QIXIS brdcfg9 need configure. * If boot from on-board NAND, ISO1 = 1, ISO2 = 0, IBOOT = 0 @@ -285,9 +272,7 @@ unsigned long get_board_sys_clk(void); */ #define RTC #define CONFIG_RTC_DS3231 1 -#define CONFIG_RTC_ENABLE_32KHZ_OUTPUT #define CONFIG_SYS_I2C_RTC_ADDR 0x68 -#define CONFIG_RTC_ENABLE_32KHZ_OUTPUT /* EEPROM */ #define CONFIG_SYS_I2C_EEPROM_NXID diff --git a/include/configs/ls2080ardb.h b/include/configs/ls2080ardb.h index 54fab54609e..a54387e16ca 100644 --- a/include/configs/ls2080ardb.h +++ b/include/configs/ls2080ardb.h @@ -17,13 +17,7 @@ #define I2C_MUX_CH_VOL_MONITOR 0xa #define I2C_VOL_MONITOR_ADDR 0x38 -#define CONFIG_VOL_MONITOR_IR36021_READ -#define CONFIG_VOL_MONITOR_IR36021_SET -#define CONFIG_VID_FLS_ENV "ls2080ardb_vdd_mv" -#ifndef CONFIG_SPL_BUILD -#define CONFIG_VID -#endif /* step the IR regulator in 5mV increments */ #define IR_VDD_STEP_DOWN 5 #define IR_VDD_STEP_UP 5 @@ -31,12 +25,7 @@ #define VDD_MV_MIN 819 #define VDD_MV_MAX 1212 -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() -#define COUNTER_FREQUENCY_REAL (CONFIG_SYS_CLK_FREQ/4) +#define COUNTER_FREQUENCY_REAL (get_board_sys_clk()/4) #define CONFIG_MEM_INIT_VALUE 0xdeadbeef #define SPD_EEPROM_ADDRESS1 0x51 @@ -258,9 +247,6 @@ unsigned long get_board_sys_clk(void); #define I2C_MUX_CH_DEFAULT 0x8 /* SPI */ -#if defined(CONFIG_FSL_DSPI) -#define CONFIG_SPI_FLASH_STMICRO -#endif /* * RTC configuration @@ -507,38 +493,12 @@ unsigned long get_board_sys_clk(void); "run distro_bootcmd;run nor_bootcmd; " \ "env exists secureboot && esbc_halt;" #else -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_QSPI_BOOT /* Try to boot an on-QSPI kernel first, then do normal distro boot */ -#define CONFIG_BOOTCOMMAND \ - "sf probe 0:0; " \ - "sf read 0x806c0000 0x6c0000 0x40000; " \ - "env exists mcinitcmd && env exists secureboot "\ - "&& esbc_validate 0x806C0000; " \ - "sf read 0x80d00000 0xd00000 0x100000; " \ - "env exists mcinitcmd && " \ - "fsl_mc lazyapply dpl 0x80d00000; " \ - "run distro_bootcmd;run qspi_bootcmd; " \ - "env exists secureboot && esbc_halt;" #elif defined(CONFIG_SD_BOOT) /* Try to boot an on-SD kernel first, then do normal distro boot */ -#define CONFIG_BOOTCOMMAND \ - "env exists mcinitcmd && env exists secureboot "\ - "&& mmcinfo && mmc read $load_addr 0x3600 0x800 " \ - "&& esbc_validate $load_addr; " \ - "env exists mcinitcmd && run mcinitcmd " \ - "&& mmc read 0x88000000 0x6800 0x800 " \ - "&& fsl_mc lazyapply dpl 0x88000000; " \ - "run distro_bootcmd;run sd_bootcmd; " \ - "env exists secureboot && esbc_halt;" #else /* Try to boot an on-NOR kernel first, then do normal distro boot */ -#define CONFIG_BOOTCOMMAND \ - "env exists mcinitcmd && env exists secureboot "\ - "&& esbc_validate 0x5806C0000; env exists mcinitcmd "\ - "&& fsl_mc lazyapply dpl 0x580d00000;" \ - "run distro_bootcmd;run nor_bootcmd; " \ - "env exists secureboot && esbc_halt;" #endif #endif diff --git a/include/configs/lsxl.h b/include/configs/lsxl.h index 7294a3c20a5..afa0206fb93 100644 --- a/include/configs/lsxl.h +++ b/include/configs/lsxl.h @@ -8,23 +8,8 @@ #define _CONFIG_LSXL_H /* - * Version number information - */ -#if defined(CONFIG_LSCHLV2) -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage-lschl.cfg -#elif defined(CONFIG_LSXHL) -#define CONFIG_SYS_KWD_CONFIG $(CONFIG_BOARDDIR)/kwbimage-lsxhl.cfg -#else -#error "unknown board" -#endif - -/* * General configuration options */ -#define CONFIG_FEROCEON_88FR131 /* CPU Core subversion */ -#define CONFIG_KW88F6281 /* SOC Name */ - -#define CONFIG_KIRKWOOD_GPIO #include "mv-common.h" diff --git a/include/configs/lx2160a_common.h b/include/configs/lx2160a_common.h index 7173fe6ba65..e285109cbba 100644 --- a/include/configs/lx2160a_common.h +++ b/include/configs/lx2160a_common.h @@ -11,14 +11,12 @@ #include <asm/arch/soc.h> #define CONFIG_REMAKE_ELF -#define CONFIG_FSL_TZPC_BP147 #define CONFIG_FSL_MEMAC #define CONFIG_SYS_INIT_SP_ADDR CONFIG_SYS_TEXT_BASE #define CONFIG_SYS_FLASH_BASE 0x20000000 /* DDR */ -#define CONFIG_FSL_DDR_INTERACTIVE /* Interactive debugging */ #define CONFIG_SYS_FSL_DDR_INTLV_256B /* force 256 byte interleaving */ #define CONFIG_VERY_BIG_RAM #define CONFIG_SYS_DDR_SDRAM_BASE 0x80000000UL @@ -38,7 +36,6 @@ #define CONFIG_SYS_SPD_BUS_NUM 0 /* SPD on I2C bus 0 */ #define CONFIG_DIMM_SLOTS_PER_CTLR 2 #define CONFIG_CHIP_SELECTS_PER_CTRL 4 -#define CONFIG_FSL_DDR_BIST /* enable built-in memory test */ #define CONFIG_SYS_MONITOR_LEN (936 * 1024) /* Miscellaneous configurable options */ @@ -107,7 +104,6 @@ /* PCI */ #ifdef CONFIG_PCI -#define CONFIG_SYS_PCI_64BIT #define CONFIG_PCI_SCAN_SHOW #endif @@ -130,19 +126,7 @@ #endif #endif -/* GPIO */ -#ifdef CONFIG_DM_GPIO -#ifndef CONFIG_MPC8XXX_GPIO -#define CONFIG_MPC8XXX_GPIO -#endif -#endif - -#ifndef __ASSEMBLY__ -unsigned long get_board_sys_clk(void); -#endif - -#define CONFIG_SYS_CLK_FREQ get_board_sys_clk() -#define COUNTER_FREQUENCY_REAL (CONFIG_SYS_CLK_FREQ / 4) +#define COUNTER_FREQUENCY_REAL (get_board_sys_clk() / 4) #define CONFIG_HWCONFIG #define HWCONFIG_BUFFER_SIZE 128 diff --git a/include/configs/lx2160aqds.h b/include/configs/lx2160aqds.h index a04bbb6e6eb..a07ebeb7233 100644 --- a/include/configs/lx2160aqds.h +++ b/include/configs/lx2160aqds.h @@ -8,12 +8,6 @@ #include "lx2160a_common.h" -/* VID */ -#define CONFIG_VID_FLS_ENV "lx2160aqds_vdd_mv" -#define CONFIG_VID -#define CONFIG_VOL_MONITOR_LTC3882_SET -#define CONFIG_VOL_MONITOR_LTC3882_READ - /* RTC */ #define CONFIG_SYS_RTC_BUS_NUM 0 diff --git a/include/configs/lx2160ardb.h b/include/configs/lx2160ardb.h index 4fd3e548309..a8a9f8259eb 100644 --- a/include/configs/lx2160ardb.h +++ b/include/configs/lx2160ardb.h @@ -8,12 +8,6 @@ #include "lx2160a_common.h" -/* VID */ -#define CONFIG_VID_FLS_ENV "lx2160ardb_vdd_mv" -#define CONFIG_VID -#define CONFIG_VOL_MONITOR_LTC3882_SET -#define CONFIG_VOL_MONITOR_LTC3882_READ - /* RTC */ #define CONFIG_SYS_RTC_BUS_NUM 4 diff --git a/include/configs/lx2162aqds.h b/include/configs/lx2162aqds.h index 67c469c0090..c2fa5794c8a 100644 --- a/include/configs/lx2162aqds.h +++ b/include/configs/lx2162aqds.h @@ -12,12 +12,6 @@ #undef CONFIG_USB_MAX_CONTROLLER_COUNT #define CONFIG_USB_MAX_CONTROLLER_COUNT 1 -/* Voltage monitor on channel 2*/ -#define CONFIG_VID_FLS_ENV "lx2162aqds_vdd_mv" -#define CONFIG_VID -#define CONFIG_VOL_MONITOR_LTC3882_SET -#define CONFIG_VOL_MONITOR_LTC3882_READ - /* RTC */ #define CONFIG_SYS_RTC_BUS_NUM 0 diff --git a/include/configs/m53menlo.h b/include/configs/m53menlo.h index f94cf28b135..6eb5ec955b3 100644 --- a/include/configs/m53menlo.h +++ b/include/configs/m53menlo.h @@ -11,8 +11,6 @@ #include <asm/arch/imx-regs.h> -#define CONFIG_SYS_FSL_CLK - #define CONFIG_TIMESTAMP /* Print image info with timestamp */ /* @@ -112,7 +110,6 @@ /* * LCD */ -#define CONFIG_VIDEO_LOGO #define CONFIG_SYS_VIDEO_LOGO_MAX_SIZE (2 << 20) /* LVDS display */ @@ -128,7 +125,6 @@ * Boot Linux */ #define CONFIG_BOOTFILE "boot/fitImage" -#define CONFIG_BOOTCOMMAND "run mmc_mmc" /* * NAND SPL @@ -205,9 +201,4 @@ "fi ; " \ "fi\0" -#if defined(CONFIG_SPL_BUILD) -#undef CONFIG_WATCHDOG -#define CONFIG_HW_WATCHDOG -#endif - #endif /* __M53MENLO_CONFIG_H__ */ diff --git a/include/configs/maxbcm.h b/include/configs/maxbcm.h index 53ba64909e1..073c5a57b2c 100644 --- a/include/configs/maxbcm.h +++ b/include/configs/maxbcm.h @@ -48,7 +48,7 @@ /* SPL */ /* Defines for SPL */ -#define CONFIG_SPL_MAX_SIZE ((128 << 10) - 0x4030) +#define CONFIG_SPL_MAX_SIZE ((128 << 10) - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + (128 << 10)) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/medcom-wide.h b/include/configs/medcom-wide.h index 84b998e23af..b35ba59aba9 100644 --- a/include/configs/medcom-wide.h +++ b/include/configs/medcom-wide.h @@ -19,7 +19,6 @@ #define CONFIG_SYS_NS16550_COM1 NV_PA_APB_UARTD_BASE /* NAND support */ -#define CONFIG_TEGRA_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 /* Environment in NAND, aligned to start of last sector */ diff --git a/include/configs/meson64.h b/include/configs/meson64.h index cb202d55556..44f2967fc6b 100644 --- a/include/configs/meson64.h +++ b/include/configs/meson64.h @@ -29,7 +29,6 @@ #define STDIN_CFG "serial" #endif -#define CONFIG_CPU_ARMV8 #define CONFIG_REMAKE_ELF #define CONFIG_SYS_MAXARGS 32 #define CONFIG_SYS_CBSIZE 1024 diff --git a/include/configs/meson64_android.h b/include/configs/meson64_android.h index 7cd1ab03411..0303d187dec 100644 --- a/include/configs/meson64_android.h +++ b/include/configs/meson64_android.h @@ -23,6 +23,10 @@ #define CONTROL_PARTITION "misc" #endif +#ifndef EXTRA_ANDROID_ENV_SETTINGS +#define EXTRA_ANDROID_ENV_SETTINGS "" +#endif + #if defined(CONFIG_CMD_AVB) #define AVB_VERIFY_CHECK \ "if test \"${force_avb}\" -eq 1; then " \ @@ -100,6 +104,12 @@ "elif test $board_name = sei610; then " \ "echo \" Reading DTB for sei610...\"; " \ "setenv dtb_index 1;" \ + "elif test $board_name = vim3l; then " \ + "echo \" Reading DTB for vim3l...\"; " \ + "setenv dtb_index 2;" \ + "elif test $board_name = vim3; then " \ + "echo \" Reading DTB for vim3...\"; " \ + "setenv dtb_index 3;" \ "else " \ "echo Error: Android boot is not supported for $board_name; " \ "exit; " \ @@ -113,6 +123,12 @@ "elif test $board_name = sei610; then " \ "echo \" Reading DTBO for sei610...\"; " \ "setenv dtbo_index 1;" \ + "elif test $board_name = vim3l; then " \ + "echo \" Reading DTBO for vim3l...\"; " \ + "setenv dtbo_index 2;" \ + "elif test $board_name = vim3; then " \ + "echo \" Reading DTBO for vim3...\"; " \ + "setenv dtbo_index 3;" \ "else " \ "echo Error: Android boot is not supported for $board_name; " \ "exit; " \ @@ -264,6 +280,7 @@ "fi;" #define CONFIG_EXTRA_ENV_SETTINGS \ + EXTRA_ANDROID_ENV_SETTINGS \ "partitions=" PARTS_DEFAULT "\0" \ "mmcdev=2\0" \ ANDROIDBOOT_GET_CURRENT_SLOT_CMD \ diff --git a/include/configs/mt8183.h b/include/configs/mt8183.h index ebd2b326ade..2b4e976aa1f 100644 --- a/include/configs/mt8183.h +++ b/include/configs/mt8183.h @@ -11,7 +11,6 @@ #include <linux/sizes.h> -#define CONFIG_CPU_ARMV8 #define COUNTER_FREQUENCY 13000000 #define CONFIG_SYS_NS16550_SERIAL diff --git a/include/configs/mt8512.h b/include/configs/mt8512.h index 8882a5a4097..9c443db9f52 100644 --- a/include/configs/mt8512.h +++ b/include/configs/mt8512.h @@ -13,8 +13,6 @@ #define CONFIG_SYS_NONCACHED_MEMORY SZ_1M -#define CONFIG_CPU_ARMV8 - #define COUNTER_FREQUENCY 13000000 #define CONFIG_SYS_BOOTM_LEN SZ_64M diff --git a/include/configs/mt8516.h b/include/configs/mt8516.h index 12840b883de..47132c1db1d 100644 --- a/include/configs/mt8516.h +++ b/include/configs/mt8516.h @@ -11,7 +11,6 @@ #include <linux/sizes.h> -#define CONFIG_CPU_ARMV8 #define COUNTER_FREQUENCY 13000000 #define CONFIG_SYS_NS16550_SERIAL diff --git a/include/configs/mt8518.h b/include/configs/mt8518.h index 593c6a11d74..49ee926b0c9 100644 --- a/include/configs/mt8518.h +++ b/include/configs/mt8518.h @@ -13,8 +13,6 @@ #define CONFIG_SYS_NONCACHED_MEMORY SZ_1M -#define CONFIG_CPU_ARMV8 - #define COUNTER_FREQUENCY 13000000 /* DRAM definition */ diff --git a/include/configs/mv-plug-common.h b/include/configs/mv-plug-common.h deleted file mode 100644 index d38d9872c00..00000000000 --- a/include/configs/mv-plug-common.h +++ /dev/null @@ -1,21 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * (C) Copyright 2009-2015 - * Marvell Semiconductor <www.marvell.com> - */ - -#ifndef _CONFIG_MARVELL_PLUG_H -#define _CONFIG_MARVELL_PLUG_H - -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_KW88F6281 1 /* SOC Name */ - -/* - * mv-common.h should be defined after CMD configs since it used them - * to enable certain macros - */ -#include "mv-common.h" - -#endif /* _CONFIG_MARVELL_PLUG_H */ diff --git a/include/configs/mx23_olinuxino.h b/include/configs/mx23_olinuxino.h index b0c78d3561c..370f0002120 100644 --- a/include/configs/mx23_olinuxino.h +++ b/include/configs/mx23_olinuxino.h @@ -95,18 +95,6 @@ "bootm; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loaduimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* The rest of the configuration is shared */ #include <configs/mxs.h> diff --git a/include/configs/mx23evk.h b/include/configs/mx23evk.h index bccba5cbb17..552bf5ac630 100644 --- a/include/configs/mx23evk.h +++ b/include/configs/mx23evk.h @@ -27,7 +27,6 @@ /* Framebuffer support */ #ifdef CONFIG_DM_VIDEO -#define CONFIG_VIDEO_LOGO #define CONFIG_SYS_VIDEO_LOGO_MAX_SIZE (512 << 10) #endif @@ -78,19 +77,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else " \ - "echo ERR: Fail to boot from MMC; " \ - "fi; " \ - "fi; " \ - "else exit; fi" - /* The rest of the configuration is shared */ #include <configs/mxs.h> diff --git a/include/configs/mx28evk.h b/include/configs/mx28evk.h index fe4ea8997d4..caad95b7271 100644 --- a/include/configs/mx28evk.h +++ b/include/configs/mx28evk.h @@ -41,7 +41,6 @@ /* Framebuffer support */ #ifdef CONFIG_DM_VIDEO -#define CONFIG_VIDEO_LOGO #define CONFIG_SYS_VIDEO_LOGO_MAX_SIZE (512 << 10) #endif @@ -196,18 +195,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* The rest of the configuration is shared */ #include <configs/mxs.h> diff --git a/include/configs/mx51evk.h b/include/configs/mx51evk.h index 9cc297da30e..dc5891e74e9 100644 --- a/include/configs/mx51evk.h +++ b/include/configs/mx51evk.h @@ -12,8 +12,6 @@ /* High Level Configuration Options */ -#define CONFIG_SYS_FSL_CLK - #include <asm/arch/imx-regs.h> /* @@ -45,7 +43,6 @@ #define CONFIG_MXC_USB_FLAGS MXC_EHCI_POWER_PINS_ENABLED /* Framebuffer and LCD */ -#define CONFIG_VIDEO_LOGO #define CONFIG_ETHPRIME "FEC0" @@ -108,18 +105,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - #define CONFIG_ARP_TIMEOUT 200UL /* diff --git a/include/configs/mx53cx9020.h b/include/configs/mx53cx9020.h index f03e4252976..16c2241fd57 100644 --- a/include/configs/mx53cx9020.h +++ b/include/configs/mx53cx9020.h @@ -14,8 +14,6 @@ #include <asm/arch/imx-regs.h> -#define CONFIG_SYS_FSL_CLK - #define CONFIG_MXC_UART_BASE UART2_BASE #define CONFIG_FPGA_COUNT 1 diff --git a/include/configs/mx53loco.h b/include/configs/mx53loco.h index b026c6ff89f..92140df4be1 100644 --- a/include/configs/mx53loco.h +++ b/include/configs/mx53loco.h @@ -11,8 +11,6 @@ #include <asm/arch/imx-regs.h> -#define CONFIG_SYS_FSL_CLK - #define CONFIG_MXC_UART_BASE UART1_BASE /* MMC Configs */ @@ -93,18 +91,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - #define CONFIG_ARP_TIMEOUT 200UL /* Miscellaneous configurable options */ @@ -146,6 +132,5 @@ #endif /* Framebuffer and LCD */ -#define CONFIG_VIDEO_LOGO #endif /* __CONFIG_H */ diff --git a/include/configs/mx53ppd.h b/include/configs/mx53ppd.h index f8118818b01..8f8dfe94ca9 100644 --- a/include/configs/mx53ppd.h +++ b/include/configs/mx53ppd.h @@ -11,8 +11,6 @@ #include <asm/arch/imx-regs.h> -#define CONFIG_SYS_FSL_CLK - /* USB Configs */ #define CONFIG_MXC_USB_PORT 1 #define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW) @@ -87,12 +85,6 @@ "video-mode=" \ "lcd:800x480-24@60,monitor=lcd\0" \ -#define MMCBOOTCOMMAND \ - "run doquiet; " \ - "run tryboot; " \ - -#define CONFIG_BOOTCOMMAND MMCBOOTCOMMAND - #define CONFIG_ARP_TIMEOUT 200UL /* Miscellaneous configurable options */ diff --git a/include/configs/mx6_common.h b/include/configs/mx6_common.h index 0ae8305c592..5ff931ee3bc 100644 --- a/include/configs/mx6_common.h +++ b/include/configs/mx6_common.h @@ -27,8 +27,6 @@ #include <asm/arch/imx-regs.h> #include <asm/mach-imx/gpio.h> -#define CONFIG_SYS_FSL_CLK - /* Miscellaneous configurable options */ #define CONFIG_SYS_CBSIZE 512 #define CONFIG_SYS_MAXARGS 32 diff --git a/include/configs/mx6cuboxi.h b/include/configs/mx6cuboxi.h index da2533637b0..7d3e651f44d 100644 --- a/include/configs/mx6cuboxi.h +++ b/include/configs/mx6cuboxi.h @@ -25,7 +25,6 @@ #endif /* Framebuffer */ -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP diff --git a/include/configs/mx6sabre_common.h b/include/configs/mx6sabre_common.h index 51f6b3ac462..c1c012bbb53 100644 --- a/include/configs/mx6sabre_common.h +++ b/include/configs/mx6sabre_common.h @@ -136,20 +136,6 @@ "echo WARNING: Could not determine dtb to use; fi; " \ "fi;\0" \ -#define CONFIG_BOOTCOMMAND \ - "run findfdt;" \ - "mmc dev ${mmcdev};" \ - "if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - #define CONFIG_ARP_TIMEOUT 200UL /* Physical Memory Map */ @@ -167,7 +153,6 @@ /* Environment organization */ /* Framebuffer */ -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP diff --git a/include/configs/mx6slevk.h b/include/configs/mx6slevk.h index e8fd2126f7b..3da796d03a0 100644 --- a/include/configs/mx6slevk.h +++ b/include/configs/mx6slevk.h @@ -81,19 +81,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev};" \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* Miscellaneous configurable options */ /* Physical Memory Map */ diff --git a/include/configs/mx6sllevk.h b/include/configs/mx6sllevk.h index f2bddd13bd0..0793028ba1f 100644 --- a/include/configs/mx6sllevk.h +++ b/include/configs/mx6sllevk.h @@ -76,19 +76,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev};" \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* Miscellaneous configurable options */ /* Physical Memory Map */ diff --git a/include/configs/mx6sxsabreauto.h b/include/configs/mx6sxsabreauto.h index 12b17839189..953f0710b11 100644 --- a/include/configs/mx6sxsabreauto.h +++ b/include/configs/mx6sxsabreauto.h @@ -73,19 +73,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev};" \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* Miscellaneous configurable options */ /* Physical Memory Map */ diff --git a/include/configs/mx6sxsabresd.h b/include/configs/mx6sxsabresd.h index a554011d75d..8bc86749aac 100644 --- a/include/configs/mx6sxsabresd.h +++ b/include/configs/mx6sxsabresd.h @@ -107,19 +107,6 @@ "if test test $board_rev = REVA ; then " \ "setenv fdt_file imx6sx-sdb-reva.dtb; fi; " \ -#define CONFIG_BOOTCOMMAND \ - "run findfdt; " \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* Miscellaneous configurable options */ /* Physical Memory Map */ @@ -161,7 +148,6 @@ #ifndef CONFIG_SPL_BUILD #ifdef CONFIG_DM_VIDEO -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define MXS_LCDIF_BASE MX6SX_LCDIF1_BASE_ADDR #endif diff --git a/include/configs/mx6ul_14x14_evk.h b/include/configs/mx6ul_14x14_evk.h index 0b777fbbdc0..c24578aff1c 100644 --- a/include/configs/mx6ul_14x14_evk.h +++ b/include/configs/mx6ul_14x14_evk.h @@ -33,8 +33,6 @@ #endif -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_EXTRA_ENV_SETTINGS \ "script=boot.scr\0" \ "image=zImage\0" \ @@ -48,7 +46,7 @@ "splashimage=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ "videomode=video=ctfb:x:480,y:272,depth:24,pclk:108695,le:8,ri:4,up:2,lo:4,hs:41,vs:10,sync:0,vmode:0\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ @@ -108,20 +106,6 @@ "echo WARNING: Could not determine dtb to use; fi; " \ "fi;\0" \ -#define CONFIG_BOOTCOMMAND \ - "run findfdt;" \ - "mmc dev ${mmcdev};" \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* Miscellaneous configurable options */ /* Physical Memory Map */ @@ -165,7 +149,6 @@ #ifndef CONFIG_SPL_BUILD #if defined(CONFIG_DM_VIDEO) -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define MXS_LCDIF_BASE MX6UL_LCDIF1_BASE_ADDR #endif diff --git a/include/configs/mx6ullevk.h b/include/configs/mx6ullevk.h index e384d2a2696..6bcca11c4c2 100644 --- a/include/configs/mx6ullevk.h +++ b/include/configs/mx6ullevk.h @@ -30,8 +30,6 @@ #endif #endif -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_EXTRA_ENV_SETTINGS \ "script=boot.scr\0" \ "image=zImage\0" \ @@ -44,7 +42,7 @@ "ip_dyn=yes\0" \ "videomode=video=ctfb:x:480,y:272,depth:24,pclk:108695,le:8,ri:4,up:2,lo:4,hs:41,vs:10,sync:0,vmode:0\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ @@ -105,20 +103,6 @@ "bootz; " \ "fi;\0" \ -#define CONFIG_BOOTCOMMAND \ - "run findfdt;" \ - "mmc dev ${mmcdev};" \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* Miscellaneous configurable options */ /* Physical Memory Map */ @@ -138,8 +122,6 @@ #define CONFIG_IOMUX_LPSR -#define CONFIG_SOFT_SPI - #ifdef CONFIG_CMD_NET #define CONFIG_FEC_ENET_DEV 1 #if (CONFIG_FEC_ENET_DEV == 0) diff --git a/include/configs/mx7_common.h b/include/configs/mx7_common.h index ffe8c758dd2..2e976df6985 100644 --- a/include/configs/mx7_common.h +++ b/include/configs/mx7_common.h @@ -17,7 +17,6 @@ #define CONFIG_MXC_GPT_HCLK #define CONFIG_SC_TIMER_CLK 8000000 /* 8Mhz */ #define COUNTER_FREQUENCY CONFIG_SC_TIMER_CLK -#define CONFIG_SYS_FSL_CLK #define CONFIG_SYS_BOOTM_LEN 0x1000000 diff --git a/include/configs/mx7dsabresd.h b/include/configs/mx7dsabresd.h index f11e2e3f807..d5b38fd91dd 100644 --- a/include/configs/mx7dsabresd.h +++ b/include/configs/mx7dsabresd.h @@ -17,8 +17,6 @@ /* MMC Config*/ #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #ifdef CONFIG_IMX_BOOTAUX /* Set to QSPI1 A flash at default */ #define CONFIG_SYS_AUXCORE_BOOTDATA 0x60000000 @@ -125,7 +123,6 @@ #define CONFIG_USBD_HS #ifdef CONFIG_DM_VIDEO -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #endif diff --git a/include/configs/mx7ulp_com.h b/include/configs/mx7ulp_com.h index 58d48edac43..8c4d94215b9 100644 --- a/include/configs/mx7ulp_com.h +++ b/include/configs/mx7ulp_com.h @@ -25,7 +25,6 @@ */ #define CONFIG_BOARD_SIZE_LIMIT 785408 #define CONFIG_MMCROOT "/dev/mmcblk0p2" -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 /* Using ULP WDOG for reset */ #define WDOG_BASE_ADDR WDG1_RBASE @@ -48,7 +47,7 @@ "fdt_file=imx7ulp-com.dtb\0" \ "fdt_addr=0x63000000\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ "root=${mmcroot}\0" \ diff --git a/include/configs/mx7ulp_evk.h b/include/configs/mx7ulp_evk.h index 4046c3fbf73..8f2cbc643ee 100644 --- a/include/configs/mx7ulp_evk.h +++ b/include/configs/mx7ulp_evk.h @@ -15,7 +15,6 @@ #define CONFIG_SYS_BOOTM_LEN 0x1000000 #define CONFIG_MMCROOT "/dev/mmcblk0p2" /* USDHC1 */ -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 /* Using ULP WDOG for reset */ #define WDOG_BASE_ADDR WDG1_RBASE @@ -48,7 +47,7 @@ "earlycon=lpuart32,0x402D0010\0" \ "ip_dyn=yes\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ @@ -100,17 +99,6 @@ "bootz; " \ "fi;\0" \ -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "fi; " \ - "fi; " \ - "fi" - #define CONFIG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR #define CONFIG_SYS_INIT_RAM_SIZE SZ_256K diff --git a/include/configs/nas220.h b/include/configs/nas220.h index 99b14ba6218..815f81f6493 100644 --- a/include/configs/nas220.h +++ b/include/configs/nas220.h @@ -11,12 +11,6 @@ #ifndef _CONFIG_NAS220_H #define _CONFIG_NAS220_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 /* #define CPU Core subversion */ -#define CONFIG_KW88F6192 /* SOC Name */ - /* power-on led, regulator, sata0, sata1 */ #define NAS220_GE_OE_VAL_LOW ((1 << 12)|(1 << 14)|(1 << 24)|(1 << 28)) #define NAS220_GE_OE_VAL_HIGH (0) @@ -40,7 +34,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND "" #define CONFIG_EXTRA_ENV_SETTINGS \ "bootargs=console=ttyS0,115200\0" \ @@ -61,15 +54,7 @@ #endif /* CONFIG_CMD_NET */ /* - * File system - */ -#define CONFIG_JFFS2_NAND -#define CONFIG_JFFS2_LZO - -/* * EFI partition */ -#define CONFIG_KIRKWOOD_GPIO - #endif /* _CONFIG_NAS220_H */ diff --git a/include/configs/nokia_rx51.h b/include/configs/nokia_rx51.h index b37e05406e9..adfc055a2c9 100644 --- a/include/configs/nokia_rx51.h +++ b/include/configs/nokia_rx51.h @@ -21,7 +21,6 @@ /* * High Level Configuration Options */ -#define CONFIG_SYS_L2CACHE_OFF /* pretend there is no L2 CACHE */ #include <asm/arch/cpu.h> /* get chip and board defs */ #include <asm/arch/omap.h> @@ -75,7 +74,6 @@ * Framebuffer */ /* Video console */ -#define CONFIG_VIDEO_LOGO #define VIDEO_FB_16BPP_PIXEL_SWAP #define VIDEO_FB_16BPP_WORD_SWAP @@ -168,12 +166,6 @@ int rx51_kp_getc(struct stdio_dev *sdev); "echo run attachboot - Boot attached kernel image.;" \ "echo" -#define CONFIG_BOOTCOMMAND \ - "run sdboot;" \ - "run emmcboot;" \ - "run attachboot;" \ - "echo" - /* * OMAP3 has 12 GP timers, they can be driven by the system clock * (12/13/16.8/19.2/38.4MHz) or by 32KHz clock. We use 13MHz (V_SCLK). diff --git a/include/configs/novena.h b/include/configs/novena.h index 28fb1b8d753..1ce2f4e5622 100644 --- a/include/configs/novena.h +++ b/include/configs/novena.h @@ -9,7 +9,6 @@ #define __CONFIG_H /* System configurations */ -#define CONFIG_KEYBOARD #include "mx6_common.h" @@ -87,7 +86,6 @@ #endif /* Video output */ -#define CONFIG_VIDEO_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP diff --git a/include/configs/nsa310s.h b/include/configs/nsa310s.h index 950549c31ca..8cc9ca6a49d 100644 --- a/include/configs/nsa310s.h +++ b/include/configs/nsa310s.h @@ -9,25 +9,11 @@ #ifndef _CONFIG_NSA310S_H #define _CONFIG_NSA310S_H -/* high level configuration options */ -#define CONFIG_FEROCEON_88FR131 1 /* CPU Core subversion */ -#define CONFIG_KW88F6192 1 /* SOC Name */ -#define CONFIG_KW88F6702 1 /* SOC Name */ - #include "mv-common.h" /* environment variables configuration */ /* default environment variables */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs ${console} ${mtdparts} ${bootargs_root}; " \ - "ubi part root; " \ - "ubifsmount ubi:rootfs; " \ - "ubifsload 0x800000 ${kernel}; " \ - "ubifsload 0x700000 ${fdt}; " \ - "ubifsumount; " \ - "fdt addr 0x700000; fdt resize; fdt chosen; " \ - "bootz 0x800000 - 0x700000" #define CONFIG_EXTRA_ENV_SETTINGS \ "console=console=ttyS0,115200\0" \ @@ -50,9 +36,4 @@ #define CONFIG_LBA48 #endif /* CONFIG_SATA */ -/* RTC driver configuration */ -#ifdef CONFIG_CMD_DATE -#define CONFIG_RTC_MV -#endif /* CONFIG_CMD_DATE */ - #endif /* _CONFIG_NSA310S_H */ diff --git a/include/configs/octeontx2_common.h b/include/configs/octeontx2_common.h index bc21b795cf6..536dff2bdfd 100644 --- a/include/configs/octeontx2_common.h +++ b/include/configs/octeontx2_common.h @@ -7,8 +7,6 @@ #ifndef __OCTEONTX2_COMMON_H__ #define __OCTEONTX2_COMMON_H__ -#define CONFIG_SUPPORT_RAW_INITRD - /** Maximum size of image supported for bootm (and bootable FIT images) */ #define CONFIG_SYS_BOOTM_LEN (256 << 20) @@ -43,7 +41,6 @@ #if defined(CONFIG_MMC_OCTEONTX) #define MMC_SUPPORTS_TUNING /** EMMC specific defines */ -#define CONFIG_SUPPORT_EMMC_RPMB #endif #endif /* __OCTEONTX2_COMMON_H__ */ diff --git a/include/configs/octeontx_common.h b/include/configs/octeontx_common.h index 46908be32a3..8185f4b6250 100644 --- a/include/configs/octeontx_common.h +++ b/include/configs/octeontx_common.h @@ -61,12 +61,6 @@ # define CONFIG_SYS_64BIT_LBA #endif -/***** SPI Defines *********/ -#ifdef CONFIG_DM_SPI_FLASH -# define CONFIG_SF_DEFAULT_BUS 0 -# define CONFIG_SF_DEFAULT_CS 0 -#endif - /* Monitor Command Prompt */ #define CONFIG_SYS_CBSIZE 1024 /** Console I/O Buffer Size */ #define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE @@ -76,9 +70,6 @@ #define CONFIG_SYS_MMC_MAX_BLK_COUNT 8192 /** EMMC specific defines */ -#if defined(CONFIG_MMC_OCTEONTX) -#define CONFIG_SUPPORT_EMMC_RPMB -#endif #if defined(CONFIG_NAND_OCTEONTX) /*#define CONFIG_MTD_CONCAT */ diff --git a/include/configs/odroid.h b/include/configs/odroid.h index 281922af4a8..ed9b41d179d 100644 --- a/include/configs/odroid.h +++ b/include/configs/odroid.h @@ -13,7 +13,6 @@ #include <configs/exynos4-common.h> -#define CONFIG_SYS_L2CACHE_OFF #ifndef CONFIG_SYS_L2CACHE_OFF #define CONFIG_SYS_L2_PL310 #define CONFIG_SYS_PL310_BASE 0x10502000 @@ -28,8 +27,6 @@ #include <linux/sizes.h> -#define CONFIG_BOOTCOMMAND "run distro_bootcmd ; run autoboot" - #define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_LOAD_ADDR \ - GENERATED_GBL_DATA_SIZE) diff --git a/include/configs/odroid_xu3.h b/include/configs/odroid_xu3.h index 70481b5d0c8..a4825982a89 100644 --- a/include/configs/odroid_xu3.h +++ b/include/configs/odroid_xu3.h @@ -80,8 +80,6 @@ * Need to override existing one (smdk5420) with odroid so set_board_info will * use proper prefix when creating full board_name (SYS_BOARD + type) */ -#undef CONFIG_SYS_BOARD -#define CONFIG_SYS_BOARD "odroid" /* Define new extra env settings, including DFU settings */ #undef CONFIG_EXTRA_ENV_SETTINGS diff --git a/include/configs/omap3_logic.h b/include/configs/omap3_logic.h index e71f7371d8c..211f39a0fac 100644 --- a/include/configs/omap3_logic.h +++ b/include/configs/omap3_logic.h @@ -142,9 +142,6 @@ "nandboot=run nandbootcommon; "\ "bootm ${loadaddr} - ${fdtaddr}\0"\ -#define CONFIG_BOOTCOMMAND \ - "run autoboot" - /* Miscellaneous configurable options */ /* memtest works on */ diff --git a/include/configs/omapl138_lcdk.h b/include/configs/omapl138_lcdk.h index f2352d82161..45297b9a612 100644 --- a/include/configs/omapl138_lcdk.h +++ b/include/configs/omapl138_lcdk.h @@ -17,7 +17,6 @@ /* * SoC Configuration */ -#define CONFIG_SYS_CLK_FREQ clk_get(DAVINCI_ARM_CLKID) #define CONFIG_SYS_OSCIN_FREQ 24000000 #define CONFIG_SYS_TIMERBASE DAVINCI_TIMER0_BASE #define CONFIG_SYS_HZ_CLOCK clk_get(DAVINCI_AUXCLK_CLKID) @@ -161,9 +160,6 @@ * Linux Information */ #define LINUX_BOOT_PARAM_ADDR (PHYS_SDRAM_1 + 0x100) -#define CONFIG_BOOTCOMMAND \ - "run envboot; " \ - "run mmcboot; " #define DEFAULT_LINUX_BOOT_ENV \ "loadaddr=0xc0700000\0" \ diff --git a/include/configs/openpiton-riscv64.h b/include/configs/openpiton-riscv64.h index c9d966fff67..75b48f880af 100644 --- a/include/configs/openpiton-riscv64.h +++ b/include/configs/openpiton-riscv64.h @@ -43,11 +43,4 @@ "mmcdev=0\0" \ "mmcpart=1\0" -#define CONFIG_USE_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND \ - "fdt addr ${fdtcontroladdr}; " \ - "fdt move ${fdtcontroladdr} ${fdt_addr_r}; " \ - "load mmc ${mmcdev}:${mmcpart} ${kernel_addr_r} ${image}; " \ - "booti ${kernel_addr_r} - ${fdt_addr_r}; " - #endif/* __CONFIG_H */ diff --git a/include/configs/openrd.h b/include/configs/openrd.h index 56bfe8747ef..43d089657b1 100644 --- a/include/configs/openrd.h +++ b/include/configs/openrd.h @@ -13,12 +13,6 @@ #ifndef _CONFIG_OPENRD_H #define _CONFIG_OPENRD_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_SHEEVA_88SV131 1 /* CPU Core subversion */ -#define CONFIG_KW88F6281 1 /* SOC Name */ - #include "mv-common.h" /* @@ -37,9 +31,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND "${x_bootcmd_kernel}; " \ - "setenv bootargs ${x_bootargs} ${x_bootargs_root}; " \ - "${x_bootcmd_usb}; bootm 0x6400000;" #define CONFIG_EXTRA_ENV_SETTINGS "x_bootargs=console=ttyS0,115200 " \ CONFIG_MTDPARTS_DEFAULT " rw ubi.mtd=2,2048\0" \ diff --git a/include/configs/opos6uldev.h b/include/configs/opos6uldev.h index d9311a49350..ac8eb052756 100644 --- a/include/configs/opos6uldev.h +++ b/include/configs/opos6uldev.h @@ -41,7 +41,6 @@ /* LCD */ #ifndef CONFIG_SPL_BUILD #ifdef CONFIG_DM_VIDEO -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define MXS_LCDIF_BASE MX6UL_LCDIF1_BASE_ADDR #endif @@ -54,7 +53,6 @@ #define ACFG_CONSOLE_DEV ttymxc0 #define CONFIG_SYS_AUTOLOAD "no" #define CONFIG_ROOTPATH "/tftpboot/" __stringify(CONFIG_BOARD_NAME) "-root" -#define CONFIG_BOOTCOMMAND "run emmcboot" #define CONFIG_EXTRA_ENV_SETTINGS \ "env_version=" __stringify(CONFIG_ENV_VERSION) "\0" \ diff --git a/include/configs/origen.h b/include/configs/origen.h index 881df2d3b0b..1caeed6ba5c 100644 --- a/include/configs/origen.h +++ b/include/configs/origen.h @@ -45,22 +45,6 @@ "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \ "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \ "source ${loadaddr}\0" -#define CONFIG_BOOTCOMMAND \ - "if mmc rescan; then " \ - "echo SD/MMC found on device ${mmcdev};" \ - "if run loadbootenv; then " \ - "echo Loaded environment from ${bootenv};" \ - "run importbootenv;" \ - "fi;" \ - "if test -n $uenvcmd; then " \ - "echo Running uenvcmd ...;" \ - "run uenvcmd;" \ - "fi;" \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "fi; " \ - "fi;" \ - "load mmc ${mmcdev} ${loadaddr} uImage; bootm ${loadaddr} " #define CONFIG_CLK_1000_400_200 diff --git a/include/configs/p1_p2_rdb_pc.h b/include/configs/p1_p2_rdb_pc.h index 6b4fc398a81..2e1331b9b07 100644 --- a/include/configs/p1_p2_rdb_pc.h +++ b/include/configs/p1_p2_rdb_pc.h @@ -102,12 +102,10 @@ #define CONFIG_SPL_NAND_INIT #define CONFIG_SPL_COMMON_INIT_DDR #define CONFIG_SPL_MAX_SIZE (128 << 10) -#define CONFIG_TPL_TEXT_BASE 0xf8f81000 #define CONFIG_SYS_MPC85XX_NO_RESETVEC #define CONFIG_SYS_NAND_U_BOOT_SIZE (832 << 10) #define CONFIG_SYS_NAND_U_BOOT_DST (0x11000000) #define CONFIG_SYS_NAND_U_BOOT_START (0x11000000) -#define CONFIG_SYS_NAND_U_BOOT_OFFS ((128 + 128) << 10) #elif defined(CONFIG_SPL_BUILD) #define CONFIG_SPL_INIT_MINIMAL #define CONFIG_SPL_FLUSH_IMAGE @@ -116,7 +114,6 @@ #define CONFIG_SYS_NAND_U_BOOT_SIZE (128 << 10) #define CONFIG_SYS_NAND_U_BOOT_DST 0xf8f80000 #define CONFIG_SYS_NAND_U_BOOT_START 0xf8f80000 -#define CONFIG_SYS_NAND_U_BOOT_OFFS (128 << 10) #endif /* not CONFIG_TPL_BUILD */ #define CONFIG_SPL_PAD_TO 0x20000 @@ -130,7 +127,7 @@ #ifndef CONFIG_SYS_MONITOR_BASE #ifdef CONFIG_TPL_BUILD -#define CONFIG_SYS_MONITOR_BASE CONFIG_TPL_TEXT_BASE +#define CONFIG_SYS_MONITOR_BASE 0xf8f81000 #elif defined(CONFIG_SPL_BUILD) #define CONFIG_SYS_MONITOR_BASE CONFIG_SPL_TEXT_BASE #else @@ -140,17 +137,10 @@ #define CONFIG_PCIE1 /* PCIE controller 1 (slot 1) */ #define CONFIG_PCIE2 /* PCIE controller 2 (slot 2) */ -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ #define CONFIG_SYS_SATA_MAX_DEVICE 2 #define CONFIG_LBA48 -#if defined(CONFIG_TARGET_P2020RDB) -#define CONFIG_SYS_CLK_FREQ 100000000 -#else -#define CONFIG_SYS_CLK_FREQ 66666666 -#endif - #define CONFIG_HWCONFIG /* * These can be toggled for performance analysis, otherwise use default. @@ -352,22 +342,6 @@ OR_GPCM_SCY | OR_GPCM_TRLX | OR_GPCM_EHTR | \ OR_GPCM_EAD) -#ifdef CONFIG_MTD_RAW_NAND -#define CONFIG_SYS_BR0_PRELIM CONFIG_SYS_NAND_BR_PRELIM /* NAND Base Addr */ -#define CONFIG_SYS_OR0_PRELIM CONFIG_SYS_NAND_OR_PRELIM /* NAND Options */ -#define CONFIG_SYS_BR1_PRELIM CONFIG_FLASH_BR_PRELIM /* NOR Base Address */ -#define CONFIG_SYS_OR1_PRELIM CONFIG_FLASH_OR_PRELIM /* NOR Options */ -#else -#define CONFIG_SYS_BR0_PRELIM CONFIG_FLASH_BR_PRELIM /* NOR Base Address */ -#define CONFIG_SYS_OR0_PRELIM CONFIG_FLASH_OR_PRELIM /* NOR Options */ -#ifdef CONFIG_NAND_FSL_ELBC -#define CONFIG_SYS_BR1_PRELIM CONFIG_SYS_NAND_BR_PRELIM /* NAND Base Addr */ -#define CONFIG_SYS_OR1_PRELIM CONFIG_SYS_NAND_OR_PRELIM /* NAND Options */ -#endif -#endif -#define CONFIG_SYS_BR3_PRELIM CONFIG_CPLD_BR_PRELIM /* CPLD Base Address */ -#define CONFIG_SYS_OR3_PRELIM CONFIG_CPLD_OR_PRELIM /* CPLD Options */ - /* Vsc7385 switch */ #ifdef CONFIG_VSC7385_ENET #define __VSCFW_ADDR "vscfw_addr=ef000000" @@ -385,9 +359,6 @@ OR_GPCM_XACS | OR_GPCM_SCY_15 | OR_GPCM_SETA | \ OR_GPCM_TRLX | OR_GPCM_EHTR | OR_GPCM_EAD) -#define CONFIG_SYS_BR2_PRELIM CONFIG_SYS_VSC7385_BR_PRELIM -#define CONFIG_SYS_OR2_PRELIM CONFIG_SYS_VSC7385_OR_PRELIM - /* The size of the VSC7385 firmware image */ #define CONFIG_VSC7385_IMAGE_SIZE 8192 #endif @@ -553,7 +524,6 @@ #if defined(CONFIG_HAS_FSL_DR_USB) #ifdef CONFIG_USB_EHCI_HCD #define CONFIG_EHCI_HCD_INIT_AFTER_RESET -#define CONFIG_USB_EHCI_FSL #endif #endif @@ -565,8 +535,6 @@ #define CONFIG_SYS_FSL_ESDHC_ADDR CONFIG_SYS_MPC85xx_ESDHC_ADDR #endif -#undef CONFIG_WATCHDOG /* watchdog disabled */ - /* * Miscellaneous configurable options */ @@ -646,23 +614,6 @@ __stringify(__SD_RST_CMD)"\0" \ __stringify(__NAND_RST_CMD)"\0" \ __stringify(__PCIE_RST_CMD)"\0" -#define NFSBOOTCOMMAND \ -"setenv bootargs root=/dev/nfs rw " \ -"nfsroot=$serverip:$rootpath " \ -"ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ -"console=$consoledev,$baudrate $othbootargs;" \ -"tftp $loadaddr $bootfile;" \ -"tftp $fdtaddr $fdtfile;" \ -"bootm $loadaddr - $fdtaddr" - -#define HDBOOT \ -"setenv bootargs root=/dev/$bdev rw rootdelay=30 " \ -"console=$consoledev,$baudrate $othbootargs;" \ -"usb start;" \ -"ext2load usb 0:1 $loadaddr /boot/$bootfile;" \ -"ext2load usb 0:1 $fdtaddr /boot/$fdtfile;" \ -"bootm $loadaddr - $fdtaddr" - #define CONFIG_USB_FAT_BOOT \ "setenv bootargs root=/dev/ram rw " \ "console=$consoledev,$baudrate $othbootargs " \ @@ -688,15 +639,4 @@ __stringify(__PCIE_RST_CMD)"\0" "console=$consoledev,$baudrate rootfstype=jffs2 $othbootargs;" \ "bootm $norbootaddr - $norfdtaddr" -#define RAMBOOTCOMMAND \ -"setenv bootargs root=/dev/ram rw " \ -"console=$consoledev,$baudrate $othbootargs " \ -"ramdisk_size=$ramdisk_size;" \ -"tftp $ramdiskaddr $ramdiskfile;" \ -"tftp $loadaddr $bootfile;" \ -"tftp $fdtaddr $fdtfile;" \ -"bootm $loadaddr $ramdiskaddr $fdtaddr" - -#define CONFIG_BOOTCOMMAND HDBOOT - #endif /* __CONFIG_H */ diff --git a/include/configs/p3450-0000.h b/include/configs/p3450-0000.h index 7f05bebbcd7..b03d3a433b7 100644 --- a/include/configs/p3450-0000.h +++ b/include/configs/p3450-0000.h @@ -24,12 +24,8 @@ func(DHCP, dhcp, na) /* Environment at end of QSPI, in the VER partition */ -#define CONFIG_ENV_SPI_MAX_HZ 48000000 -#define CONFIG_ENV_SPI_MODE SPI_MODE_0 #define CONFIG_SPI_FLASH_SIZE (4 << 20) -#define CONFIG_PREBOOT - #define BOARD_EXTRA_ENV_SETTINGS \ "preboot=if test -e mmc 1:1 /u-boot-preboot.scr; then " \ "load mmc 1:1 ${scriptaddr} /u-boot-preboot.scr; " \ diff --git a/include/configs/pcl063_ull.h b/include/configs/pcl063_ull.h index 0e047dfa43a..068fc7db347 100644 --- a/include/configs/pcl063_ull.h +++ b/include/configs/pcl063_ull.h @@ -83,8 +83,6 @@ "fit_addr=0x82000000\0" \ ENV_MMC -#define CONFIG_BOOTCOMMAND "run mmc_mmc_fit" - #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 0) \ func(MMC, mmc, 1) \ diff --git a/include/configs/pcm052.h b/include/configs/pcm052.h index 244d373843c..fd4a0b1aa86 100644 --- a/include/configs/pcm052.h +++ b/include/configs/pcm052.h @@ -25,12 +25,6 @@ #define PCM052_EXTRA_ENV_SETTINGS #endif -/* if no target-specific boot command was defined by the target, - define an empty one */ -#ifndef PCM052_BOOTCOMMAND -#define PCM052_BOOTCOMMAND -#endif - /* if no target-specific extra environment settings were defined by the target, define an empty one */ #ifndef PCM052_NET_INIT @@ -38,7 +32,6 @@ #endif /* boot command, including the target-defined one if any */ -#define CONFIG_BOOTCOMMAND PCM052_BOOTCOMMAND "run bootcmd_nand" /* Extra env settings (including the target-defined ones if any) */ #define CONFIG_EXTRA_ENV_SETTINGS \ diff --git a/include/configs/pcm058.h b/include/configs/pcm058.h index a0bb2b50505..4d4185b4668 100644 --- a/include/configs/pcm058.h +++ b/include/configs/pcm058.h @@ -56,6 +56,4 @@ "optargs=rw rootwait\0" \ ENV_MMC \ ENV_NAND - -#define CONFIG_BOOTCOMMAND "run mmcboot;run nandboot" #endif diff --git a/include/configs/pdu001.h b/include/configs/pdu001.h index 3d18747f9b6..7ab6a896040 100644 --- a/include/configs/pdu001.h +++ b/include/configs/pdu001.h @@ -32,19 +32,6 @@ #define CONSOLE_DEV "ttyO5" #endif -#define CONFIG_BOOTCOMMAND \ - "run eval_boot_device;" \ - "part uuid mmc ${mmc_boot}:${root_fs_partition} root_fs_partuuid;" \ - "setenv bootargs console=${console} " \ - "vt.global_cursor_default=0 " \ - "root=PARTUUID=${root_fs_partuuid} " \ - "rootfstype=ext4 " \ - "rootwait " \ - "rootdelay=1;" \ - "fatload mmc ${mmc_boot} ${fdtaddr} ${fdtfile};" \ - "fatload mmc ${mmc_boot} ${loadaddr} ${bootfile};" \ - "bootz ${loadaddr} - ${fdtaddr}" - #ifndef CONFIG_SPL_BUILD #define CONFIG_EXTRA_ENV_SETTINGS \ DEFAULT_LINUX_BOOT_ENV \ diff --git a/include/configs/phycore_imx8mm.h b/include/configs/phycore_imx8mm.h index 38c8a836170..7438d0a4647 100644 --- a/include/configs/phycore_imx8mm.h +++ b/include/configs/phycore_imx8mm.h @@ -14,8 +14,6 @@ #define CONFIG_SYS_BOOTM_LEN SZ_64M #define CONFIG_SPL_MAX_SIZE (148 * SZ_1K) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -39,7 +37,7 @@ "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \ "ip_dyn=yes\0" \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=2\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console} " \ @@ -70,14 +68,6 @@ "echo WARN: Cannot load the DT; " \ "fi;\0" \ -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi;" - /* Link Definitions */ #define CONFIG_SYS_INIT_RAM_ADDR 0x40000000 @@ -105,6 +95,5 @@ /* USDHC */ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 #endif /* __PHYCORE_IMX8MM_H */ diff --git a/include/configs/phycore_imx8mp.h b/include/configs/phycore_imx8mp.h index fcd5896a97b..8c5ffeef544 100644 --- a/include/configs/phycore_imx8mp.h +++ b/include/configs/phycore_imx8mp.h @@ -14,8 +14,6 @@ #define CONFIG_SPL_MAX_SIZE (152 * SZ_1K) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -39,7 +37,7 @@ "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \ "ip_dyn=yes\0" \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=2\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console} " \ @@ -70,14 +68,6 @@ "echo WARN: Cannot load the DT; " \ "fi;\0" \ -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi;" - /* Link Definitions */ #define CONFIG_SYS_INIT_RAM_ADDR 0x40000000 @@ -105,6 +95,5 @@ /* USDHC */ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 #endif /* __PHYCORE_IMX8MP_H */ diff --git a/include/configs/pic32mzdask.h b/include/configs/pic32mzdask.h index a83e49ff3ba..3624c122fcd 100644 --- a/include/configs/pic32mzdask.h +++ b/include/configs/pic32mzdask.h @@ -33,9 +33,6 @@ #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE #define CONFIG_SYS_MONITOR_LEN (192 << 10) -#define CONFIG_SYS_ENV_ADDR 0x88300000 -#define CONFIG_SYS_FDT_ADDR 0x89d00000 - /* Memory Test */ /*---------------------------------------------------------------------- @@ -74,8 +71,8 @@ #define MEM_LAYOUT_ENV_SETTINGS \ "kernel_addr_r="__stringify(CONFIG_SYS_LOAD_ADDR)"\0" \ - "fdt_addr_r="__stringify(CONFIG_SYS_FDT_ADDR)"\0" \ - "scriptaddr="__stringify(CONFIG_SYS_ENV_ADDR)"\0" + "fdt_addr_r=0x89d00000\0" \ + "scriptaddr=0x88300000\0" \ #define CONFIG_LEGACY_BOOTCMD_ENV \ "legacy_bootcmd= " \ @@ -99,7 +96,4 @@ CONFIG_LEGACY_BOOTCMD_ENV \ BOOTENV -#undef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND "run distro_bootcmd || run legacy_bootcmd" - #endif /* __PIC32MZDASK_CONFIG_H */ diff --git a/include/configs/pico-imx6.h b/include/configs/pico-imx6.h index 2528d319d1f..19955623b7f 100644 --- a/include/configs/pico-imx6.h +++ b/include/configs/pico-imx6.h @@ -136,7 +136,6 @@ #define CONFIG_FEC_MXC_PHYADDR 1 /* Framebuffer */ -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP diff --git a/include/configs/pico-imx6ul.h b/include/configs/pico-imx6ul.h index 3fe178316f7..03e48011dc2 100644 --- a/include/configs/pico-imx6ul.h +++ b/include/configs/pico-imx6ul.h @@ -64,8 +64,6 @@ "bootmenu_2=Boot using PICO-Pi baseboard=" \ "setenv fdtfile imx6ul-pico-pi.dtb\0" \ -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_EXTRA_ENV_SETTINGS \ "script=boot.scr\0" \ "image=zImage\0" \ @@ -133,7 +131,6 @@ #define CONFIG_BOARD_SIZE_LIMIT 715776 #ifdef CONFIG_DM_VIDEO -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define MXS_LCDIF_BASE MX6UL_LCDIF1_BASE_ADDR #endif diff --git a/include/configs/pico-imx7d.h b/include/configs/pico-imx7d.h index cbac9505492..8c0b8c07a8e 100644 --- a/include/configs/pico-imx7d.h +++ b/include/configs/pico-imx7d.h @@ -65,9 +65,6 @@ BOOTENV #endif - -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_EXTRA_ENV_SETTINGS \ "image=zImage\0" \ "splashpos=m,m\0" \ @@ -124,7 +121,6 @@ #define CONFIG_POWER_PFUZE3000_I2C_ADDR 0x08 #ifdef CONFIG_DM_VIDEO -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #endif diff --git a/include/configs/pico-imx8mq.h b/include/configs/pico-imx8mq.h index 5c1b65207e0..2293a2919e2 100644 --- a/include/configs/pico-imx8mq.h +++ b/include/configs/pico-imx8mq.h @@ -11,8 +11,6 @@ #define CONFIG_SPL_MAX_SIZE (124 * 1024) #define CONFIG_SYS_MONITOR_LEN (512 * 1024) -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #ifdef CONFIG_SPL_BUILD /*#define CONFIG_ENABLE_DDR_TRAINING_DEBUG*/ @@ -56,7 +54,7 @@ "initrd_addr=0x43800000\0" \ "initrd_high=0xffffffffffffffff\0" \ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console} root=${mmcroot}\0 " \ @@ -82,18 +80,6 @@ "${get_cmd} ${loadaddr} ${image}; " \ "booti; " -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else booti ${loadaddr} - ${fdt_addr}; fi" - /* Link Definitions */ #define CONFIG_SYS_INIT_RAM_ADDR 0x40000000 @@ -109,10 +95,6 @@ #define PHYS_SDRAM 0x40000000 #define PHYS_SDRAM_SIZE 0x80000000 /* 2 GiB DDR */ -#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM -#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + \ - (PHYS_SDRAM_SIZE >> 1)) - #define CONFIG_MXC_UART_BASE UART1_BASE_ADDR /* Monitor Command Prompt */ @@ -125,12 +107,6 @@ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - -#define CONFIG_MXC_GPIO - -#define CONFIG_OF_SYSTEM_SETUP - #define CONFIG_SYS_BOOTM_LEN SZ_128M #endif diff --git a/include/configs/plutux.h b/include/configs/plutux.h index 7fc06e8326b..9a4a632a521 100644 --- a/include/configs/plutux.h +++ b/include/configs/plutux.h @@ -19,7 +19,6 @@ #define CONFIG_SYS_NS16550_COM1 NV_PA_APB_UARTD_BASE /* NAND support */ -#define CONFIG_TEGRA_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 /* Environment in NAND, aligned to start of last sector */ diff --git a/include/configs/pm9261.h b/include/configs/pm9261.h index d5301071166..be24d825389 100644 --- a/include/configs/pm9261.h +++ b/include/configs/pm9261.h @@ -179,14 +179,10 @@ #ifdef CONFIG_SYS_USE_DATAFLASH_CS0 /* bootstrap + u-boot + env + linux in dataflash on CS0 */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x22000000 0x84000 0x210000; " \ - "bootm 0x22000000" #elif defined(CONFIG_SYS_USE_NANDFLASH) /* CONFIG_SYS_USE_NANDFLASH */ /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND "nand read 0x22000000 0xA0000 0x200000; bootm" #elif defined (CONFIG_SYS_USE_FLASH) /* JFFS Partition offset set */ @@ -196,8 +192,6 @@ /* 512k reserved for u-boot */ #define CONFIG_SYS_JFFS2_FIRST_SECTOR 11 -#define CONFIG_BOOTCOMMAND "run flashboot" - #define CONFIG_CON_ROT "fbcon=rotate:3 " #define CONFIG_EXTRA_ENV_SETTINGS \ diff --git a/include/configs/pm9263.h b/include/configs/pm9263.h index 80899930b29..e9eb736ecb1 100644 --- a/include/configs/pm9263.h +++ b/include/configs/pm9263.h @@ -179,11 +179,6 @@ #endif -#define CONFIG_JFFS2_NAND 1 -#define CONFIG_JFFS2_DEV "nand0" /* NAND device jffs2 lives on */ -#define CONFIG_JFFS2_PART_OFFSET 0 /* start of jffs2 partition */ -#define CONFIG_JFFS2_PART_SIZE (256 * 1024 * 1024) /* partition size*/ - /* PSRAM */ #define PHYS_PSRAM 0x70000000 #define PHYS_PSRAM_SIZE 0x00400000 /* 4MB */ @@ -209,14 +204,10 @@ #ifdef CONFIG_SYS_USE_DATAFLASH /* bootstrap + u-boot + env + linux in dataflash on CS0 */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x22000000 0x84000 0x294000; " \ - "bootm 0x22000000" #elif defined(CONFIG_SYS_USE_NANDFLASH) /* CFG_USE_NANDFLASH */ /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND "nand read 0x22000000 0xA0000 0x200000; bootm" #elif defined(CONFIG_SYS_USE_FLASH) /* CFG_USE_FLASH */ /* JFFS Partition offset set */ @@ -226,7 +217,6 @@ /* 512k reserved for u-boot */ #define CONFIG_SYS_JFFS2_FIRST_SECTOR 11 -#define CONFIG_BOOTCOMMAND "run flashboot" #define CONFIG_ROOTPATH "/ronetix/rootfs" #define CONFIG_CON_ROT "fbcon=rotate:3 " diff --git a/include/configs/pm9g45.h b/include/configs/pm9g45.h index 3d039b60a86..b2053916421 100644 --- a/include/configs/pm9g45.h +++ b/include/configs/pm9g45.h @@ -45,7 +45,6 @@ #define CONFIG_SYS_NAND_MASK_CLE BIT(22) #define CONFIG_SYS_NAND_ENABLE_PIN AT91_PIN_PC14 #define CONFIG_SYS_NAND_READY_PIN AT91_PIN_PD3 -#define CONFIG_SYS_NAND_DRIVER_ECC_LAYOUT #endif /* Ethernet */ @@ -54,16 +53,8 @@ #ifdef CONFIG_NAND_BOOT /* bootstrap + u-boot + env in nandflash */ - -#define CONFIG_BOOTCOMMAND \ - "nand read 0x70000000 0x200000 0x300000;" \ - "bootm 0x70000000" #elif CONFIG_SD_BOOT /* bootstrap + u-boot + env + linux in mmc */ - -#define CONFIG_BOOTCOMMAND "fatload mmc 0:1 0x71000000 dtb; " \ - "fatload mmc 0:1 0x72000000 zImage; " \ - "bootz 0x72000000 - 0x71000000" #endif /* Defines for SPL */ diff --git a/include/configs/pogo_e02.h b/include/configs/pogo_e02.h index f49bcfb6a21..3e94125cb35 100644 --- a/include/configs/pogo_e02.h +++ b/include/configs/pogo_e02.h @@ -12,12 +12,6 @@ #ifndef _CONFIG_POGO_E02_H #define _CONFIG_POGO_E02_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 /* CPU Core subversion */ -#define CONFIG_KW88F6281 /* SOC Name */ - #include "mv-common.h" /* @@ -27,10 +21,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND \ - "setenv bootargs $(bootargs_console); " \ - "run bootcmd_usb; " \ - "bootm 0x00800000 0x01100000" #define CONFIG_EXTRA_ENV_SETTINGS \ "mtdparts=mtdparts=orion_nand:1M(u-boot),4M(uImage)," \ diff --git a/include/configs/porter.h b/include/configs/porter.h index 7ffcf5fc38a..867dadaedd0 100644 --- a/include/configs/porter.h +++ b/include/configs/porter.h @@ -35,8 +35,6 @@ #define CONFIG_BITBANGMII_MULTI /* Board Clock */ -#define RMOBILE_XTAL_CLK 20000000u -#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK #define CONFIG_EXTRA_ENV_SETTINGS \ "bootm_size=0x10000000\0" diff --git a/include/configs/presidio_asic.h b/include/configs/presidio_asic.h index 3df51437ca2..928ccb1e18a 100644 --- a/include/configs/presidio_asic.h +++ b/include/configs/presidio_asic.h @@ -10,8 +10,6 @@ #define CONFIG_REMAKE_ELF -#define CONFIG_SUPPORT_RAW_INITRD - #define CONFIG_SYS_INIT_SP_ADDR 0x00100000 #define CONFIG_SYS_BOOTM_LEN 0x00c00000 diff --git a/include/configs/pxm2.h b/include/configs/pxm2.h index a333326dff6..753fc14ce0e 100644 --- a/include/configs/pxm2.h +++ b/include/configs/pxm2.h @@ -71,44 +71,11 @@ #ifndef CONFIG_RESTORE_FLASH /* set to negative value for no autoboot */ - -#define CONFIG_BOOTCOMMAND \ - "if dfubutton; then " \ - "run dfu_start; " \ - "reset; " \ - "fi; " \ - "if mmc rescan; then " \ - "echo SD/MMC found on device ${mmc_dev};" \ - "if run loadbootenv; then " \ - "echo Loaded environment from ${bootenv};" \ - "run importbootenv;" \ - "fi;" \ - "if test -n $uenvcmd; then " \ - "echo Running uenvcmd ...;" \ - "run uenvcmd;" \ - "fi;" \ - "if run mmc_load_uimage; then " \ - "run mmc_args;" \ - "bootm ${kloadaddr};" \ - "fi;" \ - "fi;" \ - "run nand_boot;" \ - "reset;" - -#else - -#define CONFIG_BOOTCOMMAND \ - "setenv autoload no; " \ - "dhcp; " \ - "if tftp 80000000 debrick.scr; then " \ - "source 80000000; " \ - "fi" #endif #endif /* CONFIG_SPL_BUILD */ #if defined(CONFIG_VIDEO) #define CONFIG_VIDEO_DA8XX -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define DA8XX_LCD_CNTL_BASE LCD_CNTL_BASE #define PWM_TICKS 0x1388 diff --git a/include/configs/qemu-arm.h b/include/configs/qemu-arm.h index 1287fd16715..9fc53b4739b 100644 --- a/include/configs/qemu-arm.h +++ b/include/configs/qemu-arm.h @@ -21,11 +21,35 @@ /* Environment options */ +#if CONFIG_IS_ENABLED(CMD_USB) +# define BOOT_TARGET_USB(func) func(USB, usb, 0) +#else +# define BOOT_TARGET_USB(func) +#endif + +#if CONFIG_IS_ENABLED(CMD_SCSI) +# define BOOT_TARGET_SCSI(func) func(SCSI, scsi, 0) +#else +# define BOOT_TARGET_SCSI(func) +#endif + +#if CONFIG_IS_ENABLED(CMD_VIRTIO) +# define BOOT_TARGET_VIRTIO(func) func(VIRTIO, virtio, 0) +#else +# define BOOT_TARGET_VIRTIO(func) +#endif + +#if CONFIG_IS_ENABLED(CMD_DHCP) +# define BOOT_TARGET_DHCP(func) func(DHCP, dhcp, na) +#else +# define BOOT_TARGET_DHCP(func) +#endif + #define BOOT_TARGET_DEVICES(func) \ - func(USB, usb, 0) \ - func(SCSI, scsi, 0) \ - func(VIRTIO, virtio, 0) \ - func(DHCP, dhcp, na) + BOOT_TARGET_USB(func) \ + BOOT_TARGET_SCSI(func) \ + BOOT_TARGET_VIRTIO(func) \ + BOOT_TARGET_DHCP(func) #include <config_distro_bootcmd.h> diff --git a/include/configs/qemu-ppce500.h b/include/configs/qemu-ppce500.h index f79e0fea4d5..e257c0ec1f4 100644 --- a/include/configs/qemu-ppce500.h +++ b/include/configs/qemu-ppce500.h @@ -13,8 +13,6 @@ #define CONFIG_SYS_RAMBOOT -#define CONFIG_SYS_PCI_64BIT /* enable 64-bit PCI resources */ - #define CONFIG_ENABLE_36BIT_PHYS /* Needed to fill the ccsrbar pointer */ @@ -47,8 +45,6 @@ extern unsigned long long get_phys_ccsrbar_addr_early(void); #define CONFIG_CHIP_SELECTS_PER_CTRL 0 -#define CONFIG_SYS_CLK_FREQ 33000000 - #define CONFIG_SYS_BOOT_BLOCK 0x00000000 /* boot TLB */ #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE @@ -100,7 +96,4 @@ extern unsigned long long get_phys_ccsrbar_addr_early(void); #define CONFIG_BOOTFILE "uImage" #define CONFIG_UBOOTPATH "u-boot.bin" /* U-Boot image on TFTP server*/ -#define CONFIG_BOOTCOMMAND \ - "test -n \"$qemu_kernel_addr\" && bootm $qemu_kernel_addr - $fdtcontroladdr\0" - #endif /* __QEMU_PPCE500_H */ diff --git a/include/configs/r2dplus.h b/include/configs/r2dplus.h index 58ca6c28b53..8e86830e61b 100644 --- a/include/configs/r2dplus.h +++ b/include/configs/r2dplus.h @@ -1,7 +1,6 @@ #ifndef __CONFIG_H #define __CONFIG_H -#define CONFIG_CPU_SH7751 1 #define __LITTLE_ENDIAN__ 1 /* SCIF */ @@ -29,7 +28,6 @@ /* * SuperH Clock setting */ -#define CONFIG_SYS_CLK_FREQ 60000000 #define CONFIG_SYS_PLL_SETTLING_TIME 100/* in us */ /* @@ -44,7 +42,6 @@ #define CONFIG_SYS_ATA_DATA_OFFSET 0x1000 /* data reg offset */ #define CONFIG_SYS_ATA_REG_OFFSET 0x1000 /* reg offset */ #define CONFIG_SYS_ATA_ALT_OFFSET 0x800 /* alternate register offset */ -#define CONFIG_IDE_SWAP_IO /* * SuperH PCI Bridge Configration diff --git a/include/configs/rastaban.h b/include/configs/rastaban.h index de8ea8b850a..8e20a448d2a 100644 --- a/include/configs/rastaban.h +++ b/include/configs/rastaban.h @@ -57,24 +57,6 @@ #ifndef CONFIG_RESTORE_FLASH /* set to negative value for no autoboot */ - -#define CONFIG_BOOTCOMMAND \ -"if dfubutton; then " \ - "run dfu_start; " \ - "reset; " \ -"fi;" \ -"run nand_boot;" \ -"run nand_boot_backup;" \ -"reset;" - -#else - -#define CONFIG_BOOTCOMMAND \ - "setenv autoload no; " \ - "dhcp; " \ - "if tftp 80000000 debrick.scr; then " \ - "source 80000000; " \ - "fi" #endif #endif /* CONFIG_SPL_BUILD */ #endif /* ! __CONFIG_RASTABAN_H */ diff --git a/include/configs/rcar-gen2-common.h b/include/configs/rcar-gen2-common.h index 595482c22e9..f1f5d07bf81 100644 --- a/include/configs/rcar-gen2-common.h +++ b/include/configs/rcar-gen2-common.h @@ -42,6 +42,6 @@ #define CONFIG_TMU_TIMER #define CONFIG_SYS_TIMER_COUNTS_DOWN #define CONFIG_SYS_TIMER_COUNTER (TMU_BASE + 0xc) /* TCNT0 */ -#define CONFIG_SYS_TIMER_RATE (CONFIG_SYS_CLK_FREQ / 8) +#define CONFIG_SYS_TIMER_RATE (get_board_sys_clk() / 8) #endif /* __RCAR_GEN2_COMMON_H */ diff --git a/include/configs/rcar-gen3-common.h b/include/configs/rcar-gen3-common.h index 2b3e1bb0d1c..eed21255eb2 100644 --- a/include/configs/rcar-gen3-common.h +++ b/include/configs/rcar-gen3-common.h @@ -55,11 +55,6 @@ #define CONFIG_EXTRA_ENV_SETTINGS \ "bootm_size=0x10000000\0" -#define CONFIG_BOOTCOMMAND \ - "tftp 0x48080000 Image; " \ - "tftp 0x48000000 Image-"CONFIG_DEFAULT_FDT_FILE"; " \ - "booti 0x48080000 - 0x48000000" - /* SPL support */ #if defined(CONFIG_R8A7795) || defined(CONFIG_R8A7796) || defined(CONFIG_R8A77965) #define CONFIG_SPL_BSS_START_ADDR 0xe633f000 diff --git a/include/configs/rk3036_common.h b/include/configs/rk3036_common.h index b133d8ec48b..00c453d739d 100644 --- a/include/configs/rk3036_common.h +++ b/include/configs/rk3036_common.h @@ -12,7 +12,6 @@ #define CONFIG_ROCKCHIP_STIMER_BASE 0x200440a0 #define COUNTER_FREQUENCY 24000000 -#define CONFIG_SYS_ARCH_TIMER #define CONFIG_SYS_HZ_CLOCK 24000000 #define CONFIG_SYS_INIT_SP_ADDR 0x60100000 diff --git a/include/configs/rk3128_common.h b/include/configs/rk3128_common.h index 8b7a0bbbca1..97caceacfe6 100644 --- a/include/configs/rk3128_common.h +++ b/include/configs/rk3128_common.h @@ -13,7 +13,6 @@ #define CONFIG_ROCKCHIP_STIMER_BASE 0x200440a0 #define COUNTER_FREQUENCY 24000000 -#define CONFIG_SYS_ARCH_TIMER #define CONFIG_SYS_HZ_CLOCK 24000000 #define CONFIG_IRAM_BASE 0x10080000 diff --git a/include/configs/rk3188_common.h b/include/configs/rk3188_common.h index e7c09645ec6..7449e816b7d 100644 --- a/include/configs/rk3188_common.h +++ b/include/configs/rk3188_common.h @@ -22,7 +22,6 @@ /* spl size 32kb sram - 2kb bootrom */ #define CONFIG_SPL_MAX_SIZE (0x8000 - 0x800) -#define CONFIG_ROCKCHIP_SERIAL 1 #define CONFIG_SPL_STACK 0x10087fff diff --git a/include/configs/rk322x_common.h b/include/configs/rk322x_common.h index a46b1ffe865..ef55ef0a83b 100644 --- a/include/configs/rk322x_common.h +++ b/include/configs/rk322x_common.h @@ -13,7 +13,6 @@ #define CONFIG_ROCKCHIP_STIMER_BASE 0x110d0020 #define COUNTER_FREQUENCY 24000000 -#define CONFIG_SYS_ARCH_TIMER #define CONFIG_SYS_HZ_CLOCK 24000000 #define CONFIG_SYS_INIT_SP_ADDR 0x61100000 diff --git a/include/configs/rk3288_common.h b/include/configs/rk3288_common.h index abbb27395e6..490da7cb23b 100644 --- a/include/configs/rk3288_common.h +++ b/include/configs/rk3288_common.h @@ -15,7 +15,6 @@ #define CONFIG_ROCKCHIP_STIMER_BASE 0xff810020 #define COUNTER_FREQUENCY 24000000 -#define CONFIG_SYS_ARCH_TIMER #define CONFIG_SYS_HZ_CLOCK 24000000 #ifdef CONFIG_SPL_ROCKCHIP_BACK_TO_BROM diff --git a/include/configs/rk3308_common.h b/include/configs/rk3308_common.h index 496f4628d34..1664707ca65 100644 --- a/include/configs/rk3308_common.h +++ b/include/configs/rk3308_common.h @@ -12,7 +12,6 @@ #define CONFIG_SPL_MAX_SIZE 0x20000 #define CONFIG_SPL_BSS_START_ADDR 0x00400000 #define CONFIG_SPL_BSS_MAX_SIZE 0x2000 -#define CONFIG_SYS_SPI_U_BOOT_OFFS 0x8000 #define CONFIG_SYS_NS16550_MEM32 diff --git a/include/configs/rk3568_common.h b/include/configs/rk3568_common.h index afe5050e4d8..25d7c5cc8ff 100644 --- a/include/configs/rk3568_common.h +++ b/include/configs/rk3568_common.h @@ -16,6 +16,12 @@ #define CONFIG_IRAM_BASE 0xfdcc0000 #define CONFIG_SYS_INIT_SP_ADDR 0x00c00000 + +#define CONFIG_SPL_STACK 0x00400000 +#define CONFIG_SPL_MAX_SIZE 0x20000 +#define CONFIG_SPL_BSS_START_ADDR 0x4000000 +#define CONFIG_SPL_BSS_MAX_SIZE 0x4000 + #define CONFIG_SYS_BOOTM_LEN (64 << 20) /* 64M */ #define CONFIG_SYS_SDRAM_BASE 0 diff --git a/include/configs/rpi.h b/include/configs/rpi.h index 55768a46da2..d5e064fb379 100644 --- a/include/configs/rpi.h +++ b/include/configs/rpi.h @@ -44,7 +44,6 @@ /* GPIO */ #define CONFIG_BCM2835_GPIO /* LCD */ -#define CONFIG_LCD_DT_SIMPLEFB #define CONFIG_VIDEO_BCM2835 /* DFU over USB/UDC */ @@ -137,7 +136,8 @@ #if CONFIG_IS_ENABLED(CMD_MMC) #define BOOT_TARGET_MMC(func) \ func(MMC, mmc, 0) \ - func(MMC, mmc, 1) + func(MMC, mmc, 1) \ + func(MMC, mmc, 2) #else #define BOOT_TARGET_MMC(func) #endif diff --git a/include/configs/rut.h b/include/configs/rut.h index 68d68d084d2..02d330e4f0f 100644 --- a/include/configs/rut.h +++ b/include/configs/rut.h @@ -63,41 +63,12 @@ #ifndef CONFIG_RESTORE_FLASH /* set to negative value for no autoboot */ - -#define CONFIG_BOOTCOMMAND \ - "if mmc rescan; then " \ - "echo SD/MMC found on device ${mmc_dev};" \ - "if run loadbootenv; then " \ - "echo Loaded environment from ${bootenv};" \ - "run importbootenv;" \ - "fi;" \ - "if test -n $uenvcmd; then " \ - "echo Running uenvcmd ...;" \ - "run uenvcmd;" \ - "fi;" \ - "if run mmc_load_uimage; then " \ - "run mmc_args;" \ - "bootm ${kloadaddr};" \ - "fi;" \ - "fi;" \ - "run nand_boot;" \ - "reset;" - -#else - -#define CONFIG_BOOTCOMMAND \ - "setenv autoload no; " \ - "dhcp; " \ - "if tftp 80000000 debrick.scr; then " \ - "source 80000000; " \ - "fi" #endif #endif /* CONFIG_SPL_BUILD */ #if defined(CONFIG_VIDEO) #define CONFIG_VIDEO_DA8XX -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define DA8XX_LCD_CNTL_BASE LCD_CNTL_BASE diff --git a/include/configs/s5p4418_nanopi2.h b/include/configs/s5p4418_nanopi2.h index 2e94613c37a..632fc0cc9ee 100644 --- a/include/configs/s5p4418_nanopi2.h +++ b/include/configs/s5p4418_nanopi2.h @@ -104,16 +104,6 @@ (void *)PHY_BASEADDR_UART3} /*----------------------------------------------------------------------- - * PLL - */ -#define CONFIG_SYS_PLLFIN 24000000UL - -/*----------------------------------------------------------------------- - * Timer - */ -#define CONFIG_TIMER_SYS_TICK_CH 0 - -/*----------------------------------------------------------------------- * BACKLIGHT */ #ifndef CONFIG_S5P4418_ONEWIRE @@ -131,8 +121,6 @@ * VIDEO */ -#define CONFIG_VIDEO_LOGO - #ifdef CONFIG_VIDEO_LOGO #ifdef CONFIG_SPLASH_SCREEN #define SPLASH_FILE logo.bmp diff --git a/include/configs/s5p_goni.h b/include/configs/s5p_goni.h index b4a3cc0445c..e3b091a9370 100644 --- a/include/configs/s5p_goni.h +++ b/include/configs/s5p_goni.h @@ -18,9 +18,6 @@ #include <linux/sizes.h> #include <asm/arch/cpu.h> /* get chip and board defs */ -/* input clock of PLL: has 24MHz input clock at S5PC110 */ -#define CONFIG_SYS_CLK_FREQ_C110 24000000 - /* DRAM Base */ #define CONFIG_SYS_SDRAM_BASE 0x30000000 @@ -70,8 +67,6 @@ "name="PARTS_CSC",size=150MiB,uuid=${uuid_gpt_"PARTS_CSC"};" \ "name="PARTS_UMS",size=-,uuid=${uuid_gpt_"PARTS_UMS"}\0" \ -#define CONFIG_BOOTCOMMAND "run mmcboot" - #define CONFIG_RAMDISK_BOOT "root=/dev/ram0 rw rootfstype=ext4" \ " ${console} ${meminfo}" diff --git a/include/configs/s5pc210_universal.h b/include/configs/s5pc210_universal.h index ff29de0d060..29adab33924 100644 --- a/include/configs/s5pc210_universal.h +++ b/include/configs/s5pc210_universal.h @@ -14,7 +14,6 @@ #define CONFIG_TIZEN /* TIZEN lib */ /* Keep L2 Cache Disabled */ -#define CONFIG_SYS_L2CACHE_OFF 1 /* Universal has 2 banks of DRAM */ #define CONFIG_SYS_SDRAM_BASE 0x40000000 @@ -22,8 +21,6 @@ #define SDRAM_BANK_SIZE (256 << 20) /* 256 MB */ -#define CONFIG_BOOTCOMMAND "run mmcboot" - #define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_LOAD_ADDR \ - GENERATED_GBL_DATA_SIZE) @@ -106,11 +103,6 @@ #define CONFIG_USB_GADGET_DWC2_OTG_PHY -/* - * SPI Settings - */ -#define CONFIG_SOFT_SPI - #ifndef __ASSEMBLY__ void universal_spi_scl(int bit); void universal_spi_sda(int bit); diff --git a/include/configs/salvator-x.h b/include/configs/salvator-x.h index 1eafff10ff3..c29b34e231a 100644 --- a/include/configs/salvator-x.h +++ b/include/configs/salvator-x.h @@ -23,7 +23,6 @@ #define CONFIG_FLASH_SHOW_PROGRESS 45 #define CONFIG_SYS_FLASH_QUIET_TEST #define CONFIG_SYS_FLASH_BANKS_LIST { 0x08000000 } -#define CONFIG_SYS_FLASH_CFI #define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_MAX_FLASH_BANKS_DETECT 1 #define CONFIG_SYS_MAX_FLASH_SECT 256 diff --git a/include/configs/sam9x60ek.h b/include/configs/sam9x60ek.h index df30d4868bd..eb96e501fb4 100644 --- a/include/configs/sam9x60ek.h +++ b/include/configs/sam9x60ek.h @@ -50,24 +50,12 @@ #ifdef CONFIG_SD_BOOT /* bootstrap + u-boot + env + linux in sd card */ -#define CONFIG_BOOTCOMMAND \ - "fatload mmc 0:1 0x21000000 at91-sam9x60ek.dtb;" \ - "fatload mmc 0:1 0x22000000 zImage;" \ - "bootz 0x22000000 - 0x21000000" #elif defined(CONFIG_NAND_BOOT) /* bootstrap + u-boot + env + linux in nandflash */ -#define CONFIG_BOOTCOMMAND "nand read " \ - "0x22000000 0x200000 0x600000; " \ - "nand read 0x21000000 0x180000 0x20000; " \ - "bootz 0x22000000 - 0x21000000" #elif defined(CONFIG_QSPI_BOOT) /* bootstrap + u-boot + env + linux in SPI NOR flash */ -#define CONFIG_BOOTCOMMAND "sf probe 0; " \ - "sf read 0x21000000 0x180000 0x80000; " \ - "sf read 0x22000000 0x200000 0x600000; " \ - "bootz 0x22000000 - 0x21000000" #endif #endif diff --git a/include/configs/sama5d27_som1_ek.h b/include/configs/sama5d27_som1_ek.h index 1c30e443923..f7d8fb63527 100644 --- a/include/configs/sama5d27_som1_ek.h +++ b/include/configs/sama5d27_som1_ek.h @@ -21,13 +21,8 @@ (0x22000000 + 16 * 1024 - GENERATED_GBL_DATA_SIZE) #endif -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_SD_BOOT /* bootstrap + u-boot + env in sd card */ -#define CONFIG_BOOTCOMMAND "fatload mmc " CONFIG_ENV_FAT_DEVICE_AND_PART " 0x22000000 " \ - CONFIG_DEFAULT_DEVICE_TREE ".dtb; " \ - "fatload mmc " CONFIG_ENV_FAT_DEVICE_AND_PART " 0x23000000 zImage; " \ - "bootz 0x23000000 - 0x22000000" #endif /* SPL */ diff --git a/include/configs/sama5d2_icp.h b/include/configs/sama5d2_icp.h index 53113f03799..c3a5c2ae323 100644 --- a/include/configs/sama5d2_icp.h +++ b/include/configs/sama5d2_icp.h @@ -25,21 +25,12 @@ (CONFIG_SYS_SDRAM_BASE + 16 * 1024 - GENERATED_GBL_DATA_SIZE) #endif -/* NAND flash */ - -/* SPI flash */ -#define CONFIG_SF_DEFAULT_SPEED 66000000 - -#undef CONFIG_BOOTCOMMAND #ifdef CONFIG_SD_BOOT /* u-boot env in sd/mmc card */ #define FAT_ENV_INTERFACE "mmc" #define FAT_ENV_DEVICE_AND_PART "0" #define FAT_ENV_FILE "uboot.env" /* bootstrap + u-boot + env in sd card */ -#define CONFIG_BOOTCOMMAND "fatload mmc 0:1 0x21000000 at91-sama5d2_icp.dtb; " \ - "fatload mmc 0:1 0x22000000 zImage; " \ - "bootz 0x22000000 - 0x21000000" #endif /* SPL */ diff --git a/include/configs/sama5d2_xplained.h b/include/configs/sama5d2_xplained.h index da573bc96a8..11c13c65d8d 100644 --- a/include/configs/sama5d2_xplained.h +++ b/include/configs/sama5d2_xplained.h @@ -23,31 +23,10 @@ #ifdef CONFIG_SD_BOOT /* bootstrap + u-boot + env in sd card */ -#undef CONFIG_BOOTCOMMAND - -#define CONFIG_BOOTCOMMAND "fatload mmc " CONFIG_ENV_FAT_DEVICE_AND_PART " 0x22000000 at91-sama5d2_xplained.dtb; " \ - "fatload mmc " CONFIG_ENV_FAT_DEVICE_AND_PART " 0x23000000 zImage; " \ - "bootz 0x23000000 - 0x22000000" #elif CONFIG_SPI_BOOT /* bootstrap + u-boot + env in sd card, but kernel + dtb in eMMC */ -#undef CONFIG_BOOTCOMMAND - -#define CONFIG_BOOTCOMMAND "ext4load mmc 0:1 0x22000000 /boot/at91-sama5d2_xplained.dtb; " \ - "ext4load mmc 0:1 0x23000000 /boot/zImage; " \ - "bootz 0x23000000 - 0x22000000" - -#endif - -#ifdef CONFIG_QSPI_BOOT -#undef CONFIG_ENV_SPI_BUS -#undef CONFIG_BOOTCOMMAND -#define CONFIG_ENV_SPI_BUS 1 -#define CONFIG_BOOTCOMMAND "sf probe 1:0; " \ - "sf read 0x22000000 0x180000 0x80000; " \ - "sf read 0x23000000 0x200000 0x600000; "\ - "bootz 0x23000000 - 0x22000000" #endif diff --git a/include/configs/sama7g5ek.h b/include/configs/sama7g5ek.h index 9b7cc2ce4d0..2aec9ffdc69 100644 --- a/include/configs/sama7g5ek.h +++ b/include/configs/sama7g5ek.h @@ -24,20 +24,6 @@ GENERATED_GBL_DATA_SIZE) #endif -#ifndef CONFIG_BOOTCOMMAND -#ifdef CONFIG_SD_BOOT -/* u-boot env in sd/mmc card */ - -/* bootstrap + u-boot + env in sd card */ -#define CONFIG_BOOTCOMMAND "fatload mmc " CONFIG_ENV_FAT_DEVICE_AND_PART " 0x61000000 at91-sama7g5ek.dtb; " \ - "fatload mmc " CONFIG_ENV_FAT_DEVICE_AND_PART " 0x62000000 zImage; " \ - "bootz 0x62000000 - 0x61000000" -#else -#define CONFIG_BOOTCOMMAND "Place your bootcommand here" -#endif - -#endif - #define CONFIG_ARP_TIMEOUT 200 #define CONFIG_NET_RETRY_COUNT 50 diff --git a/include/configs/sandbox.h b/include/configs/sandbox.h index d614b704715..cd7d99ec69c 100644 --- a/include/configs/sandbox.h +++ b/include/configs/sandbox.h @@ -10,24 +10,10 @@ #define CONFIG_IO_TRACE #endif -#ifndef CONFIG_TIMER -#define CONFIG_SYS_TIMER_RATE 1000000 -#endif - -#define CONFIG_HOST_MAX_DEVICES 4 - #define CONFIG_MALLOC_F_ADDR 0x0010000 #define CONFIG_SYS_CBSIZE 1024 /* Console I/O Buffer Size */ -/* turn on command-line edit/c/auto */ - -/* SPI - enable all SPI flash types for testing purposes */ - -#define CONFIG_SYS_FDT_LOAD_ADDR 0x100 - -#define CONFIG_PHYSMEM - /* Size of our emulated memory */ #define SB_CONCAT(x, y) x ## y #define SB_TO_UL(s) SB_CONCAT(s, UL) @@ -39,16 +25,6 @@ #define CONFIG_SYS_BAUDRATE_TABLE {4800, 9600, 19200, 38400, 57600,\ 115200} -#define BOOT_TARGET_DEVICES(func) \ - func(HOST, host, 1) \ - func(HOST, host, 0) - -#ifdef __ASSEMBLY__ -#define BOOTENV -#else -#include <config_distro_bootcmd.h> -#endif - #define CONFIG_KEEP_SERVERADDR #define CONFIG_UDP_CHECKSUM #define CONFIG_TIMESTAMP @@ -58,44 +34,6 @@ #define CONFIG_SANDBOX_SDL #endif -/* LCD and keyboard require SDL support */ -#ifdef CONFIG_SANDBOX_SDL -#define LCD_BPP LCD_COLOR16 -#define CONFIG_LCD_BMP_RLE8 - -#define CONFIG_KEYBOARD - -#define SANDBOX_SERIAL_SETTINGS "stdin=serial,cros-ec-keyb,usbkbd\0" \ - "stdout=serial,vidconsole\0" \ - "stderr=serial,vidconsole\0" -#else -#define SANDBOX_SERIAL_SETTINGS "stdin=serial\0" \ - "stdout=serial,vidconsole\0" \ - "stderr=serial,vidconsole\0" -#endif - -#define SANDBOX_ETH_SETTINGS "ethaddr=00:00:11:22:33:44\0" \ - "eth2addr=00:00:11:22:33:48\0" \ - "eth3addr=00:00:11:22:33:45\0" \ - "eth4addr=00:00:11:22:33:48\0" \ - "eth5addr=00:00:11:22:33:46\0" \ - "eth6addr=00:00:11:22:33:47\0" \ - "ipaddr=1.2.3.4\0" - -#define MEM_LAYOUT_ENV_SETTINGS \ - "bootm_size=0x10000000\0" \ - "kernel_addr_r=0x1000000\0" \ - "fdt_addr_r=0xc00000\0" \ - "ramdisk_addr_r=0x2000000\0" \ - "scriptaddr=0x1000\0" \ - "pxefile_addr_r=0x2000\0" - -#define CONFIG_EXTRA_ENV_SETTINGS \ - SANDBOX_SERIAL_SETTINGS \ - SANDBOX_ETH_SETTINGS \ - BOOTENV \ - MEM_LAYOUT_ENV_SETTINGS - #ifndef CONFIG_SPL_BUILD #define CONFIG_SYS_IDE_MAXBUS 1 #define CONFIG_SYS_ATA_IDE0_OFFSET 0 diff --git a/include/configs/seaboard.h b/include/configs/seaboard.h index c51517a76bf..e6c200f7612 100644 --- a/include/configs/seaboard.h +++ b/include/configs/seaboard.h @@ -27,7 +27,6 @@ /* Environment in eMMC, at the end of 2nd "boot sector" */ /* NAND support */ -#define CONFIG_TEGRA_NAND /* Max number of NAND devices */ #define CONFIG_SYS_MAX_NAND_DEVICE 1 diff --git a/include/configs/sheevaplug.h b/include/configs/sheevaplug.h index e28f98458e6..8dba4fcb4f8 100644 --- a/include/configs/sheevaplug.h +++ b/include/configs/sheevaplug.h @@ -9,12 +9,7 @@ #ifndef _CONFIG_SHEEVAPLUG_H #define _CONFIG_SHEEVAPLUG_H -/* - * High Level Configuration Options (easy to change) - */ -#define CONFIG_FEROCEON_88FR131 1 /* CPU Core subversion */ - -#include "mv-plug-common.h" +#include "mv-common.h" /* * Environment variables configurations @@ -32,9 +27,6 @@ /* * Default environment variables */ -#define CONFIG_BOOTCOMMAND "${x_bootcmd_kernel}; " \ - "setenv bootargs ${x_bootargs} ${x_bootargs_root}; " \ - "bootm 0x6400000;" #define CONFIG_EXTRA_ENV_SETTINGS "x_bootargs=console" \ "=ttyS0,115200 mtdparts="CONFIG_MTDPARTS_DEFAULT \ diff --git a/include/configs/siemens-ccp-common.h b/include/configs/siemens-ccp-common.h deleted file mode 100644 index 01051c8ad7d..00000000000 --- a/include/configs/siemens-ccp-common.h +++ /dev/null @@ -1,19 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* Be very careful updating CONFIG_IDENT_STRING - * This string will control the update flow whether an U-Boot should be - * updated or not. If the version of installed U-Boot (in flash) is smaller - * than the version to be installed (from update file), an update will - * be performed. - * - * General rules: - * 1. First 4 characters ' ##v' or IDENT_MAGIC represent kind of a magic number - * to identify the following strings after easily. Don't change them! - * - * 2. First 2 digits after 'v' or CCP_MAJOR are updated with U-Boot version - * change, e.g. from 2015.04 to 2018.03 - * - * 3. Second 2 digits after '.' or CCP_MINOR are updated if we want to upgrade - * U-Boot within an U-Boot version. - */ -#define CCP_IDENT_MAGIC " ##v" -#define GENERATE_CCP_VERSION(MAJOR, MINOR) CCP_IDENT_MAGIC MAJOR "." MINOR diff --git a/include/configs/sifive-unleashed.h b/include/configs/sifive-unleashed.h index 85356789eff..920f3140f64 100644 --- a/include/configs/sifive-unleashed.h +++ b/include/configs/sifive-unleashed.h @@ -74,10 +74,6 @@ "fdtfile=" CONFIG_DEFAULT_FDT_FILE "\0" \ BOOTENV \ BOOTENV_SF - -#define CONFIG_PREBOOT \ - "setenv fdt_addr ${fdtcontroladdr};" \ - "fdt addr ${fdtcontroladdr};" #endif #endif /* __CONFIG_H */ diff --git a/include/configs/sifive-unmatched.h b/include/configs/sifive-unmatched.h index f68d7d7676f..30adfe948f1 100644 --- a/include/configs/sifive-unmatched.h +++ b/include/configs/sifive-unmatched.h @@ -32,8 +32,6 @@ #define CONFIG_STANDALONE_LOAD_ADDR 0x80200000 -#define CONFIG_SYS_PCI_64BIT 1 /* enable 64-bit resources */ - #define CONFIG_SYS_SCSI_MAX_SCSI_ID 4 /* Environment options */ @@ -72,10 +70,6 @@ "partitions=" PARTS_DEFAULT "\0" \ "fdtfile=" CONFIG_DEFAULT_FDT_FILE "\0" \ BOOTENV - -#define CONFIG_PREBOOT \ - "setenv fdt_addr ${fdtcontroladdr};" \ - "fdt addr ${fdtcontroladdr};" #endif /* CONFIG_SPL_BUILD */ #define CONFIG_SYS_EEPROM_BUS_NUM 0 diff --git a/include/configs/silk.h b/include/configs/silk.h index eee60fdfabd..29350a635b2 100644 --- a/include/configs/silk.h +++ b/include/configs/silk.h @@ -35,8 +35,6 @@ #define CONFIG_BITBANGMII_MULTI /* Board Clock */ -#define RMOBILE_XTAL_CLK 20000000u -#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK #define CONFIG_EXTRA_ENV_SETTINGS \ "bootm_size=0x10000000\0" diff --git a/include/configs/slimbootloader.h b/include/configs/slimbootloader.h index b8169072cc8..ff0ed180e92 100644 --- a/include/configs/slimbootloader.h +++ b/include/configs/slimbootloader.h @@ -35,15 +35,5 @@ /* * Override CONFIG_BOOTCOMMAND in x86-common.h */ -#undef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND \ - "if test ${bootdev} = \"usb\"; then ${bootdev} start; fi; " \ - "if test ${bootdev} = \"scsi\"; then ${bootdev} scan; fi; " \ - "${bootdev} info; " \ - "${bootfsload} ${bootdev} ${bootdevnum}:${bootdevpart} " \ - "${loadaddr} ${bootfile}; " \ - "${bootfsload} ${bootdev} ${bootdevnum}:${bootdevpart} " \ - "${ramdiskaddr} ${ramdiskfile}; " \ - "zboot ${loadaddr} 0 ${ramdiskaddr} ${filesize}" #endif /* __SLIMBOOTLOADER_CONFIG_H__ */ diff --git a/include/configs/smartweb.h b/include/configs/smartweb.h index 7ce3aeafe3c..8bfd1fcd25a 100644 --- a/include/configs/smartweb.h +++ b/include/configs/smartweb.h @@ -91,11 +91,6 @@ /* BOOTP and DHCP options */ #define CONFIG_BOOTP_BOOTFILESIZE -#define NFSBOOTCOMMAND \ - "setenv autoload yes; setenv autoboot yes; " \ - "setenv bootargs ${basicargs} ${mtdparts} " \ - "root=/dev/nfs ip=dhcp nfsroot=${serverip}:/srv/nfs/rootfs; " \ - "dhcp" #if !defined(CONFIG_SPL_BUILD) /* USB configuration */ @@ -116,7 +111,6 @@ #endif /* General Boot Parameter */ -#define CONFIG_BOOTCOMMAND "run flashboot" #define CONFIG_SYS_CBSIZE 512 /* diff --git a/include/configs/smdk5250.h b/include/configs/smdk5250.h index 3af13673f2a..d7e86f2f764 100644 --- a/include/configs/smdk5250.h +++ b/include/configs/smdk5250.h @@ -14,7 +14,6 @@ #undef CONFIG_EXYNOS_FB #undef CONFIG_EXYNOS_DP -#undef CONFIG_KEYBOARD #define CONFIG_BOARD_COMMON diff --git a/include/configs/smdk5420.h b/include/configs/smdk5420.h index d06dfe43a23..38691b63daf 100644 --- a/include/configs/smdk5420.h +++ b/include/configs/smdk5420.h @@ -15,8 +15,6 @@ #undef CONFIG_EXYNOS_FB #undef CONFIG_EXYNOS_DP -#undef CONFIG_KEYBOARD - #define CONFIG_BOARD_COMMON #define CONFIG_SMDK5420 /* which is in a SMDK5420 */ diff --git a/include/configs/smdkc100.h b/include/configs/smdkc100.h index a5edf04a432..28ff48bf3d7 100644 --- a/include/configs/smdkc100.h +++ b/include/configs/smdkc100.h @@ -22,7 +22,6 @@ #include <asm/arch/cpu.h> /* get chip and board defs */ /* input clock of PLL: SMDKC100 has 12MHz input clock */ -#define CONFIG_SYS_CLK_FREQ 12000000 /* DRAM Base */ #define CONFIG_SYS_SDRAM_BASE 0x30000000 @@ -36,8 +35,6 @@ /* PWM */ #define CONFIG_PWM 1 -#define CONFIG_BOOTCOMMAND "run ubifsboot" - #define CONFIG_RAMDISK_BOOT "root=/dev/ram0 rw rootfstype=ext2" \ " console=ttySAC0,115200n8" \ " mem=128M" diff --git a/include/configs/smdkv310.h b/include/configs/smdkv310.h index 4a6b6258ab7..f113fa44045 100644 --- a/include/configs/smdkv310.h +++ b/include/configs/smdkv310.h @@ -26,8 +26,6 @@ /* MMC SPL */ #define COPY_BL2_FNPTR_ADDR 0x00002488 -#define CONFIG_BOOTCOMMAND "fatload mmc 0 40007000 uImage; bootm 40007000" - /* SMDKV310 has 4 bank of DRAM */ #define SDRAM_BANK_SIZE (512UL << 20UL) /* 512 MB */ #define PHYS_SDRAM_1 CONFIG_SYS_SDRAM_BASE diff --git a/include/configs/smegw01.h b/include/configs/smegw01.h index bbdd42b1afb..a7f77566042 100644 --- a/include/configs/smegw01.h +++ b/include/configs/smegw01.h @@ -16,7 +16,6 @@ /* MMC Config*/ #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 #define CONFIG_EXTRA_ENV_SETTINGS \ "image=zImage\0" \ @@ -36,11 +35,6 @@ "bootz ${loadaddr} - ${fdt_addr}; " \ "fi;\0" \ -#define CONFIG_BOOTCOMMAND \ - "if run loadimage; then " \ - "run mmcboot; " \ - "fi; " \ - /* Physical Memory Map */ #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR diff --git a/include/configs/snapper9g45.h b/include/configs/snapper9g45.h index de918e76803..3889a88ae98 100644 --- a/include/configs/snapper9g45.h +++ b/include/configs/snapper9g45.h @@ -45,9 +45,6 @@ #define CONFIG_AT91_WANTS_COMMON_PHY #define CONFIG_TFTP_PORT -/* MMC */ -#define CONFIG_GENERIC_ATMEL_MCI - /* LCD */ #define CONFIG_ATMEL_LCD #define CONFIG_GURNARD_SPLASH diff --git a/include/configs/sniper.h b/include/configs/sniper.h index 7c563b7b045..ca3da9547cb 100644 --- a/include/configs/sniper.h +++ b/include/configs/sniper.h @@ -102,16 +102,4 @@ * Boot */ -#define CONFIG_BOOTCOMMAND \ - "setenv boot_mmc_part ${kernel_mmc_part}; " \ - "if test reboot-${reboot-mode} = reboot-r; then " \ - "echo recovery; setenv boot_mmc_part ${recovery_mmc_part}; fi; " \ - "if test reboot-${reboot-mode} = reboot-b; then " \ - "echo fastboot; fastboot 0; fi; " \ - "part start mmc ${boot_mmc_dev} ${boot_mmc_part} boot_mmc_start; " \ - "part size mmc ${boot_mmc_dev} ${boot_mmc_part} boot_mmc_size; " \ - "mmc dev ${boot_mmc_dev}; " \ - "mmc read ${kernel_addr_r} ${boot_mmc_start} ${boot_mmc_size} && " \ - "bootm ${kernel_addr_r};" - #endif diff --git a/include/configs/socfpga_arria5_secu1.h b/include/configs/socfpga_arria5_secu1.h index 21e70c282a7..0935eaedacb 100644 --- a/include/configs/socfpga_arria5_secu1.h +++ b/include/configs/socfpga_arria5_secu1.h @@ -27,19 +27,6 @@ /* Booting Linux */ #define CONFIG_BOOTFILE "zImage" -#define CONFIG_BOOTCOMMAND \ - "setenv bootcmd '" \ - "bridge enable; " \ - "if test ${bootnum} = \"b\"; " \ - "then run _fpga_loadsafe; " \ - "else if test ${bootcount} -eq 4; then echo \"Switching copy...\"; setexpr x $bootnum % 2 && setexpr bootnum $x + 1; saveenv; fi; " \ - "run _fpga_loaduser; " \ - "fi;" \ - "echo \"Booting bank $bootnum\" && run userload && run userboot;" \ - "' && " \ - "setenv altbootcmd 'setenv bootnum b && saveenv && boot;' && " \ - "saveenv && saveenv && boot;" - #define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Environment settings */ @@ -108,7 +95,4 @@ /* The rest of the configuration is shared */ #include <configs/socfpga_common.h> -#undef CONFIG_WATCHDOG_TIMEOUT_MSECS -#define CONFIG_WATCHDOG_TIMEOUT_MSECS 60000 - #endif /* __CONFIG_SOCFPGA_SECU1_H__ */ diff --git a/include/configs/socfpga_common.h b/include/configs/socfpga_common.h index 31f95f52f8c..155aece4c31 100644 --- a/include/configs/socfpga_common.h +++ b/include/configs/socfpga_common.h @@ -187,10 +187,6 @@ unsigned int cm_get_qspi_controller_clk_hz(void); #if defined(CONFIG_SPL_FS_FAT) || defined(CONFIG_SPL_FS_EXT4) #define CONFIG_SPL_FS_LOAD_PAYLOAD_NAME "u-boot.img" #endif -#else -#ifndef CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_PARTITION 1 -#endif #endif /* SPL QSPI boot support */ diff --git a/include/configs/socfpga_dbm_soc1.h b/include/configs/socfpga_dbm_soc1.h index 137da2f1fcf..8acddbe8bb9 100644 --- a/include/configs/socfpga_dbm_soc1.h +++ b/include/configs/socfpga_dbm_soc1.h @@ -12,7 +12,6 @@ /* Booting Linux */ #define CONFIG_BOOTFILE "fitImage" -#define CONFIG_BOOTCOMMAND "run mmc_mmc" /* Environment is in MMC */ diff --git a/include/configs/socfpga_mcvevk.h b/include/configs/socfpga_mcvevk.h index 14562143255..3aa231c1521 100644 --- a/include/configs/socfpga_mcvevk.h +++ b/include/configs/socfpga_mcvevk.h @@ -12,7 +12,6 @@ /* Booting Linux */ #define CONFIG_BOOTFILE "fitImage" -#define CONFIG_BOOTCOMMAND "run mmc_mmc" /* Environment is in MMC */ diff --git a/include/configs/socfpga_soc64_common.h b/include/configs/socfpga_soc64_common.h index 4d7072c4dbf..928582ab8cf 100644 --- a/include/configs/socfpga_soc64_common.h +++ b/include/configs/socfpga_soc64_common.h @@ -60,7 +60,6 @@ /* Flash device info */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_MTD_PARTITIONS #define MTDIDS_DEFAULT "nor0=ff705000.spi.0" #endif /* CONFIG_SPL_BUILD */ @@ -148,7 +147,6 @@ unsigned int cm_get_qspi_controller_clk_hz(void); * L4 Watchdog */ #ifndef CONFIG_SPL_BUILD -#undef CONFIG_HW_WATCHDOG #undef CONFIG_DESIGNWARE_WATCHDOG #endif #define CONFIG_DW_WDT_BASE SOCFPGA_L4WD0_ADDRESS diff --git a/include/configs/socfpga_vining_fpga.h b/include/configs/socfpga_vining_fpga.h index d9d0a4af5ac..d7674928150 100644 --- a/include/configs/socfpga_vining_fpga.h +++ b/include/configs/socfpga_vining_fpga.h @@ -12,7 +12,6 @@ /* Booting Linux */ #define CONFIG_BOOTFILE "fitImage" -#define CONFIG_BOOTCOMMAND "run selboot" #define CONFIG_SYS_BOOTM_LEN 0x2000000 /* 32 MiB */ /* Extra Environment */ diff --git a/include/configs/socrates.h b/include/configs/socrates.h index 454dbd30b61..15e93d044ef 100644 --- a/include/configs/socrates.h +++ b/include/configs/socrates.h @@ -38,10 +38,6 @@ * in the README.mpc85xxads. */ -#ifndef CONFIG_SYS_CLK_FREQ -#define CONFIG_SYS_CLK_FREQ 66666666 -#endif - /* * These can be toggled for performance analysis, otherwise use default. */ @@ -97,11 +93,6 @@ #define CONFIG_SYS_LBC_FLASH_BASE CONFIG_SYS_FLASH1 /* Localbus flash start */ #define CONFIG_SYS_FLASH_BASE CONFIG_SYS_LBC_FLASH_BASE /* start of FLASH */ -#define CONFIG_SYS_BR0_PRELIM 0xfe001001 /* port size 16bit */ -#define CONFIG_SYS_OR0_PRELIM 0xfe000030 /* 32MB Flash */ -#define CONFIG_SYS_BR1_PRELIM 0xfc001001 /* port size 16bit */ -#define CONFIG_SYS_OR1_PRELIM 0xfe000030 /* 32MB Flash */ - #define CONFIG_SYS_MAX_FLASH_BANKS 2 /* number of banks */ #define CONFIG_SYS_MAX_FLASH_SECT 256 /* sectors per device */ #undef CONFIG_SYS_FLASH_CHECKSUM @@ -128,8 +119,6 @@ #define CONFIG_SYS_FPGA_BASE 0xc0000000 #define CONFIG_SYS_FPGA_SIZE 0x00100000 /* 1 MB */ #define CONFIG_SYS_HMI_BASE 0xc0010000 -#define CONFIG_SYS_BR3_PRELIM 0xc0001881 /* UPMA, 32-bit */ -#define CONFIG_SYS_OR3_PRELIM 0xfff00000 /* 1 MB */ #define CONFIG_SYS_NAND_BASE (CONFIG_SYS_FPGA_BASE + 0x70) #define CONFIG_SYS_MAX_NAND_DEVICE 1 @@ -137,8 +126,6 @@ /* LIME GDC */ #define CONFIG_SYS_LIME_BASE 0xc8000000 #define CONFIG_SYS_LIME_SIZE 0x04000000 /* 64 MB */ -#define CONFIG_SYS_BR2_PRELIM 0xc80018a1 /* UPMB, 32-bit */ -#define CONFIG_SYS_OR2_PRELIM 0xfc000000 /* 64 MB */ #define CONFIG_SYS_SPD_BUS_NUM 0 @@ -190,8 +177,6 @@ */ #define CONFIG_BOOTP_BOOTFILESIZE -#undef CONFIG_WATCHDOG /* watchdog disabled */ - /* * Miscellaneous configurable options */ @@ -258,7 +243,6 @@ "bootm ${kernel_addr_r} - ${fdt_addr};" \ "bootm ${kernel_addr} ${ramdisk_addr} ${fdt_addr}\0" \ "" -#define CONFIG_BOOTCOMMAND "run boot_nor" /* pass open firmware flat tree */ diff --git a/include/configs/somlabs_visionsom_6ull.h b/include/configs/somlabs_visionsom_6ull.h index a2fe54709da..768e33dd89e 100644 --- a/include/configs/somlabs_visionsom_6ull.h +++ b/include/configs/somlabs_visionsom_6ull.h @@ -53,19 +53,6 @@ "run setrootmmc; " \ "run setloadmmc; " \ -#define CONFIG_BOOTCOMMAND \ - "run setfdtfile; " \ - "run checkbootdev; " \ - "run loadfdt;" \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run setbootargs; " \ - "bootz ${loadaddr} - ${fdt_addr}; " \ - "fi; " \ - "fi" - /* Miscellaneous configurable options */ /* Physical Memory Map */ diff --git a/include/configs/stemmy.h b/include/configs/stemmy.h index e5571b240dc..96e759d99ca 100644 --- a/include/configs/stemmy.h +++ b/include/configs/stemmy.h @@ -14,6 +14,7 @@ * bootloader. New images are loaded at the same address for compatibility. */ #define CONFIG_SYS_INIT_SP_ADDR CONFIG_SYS_TEXT_BASE +#define CONFIG_SYS_BOOTM_LEN SZ_64M /* FIXME: This should be loaded from device tree... */ #define CONFIG_SYS_L2_PL310 diff --git a/include/configs/stm32mp15_common.h b/include/configs/stm32mp15_common.h index 4e2cabff2e7..dab679f71e3 100644 --- a/include/configs/stm32mp15_common.h +++ b/include/configs/stm32mp15_common.h @@ -142,6 +142,10 @@ "env_check=if env info -p -d -q; then env save; fi\0" \ "boot_net_usb_start=true\0" +#ifndef STM32MP_BOARD_EXTRA_ENV +#define STM32MP_BOARD_EXTRA_ENV +#endif + #include <config_distro_bootcmd.h> /* @@ -169,7 +173,8 @@ STM32MP_BOOTCMD \ STM32MP_PARTS_DEFAULT \ BOOTENV \ - STM32MP_EXTRA + STM32MP_EXTRA \ + STM32MP_BOARD_EXTRA_ENV #endif /* ifndef CONFIG_SPL_BUILD */ #endif /* ifdef CONFIG_DISTRO_DEFAULTS*/ diff --git a/include/configs/stm32mp15_dh_dhsom.h b/include/configs/stm32mp15_dh_dhsom.h index c559cd72da7..c79f0272cbe 100644 --- a/include/configs/stm32mp15_dh_dhsom.h +++ b/include/configs/stm32mp15_dh_dhsom.h @@ -8,6 +8,22 @@ #ifndef __CONFIG_STM32MP15_DH_DHSOM_H__ #define __CONFIG_STM32MP15_DH_DHSOM_H__ +/* PHY needs a longer autoneg timeout */ +#define PHY_ANEG_TIMEOUT 20000 + +#define STM32MP_BOARD_EXTRA_ENV \ + "usb_pgood_delay=1000\0" \ + "update_sf=" /* Erase SPI NOR and install U-Boot from SD */ \ + "setexpr loadaddr1 ${loadaddr} + 0x1000000 && " \ + "load mmc 0:4 ${loadaddr1} /boot/u-boot-spl.stm32 && " \ + "env set filesize1 ${filesize} && " \ + "load mmc 0:4 ${loadaddr} /boot/u-boot.itb && " \ + "sf probe && sf erase 0 0x200000 && " \ + "sf update ${loadaddr1} 0 ${filesize1} && " \ + "sf update ${loadaddr1} 0x40000 ${filesize1} && " \ + "sf update ${loadaddr} 0x80000 ${filesize} && " \ + "env set filesize1 && env set loadaddr1\0" + #include <configs/stm32mp15_common.h> #define CONFIG_SPL_TARGET "u-boot.itb" diff --git a/include/configs/stmark2.h b/include/configs/stmark2.h index 0a4cd84c15d..18a57f2231b 100644 --- a/include/configs/stmark2.h +++ b/include/configs/stmark2.h @@ -17,11 +17,6 @@ #define CONFIG_TIMESTAMP -#define CONFIG_BOOTCOMMAND \ - "sf probe 0:1 50000000; " \ - "sf read ${loadaddr} 0x100000 ${kern_size}; " \ - "bootm ${loadaddr}" - #define CONFIG_EXTRA_ENV_SETTINGS \ "kern_size=0x700000\0" \ "loadaddr=0x40001000\0" \ @@ -46,9 +41,6 @@ #define CONFIG_RTC_MCFRRTC #define CONFIG_SYS_MCFRRTC_BASE 0xFC0A8000 -/* spi not partitions */ -#define CONFIG_JFFS2_DEV "nor0" - /* Timer */ #define CONFIG_MCFTMR diff --git a/include/configs/stout.h b/include/configs/stout.h index a1e7e86f39a..df2d9676b5e 100644 --- a/include/configs/stout.h +++ b/include/configs/stout.h @@ -39,8 +39,6 @@ #define CONFIG_BITBANGMII_MULTI /* Board Clock */ -#define RMOBILE_XTAL_CLK 20000000u -#define CONFIG_SYS_CLK_FREQ RMOBILE_XTAL_CLK #define CONFIG_EXTRA_ENV_SETTINGS \ "bootm_size=0x10000000\0" diff --git a/include/configs/stv0991.h b/include/configs/stv0991.h index d3808842bd5..dd942168763 100644 --- a/include/configs/stv0991.h +++ b/include/configs/stv0991.h @@ -34,8 +34,6 @@ /* Misc configuration */ -#define CONFIG_BOOTCOMMAND "go 0x40040000" - /* + * QSPI support + */ diff --git a/include/configs/synquacer.h b/include/configs/synquacer.h index 3d099b4f11f..04095891525 100644 --- a/include/configs/synquacer.h +++ b/include/configs/synquacer.h @@ -41,15 +41,11 @@ #define CONFIG_SYS_FLASH_BASE (0x08000000) #define CONFIG_SYS_FLASH_BANKS_LIST {CONFIG_SYS_FLASH_BASE} -#define CONFIG_SYS_MEMTEST_START (CONFIG_SYS_SDRAM_BASE + (512 * 1024)) -#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_SDRAM_BASE + PHYS_SDRAM_SIZE) - #define CONFIG_SYS_CBSIZE 1024 #define CONFIG_SYS_MAXARGS 128 #define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16) /* Since U-Boot 64bit PCIe support is limited, disable 64bit MMIO support */ -/* #define CONFIG_SYS_PCI_64BIT 1 */ #define DEFAULT_DFU_ALT_INFO "dfu_alt_info=" \ "mtd nor1=u-boot.bin raw 200000 100000;" \ diff --git a/include/configs/tam3517-common.h b/include/configs/tam3517-common.h deleted file mode 100644 index a47e2c5b285..00000000000 --- a/include/configs/tam3517-common.h +++ /dev/null @@ -1,281 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * Copyright (C) 2011 - * Stefano Babic, DENX Software Engineering, sbabic@denx.de. - * - * Copyright (C) 2009 TechNexion Ltd. - */ - -#ifndef __TAM3517_H -#define __TAM3517_H - -/* - * High Level Configuration Options - */ - -#include <asm/arch/cpu.h> /* get chip and board defs */ -#include <asm/arch/omap.h> - -/* Clock Defines */ -#define V_OSCK 26000000 /* Clock output from T2 */ -#define V_SCLK (V_OSCK >> 1) - -/* - * DDR related - */ -#define CONFIG_SYS_CS0_SIZE (256 * 1024 * 1024) - -/* - * Hardware drivers - */ - -/* - * NS16550 Configuration - */ -#define CONFIG_SYS_NS16550_SERIAL -#define CONFIG_SYS_NS16550_REG_SIZE (-4) -#define CONFIG_SYS_NS16550_CLK 48000000 /* 48MHz (APLL96/2) */ - -/* - * select serial console configuration - */ -#define CONFIG_SYS_NS16550_COM1 OMAP34XX_UART1 - -#define CONFIG_SYS_BAUDRATE_TABLE {4800, 9600, 19200, 38400, 57600,\ - 115200} - -#define CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW 0x07 - -/* - * Board NAND Info. - */ -#define CONFIG_SYS_NAND_BASE NAND_BASE /* physical address */ - /* to access */ - /* nand at CS0 */ - -#define CONFIG_SYS_MAX_NAND_DEVICE 1 /* Max number of */ - /* NAND devices */ - -/* - * Miscellaneous configurable options - */ -#define CONFIG_SYS_CBSIZE 512 /* Console I/O Buffer Size */ - -#define CONFIG_SYS_MAXARGS 32 /* max number of command */ - /* args */ - -/* - * AM3517 has 12 GP timers, they can be driven by the system clock - * (12/13/16.8/19.2/38.4MHz) or by 32KHz clock. We use 13MHz (V_SCLK). - * This rate is divided by a local divisor. - */ -#define CONFIG_SYS_TIMERBASE OMAP34XX_GPT2 -#define CONFIG_SYS_PTV 2 /* Divisor: 2^(PTV+1) => 8 */ - -/* - * Physical Memory Map - */ -#define PHYS_SDRAM_1 OMAP34XX_SDRC_CS0 -#define PHYS_SDRAM_2 OMAP34XX_SDRC_CS1 - -/* - * FLASH and environment organization - */ - -/* **** PISMO SUPPORT *** */ - -/* Redundant Environment */ -#define CONFIG_SYS_ENV_SECT_SIZE (128 << 10) /* 128 KiB */ - -#define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM_1 -#define CONFIG_SYS_INIT_RAM_ADDR 0x4020f800 -#define CONFIG_SYS_INIT_RAM_SIZE 0x800 -#define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_INIT_RAM_ADDR + \ - CONFIG_SYS_INIT_RAM_SIZE - \ - GENERATED_GBL_DATA_SIZE) - -/* - * ethernet support, EMAC - * - */ -#define CONFIG_NET_RETRY_COUNT 10 - -/* Defines for SPL */ -#define CONFIG_SPL_CONSOLE -#define CONFIG_SPL_NAND_SOFTECC -#define CONFIG_SPL_NAND_WORKSPACE 0x8f07f000 /* below BSS */ - -#define CONFIG_SPL_MAX_SIZE (SRAM_SCRATCH_SPACE_ADDR - \ - CONFIG_SPL_TEXT_BASE) -#define CONFIG_SPL_STACK LOW_LEVEL_SRAM_STACK - -#define CONFIG_SYS_SPL_MALLOC_START 0x8f000000 -#define CONFIG_SYS_SPL_MALLOC_SIZE 0x80000 -#define CONFIG_SPL_BSS_START_ADDR 0x8f080000 /* end of RAM */ -#define CONFIG_SPL_BSS_MAX_SIZE 0x80000 - -#define CONFIG_SPL_FS_LOAD_PAYLOAD_NAME "u-boot.img" - -/* FAT */ -#define CONFIG_SPL_FS_LOAD_KERNEL_NAME "uImage" -#define CONFIG_SPL_FS_LOAD_ARGS_NAME "args" - -/* RAW SD card / eMMC */ -#define CONFIG_SYS_MMCSD_RAW_MODE_KERNEL_SECTOR 0x900 /* address 0x120000 */ -#define CONFIG_SYS_MMCSD_RAW_MODE_ARGS_SECTOR 0x80 /* address 0x10000 */ -#define CONFIG_SYS_MMCSD_RAW_MODE_ARGS_SECTORS 0x80 /* 64KiB */ - -/* NAND boot config */ -#define CONFIG_SYS_NAND_ECCPOS {40, 41, 42, 43, 44, 45, 46, 47,\ - 48, 49, 50, 51, 52, 53, 54, 55,\ - 56, 57, 58, 59, 60, 61, 62, 63} -#define CONFIG_SYS_NAND_ECCSIZE 256 -#define CONFIG_SYS_NAND_ECCBYTES 3 - -#define CONFIG_SYS_NAND_U_BOOT_START CONFIG_SYS_TEXT_BASE - -#define CONFIG_SYS_NAND_U_BOOT_SIZE 0x80000 - -/* Setup MTD for NAND on the SOM */ - -#define CONFIG_TAM3517_SETTINGS \ - "netdev=eth0\0" \ - "nandargs=setenv bootargs root=${nandroot} " \ - "rootfstype=${nandrootfstype}\0" \ - "nfsargs=setenv bootargs root=/dev/nfs rw " \ - "nfsroot=${serverip}:${rootpath}\0" \ - "ramargs=setenv bootargs root=/dev/ram rw\0" \ - "addip_sta=setenv bootargs ${bootargs} " \ - "ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}" \ - ":${hostname}:${netdev}:off panic=1\0" \ - "addip_dyn=setenv bootargs ${bootargs} ip=dhcp\0" \ - "addip=if test -n ${ipdyn};then run addip_dyn;" \ - "else run addip_sta;fi\0" \ - "addmtd=setenv bootargs ${bootargs} ${mtdparts}\0" \ - "addtty=setenv bootargs ${bootargs}" \ - " console=ttyO0,${baudrate}\0" \ - "addmisc=setenv bootargs ${bootargs} ${misc}\0" \ - "loadaddr=82000000\0" \ - "kernel_addr_r=82000000\0" \ - "hostname=" CONFIG_HOSTNAME "\0" \ - "bootfile=" CONFIG_HOSTNAME "/uImage\0" \ - "flash_self=run ramargs addip addtty addmtd addmisc;" \ - "bootm ${kernel_addr} ${ramdisk_addr}\0" \ - "flash_nfs=run nfsargs addip addtty addmtd addmisc;" \ - "bootm ${kernel_addr}\0" \ - "nandboot=run nandargs addip addtty addmtd addmisc;" \ - "nand read ${kernel_addr_r} kernel\0" \ - "bootm ${kernel_addr_r}\0" \ - "net_nfs=tftp ${kernel_addr_r} ${bootfile}; " \ - "run nfsargs addip addtty addmtd addmisc;" \ - "bootm ${kernel_addr_r}\0" \ - "net_self=if run net_self_load;then " \ - "run ramargs addip addtty addmtd addmisc;" \ - "bootm ${kernel_addr_r} ${ramdisk_addr_r};" \ - "else echo Images not loades;fi\0" \ - "u-boot=" CONFIG_HOSTNAME "/u-boot.img\0" \ - "load=tftp ${loadaddr} ${u-boot}\0" \ - "loadmlo=tftp ${loadaddr} ${mlo}\0" \ - "mlo=" CONFIG_HOSTNAME "/MLO\0" \ - "uboot_addr=0x80000\0" \ - "update=nandecc sw;nand erase ${uboot_addr} 100000;" \ - "nand write ${loadaddr} ${uboot_addr} 80000\0" \ - "updatemlo=nandecc hw;nand erase 0 20000;" \ - "nand write ${loadaddr} 0 20000\0" \ - "upd=if run load;then echo Updating u-boot;if run update;" \ - "then echo U-Boot updated;" \ - "else echo Error updating u-boot !;" \ - "echo Board without bootloader !!;" \ - "fi;" \ - "else echo U-Boot not downloaded..exiting;fi\0" \ - -/* - * this is common code for all TAM3517 boards. - * MAC address is stored from manufacturer in - * I2C EEPROM - */ -#if !(defined(__KERNEL_STRICT_NAMES) || defined(__ASSEMBLY__)) -/* - * The I2C EEPROM on the TAM3517 contains - * mac address and production data - */ -struct tam3517_module_info { - char customer[48]; - char product[48]; - - /* - * bit 0~47 : sequence number - * bit 48~55 : week of year, from 0. - * bit 56~63 : year - */ - unsigned long long sequence_number; - - /* - * bit 0~7 : revision fixed - * bit 8~15 : revision major - * bit 16~31 : TNxxx - */ - unsigned int revision; - unsigned char eth_addr[4][8]; - unsigned char _rev[100]; -}; - -#define TAM3517_READ_EEPROM(info, ret) \ -do { \ - i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE); \ - if (eeprom_read(CONFIG_SYS_I2C_EEPROM_ADDR, 0, \ - (void *)info, sizeof(*info))) \ - ret = 1; \ - else \ - ret = 0; \ -} while (0) - -#define TAM3517_READ_MAC_FROM_EEPROM(info) \ -do { \ - char buf[80], ethname[20]; \ - int i; \ - memset(buf, 0, sizeof(buf)); \ - for (i = 0 ; i < ARRAY_SIZE((info)->eth_addr); i++) { \ - sprintf(buf, "%02X:%02X:%02X:%02X:%02X:%02X", \ - (info)->eth_addr[i][5], \ - (info)->eth_addr[i][4], \ - (info)->eth_addr[i][3], \ - (info)->eth_addr[i][2], \ - (info)->eth_addr[i][1], \ - (info)->eth_addr[i][0]); \ - \ - if (i) \ - sprintf(ethname, "eth%daddr", i); \ - else \ - strcpy(ethname, "ethaddr"); \ - printf("Setting %s from EEPROM with %s\n", ethname, buf);\ - env_set(ethname, buf); \ - } \ -} while (0) - -/* The following macros are taken from Technexion's documentation */ -#define TAM3517_sequence_number(info) \ - ((info)->sequence_number % 0x1000000000000LL) -#define TAM3517_week_of_year(info) (((info)->sequence_number >> 48) % 0x100) -#define TAM3517_year(info) ((info)->sequence_number >> 56) -#define TAM3517_revision_fixed(info) ((info)->revision % 0x100) -#define TAM3517_revision_major(info) (((info)->revision >> 8) % 0x100) -#define TAM3517_revision_tn(info) ((info)->revision >> 16) - -#define TAM3517_PRINT_SOM_INFO(info) \ -do { \ - printf("Vendor:%s\n", (info)->customer); \ - printf("SOM: %s\n", (info)->product); \ - printf("SeqNr: %02llu%02llu%012llu\n", \ - TAM3517_year(info), \ - TAM3517_week_of_year(info), \ - TAM3517_sequence_number(info)); \ - printf("Rev: TN%u %u.%u\n", \ - TAM3517_revision_tn(info), \ - TAM3517_revision_major(info), \ - TAM3517_revision_fixed(info)); \ -} while (0) - -#endif - -#endif /* __TAM3517_H */ diff --git a/include/configs/tec.h b/include/configs/tec.h index aa9665eab59..432ccbdc32b 100644 --- a/include/configs/tec.h +++ b/include/configs/tec.h @@ -19,7 +19,6 @@ #define CONFIG_SYS_NS16550_COM1 NV_PA_APB_UARTD_BASE /* NAND support */ -#define CONFIG_TEGRA_NAND #define CONFIG_SYS_MAX_NAND_DEVICE 1 /* Environment in NAND, aligned to start of last sector */ diff --git a/include/configs/tegra-common.h b/include/configs/tegra-common.h index 673056ce517..99b7bd07aa0 100644 --- a/include/configs/tegra-common.h +++ b/include/configs/tegra-common.h @@ -12,7 +12,6 @@ /* * High Level Configuration Options */ -#define CONFIG_SYS_L2CACHE_OFF /* No L2 cache */ #include <asm/arch/tegra.h> /* get chip and board defs */ diff --git a/include/configs/tegra20-common.h b/include/configs/tegra20-common.h index 063213cbfeb..fac86927285 100644 --- a/include/configs/tegra20-common.h +++ b/include/configs/tegra20-common.h @@ -79,6 +79,4 @@ */ #define CONFIG_USB_EHCI_TXFIFO_THRESH 0x10 -#define CONFIG_SYS_NAND_SELF_INIT - #endif /* _TEGRA20_COMMON_H_ */ diff --git a/include/configs/theadorable-x86-common.h b/include/configs/theadorable-x86-common.h index 193c6c3bb5c..eaa19ee9b2d 100644 --- a/include/configs/theadorable-x86-common.h +++ b/include/configs/theadorable-x86-common.h @@ -22,7 +22,6 @@ /* Environment settings */ -#undef CONFIG_BOOTCOMMAND #undef CONFIG_EXTRA_ENV_SETTINGS #define CONFIG_EXTRA_ENV_SETTINGS \ diff --git a/include/configs/theadorable.h b/include/configs/theadorable.h index b43c03d3e8a..3c942cc6fa0 100644 --- a/include/configs/theadorable.h +++ b/include/configs/theadorable.h @@ -77,7 +77,7 @@ /* SPL */ /* Defines for SPL */ -#define CONFIG_SPL_MAX_SIZE ((128 << 10) - 0x4030) +#define CONFIG_SPL_MAX_SIZE ((128 << 10) - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + (128 << 10)) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/thuban.h b/include/configs/thuban.h index d45ff7d84da..3b120073fef 100644 --- a/include/configs/thuban.h +++ b/include/configs/thuban.h @@ -50,24 +50,6 @@ #ifndef CONFIG_RESTORE_FLASH /* set to negative value for no autoboot */ - -#define CONFIG_BOOTCOMMAND \ -"if dfubutton; then " \ - "run dfu_start; " \ - "reset; " \ -"fi;" \ -"run nand_boot;" \ -"run nand_boot_backup;" \ -"reset;" - -#else - -#define CONFIG_BOOTCOMMAND \ - "setenv autoload no; " \ - "dhcp; " \ - "if tftp 80000000 debrick.scr; then " \ - "source 80000000; " \ - "fi" #endif #endif /* CONFIG_SPL_BUILD */ #endif /* ! __CONFIG_THUBAN_H */ diff --git a/include/configs/ti814x_evm.h b/include/configs/ti814x_evm.h index ee63ce37cd9..0f786abeb84 100644 --- a/include/configs/ti814x_evm.h +++ b/include/configs/ti814x_evm.h @@ -56,22 +56,6 @@ "bootm ${loadaddr}\0" \ "fdtfile=ti814x-evm.dtb\0" \ -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "echo SD/MMC found on device ${mmcdev};" \ - "if run loadbootenv; then " \ - "echo Loaded environment from ${bootenv};" \ - "run importbootenv;" \ - "fi;" \ - "if test -n $uenvcmd; then " \ - "echo Running uenvcmd ...;" \ - "run uenvcmd;" \ - "fi;" \ - "if run loaduimage; then " \ - "run mmcboot;" \ - "fi;" \ - "fi;" \ - /* Clock Defines */ #define V_OSCK 24000000 /* Clock output from T2 */ #define V_SCLK (V_OSCK >> 1) diff --git a/include/configs/ti816x_evm.h b/include/configs/ti816x_evm.h index fa99152d6f6..533673ba5d3 100644 --- a/include/configs/ti816x_evm.h +++ b/include/configs/ti816x_evm.h @@ -17,11 +17,6 @@ "mtdids=" CONFIG_MTDIDS_DEFAULT "\0" \ "mtdparts=" CONFIG_MTDPARTS_DEFAULT "\0" \ -#define CONFIG_BOOTCOMMAND \ - "mmc rescan;" \ - "fatload mmc 0 ${loadaddr} uImage;" \ - "bootm ${loadaddr}" \ - /* Clock Defines */ #define V_OSCK 24000000 /* Clock output from T2 */ #define V_SCLK (V_OSCK >> 1) @@ -32,7 +27,6 @@ /** * Platform/Board specific defs */ -#define CONFIG_SYS_CLK_FREQ 27000000 #define CONFIG_SYS_TIMERBASE 0x4802E000 #define CONFIG_SYS_PTV 2 /* Divisor: 2^(PTV+1) => 8 */ diff --git a/include/configs/ti_armv7_common.h b/include/configs/ti_armv7_common.h index fa48cd2818c..797e1211980 100644 --- a/include/configs/ti_armv7_common.h +++ b/include/configs/ti_armv7_common.h @@ -37,6 +37,7 @@ "fdtaddr=0x88000000\0" \ "dtboaddr=0x89000000\0" \ "fdt_addr_r=0x88000000\0" \ + "fdtoverlay_addr_r=0x89000000\0" \ "rdaddr=0x88080000\0" \ "ramdisk_addr_r=0x88080000\0" \ "scriptaddr=0x80000000\0" \ diff --git a/include/configs/ti_armv7_keystone2.h b/include/configs/ti_armv7_keystone2.h index 8b0dd49e027..4a329bf6eca 100644 --- a/include/configs/ti_armv7_keystone2.h +++ b/include/configs/ti_armv7_keystone2.h @@ -205,24 +205,6 @@ "mtdparts=mtdparts=davinci_nand.0:" \ "1024k(bootloader)ro,512k(params)ro,-(ubifs)\0" -#ifndef CONFIG_BOOTCOMMAND -#ifndef CONFIG_TI_SECURE_DEVICE -#define CONFIG_BOOTCOMMAND \ - "run init_${boot}; " \ - "run get_mon_${boot} run_mon; " \ - "run get_kern_${boot}; " \ - "run init_fw_rd_${boot}; " \ - "run get_fdt_${boot}; " \ - "run run_kern" -#else -#define CONFIG_BOOTCOMMAND \ - "run run_mon_hs; " \ - "run init_${boot}; " \ - "run get_fit_${boot}; " \ - "bootm ${addr_fit}#${name_fdt}" -#endif -#endif - /* Now for the remaining common defines */ #include <configs/ti_armv7_common.h> diff --git a/include/configs/ti_omap5_common.h b/include/configs/ti_omap5_common.h index 055d108ddef..270ef9598d2 100644 --- a/include/configs/ti_omap5_common.h +++ b/include/configs/ti_omap5_common.h @@ -170,10 +170,6 @@ "exit; " \ "fi; " \ -#define FASTBOOT_CMD \ - "echo Booting into fastboot ...; " \ - "fastboot " __stringify(CONFIG_FASTBOOT_USB_DEV) "; " - #define DEFAULT_COMMON_BOOT_TI_ARGS \ "console=" CONSOLEDEV ",115200n8\0" \ "fdtfile=undefined\0" \ @@ -195,7 +191,7 @@ "if bcb test command = bootonce-bootloader; then " \ "echo Android: Bootloader boot...; " \ "bcb clear command; bcb store; " \ - FASTBOOT_CMD \ + "fastboot 1; " \ "exit; " \ "elif bcb test command = boot-recovery; then " \ "echo Android: Recovery boot...; " \ @@ -260,21 +256,6 @@ "if test $fdtfile = undefined; then " \ "echo WARNING: Could not determine device tree to use; fi; \0" -#define CONFIG_BOOTCOMMAND \ - "if test ${dofastboot} -eq 1; then " \ - "echo Boot fastboot requested, resetting dofastboot ...;" \ - "setenv dofastboot 0; saveenv;" \ - FASTBOOT_CMD \ - "fi;" \ - "if test ${boot_fit} -eq 1; then " \ - "run update_to_fit;" \ - "fi;" \ - "run findfdt; " \ - "run finduuid; " \ - "run distro_bootcmd;" \ - "run emmc_android_boot; " \ - "" - #define BOOT_TARGET_DEVICES(func) \ func(MMC, mmc, 0) \ func(MMC, mmc, 1) \ diff --git a/include/configs/topic_miami.h b/include/configs/topic_miami.h index 88bb4a8fd5e..ba6c3f0cec3 100644 --- a/include/configs/topic_miami.h +++ b/include/configs/topic_miami.h @@ -94,9 +94,4 @@ EXTRA_ENV_USB \ DFU_ALT_INFO -#undef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND "if mmcinfo; then " \ - "if fatload mmc 0 0x1900000 ${bootscript}; then source 0x1900000; " \ - "fi; fi; run $modeboot" - #endif /* __CONFIG_TOPIC_MIAMI_H */ diff --git a/include/configs/total_compute.h b/include/configs/total_compute.h index 933a145f993..c752da374b5 100644 --- a/include/configs/total_compute.h +++ b/include/configs/total_compute.h @@ -47,27 +47,6 @@ * without verification (for development purposes). * Else boot FIT image. */ -#define CONFIG_BOOTCOMMAND \ - "if part number mmc 0 vbmeta is_avb; then" \ - " echo MMC with vbmeta partition detected.;" \ - " echo starting Android Verified boot.;" \ - " avb init 0; " \ - " if avb verify; then " \ - " set bootargs $bootargs $avb_bootargs; " \ - " part start mmc 0 boot boot_start; " \ - " part size mmc 0 boot boot_size; " \ - " mmc read ${load_addr} ${boot_start} ${boot_size}; " \ - " bootm ${load_addr} ${load_addr} ${fdt_addr_r}; " \ - " else; " \ - " echo AVB verification failed.; " \ - " exit; " \ - " fi; " \ - "elif part number mmc 0 system is_non_avb_android; then " \ - " booti ${kernel_addr_r} ${initrd_addr_r} ${fdt_addr_r};" \ - "else;" \ - " echo Booting FIT image.;" \ - " bootm ${load_addr} ${load_addr} ${fdt_addr_r}; " \ - "fi;" /* Monitor Command Prompt */ #define CONFIG_SYS_CBSIZE 512 /* Console I/O Buffer Size */ diff --git a/include/configs/tplink_wdr4300.h b/include/configs/tplink_wdr4300.h index e6dc9f17fed..4d5b470685a 100644 --- a/include/configs/tplink_wdr4300.h +++ b/include/configs/tplink_wdr4300.h @@ -25,9 +25,6 @@ */ #define CONFIG_SYS_NS16550_CLK 40000000 -#define CONFIG_BOOTCOMMAND \ - "dhcp 192.168.1.1:wdr4300.fit && bootm $loadaddr" - /* * Command */ diff --git a/include/configs/tqma6.h b/include/configs/tqma6.h index 233031bc38a..633b100002f 100644 --- a/include/configs/tqma6.h +++ b/include/configs/tqma6.h @@ -119,9 +119,6 @@ "fi; fi; " \ "setenv filesize; setenv blkc \0" \ -#define CONFIG_BOOTCOMMAND \ - "run mmcboot; run netboot; run panicboot" - #elif defined(CONFIG_TQMA6X_SPI_BOOT) #define TQMA6_UBOOT_OFFSET 0x400 @@ -205,11 +202,7 @@ "setexpr offset ${fdt_start} * " \ __stringify(TQMA6_SPI_FLASH_SECTOR_SIZE)"; " \ "sf read ${fdt_addr} ${offset} ${size}; " \ - "setenv size ; setenv offset\0" \ - -#define CONFIG_BOOTCOMMAND \ - "sf probe; run mmcboot; run netboot; run panicboot" \ - + "setenv size ; setenv offset\0" #else #error "need to define boot source" diff --git a/include/configs/trats.h b/include/configs/trats.h index 396e9f28100..5217400b6bd 100644 --- a/include/configs/trats.h +++ b/include/configs/trats.h @@ -15,7 +15,6 @@ #define CONFIG_TIZEN /* TIZEN lib */ -#define CONFIG_SYS_L2CACHE_OFF #ifndef CONFIG_SYS_L2CACHE_OFF #define CONFIG_SYS_L2_PL310 #define CONFIG_SYS_PL310_BASE 0x10502000 @@ -26,8 +25,6 @@ #define PHYS_SDRAM_1 CONFIG_SYS_SDRAM_BASE #define SDRAM_BANK_SIZE (256 << 20) /* 256 MB */ -#define CONFIG_BOOTCOMMAND "run autoboot" - #define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_LOAD_ADDR \ - GENERATED_GBL_DATA_SIZE) diff --git a/include/configs/trats2.h b/include/configs/trats2.h index 114dd8e56fa..8d4b782372c 100644 --- a/include/configs/trats2.h +++ b/include/configs/trats2.h @@ -14,7 +14,6 @@ #define CONFIG_TIZEN /* TIZEN lib */ -#define CONFIG_SYS_L2CACHE_OFF #ifndef CONFIG_SYS_L2CACHE_OFF #define CONFIG_SYS_L2_PL310 #define CONFIG_SYS_PL310_BASE 0x10502000 @@ -25,8 +24,6 @@ #define PHYS_SDRAM_1 CONFIG_SYS_SDRAM_BASE #define SDRAM_BANK_SIZE (256 << 20) /* 256 MB */ -#define CONFIG_BOOTCOMMAND "run autoboot" - #define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_LOAD_ADDR \ - GENERATED_GBL_DATA_SIZE) diff --git a/include/configs/turris_omnia.h b/include/configs/turris_omnia.h index 9436a623d6f..b35299b2fbb 100644 --- a/include/configs/turris_omnia.h +++ b/include/configs/turris_omnia.h @@ -28,7 +28,7 @@ /* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10) -#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - 0x0030) +#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + CONFIG_SPL_SIZE) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/udoo.h b/include/configs/udoo.h index fe6ea68dd46..4bddc0eca30 100644 --- a/include/configs/udoo.h +++ b/include/configs/udoo.h @@ -28,7 +28,7 @@ "fdt_addr=0x18000000\0" \ "fdt_addr_r=0x18000000\0" \ "ip_dyn=yes\0" \ - "mmcdev=0\0" \ + "mmcdev=2\0" \ "mmcrootfstype=ext4\0" \ "findfdt="\ "if test ${board_rev} = MX6Q; then " \ @@ -44,7 +44,7 @@ BOOTENV #define BOOT_TARGET_DEVICES(func) \ - func(MMC, mmc, 0) \ + func(MMC, mmc, 2) \ func(SATA, sata, 0) \ func(DHCP, dhcp, na) diff --git a/include/configs/udoo_neo.h b/include/configs/udoo_neo.h index b06abc9286b..3a7cb050b10 100644 --- a/include/configs/udoo_neo.h +++ b/include/configs/udoo_neo.h @@ -29,7 +29,7 @@ "fdt_addr=0x83000000\0" \ "fdt_addr_r=0x83000000\0" \ "ip_dyn=yes\0" \ - "mmcdev=0\0" \ + "mmcdev=1\0" \ "mmcrootfstype=ext4\0" \ "findfdt="\ "if test $board_name = BASIC; then " \ @@ -49,7 +49,8 @@ BOOTENV #define BOOT_TARGET_DEVICES(func) \ - func(MMC, mmc, 0) \ + func(MMC, mmc, 1) \ + func(USB, usb, 0) \ func(DHCP, dhcp, na) #include <config_distro_bootcmd.h> diff --git a/include/configs/ulcb.h b/include/configs/ulcb.h index 1ce844f4920..bdd6b4b0d93 100644 --- a/include/configs/ulcb.h +++ b/include/configs/ulcb.h @@ -23,7 +23,6 @@ #define CONFIG_FLASH_SHOW_PROGRESS 45 #define CONFIG_SYS_FLASH_QUIET_TEST #define CONFIG_SYS_FLASH_BANKS_LIST { 0x08000000 } -#define CONFIG_SYS_FLASH_CFI #define CONFIG_SYS_FLASH_CFI_WIDTH FLASH_CFI_16BIT #define CONFIG_SYS_MAX_FLASH_BANKS_DETECT 1 #define CONFIG_SYS_MAX_FLASH_SECT 256 diff --git a/include/configs/uniphier.h b/include/configs/uniphier.h index dbd4a0089ec..fb7b83d285d 100644 --- a/include/configs/uniphier.h +++ b/include/configs/uniphier.h @@ -79,11 +79,6 @@ #endif #define CONFIG_ROOTPATH "/nfs/root/path" -#define NFSBOOTCOMMAND \ - "setenv bootargs $bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off;" \ - "run __nfsboot" #ifdef CONFIG_FIT #define CONFIG_BOOTFILE "fitImage" @@ -203,6 +198,4 @@ #define CONFIG_SPL_PAD_TO 0x20000 -#define CONFIG_SYS_PCI_64BIT - #endif /* __CONFIG_UNIPHIER_H__ */ diff --git a/include/configs/usb_a9263.h b/include/configs/usb_a9263.h index 49895e7ab30..ffa69009a12 100644 --- a/include/configs/usb_a9263.h +++ b/include/configs/usb_a9263.h @@ -63,7 +63,6 @@ #endif /* bootstrap + u-boot + env + linux in dataflash on CS0 */ -#define CONFIG_BOOTCOMMAND "nboot 21000000 0" #define CONFIG_EXTRA_ENV_SETTINGS \ "mtdparts=" CONFIG_MTDPARTS_DEFAULT "\0" \ diff --git a/include/configs/usbarmory.h b/include/configs/usbarmory.h index 6f5a1c89e82..0faa656bc63 100644 --- a/include/configs/usbarmory.h +++ b/include/configs/usbarmory.h @@ -10,8 +10,6 @@ #ifndef __CONFIG_H #define __CONFIG_H -#define CONFIG_SYS_FSL_CLK - #include <asm/arch/imx-regs.h> /* U-Boot environment */ @@ -36,12 +34,6 @@ /* Linux boot */ #define CONFIG_HOSTNAME "usbarmory" -#define CONFIG_BOOTCOMMAND \ - "run distro_bootcmd; " \ - "setenv bootargs console=${console} ${bootargs_default}; " \ - "ext2load mmc 0:1 ${kernel_addr_r} /boot/zImage; " \ - "ext2load mmc 0:1 ${fdt_addr_r} /boot/${fdtfile}; " \ - "bootz ${kernel_addr_r} - ${fdt_addr_r}" #define BOOT_TARGET_DEVICES(func) func(MMC, mmc, 0) diff --git a/include/configs/verdin-imx8mm.h b/include/configs/verdin-imx8mm.h index 7fbec270bff..17583c0a6af 100644 --- a/include/configs/verdin-imx8mm.h +++ b/include/configs/verdin-imx8mm.h @@ -11,8 +11,6 @@ #define CONFIG_SPL_MAX_SIZE (148 * 1024) #define CONFIG_SYS_MONITOR_LEN SZ_512K -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR -#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300 #define CONFIG_SYS_UBOOT_BASE \ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) @@ -103,7 +101,6 @@ /* USDHC */ #define CONFIG_SYS_FSL_USDHC_NUM 2 #define CONFIG_SYS_FSL_ESDHC_ADDR 0 -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 /* ENET */ #define CONFIG_ETHPRIME "FEC" diff --git a/include/configs/vexpress_aemv8a.h b/include/configs/vexpress_aemv8.h index df22584d9ab..54e8caeb7bc 100644 --- a/include/configs/vexpress_aemv8a.h +++ b/include/configs/vexpress_aemv8.h @@ -4,36 +4,39 @@ * configurations. */ -#ifndef __VEXPRESS_AEMV8A_H -#define __VEXPRESS_AEMV8A_H +#ifndef __VEXPRESS_AEMV8_H +#define __VEXPRESS_AEMV8_H + +#include <linux/stringify.h> #define CONFIG_REMAKE_ELF /* Link Definitions */ -#ifdef CONFIG_TARGET_VEXPRESS64_BASE_FVP +#ifdef CONFIG_TARGET_VEXPRESS64_JUNO +#define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_SDRAM_BASE + 0x7fff0) +#else /* ATF loads u-boot here for BASE_FVP model */ #define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_SDRAM_BASE + 0x03f00000) -#elif CONFIG_TARGET_VEXPRESS64_JUNO -#define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_SDRAM_BASE + 0x7fff0) #endif #define CONFIG_SYS_BOOTM_LEN (64 << 20) /* Increase max gunzip size */ /* CS register bases for the original memory map. */ -#define V2M_PA_CS0 0x00000000 -#define V2M_PA_CS1 0x14000000 -#define V2M_PA_CS2 0x18000000 -#define V2M_PA_CS3 0x1c000000 -#define V2M_PA_CS4 0x0c000000 -#define V2M_PA_CS5 0x10000000 +#define V2M_BASE 0x80000000 +#define V2M_PA_BASE 0x00000000 + +#define V2M_PA_CS0 (V2M_PA_BASE + 0x00000000) +#define V2M_PA_CS1 (V2M_PA_BASE + 0x14000000) +#define V2M_PA_CS2 (V2M_PA_BASE + 0x18000000) +#define V2M_PA_CS3 (V2M_PA_BASE + 0x1c000000) +#define V2M_PA_CS4 (V2M_PA_BASE + 0x0c000000) +#define V2M_PA_CS5 (V2M_PA_BASE + 0x10000000) #define V2M_PERIPH_OFFSET(x) (x << 16) #define V2M_SYSREGS (V2M_PA_CS3 + V2M_PERIPH_OFFSET(1)) #define V2M_SYSCTL (V2M_PA_CS3 + V2M_PERIPH_OFFSET(2)) #define V2M_SERIAL_BUS_PCI (V2M_PA_CS3 + V2M_PERIPH_OFFSET(3)) -#define V2M_BASE 0x80000000 - /* Common peripherals relative to CS7. */ #define V2M_AACI (V2M_PA_CS3 + V2M_PERIPH_OFFSET(4)) #define V2M_MMCI (V2M_PA_CS3 + V2M_PERIPH_OFFSET(5)) @@ -72,23 +75,23 @@ /* Generic Interrupt Controller Definitions */ #ifdef CONFIG_GICV3 -#define GICD_BASE (0x2f000000) -#define GICR_BASE (0x2f100000) +#define GICD_BASE (V2M_PA_BASE + 0x2f000000) +#define GICR_BASE (V2M_PA_BASE + 0x2f100000) #else -#ifdef CONFIG_TARGET_VEXPRESS64_BASE_FVP -#define GICD_BASE (0x2f000000) -#define GICC_BASE (0x2c000000) -#elif CONFIG_TARGET_VEXPRESS64_JUNO +#ifdef CONFIG_TARGET_VEXPRESS64_JUNO #define GICD_BASE (0x2C010000) #define GICC_BASE (0x2C02f000) +#else +#define GICD_BASE (V2M_PA_BASE + 0x2f000000) +#define GICC_BASE (V2M_PA_BASE + 0x2c000000) #endif #endif /* !CONFIG_GICV3 */ -#ifndef CONFIG_TARGET_VEXPRESS64_JUNO -/* The Vexpress64 simulators use SMSC91C111 */ +#if defined(CONFIG_TARGET_VEXPRESS64_BASE_FVP) && !defined(CONFIG_DM_ETH) +/* The Vexpress64 BASE_FVP simulator uses SMSC91C111 */ #define CONFIG_SMC91111 1 -#define CONFIG_SMC91111_BASE (0x01A000000) +#define CONFIG_SMC91111_BASE (V2M_PA_BASE + 0x01A000000) #endif /* PL011 Serial Configuration */ @@ -113,7 +116,7 @@ #ifdef CONFIG_TARGET_VEXPRESS64_JUNO #define PHYS_SDRAM_2 (0x880000000) #define PHYS_SDRAM_2_SIZE 0x180000000 -#elif CONFIG_TARGET_VEXPRESS64_BASE_FVP && CONFIG_NR_DRAM_BANKS == 2 +#elif CONFIG_NR_DRAM_BANKS == 2 #define PHYS_SDRAM_2 (0x880000000) #define PHYS_SDRAM_2_SIZE 0x80000000 #endif @@ -171,35 +174,22 @@ BOOTENV #elif CONFIG_TARGET_VEXPRESS64_BASE_FVP + +#define VEXPRESS_KERNEL_ADDR 0x80080000 +#define VEXPRESS_FDT_ADDR 0x8fc00000 +#define VEXPRESS_BOOT_ADDR 0x8fd00000 +#define VEXPRESS_RAMDISK_ADDR 0x8fe00000 + #define CONFIG_EXTRA_ENV_SETTINGS \ "kernel_name=Image\0" \ - "kernel_addr=0x80080000\0" \ - "initrd_name=ramdisk.img\0" \ - "initrd_addr=0x88000000\0" \ - "fdtfile=devtree.dtb\0" \ - "fdt_addr=0x83000000\0" \ - "boot_name=boot.img\0" \ - "boot_addr=0x8007f800\0" - -#ifndef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND "if smhload ${boot_name} ${boot_addr}; then " \ - " set bootargs; " \ - " abootimg addr ${boot_addr}; " \ - " abootimg get dtb --index=0 fdt_addr; " \ - " bootm ${boot_addr} ${boot_addr} " \ - " ${fdt_addr}; " \ - "else; " \ - " set fdt_high 0xffffffffffffffff; " \ - " set initrd_high 0xffffffffffffffff; " \ - " smhload ${kernel_name} ${kernel_addr}; " \ - " smhload ${fdtfile} ${fdt_addr}; " \ - " smhload ${initrd_name} ${initrd_addr} "\ - " initrd_end; " \ - " fdt addr ${fdt_addr}; fdt resize; " \ - " fdt chosen ${initrd_addr} ${initrd_end}; " \ - " booti $kernel_addr - $fdt_addr; " \ - "fi" -#endif + "kernel_addr_r=" __stringify(VEXPRESS_KERNEL_ADDR) "\0" \ + "ramdisk_name=ramdisk.img\0" \ + "ramdisk_addr_r=" __stringify(VEXPRESS_RAMDISK_ADDR) "\0" \ + "fdtfile=devtree.dtb\0" \ + "fdt_addr_r=" __stringify(VEXPRESS_FDT_ADDR) "\0" \ + "boot_name=boot.img\0" \ + "boot_addr_r=" __stringify(VEXPRESS_BOOT_ADDR) "\0" + #endif /* Monitor Command Prompt */ @@ -213,7 +203,7 @@ /* Store environment at top of flash in the same location as blank.img */ /* in the Juno firmware. */ #else -#define CONFIG_SYS_FLASH_BASE 0x0C000000 +#define CONFIG_SYS_FLASH_BASE (V2M_PA_BASE + 0x0C000000) /* 256 x 256KiB sectors */ #define CONFIG_SYS_MAX_FLASH_SECT 256 /* Store environment at top of flash */ @@ -230,4 +220,4 @@ #define CONFIG_SYS_FLASH_EMPTY_INFO /* flinfo indicates empty blocks */ #define FLASH_MAX_SECTOR_SIZE 0x00040000 -#endif /* __VEXPRESS_AEMV8A_H */ +#endif /* __VEXPRESS_AEMV8_H */ diff --git a/include/configs/vexpress_common.h b/include/configs/vexpress_common.h index 990f5ed5470..91d50bc4a00 100644 --- a/include/configs/vexpress_common.h +++ b/include/configs/vexpress_common.h @@ -109,8 +109,6 @@ /* Board info register */ #define SYS_ID V2M_SYSREGS -#define CONFIG_SYS_L2CACHE_OFF 1 - #define SCTL_BASE V2M_SYSCTL #define VEXPRESS_FLASHPROG_FLVPPEN (1 << 0) diff --git a/include/configs/veyron.h b/include/configs/veyron.h index 2ab6d6c6aac..ce9441d71f0 100644 --- a/include/configs/veyron.h +++ b/include/configs/veyron.h @@ -13,6 +13,4 @@ #include <configs/rk3288_common.h> -#define CONFIG_KEYBOARD - #endif diff --git a/include/configs/vf610twr.h b/include/configs/vf610twr.h index 6ec39a063d7..d90c2fa0534 100644 --- a/include/configs/vf610twr.h +++ b/include/configs/vf610twr.h @@ -11,8 +11,6 @@ #include <asm/arch/imx-regs.h> #include <linux/stringify.h> -#define CONFIG_SYS_FSL_CLK - /* NAND support */ #ifdef CONFIG_CMD_NAND @@ -127,18 +125,6 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - /* Miscellaneous configurable options */ /* Physical memory map */ diff --git a/include/configs/vinco.h b/include/configs/vinco.h index b353c372efe..7bd48820ed3 100644 --- a/include/configs/vinco.h +++ b/include/configs/vinco.h @@ -34,13 +34,11 @@ #ifdef CONFIG_CMD_SF #define CONFIG_ATMEL_SPI0 -#define CONFIG_SPI_FLASH_STMICRO #endif /* MMC */ #ifdef CONFIG_CMD_MMC -#define CONFIG_GENERIC_ATMEL_MCI #define ATMEL_BASE_MMCI 0xfc000000 #define CONFIG_SYS_MMC_CLK_OD 500000 @@ -60,11 +58,6 @@ /* Use our own mapping for the VInCo platform */ /* Update the bootcommand according to our mapping for the VInCo platform */ -#undef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND "mmc dev 0 0;" \ - "mmc read ${loadaddr} ${k_offset} ${k_blksize};" \ - "mmc read ${oftaddr} ${dtb_offset} ${dtb_blksize};" \ - "bootz ${loadaddr} - ${oftaddr}" #define CONFIG_EXTRA_ENV_SETTINGS \ "kernel_start=0x20000\0" \ diff --git a/include/configs/vocore2.h b/include/configs/vocore2.h index 58888d4caf0..c60da8ac123 100644 --- a/include/configs/vocore2.h +++ b/include/configs/vocore2.h @@ -30,7 +30,6 @@ #define CONFIG_SYS_NS16550_CLK 40000000 #define CONFIG_SYS_NS16550_REG_SIZE -4 #define CONFIG_SYS_NS16550_COM3 0xb0000e00 -#define CONFIG_CONS_INDEX 3 /* RAM */ diff --git a/include/configs/wandboard.h b/include/configs/wandboard.h index ece762e512d..051c18ca232 100644 --- a/include/configs/wandboard.h +++ b/include/configs/wandboard.h @@ -32,7 +32,6 @@ #define CONFIG_MXC_USB_FLAGS 0 /* Framebuffer */ -#define CONFIG_VIDEO_LOGO #define CONFIG_VIDEO_BMP_LOGO #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP diff --git a/include/configs/warp.h b/include/configs/warp.h index 11a9b31671b..8bdda377088 100644 --- a/include/configs/warp.h +++ b/include/configs/warp.h @@ -117,17 +117,4 @@ "bootz; " \ "fi;\0" -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev};" \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "else run netboot; " \ - "fi; " \ - "fi; " \ - "else run netboot; fi" - #endif /* __CONFIG_H */ diff --git a/include/configs/warp7.h b/include/configs/warp7.h index 00031d87c12..83ee1784ce9 100644 --- a/include/configs/warp7.h +++ b/include/configs/warp7.h @@ -16,7 +16,6 @@ /* MMC Config*/ #define CONFIG_SYS_FSL_ESDHC_ADDR USDHC3_BASE_ADDR #define CONFIG_SYS_FSL_ESDHC_HAS_DDR_MODE -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 #define CONFIG_DFU_ENV_SETTINGS \ "dfu_alt_info=boot raw 0x2 0x1000 mmcpart 1\0" \ @@ -40,12 +39,12 @@ "fdt_high=0xffffffff\0" \ "initrd_high=0xffffffff\0" \ "fdt_file=imx7s-warp.dtb\0" \ - "fdt_addr=" __stringify(CONFIG_SYS_FDT_ADDR)"\0" \ + "fdt_addr=0x83000000\0" \ "fdtovaddr=0x83100000\0" \ "boot_fdt=try\0" \ "ip_dyn=yes\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "rootpart=" __stringify(CONFIG_WARP7_ROOT_PART) "\0" \ "finduuid=part uuid mmc 0:${rootpart} uuid\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ @@ -83,19 +82,6 @@ "bootz; " \ "fi;\0" \ -#define CONFIG_BOOTCOMMAND \ - "mmc dev ${mmcdev};" \ - "mmc dev ${mmcdev}; if mmc rescan; then " \ - "run do_bootscript_hab;" \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "fi; " \ - "fi; " \ - "fi" - /* Physical Memory Map */ #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR diff --git a/include/configs/work_92105.h b/include/configs/work_92105.h index a45d3b4547b..a43fd81e45d 100644 --- a/include/configs/work_92105.h +++ b/include/configs/work_92105.h @@ -55,7 +55,6 @@ */ /* driver configuration */ -#define CONFIG_SYS_NAND_SELF_INIT #define CONFIG_SYS_MAX_NAND_DEVICE 1 #define CONFIG_SYS_MAX_NAND_CHIPS 1 #define CONFIG_SYS_NAND_BASE MLC_NAND_BASE @@ -64,8 +63,6 @@ * GPIO */ -#define CONFIG_LPC32XX_GPIO - /* * Environment */ diff --git a/include/configs/x530.h b/include/configs/x530.h index e78e249e41a..67ff01db904 100644 --- a/include/configs/x530.h +++ b/include/configs/x530.h @@ -68,7 +68,7 @@ /* Defines for SPL */ #define CONFIG_SPL_SIZE (140 << 10) -#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - 0x0030) +#define CONFIG_SPL_MAX_SIZE (CONFIG_SPL_SIZE - (CONFIG_SPL_TEXT_BASE - 0x40000000)) #define CONFIG_SPL_BSS_START_ADDR (0x40000000 + CONFIG_SPL_SIZE) #define CONFIG_SPL_BSS_MAX_SIZE (16 << 10) diff --git a/include/configs/x86-common.h b/include/configs/x86-common.h index 486b5ca7765..394978b9d90 100644 --- a/include/configs/x86-common.h +++ b/include/configs/x86-common.h @@ -14,8 +14,6 @@ * High Level Configuration Options * (easy to change) */ -#define CONFIG_PHYSMEM - #define CONFIG_SYS_BOOTM_LEN (16 << 20) /* SATA AHCI storage */ @@ -39,11 +37,6 @@ */ #define CONFIG_SYS_NS16550_PORT_MAPPED -#ifndef CONFIG_BOOTCOMMAND -#define CONFIG_BOOTCOMMAND \ - "ext2load scsi 0:3 01000000 /boot/vmlinuz; zboot 01000000" -#endif - /* * Miscellaneous configurable options */ @@ -88,9 +81,14 @@ #define DISTRO_BOOTENV #endif +#ifndef SPLASH_SETTINGS +#define SPLASH_SETTINGS +#endif + #define CONFIG_EXTRA_ENV_SETTINGS \ DISTRO_BOOTENV \ CONFIG_STD_DEVICES_SETTINGS \ + SPLASH_SETTINGS \ "pciconfighost=1\0" \ "netdev=eth0\0" \ "consoledev=ttyS0\0" \ @@ -101,21 +99,4 @@ "ramdiskfile=initramfs.gz\0" -#define RAMBOOTCOMMAND \ - "setenv bootargs root=/dev/ram rw " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftpboot $kernel_addr_r $bootfile;" \ - "tftpboot $ramdisk_addr_r $ramdiskfile;" \ - "zboot $kernel_addr_r 0 $ramdisk_addr_r $filesize" - -#define NFSBOOTCOMMAND \ - "setenv bootargs root=/dev/nfs rw " \ - "nfsroot=$serverip:$rootpath " \ - "ip=$ipaddr:$serverip:$gatewayip:$netmask:$hostname:$netdev:off " \ - "console=$consoledev,$baudrate $othbootargs;" \ - "tftpboot $kernel_addr_r $bootfile;" \ - "zboot $kernel_addr_r" - - #endif /* __CONFIG_H */ diff --git a/include/configs/xea.h b/include/configs/xea.h index 5081cc86912..aa48bb92631 100644 --- a/include/configs/xea.h +++ b/include/configs/xea.h @@ -29,10 +29,6 @@ #define CONFIG_SYS_MMCSD_RAW_MODE_ARGS_SECTORS (SZ_32K / 0x200) #define CONFIG_SYS_MMCSD_RAW_MODE_KERNEL_SECTOR (SZ_1M / 0x200) -#ifndef CONFIG_SPL_BUILD -#define CONFIG_SPI_FLASH_MTD -#endif - /* Memory configuration */ #define PHYS_SDRAM_1 0x40000000 /* Base address */ #define PHYS_SDRAM_1_SIZE 0x10000000 /* Max 256 MB RAM */ @@ -42,7 +38,6 @@ /* Booting Linux */ #define CONFIG_BOOTFILE "uImage" -#define CONFIG_BOOTCOMMAND "run ${bootpri} ; run ${bootsec}" /* Extra Environment */ #define CONFIG_HOSTNAME "xea" diff --git a/include/configs/xenguest_arm64.h b/include/configs/xenguest_arm64.h index c5e3d1678d0..408c7b5dd69 100644 --- a/include/configs/xenguest_arm64.h +++ b/include/configs/xenguest_arm64.h @@ -11,17 +11,8 @@ #define CONFIG_EXTRA_ENV_SETTINGS -#undef CONFIG_NR_DRAM_BANKS #undef CONFIG_SYS_SDRAM_BASE -#define CONFIG_NR_DRAM_BANKS 1 - -/* - * This can be any arbitrary address as we are using PIE, but - * please note, that CONFIG_SYS_TEXT_BASE must match the below. - */ -#define CONFIG_LNX_KRNL_IMG_TEXT_OFFSET_BASE CONFIG_SYS_LOAD_ADDR - /* Monitor Command Prompt */ #define CONFIG_SYS_CBSIZE 1024 #define CONFIG_SYS_MAXARGS 64 @@ -29,8 +20,6 @@ #define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + \ sizeof(CONFIG_SYS_PROMPT) + 16) -#define CONFIG_OF_SYSTEM_SETUP - #undef CONFIG_EXTRA_ENV_SETTINGS #define CONFIG_EXTRA_ENV_SETTINGS \ "loadimage=ext4load pvblock 0 0x90000000 /boot/Image;\0" \ diff --git a/include/configs/xilinx_versal.h b/include/configs/xilinx_versal.h index 43486457a45..03539a41b49 100644 --- a/include/configs/xilinx_versal.h +++ b/include/configs/xilinx_versal.h @@ -26,8 +26,6 @@ #endif /* Serial setup */ -#define CONFIG_CPU_ARMV8 - #define CONFIG_SYS_BAUDRATE_TABLE \ { 4800, 9600, 19200, 38400, 57600, 115200 } diff --git a/include/configs/xilinx_zynqmp.h b/include/configs/xilinx_zynqmp.h index e2148057875..f4b7f305bf7 100644 --- a/include/configs/xilinx_zynqmp.h +++ b/include/configs/xilinx_zynqmp.h @@ -26,8 +26,6 @@ #endif /* Serial setup */ -#define CONFIG_CPU_ARMV8 - #define CONFIG_SYS_BAUDRATE_TABLE \ { 4800, 9600, 19200, 38400, 57600, 115200 } @@ -39,10 +37,6 @@ # define CONFIG_SYS_MAX_NAND_DEVICE 1 #endif -#if defined(CONFIG_SPL_BUILD) -#define CONFIG_ZYNQMP_PSU_INIT_ENABLED -#endif - /* Miscellaneous configurable options */ #if defined(CONFIG_ZYNQMP_USB) diff --git a/include/configs/xilinx_zynqmp_mini.h b/include/configs/xilinx_zynqmp_mini.h index c1064431d24..c3c8b4cbf90 100644 --- a/include/configs/xilinx_zynqmp_mini.h +++ b/include/configs/xilinx_zynqmp_mini.h @@ -15,7 +15,6 @@ #include <configs/xilinx_zynqmp.h> /* Undef unneeded configs */ -#undef CONFIG_BOOTCOMMAND #undef CONFIG_EXTRA_ENV_SETTINGS #undef CONFIG_SYS_INIT_SP_ADDR diff --git a/include/configs/xilinx_zynqmp_r5.h b/include/configs/xilinx_zynqmp_r5.h index 6d5b81e05e1..3ec99e062df 100644 --- a/include/configs/xilinx_zynqmp_r5.h +++ b/include/configs/xilinx_zynqmp_r5.h @@ -8,9 +8,6 @@ #define CONFIG_EXTRA_ENV_SETTINGS -/* CPU clock */ -#define CONFIG_CPU_FREQ_HZ 500000000 - /* Serial drivers */ /* The following table includes the supported baudrates */ #define CONFIG_SYS_BAUDRATE_TABLE \ diff --git a/include/configs/xpress.h b/include/configs/xpress.h index f6645a72940..6d621f24bdd 100644 --- a/include/configs/xpress.h +++ b/include/configs/xpress.h @@ -48,8 +48,6 @@ #define CONFIG_FEC_XCV_TYPE RMII #define CONFIG_ETHPRIME "FEC" -#define CONFIG_SYS_MMC_IMG_LOAD_PART 1 - #define CONFIG_UBOOT_SECTOR_START 0x2 #define CONFIG_UBOOT_SECTOR_COUNT 0x3fe @@ -64,7 +62,7 @@ "boot_fdt=try\0" \ "ip_dyn=yes\0" \ "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \ - "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \ + "mmcpart=1\0" \ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \ "mmcautodetect=yes\0" \ "mmcargs=setenv bootargs console=${console},${baudrate} " \ diff --git a/include/configs/xtfpga.h b/include/configs/xtfpga.h index ccc90a66f7d..c8a6e9a61af 100644 --- a/include/configs/xtfpga.h +++ b/include/configs/xtfpga.h @@ -22,9 +22,6 @@ #define CONFIG_XTFPGA -/* FPGA CPU freq after init */ -#define CONFIG_SYS_CLK_FREQ (gd->cpu_clk) - /*===================*/ /* RAM Layout */ /*===================*/ @@ -169,7 +166,7 @@ #define CONFIG_SYS_NS16550_COM1 IOADDR(0x0D050020) /* Base address */ /* Input clk to NS16550 (in Hz; the SYS_CLK_FREQ is in kHz) */ -#define CONFIG_SYS_NS16550_CLK CONFIG_SYS_CLK_FREQ +#define CONFIG_SYS_NS16550_CLK get_board_sys_clk() /*======================*/ /* Ethernet Driver Info */ diff --git a/include/configs/zynq-common.h b/include/configs/zynq-common.h index 4de2f94b040..88c6490d81c 100644 --- a/include/configs/zynq-common.h +++ b/include/configs/zynq-common.h @@ -9,15 +9,9 @@ #ifndef __CONFIG_ZYNQ_COMMON_H #define __CONFIG_ZYNQ_COMMON_H -/* CPU clock */ -#ifndef CONFIG_CPU_FREQ_HZ -# define CONFIG_CPU_FREQ_HZ 800000000 -#endif - #define CONFIG_REMAKE_ELF /* Cache options */ -#define CONFIG_SYS_L2CACHE_OFF #ifndef CONFIG_SYS_L2CACHE_OFF # define CONFIG_SYS_L2_PL310 # define CONFIG_SYS_PL310_BASE 0xf8f02000 diff --git a/include/dm/device.h b/include/dm/device.h index 3028d002ab0..435a1114f1c 100644 --- a/include/dm/device.h +++ b/include/dm/device.h @@ -145,7 +145,7 @@ enum { * @uclass_node: Used by uclass to link its devices * @child_head: List of children of this device * @sibling_node: Next device in list of all devices - * @flags_: Flags for this device DM_FLAG_... (do not access outside driver + * @flags_: Flags for this device `DM_FLAG_...` (do not access outside driver * model) * @seq_: Allocated sequence number for this device (-1 = none). This is set up * when the device is bound and is unique within the device's uclass. If the @@ -193,14 +193,14 @@ struct udevice { }; /** - * udevice_rt - runtime information set up by U-Boot + * struct udevice_rt - runtime information set up by U-Boot * * This is only used with OF_PLATDATA_RT * * There is one of these for every udevice in the linker list, indexed by * the udevice_info idx value. * - * @flags_: Flags for this device DM_FLAG_... (do not access outside driver + * @flags_: Flags for this device `DM_FLAG_...` (do not access outside driver * model) */ struct udevice_rt { @@ -239,7 +239,7 @@ static inline void dev_bic_flags(struct udevice *dev, u32 bic) * dev_ofnode() - get the DT node reference associated with a udevice * * @dev: device to check - * @return reference of the the device's DT node + * Return: reference of the device's DT node */ static inline ofnode dev_ofnode(const struct udevice *dev) { @@ -351,7 +351,7 @@ struct udevice_id { * @ops: Driver-specific operations. This is typically a list of function * pointers defined by the driver, to implement driver functions required by * the uclass. - * @flags: driver flags - see DM_FLAGS_... + * @flags: driver flags - see `DM_FLAGS_...` * @acpi_ops: Advanced Configuration and Power Interface (ACPI) operations, * allowing the device to add things to the ACPI tables passed to Linux */ @@ -378,11 +378,24 @@ struct driver { #endif }; -/* Declare a new U-Boot driver */ +/** + * U_BOOT_DRIVER() - Declare a new U-Boot driver + * @__name: name of the driver + */ #define U_BOOT_DRIVER(__name) \ ll_entry_declare(struct driver, __name, driver) -/* Get a pointer to a given driver */ +/** + * DM_DRIVER_GET() - Get a pointer to a given driver + * + * This is useful in code for referencing a driver at build time. + * Before this is used, an extern U_BOOT_DRIVER() must have been + * declared. + * + * @__name: Name of the driver. This must be a valid C identifier, + * used by the linker_list + * Return: struct driver * for the driver + */ #define DM_DRIVER_GET(__name) \ ll_entry_get(struct driver, __name, driver) @@ -392,60 +405,69 @@ struct driver { * This is useful in data structures and code for referencing a driver at * build time. Before this is used, an extern U_BOOT_DRIVER() must have been * declared. + * This is like DM_DRIVER_GET, but without the extra code, so it is suitable + * for putting into data structures. * - * For example: - * - * extern U_BOOT_DRIVER(sandbox_fixed_clock); + * For example:: * - * struct driver *drvs[] = { - * DM_DRIVER_REF(sandbox_fixed_clock), - * }; + * extern U_BOOT_DRIVER(sandbox_fixed_clock); + * struct driver *drvs[] = { + * DM_DRIVER_REF(sandbox_fixed_clock), + * }; * - * @_name: Name of the driver. This must be a valid C identifier, used by the - * linker_list - * @returns struct driver * for the driver + * @_name: Name of the driver. This must be a valid C identifier, + * used by the linker_list + * Return: struct driver * for the driver */ #define DM_DRIVER_REF(_name) \ ll_entry_ref(struct driver, _name, driver) /** - * Declare a macro to state a alias for a driver name. This macro will - * produce no code but its information will be parsed by tools like - * dtoc + * DM_DRIVER_ALIAS() - Declare a macro to state an alias for a driver name + * + * This macro will produce no code but its information will be parsed by tools + * like dtoc + * + * @__name: name of driver + * @__alias: alias for the driver name */ #define DM_DRIVER_ALIAS(__name, __alias) /** - * Declare a macro to indicate which phase of U-Boot this driver is fore. - * + * DM_PHASE() - Declare a macro to indicate which phase of U-Boot this driver is for. * * This macro produces no code but its information will be parsed by dtoc. The * macro can be only be used once in a driver. Put it within the U_BOOT_DRIVER() - * declaration, e.g.: + * declaration, e.g.:: + * + * U_BOOT_DRIVER(cpu) = { + * .name = ... + * ... + * DM_PHASE(tpl) + * }; * - * U_BOOT_DRIVER(cpu) = { - * .name = ... - * ... - * DM_PHASE(tpl) - * }; + * @_phase: Associated phase of U-Boot ("spl", "tpl") */ #define DM_PHASE(_phase) /** - * Declare a macro to declare a header needed for a driver. Often the correct - * header can be found automatically, but only for struct declarations. For - * enums and #defines used in the driver declaration and declared in a different - * header from the structs, this macro must be used. + * DM_HEADER() - Declare a macro to declare a header needed for a driver. + * + * Often the correct header can be found automatically, but only for struct + * declarations. For enums and #defines used in the driver declaration and + * declared in a different header from the structs, this macro must be used. * * This macro produces no code but its information will be parsed by dtoc. The * macro can be used multiple times with different headers, for the same driver. - * Put it within the U_BOOT_DRIVER() declaration, e.g.: + * Put it within the U_BOOT_DRIVER() declaration, e.g.:: * - * U_BOOT_DRIVER(cpu) = { - * .name = ... - * ... - * DM_HEADER(<asm/cpu.h>) - * }; + * U_BOOT_DRIVER(cpu) = { + * .name = ... + * ... + * DM_HEADER(<asm/cpu.h>) + * }; + * + * @_hdr: header needed for a driver */ #define DM_HEADER(_hdr) @@ -454,8 +476,8 @@ struct driver { * * This checks that dev is not NULL, but no other checks for now * - * @dev Device to check - * @return platform data, or NULL if none + * @dev: Device to check + * Return: platform data, or NULL if none */ void *dev_get_plat(const struct udevice *dev); @@ -464,8 +486,8 @@ void *dev_get_plat(const struct udevice *dev); * * This checks that dev is not NULL, but no other checks for now * - * @dev Device to check - * @return parent's platform data, or NULL if none + * @dev: Device to check + * Return: parent's platform data, or NULL if none */ void *dev_get_parent_plat(const struct udevice *dev); @@ -474,8 +496,8 @@ void *dev_get_parent_plat(const struct udevice *dev); * * This checks that dev is not NULL, but no other checks for now * - * @dev Device to check - * @return uclass's platform data, or NULL if none + * @dev: Device to check + * Return: uclass's platform data, or NULL if none */ void *dev_get_uclass_plat(const struct udevice *dev); @@ -484,8 +506,8 @@ void *dev_get_uclass_plat(const struct udevice *dev); * * This checks that dev is not NULL, but no other checks for now * - * @dev Device to check - * @return private data, or NULL if none + * @dev: Device to check + * Return: private data, or NULL if none */ void *dev_get_priv(const struct udevice *dev); @@ -498,8 +520,8 @@ void *dev_get_priv(const struct udevice *dev); * * This checks that dev is not NULL, but no other checks for now * - * @dev Device to check - * @return parent data, or NULL if none + * @dev: Device to check + * Return: parent data, or NULL if none */ void *dev_get_parent_priv(const struct udevice *dev); @@ -508,16 +530,16 @@ void *dev_get_parent_priv(const struct udevice *dev); * * This checks that dev is not NULL, but no other checks for now * - * @dev Device to check - * @return private uclass data for this device, or NULL if none + * @dev: Device to check + * Return: private uclass data for this device, or NULL if none */ void *dev_get_uclass_priv(const struct udevice *dev); /** - * struct dev_get_parent() - Get the parent of a device + * dev_get_parent() - Get the parent of a device * * @child: Child to check - * @return parent of child, or NULL if this is the root device + * Return: parent of child, or NULL if this is the root device */ struct udevice *dev_get_parent(const struct udevice *child); @@ -529,13 +551,14 @@ struct udevice *dev_get_parent(const struct udevice *child); * returns the associated data value for that compatible string. This is * the 'data' field in struct udevice_id. * - * As an example, consider this structure: - * static const struct udevice_id tegra_i2c_ids[] = { - * { .compatible = "nvidia,tegra114-i2c", .data = TYPE_114 }, - * { .compatible = "nvidia,tegra20-i2c", .data = TYPE_STD }, - * { .compatible = "nvidia,tegra20-i2c-dvc", .data = TYPE_DVC }, - * { } - * }; + * As an example, consider this structure:: + * + * static const struct udevice_id tegra_i2c_ids[] = { + * { .compatible = "nvidia,tegra114-i2c", .data = TYPE_114 }, + * { .compatible = "nvidia,tegra20-i2c", .data = TYPE_STD }, + * { .compatible = "nvidia,tegra20-i2c-dvc", .data = TYPE_DVC }, + * { } + * }; * * When driver model finds a driver for this it will store the 'data' value * corresponding to the compatible string it matches. This function returns @@ -544,7 +567,7 @@ struct udevice *dev_get_parent(const struct udevice *child); * For USB devices, this is the driver_info field in struct usb_device_id. * * @dev: Device to check - * @return driver data (0 if none is provided) + * Return: driver data (0 if none is provided) */ ulong dev_get_driver_data(const struct udevice *dev); @@ -555,7 +578,7 @@ ulong dev_get_driver_data(const struct udevice *dev); * driver's operations. * * @dev: Device to check - * @return void pointer to driver's operations or NULL for NULL-dev or NULL-ops + * Return: void pointer to driver's operations or NULL for NULL-dev or NULL-ops */ const void *dev_get_driver_ops(const struct udevice *dev); @@ -563,7 +586,7 @@ const void *dev_get_driver_ops(const struct udevice *dev); * device_get_uclass_id() - return the uclass ID of a device * * @dev: Device to check - * @return uclass ID for the device + * Return: uclass ID for the device */ enum uclass_id device_get_uclass_id(const struct udevice *dev); @@ -573,7 +596,7 @@ enum uclass_id device_get_uclass_id(const struct udevice *dev); * This checks that dev is not NULL. * * @dev: Device to check - * @return pointer to the uclass name for the device + * Return: pointer to the uclass name for the device */ const char *dev_get_uclass_name(const struct udevice *dev); @@ -583,17 +606,17 @@ const char *dev_get_uclass_name(const struct udevice *dev); * Returns the numbered child, 0 being the first. This does not use * sequence numbers, only the natural order. * - * @dev: Parent device to check + * @parent: Parent device to check * @index: Child index * @devp: Returns pointer to device - * @return 0 if OK, -ENODEV if no such device, other error if the device fails - * to probe + * Return: + * 0 if OK, -ENODEV if no such device, other error if the device fails to probe */ int device_get_child(const struct udevice *parent, int index, struct udevice **devp); /** - * device_get_child_count() - Get the available child count of a device + * device_get_child_count() - Get the child count of a device * * Returns the number of children to a device. * @@ -602,6 +625,15 @@ int device_get_child(const struct udevice *parent, int index, int device_get_child_count(const struct udevice *parent); /** + * device_get_decendent_count() - Get the total number of decendents of a device + * + * Returns the total number of decendents, including all children + * + * @parent: Parent device to check + */ +int device_get_decendent_count(const struct udevice *parent); + +/** * device_find_child_by_seq() - Find a child device based on a sequence * * This searches for a device with the given seq. @@ -610,7 +642,7 @@ int device_get_child_count(const struct udevice *parent); * @seq: Sequence number to find (0=first) * @devp: Returns pointer to device (there is only one per for each seq). * Set to NULL if none is found - * @return 0 if OK, -ENODEV if not found + * Return: 0 if OK, -ENODEV if not found */ int device_find_child_by_seq(const struct udevice *parent, int seq, struct udevice **devp); @@ -628,7 +660,7 @@ int device_find_child_by_seq(const struct udevice *parent, int seq, * @seq: Sequence number to find (0=first) * @devp: Returns pointer to device (there is only one per for each seq) * Set to NULL if none is found - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int device_get_child_by_seq(const struct udevice *parent, int seq, struct udevice **devp); @@ -641,7 +673,7 @@ int device_get_child_by_seq(const struct udevice *parent, int seq, * @parent: Parent device * @of_offset: Device tree offset to find * @devp: Returns pointer to device if found, otherwise this is set to NULL - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int device_find_child_by_of_offset(const struct udevice *parent, int of_offset, struct udevice **devp); @@ -656,7 +688,7 @@ int device_find_child_by_of_offset(const struct udevice *parent, int of_offset, * @parent: Parent device * @of_offset: Device tree offset to find * @devp: Returns pointer to device if found, otherwise this is set to NULL - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int device_get_child_by_of_offset(const struct udevice *parent, int of_offset, struct udevice **devp); @@ -671,7 +703,7 @@ int device_get_child_by_of_offset(const struct udevice *parent, int of_offset, * * @node: Device tree ofnode to find * @devp: Returns pointer to device if found, otherwise this is set to NULL - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int device_find_global_by_ofnode(ofnode node, struct udevice **devp); @@ -686,7 +718,7 @@ int device_find_global_by_ofnode(ofnode node, struct udevice **devp); * * @node: Device tree ofnode to find * @devp: Returns pointer to device if found, otherwise this is set to NULL - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int device_get_global_by_ofnode(ofnode node, struct udevice **devp); @@ -706,7 +738,7 @@ int device_get_global_by_ofnode(ofnode node, struct udevice **devp); * * @idx: Index number of the driver_info/udevice structure (0=first) * @devp: Returns pointer to device if found, otherwise this is set to NULL - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int device_get_by_ofplat_idx(uint idx, struct udevice **devp); @@ -715,7 +747,7 @@ int device_get_by_ofplat_idx(uint idx, struct udevice **devp); * * @parent: Parent device to search * @devp: Returns first child device, or NULL if none - * @return 0 + * Return: 0 */ int device_find_first_child(const struct udevice *parent, struct udevice **devp); @@ -725,7 +757,7 @@ int device_find_first_child(const struct udevice *parent, * * @devp: Pointer to previous child device on entry. Returns pointer to next * child device, or NULL if none - * @return 0 + * Return: 0 */ int device_find_next_child(struct udevice **devp); @@ -740,7 +772,7 @@ int device_find_next_child(struct udevice **devp); * @parent: Parent device to search * @uclass_id: Uclass to look for * @devp: Returns device found, if any, else NULL - * @return 0 if found, else -ENODEV + * Return: 0 if found, else -ENODEV */ int device_find_first_inactive_child(const struct udevice *parent, enum uclass_id uclass_id, @@ -752,7 +784,7 @@ int device_find_first_inactive_child(const struct udevice *parent, * @parent: Parent device to search * @uclass_id: Uclass to look for * @devp: Returns first child device in that uclass, if any, else NULL - * @return 0 if found, else -ENODEV + * Return: 0 if found, else -ENODEV */ int device_find_first_child_by_uclass(const struct udevice *parent, enum uclass_id uclass_id, @@ -763,8 +795,20 @@ int device_find_first_child_by_uclass(const struct udevice *parent, * * @parent: Parent device to search * @name: Name to look for + * @len: Length of the name * @devp: Returns device found, if any - * @return 0 if found, else -ENODEV + * Return: 0 if found, else -ENODEV + */ +int device_find_child_by_namelen(const struct udevice *parent, const char *name, + int len, struct udevice **devp); + +/** + * device_find_child_by_name() - Find a child by device name + * + * @parent: Parent device to search + * @name: Name to look for + * @devp: Returns device found, if any + * Return: 0 if found, else -ENODEV */ int device_find_child_by_name(const struct udevice *parent, const char *name, struct udevice **devp); @@ -777,7 +821,7 @@ int device_find_child_by_name(const struct udevice *parent, const char *name, * * @parent: Parent to check * @devp: Returns child that was found, if any - * @return 0 on success, -ENODEV if no children, other -ve on error + * Return: 0 on success, -ENODEV if no children, other -ve on error */ int device_first_child_ofdata_err(struct udevice *parent, struct udevice **devp); @@ -790,7 +834,7 @@ int device_first_child_ofdata_err(struct udevice *parent, * * @devp: On entry, points to the previous child; on exit returns the child that * was found, if any - * @return 0 on success, -ENODEV if no children, other -ve on error + * Return: 0 on success, -ENODEV if no children, other -ve on error */ int device_next_child_ofdata_err(struct udevice **devp); @@ -801,7 +845,7 @@ int device_next_child_ofdata_err(struct udevice **devp); * * @parent: Parent device to search * @devp: Returns device found, if any - * @return 0 if found, -ENODEV if not, -ve error if device failed to probe + * Return: 0 if found, -ENODEV if not, -ve error if device failed to probe */ int device_first_child_err(struct udevice *parent, struct udevice **devp); @@ -812,7 +856,7 @@ int device_first_child_err(struct udevice *parent, struct udevice **devp); * * @devp: On entry, pointer to device to lookup. On exit, returns pointer * to the next sibling if no error occurred - * @return 0 if found, -ENODEV if not, -ve error if device failed to probe + * Return: 0 if found, -ENODEV if not, -ve error if device failed to probe */ int device_next_child_err(struct udevice **devp); @@ -820,7 +864,7 @@ int device_next_child_err(struct udevice **devp); * device_has_children() - check if a device has any children * * @dev: Device to check - * @return true if the device has one or more children + * Return: true if the device has one or more children */ bool device_has_children(const struct udevice *dev); @@ -828,7 +872,7 @@ bool device_has_children(const struct udevice *dev); * device_has_active_children() - check if a device has any active children * * @dev: Device to check - * @return true if the device has one or more children and at least one of + * Return: true if the device has one or more children and at least one of * them is active (probed). */ bool device_has_active_children(const struct udevice *dev); @@ -841,7 +885,7 @@ bool device_has_active_children(const struct udevice *dev); * view of devices is being displayed. * * @dev: Device to check - * @return true if there are no more siblings after this one - i.e. is it + * Return: true if there are no more siblings after this one - i.e. is it * last in the list. */ bool device_is_last_sibling(const struct udevice *dev); @@ -859,7 +903,7 @@ bool device_is_last_sibling(const struct udevice *dev); * @dev: Device to update * @name: New name (this string is allocated new memory and attached to * the device) - * @return 0 if OK, -ENOMEM if there is not enough memory to allocate the + * Return: 0 if OK, -ENOMEM if there is not enough memory to allocate the * string */ int device_set_name(struct udevice *dev, const char *name); @@ -882,7 +926,7 @@ void device_set_name_alloced(struct udevice *dev); * @dev: udevice pointer for which compatible needs to be verified. * @compat: Compatible string which needs to verified in the given * device - * @return true if OK, false if the compatible is not found + * Return: true if OK, false if the compatible is not found */ bool device_is_compatible(const struct udevice *dev, const char *compat); @@ -893,7 +937,7 @@ bool device_is_compatible(const struct udevice *dev, const char *compat); * This allows to check whether the machine is comaptible with the compat. * * @compat: Compatible string which needs to verified - * @return true if OK, false if the compatible is not found + * Return: true if OK, false if the compatible is not found */ bool of_machine_is_compatible(const char *compat); @@ -901,7 +945,7 @@ bool of_machine_is_compatible(const char *compat); * dev_disable_by_path() - Disable a device given its device tree path * * @path: The device tree path identifying the device to be disabled - * @return 0 on success, -ve on error + * Return: 0 on success, -ve on error */ int dev_disable_by_path(const char *path); @@ -909,7 +953,7 @@ int dev_disable_by_path(const char *path); * dev_enable_by_path() - Enable a device given its device tree path * * @path: The device tree path identifying the device to be enabled - * @return 0 on success, -ve on error + * Return: 0 on success, -ve on error */ int dev_enable_by_path(const char *path); @@ -917,7 +961,7 @@ int dev_enable_by_path(const char *path); * device_is_on_pci_bus - Test if a device is on a PCI bus * * @dev: device to test - * @return: true if it is on a PCI bus, false otherwise + * Return: true if it is on a PCI bus, false otherwise */ static inline bool device_is_on_pci_bus(const struct udevice *dev) { @@ -950,7 +994,7 @@ static inline bool device_is_on_pci_bus(const struct udevice *dev) * * This stops when it gets an error, with @pos set to the device that failed to * read ofdata. - + * * This creates a for() loop which works through the available children of * a device in order from start to end. Device ofdata is read by calling * device_of_to_plat() on each one. The devices are not probed. @@ -959,8 +1003,8 @@ static inline bool device_is_on_pci_bus(const struct udevice *dev) * @parent: parent device to scan */ #define device_foreach_child_of_to_plat(pos, parent) \ - for (int _ret = device_first_child_ofdata_err(parent, &dev); !_ret; \ - _ret = device_next_child_ofdata_err(&dev)) + for (int _ret = device_first_child_ofdata_err(parent, &pos); !_ret; \ + _ret = device_next_child_ofdata_err(&pos)) /** * device_foreach_child_probe() - iterate through children, probing them @@ -976,8 +1020,8 @@ static inline bool device_is_on_pci_bus(const struct udevice *dev) * @parent: parent device to scan */ #define device_foreach_child_probe(pos, parent) \ - for (int _ret = device_first_child_err(parent, &dev); !_ret; \ - _ret = device_next_child_err(&dev)) + for (int _ret = device_first_child_err(parent, &pos); !_ret; \ + _ret = device_next_child_err(&pos)) /** * dm_scan_fdt_dev() - Bind child device in the device tree @@ -991,7 +1035,7 @@ static inline bool device_is_on_pci_bus(const struct udevice *dev) * be bound. * * @dev: Device to scan - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_scan_fdt_dev(struct udevice *dev); diff --git a/include/dm/devres.h b/include/dm/devres.h index 17bb1ee8dad..0ab277ec38e 100644 --- a/include/dm/devres.h +++ b/include/dm/devres.h @@ -51,7 +51,7 @@ void *_devres_alloc(dr_release_t release, size_t size, gfp_t gfp); * with @release. The returned pointer can be passed to * other devres_*() functions. * - * RETURNS: + * Return: * Pointer to allocated devres on success, NULL on failure. */ #define devres_alloc(release, size, gfp) \ @@ -87,7 +87,7 @@ void devres_add(struct udevice *dev, void *res); * and for which @match returns 1. If @match is NULL, it's considered * to match all. * - * @return pointer to found devres, NULL if not found. + * Return: pointer to found devres, NULL if not found. */ void *devres_find(struct udevice *dev, dr_release_t release, dr_match_t match, void *match_data); @@ -103,7 +103,7 @@ void *devres_find(struct udevice *dev, dr_release_t release, * as @new_res and for which @match return 1. If found, @new_res is * freed; otherwise, @new_res is added atomically. * - * @return ointer to found or added devres. + * Return: pointer to found or added devres. */ void *devres_get(struct udevice *dev, void *new_res, dr_match_t match, void *match_data); @@ -120,7 +120,7 @@ void *devres_get(struct udevice *dev, void *new_res, * match all. If found, the resource is removed atomically and * returned. * - * @return ointer to removed devres on success, NULL if not found. + * Return: pointer to removed devres on success, NULL if not found. */ void *devres_remove(struct udevice *dev, dr_release_t release, dr_match_t match, void *match_data); @@ -140,7 +140,7 @@ void *devres_remove(struct udevice *dev, dr_release_t release, * only the devres-allocated data will be freed. The caller becomes * responsible for freeing any other data. * - * @return 0 if devres is found and freed, -ENOENT if not found. + * Return: 0 if devres is found and freed, -ENOENT if not found. */ int devres_destroy(struct udevice *dev, dr_release_t release, dr_match_t match, void *match_data); @@ -157,7 +157,7 @@ int devres_destroy(struct udevice *dev, dr_release_t release, * match all. If found, the resource is removed atomically, the * release function called and the resource freed. * - * @return 0 if devres is found and freed, -ENOENT if not found. + * Return: 0 if devres is found and freed, -ENOENT if not found. */ int devres_release(struct udevice *dev, dr_release_t release, dr_match_t match, void *match_data); @@ -173,7 +173,7 @@ int devres_release(struct udevice *dev, dr_release_t release, * automatically freed on driver detach. Like all other devres * resources, guaranteed alignment is unsigned long long. * - * @return pointer to allocated memory on success, NULL on failure. + * Return: pointer to allocated memory on success, NULL on failure. */ void *devm_kmalloc(struct udevice *dev, size_t size, gfp_t gfp); static inline void *devm_kzalloc(struct udevice *dev, size_t size, gfp_t gfp) diff --git a/include/dm/fdtaddr.h b/include/dm/fdtaddr.h index d2c19942916..c9d2b27ba6e 100644 --- a/include/dm/fdtaddr.h +++ b/include/dm/fdtaddr.h @@ -19,7 +19,7 @@ struct udevice; * * @dev: Pointer to a device * - * @return addr + * Return: addr */ fdt_addr_t devfdt_get_addr(const struct udevice *dev); @@ -29,7 +29,7 @@ fdt_addr_t devfdt_get_addr(const struct udevice *dev); * * @dev: Pointer to a device * - * @return Pointer to addr, or NULL if there is no such property + * Return: Pointer to addr, or NULL if there is no such property */ void *devfdt_get_addr_ptr(const struct udevice *dev); @@ -39,7 +39,7 @@ void *devfdt_get_addr_ptr(const struct udevice *dev); * * @dev: Pointer to a device * - * @return Pointer to addr, or NULL if there is no such property + * Return: Pointer to addr, or NULL if there is no such property */ void *devfdt_remap_addr(const struct udevice *dev); @@ -51,7 +51,7 @@ void *devfdt_remap_addr(const struct udevice *dev); * * @dev: Pointer to a device * - * @return Pointer to addr, or NULL if there is no such property + * Return: Pointer to addr, or NULL if there is no such property */ void *devfdt_remap_addr_index(const struct udevice *dev, int index); @@ -64,7 +64,7 @@ void *devfdt_remap_addr_index(const struct udevice *dev, int index); * * @dev: Pointer to a device * - * @return Pointer to addr, or NULL if there is no such property + * Return: Pointer to addr, or NULL if there is no such property */ void *devfdt_remap_addr_name(const struct udevice *dev, const char *name); @@ -76,8 +76,7 @@ void *devfdt_remap_addr_name(const struct udevice *dev, const char *name); * @dev: Pointer to device * @size: size of the memory to map * - * @return mapped address, or NULL if the device does not have reg - * property. + * Return: mapped address, or NULL if the device does not have reg property. */ void *devfdt_map_physmem(const struct udevice *dev, unsigned long size); @@ -88,7 +87,7 @@ void *devfdt_map_physmem(const struct udevice *dev, unsigned long size); * @index: the 'reg' property can hold a list of <addr, size> pairs * and @index is used to select which one is required * - * @return addr + * Return: addr */ fdt_addr_t devfdt_get_addr_index(const struct udevice *dev, int index); @@ -100,7 +99,7 @@ fdt_addr_t devfdt_get_addr_index(const struct udevice *dev, int index); * @index: the 'reg' property can hold a list of <addr, size> pairs * and @index is used to select which one is required * - * @return Pointer to addr, or NULL if there is no such property + * Return: Pointer to addr, or NULL if there is no such property */ void *devfdt_get_addr_index_ptr(const struct udevice *dev, int index); @@ -115,7 +114,7 @@ void *devfdt_get_addr_index_ptr(const struct udevice *dev, int index); * @size: Pointer to size varible - this function returns the size * specified in the 'reg' property here * - * @return addr + * Return: addr */ fdt_addr_t devfdt_get_addr_size_index(const struct udevice *dev, int index, fdt_size_t *size); @@ -128,7 +127,7 @@ fdt_addr_t devfdt_get_addr_size_index(const struct udevice *dev, int index, * 'reg-names' property providing named-based identification. @index * indicates the value to search for in 'reg-names'. * - * @return addr + * Return: addr */ fdt_addr_t devfdt_get_addr_name(const struct udevice *dev, const char *name); @@ -145,7 +144,7 @@ fdt_addr_t devfdt_get_addr_name(const struct udevice *dev, const char *name); * @size: Pointer to size variable - this function returns the size * specified in the 'reg' property here * - * @return addr + * Return: addr */ fdt_addr_t devfdt_get_addr_size_name(const struct udevice *dev, const char *name, fdt_size_t *size); @@ -154,7 +153,7 @@ fdt_addr_t devfdt_get_addr_size_name(const struct udevice *dev, * devfdt_get_addr_pci() - Read an address and handle PCI address translation * * @dev: Device to read from - * @return address or FDT_ADDR_T_NONE if not found + * Return: address or FDT_ADDR_T_NONE if not found */ fdt_addr_t devfdt_get_addr_pci(const struct udevice *dev); diff --git a/include/dm/lists.h b/include/dm/lists.h index 5896ae36583..fc3b4ae5850 100644 --- a/include/dm/lists.h +++ b/include/dm/lists.h @@ -19,13 +19,14 @@ * for binding a driver given its name and plat. * * @name: Name of driver to look up - * @return pointer to driver, or NULL if not found + * Return: pointer to driver, or NULL if not found */ struct driver *lists_driver_lookup_name(const char *name); /** * lists_uclass_lookup() - Return uclass_driver based on ID of the class - * id: ID of the class + * + * @id: ID of the class * * This function returns the pointer to uclass_driver, which is the class's * base structure based on the ID of the class. Returns NULL on error. @@ -56,7 +57,8 @@ int lists_bind_drivers(struct udevice *parent, bool pre_reloc_only); * @drv: if non-NULL, force this driver to be bound * @pre_reloc_only: If true, bind only nodes with special devicetree properties, * or drivers with the DM_FLAG_PRE_RELOC flag. If false bind all drivers. - * @return 0 if device was bound, -EINVAL if the device tree is invalid, + * + * Return: 0 if device was bound, -EINVAL if the device tree is invalid, * other -ve value on error */ int lists_bind_fdt(struct udevice *parent, ofnode node, struct udevice **devp, diff --git a/include/dm/of.h b/include/dm/of.h index 5cb6f44a6c6..9c9065b7932 100644 --- a/include/dm/of.h +++ b/include/dm/of.h @@ -58,14 +58,13 @@ struct device_node { * struct of_phandle_args - structure to hold phandle and arguments * * This is used when decoding a phandle in a device tree property. Typically - * these look like this: + * these look like this:: * - * wibble { - * phandle = <5>; - * }; - * - * ... - * some-prop = <&wibble 1 2 3> + * wibble { + * phandle = <5>; + * }; + * ... + * some-prop = <&wibble 1 2 3> * * Here &node is the phandle of the node 'wibble', i.e. 5. There are three * arguments: 1, 2, 3. diff --git a/include/dm/of_access.h b/include/dm/of_access.h index cc382b1671c..ec6e6e2c7c0 100644 --- a/include/dm/of_access.h +++ b/include/dm/of_access.h @@ -44,7 +44,7 @@ static inline void of_node_put(const struct device_node *np) { } * which controls the given node. * * @np: Node pointer to check - * @return number of address cells this node uses + * Return: number of address cells this node uses */ int of_n_addr_cells(const struct device_node *np); @@ -55,7 +55,7 @@ int of_n_addr_cells(const struct device_node *np); * which controls the given node. * * @np: Node pointer to check - * @return number of size cells this node uses + * Return: number of size cells this node uses */ int of_n_size_cells(const struct device_node *np); @@ -65,7 +65,7 @@ int of_n_size_cells(const struct device_node *np); * This function matches fdt_address_cells(). * * @np: Node pointer to check - * @return value of #address-cells property in this node, or 2 if none + * Return: value of #address-cells property in this node, or 2 if none */ int of_simple_addr_cells(const struct device_node *np); @@ -75,7 +75,7 @@ int of_simple_addr_cells(const struct device_node *np); * This function matches fdt_size_cells(). * * @np: Node pointer to check - * @return value of #size-cells property in this node, or 2 if none + * Return: value of #size-cells property in this node, or 2 if none */ int of_simple_size_cells(const struct device_node *np); @@ -85,7 +85,7 @@ int of_simple_size_cells(const struct device_node *np); * @np: Pointer to device node holding property * @name: Name of property * @lenp: If non-NULL, returns length of property - * @return pointer to property, or NULL if not found + * Return: pointer to property, or NULL if not found */ struct property *of_find_property(const struct device_node *np, const char *name, int *lenp); @@ -98,7 +98,7 @@ struct property *of_find_property(const struct device_node *np, * @np: Pointer to device node holding property * @name: Name of property * @lenp: If non-NULL, returns length of property - * @return pointer to property value, or NULL if not found + * Return: pointer to property value, or NULL if not found */ const void *of_get_property(const struct device_node *np, const char *name, int *lenp); @@ -110,7 +110,7 @@ const void *of_get_property(const struct device_node *np, const char *name, * and read all the property with of_get_next_property_by_prop(). * * @np: Pointer to device node - * @return pointer to property or NULL if not found + * Return: pointer to property or NULL if not found */ const struct property *of_get_first_property(const struct device_node *np); @@ -122,7 +122,7 @@ const struct property *of_get_first_property(const struct device_node *np); * * @np: Pointer to device node * @property: pointer of the current property - * @return pointer to next property or NULL if not found + * Return: pointer to next property or NULL if not found */ const struct property *of_get_next_property(const struct device_node *np, const struct property *property); @@ -132,11 +132,11 @@ const struct property *of_get_next_property(const struct device_node *np, * * Get value for the property identified by node and property pointer. * - * @node: node to read + * @np: Pointer to device node * @property: pointer of the property to read - * @propname: place to property name on success + * @name: place to property name on success * @lenp: place to put length on success - * @return pointer to property value or NULL if error + * Return: pointer to property value or NULL if error */ const void *of_get_property_by_prop(const struct device_node *np, const struct property *property, @@ -145,7 +145,7 @@ const void *of_get_property_by_prop(const struct device_node *np, /** * of_device_is_compatible() - Check if the node matches given constraints - * @device: pointer to node + * @np: Pointer to device node * @compat: required compatible string, NULL or "" for any match * @type: required device_type value, NULL or "" for any match * @name: required node name, NULL or "" for any match @@ -154,7 +154,7 @@ const void *of_get_property_by_prop(const struct device_node *np, * properties of the given @device. A constraints can be skipped by * passing NULL or an empty string as the constraint. * - * @return 0 for no match, and a positive integer on match. The return + * Return: 0 for no match, and a positive integer on match. The return * value is a relative score with larger values indicating better * matches. The score is weighted for the most specific compatible value * to get the highest score. Matching type is next, followed by matching @@ -179,9 +179,9 @@ int of_device_is_compatible(const struct device_node *np, const char *compat, /** * of_device_is_available() - check if a device is available for use * - * @device: Node to check for availability + * @np: Pointer to device node to check for availability * - * @return true if the status property is absent or set to "okay", false + * Return: true if the status property is absent or set to "okay", false * otherwise */ bool of_device_is_available(const struct device_node *np); @@ -189,8 +189,8 @@ bool of_device_is_available(const struct device_node *np); /** * of_get_parent() - Get a node's parent, if any * - * @node: Node to check - * @eturns a node pointer, or NULL if none + * @np: Pointer to device node to check + * Return: a node pointer, or NULL if none */ struct device_node *of_get_parent(const struct device_node *np); @@ -208,7 +208,7 @@ struct device_node *of_get_parent(const struct device_node *np); * foo Valid alias * foo/bar Valid alias + relative path * - * @return a node pointer or NULL if not found + * Return: a node pointer or NULL if not found */ struct device_node *of_find_node_opts_by_path(const char *path, const char **opts); @@ -228,7 +228,7 @@ static inline struct device_node *of_find_node_by_path(const char *path) * @type: The type string to match "device_type" or NULL to ignore * @compatible: The string to match to one of the tokens in the device * "compatible" list. - * @return node pointer or NULL if not found + * Return: node pointer or NULL if not found */ struct device_node *of_find_compatible_node(struct device_node *from, const char *type, const char *compatible); @@ -243,7 +243,7 @@ struct device_node *of_find_compatible_node(struct device_node *from, * @propname: property name to check * @propval: property value to search for * @proplen: length of the value in propval - * @return node pointer or NULL if not found + * Return: node pointer or NULL if not found */ struct device_node *of_find_node_by_prop_value(struct device_node *from, const char *propname, @@ -254,7 +254,7 @@ struct device_node *of_find_node_by_prop_value(struct device_node *from, * * @handle: phandle of the node to find * - * @return node pointer, or NULL if not found + * Return: node pointer, or NULL if not found */ struct device_node *of_find_node_by_phandle(phandle handle); @@ -268,7 +268,7 @@ struct device_node *of_find_node_by_phandle(phandle handle); * @propname: name of the property to be searched. * @outp: pointer to return value, modified only if return value is 0. * - * @return 0 on success, -EINVAL if the property does not exist, + * Return: 0 on success, -EINVAL if the property does not exist, * -ENODATA if property does not have a value, and -EOVERFLOW if the * property data isn't large enough. */ @@ -286,9 +286,10 @@ int of_read_u32(const struct device_node *np, const char *propname, u32 *outp); * @index: index of the u32 in the list of values * @outp: pointer to return value, modified only if return value is 0. * - * @return 0 on success, -EINVAL if the property does not exist, - * -ENODATA if property does not have a value, and -EOVERFLOW if the - * property data isn't large enough. + * Return: + * 0 on success, -EINVAL if the property does not exist, + * -ENODATA if property does not have a value, and -EOVERFLOW if the + * property data isn't large enough. */ int of_read_u32_index(const struct device_node *np, const char *propname, int index, u32 *outp); @@ -303,9 +304,10 @@ int of_read_u32_index(const struct device_node *np, const char *propname, * @propname: name of the property to be searched. * @outp: pointer to return value, modified only if return value is 0. * - * @return 0 on success, -EINVAL if the property does not exist, - * -ENODATA if property does not have a value, and -EOVERFLOW if the - * property data isn't large enough. + * Return: + * 0 on success, -EINVAL if the property does not exist, + * -ENODATA if property does not have a value, and -EOVERFLOW if the + * property data isn't large enough. */ int of_read_u64(const struct device_node *np, const char *propname, u64 *outp); @@ -319,8 +321,9 @@ int of_read_u64(const struct device_node *np, const char *propname, u64 *outp); * @propname: name of the property to be searched. * @out_values: pointer to return value, modified only if return value is 0. * @sz: number of array elements to read - * @return 0 on success, -EINVAL if the property does not exist, -ENODATA - * if property does not have a value, and -EOVERFLOW is longer than sz. + * Return: + * 0 on success, -EINVAL if the property does not exist, -ENODATA + * if property does not have a value, and -EOVERFLOW is longer than sz. */ int of_read_u32_array(const struct device_node *np, const char *propname, u32 *out_values, size_t sz); @@ -334,8 +337,9 @@ int of_read_u32_array(const struct device_node *np, const char *propname, * @np: pointer to node containing string list property * @propname: string list property name * @string: pointer to string to search for in string list - * @return 0 on success, -EINVAL if the property does not exist, -ENODATA - * if property does not have a value, and -EOVERFLOW is longer than sz. + * Return: + * 0 on success, -EINVAL if the property does not exist, -ENODATA + * if property does not have a value, and -EOVERFLOW is longer than sz. */ int of_property_match_string(const struct device_node *np, const char *propname, const char *string); @@ -350,15 +354,17 @@ int of_property_read_string_helper(const struct device_node *np, * @np: device node from which the property value is to be read. * @propname: name of the property to be searched. * @index: index of the string in the list of strings - * @out_string: pointer to null terminated return string, modified only if + * @output: pointer to null terminated return string, modified only if * return value is 0. * * Search for a property in a device tree node and retrieve a null * terminated string value (pointer to data, not a copy) in the list of strings * contained in that property. - * Returns 0 on success, -EINVAL if the property does not exist, -ENODATA if - * property does not have a value, and -EILSEQ if the string is not - * null-terminated within the length of the property data. + * + * Return: + * 0 on success, -EINVAL if the property does not exist, -ENODATA if + * property does not have a value, and -EILSEQ if the string is not + * null-terminated within the length of the property data. * * The out_string pointer is modified only if a valid string can be decoded. */ @@ -377,10 +383,12 @@ static inline int of_property_read_string_index(const struct device_node *np, * @propname: name of the property to be searched. * * Search for a property in a device tree node and retrieve the number of null - * terminated string contain in it. Returns the number of strings on - * success, -EINVAL if the property does not exist, -ENODATA if property - * does not have a value, and -EILSEQ if the string is not null-terminated - * within the length of the property data. + * terminated string contain in it. + * + * Return: + * the number of strings on success, -EINVAL if the property does not exist, + * -ENODATA if property does not have a value, and -EILSEQ if the string is + * not null-terminated within the length of the property data. */ static inline int of_property_count_strings(const struct device_node *np, const char *propname) @@ -395,8 +403,9 @@ static inline int of_property_count_strings(const struct device_node *np, * @index: For properties holding a table of phandles, this is the index into * the table * - * Returns the device_node pointer with refcount incremented. Use - * of_node_put() on it when done. + * Return: + * the device_node pointer with refcount incremented. Use + * of_node_put() on it when done. */ struct device_node *of_parse_phandle(const struct device_node *np, const char *phandle_name, int index); @@ -410,10 +419,11 @@ struct device_node *of_parse_phandle(const struct device_node *np, * @cells_count: Cell count to use if @cells_name is NULL * @index: index of a phandle to parse out * @out_args: optional pointer to output arguments structure (will be filled) - * @return 0 on success (with @out_args filled out if not NULL), -ENOENT if - * @list_name does not exist, -EINVAL if a phandle was not found, - * @cells_name could not be found, the arguments were truncated or there - * were too many arguments. + * Return: + * 0 on success (with @out_args filled out if not NULL), -ENOENT if + * @list_name does not exist, -EINVAL if a phandle was not found, + * @cells_name could not be found, the arguments were truncated or there + * were too many arguments. * * This function is useful to parse lists of phandles and their arguments. * Returns 0 on success and fills out_args, on error returns appropriate @@ -424,17 +434,17 @@ struct device_node *of_parse_phandle(const struct device_node *np, * * Example: * - * phandle1: node1 { - * #list-cells = <2>; - * } + * .. code-block:: * - * phandle2: node2 { - * #list-cells = <1>; - * } - * - * node3 { - * list = <&phandle1 1 2 &phandle2 3>; - * } + * phandle1: node1 { + * #list-cells = <2>; + * }; + * phandle2: node2 { + * #list-cells = <1>; + * }; + * node3 { + * list = <&phandle1 1 2 &phandle2 3>; + * }; * * To get a device_node of the `node2' node you may call this: * of_parse_phandle_with_args(node3, "list", "#list-cells", 1, &args); @@ -451,14 +461,13 @@ int of_parse_phandle_with_args(const struct device_node *np, * @list_name: property name that contains a list * @cells_name: property name that specifies phandles' arguments count * @cells_count: Cell count to use if @cells_name is NULL - * @return number of phandle found, -ENOENT if - * @list_name does not exist, -EINVAL if a phandle was not found, - * @cells_name could not be found, the arguments were truncated or there - * were too many arguments. + * Return: + * number of phandle found, -ENOENT if @list_name does not exist, + * -EINVAL if a phandle was not found, @cells_name could not be found, + * the arguments were truncated or there were too many arguments. * * Returns number of phandle found on success, on error returns appropriate * errno value. - * */ int of_count_phandle_with_args(const struct device_node *np, const char *list_name, const char *cells_name, @@ -471,7 +480,7 @@ int of_count_phandle_with_args(const struct device_node *np, * the lookup table with the properties. It returns the number of alias * properties found, or an error code in case of failure. * - * @return 9 if OK, -ENOMEM if not enough memory + * Return: 9 if OK, -ENOMEM if not enough memory */ int of_alias_scan(void); @@ -483,7 +492,7 @@ int of_alias_scan(void); * * @np: Pointer to the given device_node * @stem: Alias stem of the given device_node - * @return alias ID, if found, else -ENODEV + * Return: alias ID, if found, else -ENODEV */ int of_alias_get_id(const struct device_node *np, const char *stem); @@ -493,14 +502,14 @@ int of_alias_get_id(const struct device_node *np, const char *stem); * * The function travels the lookup table to get the highest alias id for the * given alias stem. - * @return alias ID, if found, else -1 + * Return: alias ID, if found, else -1 */ int of_alias_get_highest_id(const char *stem); /** * of_get_stdout() - Get node to use for stdout * - * @return node referred to by stdout-path alias, or NULL if none + * Return: node referred to by stdout-path alias, or NULL if none */ struct device_node *of_get_stdout(void); diff --git a/include/dm/of_addr.h b/include/dm/of_addr.h index ee21d5cf4fc..e7f3a280817 100644 --- a/include/dm/of_addr.h +++ b/include/dm/of_addr.h @@ -20,11 +20,11 @@ * that can be mapped to a cpu physical address). This is not really specified * that way, but this is traditionally the way IBM at least do things * - * @np: node to check + * @np: pointer to node to check * @in_addr: pointer to input address - * @return translated address or OF_BAD_ADDR on error + * Return: translated address or OF_BAD_ADDR on error */ -u64 of_translate_address(const struct device_node *no, const __be32 *in_addr); +u64 of_translate_address(const struct device_node *np, const __be32 *in_addr); /** * of_translate_dma_address() - translate a device-tree DMA address to a CPU @@ -38,11 +38,11 @@ u64 of_translate_address(const struct device_node *no, const __be32 *in_addr); * that can be mapped to a cpu physical address). This is not really specified * that way, but this is traditionally the way IBM at least do things * - * @np: node to check + * @np: ne * @in_addr: pointer to input DMA address - * @return translated DMA address or OF_BAD_ADDR on error + * Return: translated DMA address or OF_BAD_ADDR on error */ -u64 of_translate_dma_address(const struct device_node *no, const __be32 *in_addr); +u64 of_translate_dma_address(const struct device_node *np, const __be32 *in_addr); /** @@ -51,14 +51,13 @@ u64 of_translate_dma_address(const struct device_node *no, const __be32 *in_addr * Get DMA ranges for a specifc node, this is useful to perform bus->cpu and * cpu->bus address translations * - * @param blob Pointer to device tree blob - * @param node_offset Node DT offset - * @param cpu Pointer to variable storing the range's cpu address - * @param bus Pointer to variable storing the range's bus address - * @param size Pointer to variable storing the range's size - * @return translated DMA address or OF_BAD_ADDR on error + * @np: Pointer to device tree blob + * @cpu: Pointer to variable storing the range's cpu address + * @bus: Pointer to variable storing the range's bus address + * @size: Pointer to variable storing the range's size + * Return: translated DMA address or OF_BAD_ADDR on error */ -int of_get_dma_range(const struct device_node *dev, phys_addr_t *cpu, +int of_get_dma_range(const struct device_node *np, phys_addr_t *cpu, dma_addr_t *bus, u64 *size); /** @@ -72,9 +71,9 @@ int of_get_dma_range(const struct device_node *dev, phys_addr_t *cpu, * @index: Index of address to read (0 = first) * @size: place to put size on success * @flags: place to put flags on success - * @return pointer to address which can be read + * Return: pointer to address which can be read */ -const __be32 *of_get_address(const struct device_node *no, int index, +const __be32 *of_get_address(const struct device_node *np, int index, u64 *size, unsigned int *flags); struct resource; @@ -90,9 +89,9 @@ struct resource; * @np: node to check * @index: index of address to read (0 = first) * @r: place to put resource information - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ -int of_address_to_resource(const struct device_node *no, int index, +int of_address_to_resource(const struct device_node *np, int index, struct resource *r); #endif diff --git a/include/dm/of_extra.h b/include/dm/of_extra.h index f0d205491c1..17e85a819be 100644 --- a/include/dm/of_extra.h +++ b/include/dm/of_extra.h @@ -41,11 +41,11 @@ struct fmap_entry { }; /** - * Read a flash entry from the fdt + * ofnode_read_fmap_entry() - Read a flash entry from the fdt * - * @param node Reference to node to read - * @param entry Place to put offset and size of this node - * @return 0 if ok, -ve on error + * @node: Reference to node to read + * @entry: Place to put offset and size of this node + * Return: 0 if ok, -ve on error */ int ofnode_read_fmap_entry(ofnode node, struct fmap_entry *entry); @@ -58,11 +58,11 @@ int ofnode_read_fmap_entry(ofnode node, struct fmap_entry *entry); * The property must hold one address with a length. This is only tested on * 32-bit machines. * - * @param node ofnode to examine - * @param prop_name name of property to find - * @param basep Returns base address of region - * @param size Returns size of region - * @return 0 if ok, -1 on error (property not found) + * @node: ofnode to examine + * @prop_name: name of property to find + * @basep: Returns base address of region + * @sizep: Returns size of region + * Return: 0 if ok, -1 on error (property not found) */ int ofnode_decode_region(ofnode node, const char *prop_name, fdt_addr_t *basep, fdt_size_t *sizep); @@ -81,14 +81,14 @@ int ofnode_decode_region(ofnode node, const char *prop_name, fdt_addr_t *basep, * The property value must have an offset and a size. The function checks * that the region is entirely within the memory bank.5 * - * @param node ofnode containing the properties (-1 for /config) - * @param mem_type Type of memory to use, which is a name, such as - * "u-boot" or "kernel". - * @param suffix String to append to the memory/offset - * property names - * @param basep Returns base of region - * @param sizep Returns size of region - * @return 0 if OK, -ive on error + * @config_node: ofnode containing the properties (invalid for "/config") + * @mem_type: Type of memory to use, which is a name, such as + * "u-boot" or "kernel". + * @suffix: String to append to the memory/offset + * property names + * @basep: Returns base of region + * @sizep: Returns size of region + * Return: 0 if OK, -ive on error */ int ofnode_decode_memory_region(ofnode config_node, const char *mem_type, const char *suffix, fdt_addr_t *basep, @@ -102,16 +102,30 @@ int ofnode_decode_memory_region(ofnode config_node, const char *mem_type, * * This function supports the following two DT bindings: * - the new DT binding, where 'fixed-link' is a sub-node of the - * Ethernet device + * Ethernet device * - the old DT binding, where 'fixed-link' is a property with 5 - * cells encoding various information about the fixed PHY + * cells encoding various information about the fixed PHY * * If both new and old bindings exist, the new one is preferred. * - * @param eth_node ofnode containing the fixed-link subnode/property - * @param phy_node if fixed-link PHY detected, containing the PHY ofnode - * @return true if a fixed-link pseudo-PHY device exists, false otherwise + * @eth_node: ofnode containing the fixed-link subnode/property + * @phy_node: if fixed-link PHY detected, containing the PHY ofnode + * Return: true if a fixed-link pseudo-PHY device exists, false otherwise */ bool ofnode_phy_is_fixed_link(ofnode eth_node, ofnode *phy_node); +/** + * ofnode_eth_uses_inband_aneg() - Detect whether MAC should use in-band autoneg + * + * This function detects whether the Ethernet controller should use IEEE 802.3 + * clause 37 in-band autonegotiation for serial protocols such as 1000base-x, + * SGMII, USXGMII, etc. The property is relevant when the Ethernet controller + * is connected to an on-board PHY or an SFP cage, and is not relevant when it + * has a fixed link (in that case, in-band autoneg should not be used). + * + * @eth_node: ofnode belonging to the Ethernet controller + * Return: true if in-band autoneg should be used, false otherwise + */ +bool ofnode_eth_uses_inband_aneg(ofnode eth_node); + #endif diff --git a/include/dm/ofnode.h b/include/dm/ofnode.h index 0f680e5aa62..0cb324c8b0c 100644 --- a/include/dm/ofnode.h +++ b/include/dm/ofnode.h @@ -19,7 +19,7 @@ struct resource; /** - * ofnode - reference to a device tree node + * typedef union ofnode_union ofnode - reference to a device tree node * * This union can hold either a straightforward pointer to a struct device_node * in the live device tree, or an offset within the flat device tree. In the @@ -27,7 +27,7 @@ struct resource; * * Thus we can reference nodes in both the live tree (once available) and the * flat tree (until then). Functions are available to translate between an - * ofnode and either an offset or a struct device_node *. + * ofnode and either an offset or a `struct device_node *`. * * The reference can also hold a null offset, in which case the pointer value * here is NULL. This corresponds to a struct device_node * value of @@ -61,7 +61,7 @@ struct ofnode_phandle_args { }; /** - * ofprop - reference to a property of a device tree node + * struct ofprop - reference to a property of a device tree node * * This struct hold the reference on one property of one node, * using struct ofnode and an offset within the flat device tree or either @@ -91,7 +91,7 @@ struct ofprop { * This cannot be called if the reference contains an offset. * * @node: Reference containing struct device_node * (possibly invalid) - * @return pointer to device node (can be NULL) + * Return: pointer to device node (can be NULL) */ static inline const struct device_node *ofnode_to_np(ofnode node) { @@ -108,7 +108,7 @@ static inline const struct device_node *ofnode_to_np(ofnode node) * This cannot be called if the reference contains a node pointer. * * @node: Reference containing offset (possibly invalid) - * @return DT offset (can be -1) + * Return: DT offset (can be -1) */ static inline int ofnode_to_offset(ofnode node) { @@ -122,7 +122,8 @@ static inline int ofnode_to_offset(ofnode node) /** * ofnode_valid() - check if an ofnode is valid * - * @return true if the reference contains a valid ofnode, false if it is NULL + * @node: Reference containing offset (possibly invalid) + * Return: true if the reference contains a valid ofnode, false if it is NULL */ static inline bool ofnode_valid(ofnode node) { @@ -136,7 +137,7 @@ static inline bool ofnode_valid(ofnode node) * offset_to_ofnode() - convert a DT offset to an ofnode * * @of_offset: DT offset (either valid, or -1) - * @return reference to the associated DT offset + * Return: reference to the associated DT offset */ static inline ofnode offset_to_ofnode(int of_offset) { @@ -154,7 +155,7 @@ static inline ofnode offset_to_ofnode(int of_offset) * np_to_ofnode() - convert a node pointer to an ofnode * * @np: Live node pointer (can be NULL) - * @return reference to the associated node pointer + * Return: reference to the associated node pointer */ static inline ofnode np_to_ofnode(const struct device_node *np) { @@ -173,7 +174,7 @@ static inline ofnode np_to_ofnode(const struct device_node *np) * is valid is not permitted. * * @node: reference to check (possibly invalid) - * @return true if the reference is a live node pointer, false if it is a DT + * Return: true if the reference is a live node pointer, false if it is a DT * offset */ static inline bool ofnode_is_np(ofnode node) @@ -193,7 +194,9 @@ static inline bool ofnode_is_np(ofnode node) /** * ofnode_equal() - check if two references are equal * - * @return true if equal, else false + * @ref1: first reference to check (possibly invalid) + * @ref2: second reference to check (possibly invalid) + * Return: true if equal, else false */ static inline bool ofnode_equal(ofnode ref1, ofnode ref2) { @@ -237,28 +240,28 @@ static inline ofnode ofnode_root(void) * * @node: valid node reference that has to be compared * @name: name that has to be compared with the node name - * @return true if matches, false if it doesn't match + * Return: true if matches, false if it doesn't match */ bool ofnode_name_eq(ofnode node, const char *name); /** * ofnode_read_u32() - Read a 32-bit integer from a property * - * @ref: valid node reference to read property from + * @node: valid node reference to read property from * @propname: name of the property to read from * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int ofnode_read_u32(ofnode node, const char *propname, u32 *outp); /** * ofnode_read_u32_index() - Read a 32-bit integer from a multi-value property * - * @ref: valid node reference to read property from + * @node: valid node reference to read property from * @propname: name of the property to read from * @index: index of the integer to return * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int ofnode_read_u32_index(ofnode node, const char *propname, int index, u32 *outp); @@ -266,47 +269,47 @@ int ofnode_read_u32_index(ofnode node, const char *propname, int index, /** * ofnode_read_s32() - Read a 32-bit integer from a property * - * @ref: valid node reference to read property from + * @node: valid node reference to read property from * @propname: name of the property to read from * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ static inline int ofnode_read_s32(ofnode node, const char *propname, - s32 *out_value) + s32 *outp) { - return ofnode_read_u32(node, propname, (u32 *)out_value); + return ofnode_read_u32(node, propname, (u32 *)outp); } /** * ofnode_read_u32_default() - Read a 32-bit integer from a property * - * @ref: valid node reference to read property from + * @node: valid node reference to read property from * @propname: name of the property to read from * @def: default value to return if the property has no value - * @return property value, or @def if not found + * Return: property value, or @def if not found */ -u32 ofnode_read_u32_default(ofnode ref, const char *propname, u32 def); +u32 ofnode_read_u32_default(ofnode node, const char *propname, u32 def); /** * ofnode_read_u32_index_default() - Read a 32-bit integer from a multi-value * property * - * @ref: valid node reference to read property from + * @node: valid node reference to read property from * @propname: name of the property to read from * @index: index of the integer to return * @def: default value to return if the property has no value - * @return property value, or @def if not found + * Return: property value, or @def if not found */ -u32 ofnode_read_u32_index_default(ofnode ref, const char *propname, int index, +u32 ofnode_read_u32_index_default(ofnode node, const char *propname, int index, u32 def); /** * ofnode_read_s32_default() - Read a 32-bit integer from a property * - * @ref: valid node reference to read property from + * @node: valid node reference to read property from * @propname: name of the property to read from * @def: default value to return if the property has no value - * @return property value, or @def if not found + * Return: property value, or @def if not found */ int ofnode_read_s32_default(ofnode node, const char *propname, s32 def); @@ -316,17 +319,17 @@ int ofnode_read_s32_default(ofnode node, const char *propname, s32 def); * @node: valid node reference to read property from * @propname: name of the property to read from * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int ofnode_read_u64(ofnode node, const char *propname, u64 *outp); /** * ofnode_read_u64_default() - Read a 64-bit integer from a property * - * @ref: valid node reference to read property from + * @node: valid node reference to read property from * @propname: name of the property to read from * @def: default value to return if the property has no value - * @return property value, or @def if not found + * Return: property value, or @def if not found */ u64 ofnode_read_u64_default(ofnode node, const char *propname, u64 def); @@ -336,8 +339,8 @@ u64 ofnode_read_u64_default(ofnode node, const char *propname, u64 def); * @node: valid node reference to read property from * @propname: name of the property to read * @sizep: if non-NULL, returns the size of the property, or an error code - if not found - * @return property value, or NULL if there is no such property + * if not found + * Return: property value, or NULL if there is no such property */ const void *ofnode_read_prop(ofnode node, const char *propname, int *sizep); @@ -346,7 +349,7 @@ const void *ofnode_read_prop(ofnode node, const char *propname, int *sizep); * * @node: valid node reference to read property from * @propname: name of the property to read - * @return string from property value, or NULL if there is no such property + * Return: string from property value, or NULL if there is no such property */ const char *ofnode_read_string(ofnode node, const char *propname); @@ -357,7 +360,7 @@ const char *ofnode_read_string(ofnode node, const char *propname); * @propname: name of the property to read * @out_values: pointer to return value, modified only if return value is 0 * @sz: number of array elements to read - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error * * Search for a property in a device node and read 32-bit value(s) from * it. Returns 0 on success, -EINVAL if the property does not exist, @@ -374,7 +377,7 @@ int ofnode_read_u32_array(ofnode node, const char *propname, * * @node: valid node reference to read property from * @propname: name of property to read - * @return true if property is present (meaning true), false if not present + * Return: true if property is present (meaning true), false if not present */ bool ofnode_read_bool(ofnode node, const char *propname); @@ -383,7 +386,7 @@ bool ofnode_read_bool(ofnode node, const char *propname); * * @node: valid reference to parent node * @subnode_name: name of subnode to find - * @return reference to subnode (which can be invalid if there is no such + * Return: reference to subnode (which can be invalid if there is no such * subnode) */ ofnode ofnode_find_subnode(ofnode node, const char *subnode_name); @@ -429,7 +432,7 @@ static inline ofnode ofnode_next_subnode(ofnode node) * by default. * * @node: node to examine - * @return false (not enabled) or true (enabled) + * Return: false (not enabled) or true (enabled) */ bool ofnode_is_enabled(ofnode node); @@ -437,7 +440,7 @@ bool ofnode_is_enabled(ofnode node); * ofnode_first_subnode() - find the first subnode of a parent node * * @node: valid reference to a valid parent node - * @return reference to the first subnode (which can be invalid if the parent + * Return: reference to the first subnode (which can be invalid if the parent * node has no subnodes) */ ofnode ofnode_first_subnode(ofnode node); @@ -446,7 +449,7 @@ ofnode ofnode_first_subnode(ofnode node); * ofnode_next_subnode() - find the next sibling of a subnode * * @node: valid reference to previous node (sibling) - * @return reference to the next subnode (which can be invalid if the node + * Return: reference to the next subnode (which can be invalid if the node * has no more siblings) */ ofnode ofnode_next_subnode(ofnode node); @@ -456,7 +459,7 @@ ofnode ofnode_next_subnode(ofnode node); * ofnode_get_parent() - get the ofnode's parent (enclosing ofnode) * * @node: valid node to look up - * @return ofnode reference of the parent node + * Return: ofnode reference of the parent node */ ofnode ofnode_get_parent(ofnode node); @@ -464,7 +467,7 @@ ofnode ofnode_get_parent(ofnode node); * ofnode_get_name() - get the name of a node * * @node: valid node to look up - * @return name of node + * Return: name of node */ const char *ofnode_get_name(ofnode node); @@ -474,7 +477,7 @@ const char *ofnode_get_name(ofnode node); * @node: valid node to look up * @buf: buffer to write the node path into * @buflen: buffer size - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int ofnode_get_path(ofnode node, char *buf, int buflen); @@ -482,7 +485,7 @@ int ofnode_get_path(ofnode node, char *buf, int buflen); * ofnode_get_by_phandle() - get ofnode from phandle * * @phandle: phandle to look up - * @return ofnode reference to the phandle + * Return: ofnode reference to the phandle */ ofnode ofnode_get_by_phandle(uint phandle); @@ -491,7 +494,7 @@ ofnode ofnode_get_by_phandle(uint phandle); * * @node: node to check * @propname: property to check - * @return size of property if present, or -EINVAL if not + * Return: size of property if present, or -EINVAL if not */ int ofnode_read_size(ofnode node, const char *propname); @@ -504,7 +507,7 @@ int ofnode_read_size(ofnode node, const char *propname); * @node: node to read from * @index: Index of address to read (0 for first) * @size: Pointer to size of the address - * @return address, or FDT_ADDR_T_NONE if not present or invalid + * Return: address, or FDT_ADDR_T_NONE if not present or invalid */ phys_addr_t ofnode_get_addr_size_index(ofnode node, int index, fdt_size_t *size); @@ -521,7 +524,7 @@ phys_addr_t ofnode_get_addr_size_index(ofnode node, int index, * @node: node to read from * @index: Index of address to read (0 for first) * @size: Pointer to size of the address - * @return address, or FDT_ADDR_T_NONE if not present or invalid + * Return: address, or FDT_ADDR_T_NONE if not present or invalid */ phys_addr_t ofnode_get_addr_size_index_notrans(ofnode node, int index, fdt_size_t *size); @@ -533,7 +536,7 @@ phys_addr_t ofnode_get_addr_size_index_notrans(ofnode node, int index, * * @node: node to read from * @index: Index of address to read (0 for first) - * @return address, or FDT_ADDR_T_NONE if not present or invalid + * Return: address, or FDT_ADDR_T_NONE if not present or invalid */ phys_addr_t ofnode_get_addr_index(ofnode node, int index); @@ -543,7 +546,7 @@ phys_addr_t ofnode_get_addr_index(ofnode node, int index); * This reads the register address from a node * * @node: node to read from - * @return address, or FDT_ADDR_T_NONE if not present or invalid + * Return: address, or FDT_ADDR_T_NONE if not present or invalid */ phys_addr_t ofnode_get_addr(ofnode node); @@ -553,7 +556,7 @@ phys_addr_t ofnode_get_addr(ofnode node); * This reads the register size from a node * * @node: node to read from - * @return size of the address, or FDT_SIZE_T_NONE if not present or invalid + * Return: size of the address, or FDT_SIZE_T_NONE if not present or invalid */ fdt_size_t ofnode_get_size(ofnode node); @@ -570,7 +573,7 @@ fdt_size_t ofnode_get_size(ofnode node); * @propname: name of the property containing the string list * @string: string to look up in the string list * - * @return: + * Return: * the index of the string in the list of strings * -ENODATA if the property is not found * -EINVAL on some other error @@ -590,11 +593,11 @@ int ofnode_stringlist_search(ofnode node, const char *propname, * * @node: node to check * @propname: name of the property containing the string list - * @index: index of the string to return - * @lenp: return location for the string length or an error code on failure + * @index: index of the string to return (cannot be negative) + * @outp: return location for the string * - * @return: - * length of string, if found or -ve error value if not found + * Return: + * 0 if found or -ve error value if not found */ int ofnode_read_string_index(ofnode node, const char *propname, int index, const char **outp); @@ -603,13 +606,34 @@ int ofnode_read_string_index(ofnode node, const char *propname, int index, * ofnode_read_string_count() - find the number of strings in a string list * * @node: node to check - * @propname: name of the property containing the string list - * @return: + * @property: name of the property containing the string list + * Return: * number of strings in the list, or -ve error value if not found */ int ofnode_read_string_count(ofnode node, const char *property); /** + * ofnode_read_string_list() - read a list of strings + * + * This produces a list of string pointers with each one pointing to a string + * in the string list. If the property does not exist, it returns {NULL}. + * + * The data is allocated and the caller is reponsible for freeing the return + * value (the list of string pointers). The strings themselves may not be + * changed as they point directly into the devicetree property. + * + * @node: node to check + * @property: name of the property containing the string list + * @listp: returns an allocated, NULL-terminated list of strings if the return + * value is > 0, else is set to NULL + * Return: + * number of strings in list, 0 if none, -ENOMEM if out of memory, + * -EINVAL if no such property, -EENODATA if property is empty + */ +int ofnode_read_string_list(ofnode node, const char *property, + const char ***listp); + +/** * ofnode_parse_phandle_with_args() - Find a node pointed by phandle in a list * * This function is useful to parse lists of phandles and their arguments. @@ -621,17 +645,17 @@ int ofnode_read_string_count(ofnode node, const char *property); * * Example: * - * phandle1: node1 { - * #list-cells = <2>; - * } - * - * phandle2: node2 { - * #list-cells = <1>; - * } + * .. code-block:: * - * node3 { - * list = <&phandle1 1 2 &phandle2 3>; - * } + * phandle1: node1 { + * #list-cells = <2>; + * }; + * phandle2: node2 { + * #list-cells = <1>; + * }; + * node3 { + * list = <&phandle1 1 2 &phandle2 3>; + * }; * * To get a device_node of the `node2' node you may call this: * ofnode_parse_phandle_with_args(node3, "list", "#list-cells", 0, 1, &args); @@ -639,13 +663,14 @@ int ofnode_read_string_count(ofnode node, const char *property); * @node: device tree node containing a list * @list_name: property name that contains a list * @cells_name: property name that specifies phandles' arguments count - * @cells_count: Cell count to use if @cells_name is NULL + * @cell_count: Cell count to use if @cells_name is NULL * @index: index of a phandle to parse out * @out_args: optional pointer to output arguments structure (will be filled) - * @return 0 on success (with @out_args filled out if not NULL), -ENOENT if - * @list_name does not exist, -EINVAL if a phandle was not found, - * @cells_name could not be found, the arguments were truncated or there - * were too many arguments. + * Return: + * 0 on success (with @out_args filled out if not NULL), -ENOENT if + * @list_name does not exist, -EINVAL if a phandle was not found, + * @cells_name could not be found, the arguments were truncated or there + * were too many arguments. */ int ofnode_parse_phandle_with_args(ofnode node, const char *list_name, const char *cells_name, int cell_count, @@ -662,10 +687,10 @@ int ofnode_parse_phandle_with_args(ofnode node, const char *list_name, * @node: device tree node containing a list * @list_name: property name that contains a list * @cells_name: property name that specifies phandles' arguments count - * @cells_count: Cell count to use if @cells_name is NULL - * @return number of phandle on success, -ENOENT if @list_name does not - * exist, -EINVAL if a phandle was not found, @cells_name could not - * be found. + * @cell_count: Cell count to use if @cells_name is NULL + * Return: + * number of phandle on success, -ENOENT if @list_name does not exist, + * -EINVAL if a phandle was not found, @cells_name could not be found. */ int ofnode_count_phandle_with_args(ofnode node, const char *list_name, const char *cells_name, int cell_count); @@ -674,7 +699,7 @@ int ofnode_count_phandle_with_args(ofnode node, const char *list_name, * ofnode_path() - find a node by full path * * @path: Full path to node, e.g. "/bus/spi@1" - * @return reference to the node found. Use ofnode_valid() to check if it exists + * Return: reference to the node found. Use ofnode_valid() to check if it exists */ ofnode ofnode_path(const char *path); @@ -684,9 +709,9 @@ ofnode ofnode_path(const char *path); * This looks for a property within the /chosen node and returns its value * * @propname: Property name to look for - * @sizep: Returns size of property, or FDT_ERR_... error code if function + * @sizep: Returns size of property, or `FDT_ERR_...` error code if function * returns NULL - * @return property value if found, else NULL + * Return: property value if found, else NULL */ const void *ofnode_read_chosen_prop(const char *propname, int *sizep); @@ -697,7 +722,7 @@ const void *ofnode_read_chosen_prop(const char *propname, int *sizep); * checking that it is a valid nul-terminated string * * @propname: Property name to look for - * @return string value if found, else NULL + * Return: string value if found, else NULL */ const char *ofnode_read_chosen_string(const char *propname); @@ -707,7 +732,8 @@ const char *ofnode_read_chosen_string(const char *propname); * This looks up a named property in the chosen node and uses that as a path to * look up a code. * - * @return the referenced node if present, else ofnode_null() + * @propname: Property name to look for + * Return: the referenced node if present, else ofnode_null() */ ofnode ofnode_get_chosen_node(const char *propname); @@ -717,9 +743,9 @@ ofnode ofnode_get_chosen_node(const char *propname); * This looks for a property within the /aliases node and returns its value * * @propname: Property name to look for - * @sizep: Returns size of property, or FDT_ERR_... error code if function + * @sizep: Returns size of property, or `FDT_ERR_...` error code if function * returns NULL - * @return property value if found, else NULL + * Return: property value if found, else NULL */ const void *ofnode_read_aliases_prop(const char *propname, int *sizep); @@ -729,7 +755,8 @@ const void *ofnode_read_aliases_prop(const char *propname, int *sizep); * This looks up a named property in the aliases node and uses that as a path to * look up a code. * - * @return the referenced node if present, else ofnode_null() + * @propname: Property name to look for + * Return: the referenced node if present, else ofnode_null() */ ofnode ofnode_get_aliases_node(const char *propname); @@ -741,10 +768,10 @@ struct display_timing; * See doc/device-tree-bindings/video/display-timing.txt for binding * information. * - * @node 'display-timing' node containing the timing subnodes - * @index Index number to read (0=first timing subnode) - * @config Place to put timings - * @return 0 if OK, -FDT_ERR_NOTFOUND if not found + * @node: 'display-timing' node containing the timing subnodes + * @index: Index number to read (0=first timing subnode) + * @config: Place to put timings + * Return: 0 if OK, -FDT_ERR_NOTFOUND if not found */ int ofnode_decode_display_timing(ofnode node, int index, struct display_timing *config); @@ -755,7 +782,7 @@ int ofnode_decode_display_timing(ofnode node, int index, * @node: node to read * @propname: property to read * @lenp: place to put length on success - * @return pointer to property, or NULL if not found + * Return: pointer to property, or NULL if not found */ const void *ofnode_get_property(ofnode node, const char *propname, int *lenp); @@ -767,7 +794,7 @@ const void *ofnode_get_property(ofnode node, const char *propname, int *lenp); * * @node: node to read * @prop: place to put argument reference - * @return 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found + * Return: 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found */ int ofnode_get_first_property(ofnode node, struct ofprop *prop); @@ -778,7 +805,7 @@ int ofnode_get_first_property(ofnode node, struct ofprop *prop); * and read all the property with ofnode_get_property_by_prop(). * * @prop: reference of current argument and place to put reference of next one - * @return 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found + * Return: 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found */ int ofnode_get_next_property(struct ofprop *prop); @@ -790,7 +817,7 @@ int ofnode_get_next_property(struct ofprop *prop); * @prop: reference on property * @propname: If non-NULL, place to property name on success, * @lenp: If non-NULL, place to put length on success - * @return 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found + * Return: 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found */ const void *ofnode_get_property_by_prop(const struct ofprop *prop, const char **propname, int *lenp); @@ -799,7 +826,7 @@ const void *ofnode_get_property_by_prop(const struct ofprop *prop, * ofnode_is_available() - check if a node is marked available * * @node: node to check - * @return true if node's 'status' property is "okay" (or is missing) + * Return: true if node's 'status' property is "okay" (or is missing) */ bool ofnode_is_available(ofnode node); @@ -812,7 +839,7 @@ bool ofnode_is_available(ofnode node); * @node: node to read from * @propname: property to read * @sizep: place to put size value (on success) - * @return address value, or FDT_ADDR_T_NONE on error + * Return: address value, or FDT_ADDR_T_NONE on error */ phys_addr_t ofnode_get_addr_size(ofnode node, const char *propname, phys_size_t *sizep); @@ -825,11 +852,12 @@ phys_addr_t ofnode_get_addr_size(ofnode node, const char *propname, * for the array (count bytes). It may have more, but this will be ignored. * The data is not copied. * - * @node node to examine - * @propname name of property to find - * @sz number of array elements - * @return pointer to byte array if found, or NULL if the property is not - * found or there is not enough data + * @node: node to examine + * @propname: name of property to find + * @sz: number of array elements + * Return: + * pointer to byte array if found, or NULL if the property is not found or + * there is not enough data */ const uint8_t *ofnode_read_u8_array_ptr(ofnode node, const char *propname, size_t sz); @@ -841,13 +869,14 @@ const uint8_t *ofnode_read_u8_array_ptr(ofnode node, const char *propname, * corresponds to the given type in the form of fdt_pci_addr. * The property must hold one fdt_pci_addr with a lengh. * - * @node node to examine - * @type pci address type (FDT_PCI_SPACE_xxx) - * @propname name of property to find - * @addr returns pci address in the form of fdt_pci_addr - * @return 0 if ok, -ENOENT if the property did not exist, -EINVAL if the - * format of the property was invalid, -ENXIO if the requested - * address type was not found + * @node: node to examine + * @type: pci address type (FDT_PCI_SPACE_xxx) + * @propname: name of property to find + * @addr: returns pci address in the form of fdt_pci_addr + * Return: + * 0 if ok, -ENOENT if the property did not exist, -EINVAL if the + * format of the property was invalid, -ENXIO if the requested + * address type was not found */ int ofnode_read_pci_addr(ofnode node, enum fdt_pci_space type, const char *propname, struct fdt_pci_addr *addr); @@ -858,10 +887,10 @@ int ofnode_read_pci_addr(ofnode node, enum fdt_pci_space type, * Look at the compatible property of a device node that represents a PCI * device and extract pci vendor id and device id from it. * - * @param node node to examine - * @param vendor vendor id of the pci device - * @param device device id of the pci device - * @return 0 if ok, negative on error + * @node: node to examine + * @vendor: vendor id of the pci device + * @device: device id of the pci device + * Return: 0 if ok, negative on error */ int ofnode_read_pci_vendev(ofnode node, u16 *vendor, u16 *device); @@ -872,7 +901,7 @@ int ofnode_read_pci_vendev(ofnode node, u16 *vendor, u16 *device); * which controls the given node. * * @node: Node to check - * @return number of address cells this node uses + * Return: number of address cells this node uses */ int ofnode_read_addr_cells(ofnode node); @@ -883,7 +912,7 @@ int ofnode_read_addr_cells(ofnode node); * which controls the given node. * * @node: Node to check - * @return number of size cells this node uses + * Return: number of size cells this node uses */ int ofnode_read_size_cells(ofnode node); @@ -892,8 +921,8 @@ int ofnode_read_size_cells(ofnode node); * * This function matches fdt_address_cells(). * - * @np: Node pointer to check - * @return value of #address-cells property in this node, or 2 if none + * @node: Node to check + * Return: value of #address-cells property in this node, or 2 if none */ int ofnode_read_simple_addr_cells(ofnode node); @@ -902,8 +931,8 @@ int ofnode_read_simple_addr_cells(ofnode node); * * This function matches fdt_size_cells(). * - * @np: Node pointer to check - * @return value of #size-cells property in this node, or 2 if none + * @node: Node to check + * Return: value of #size-cells property in this node, or 2 if none */ int ofnode_read_simple_size_cells(ofnode node); @@ -922,14 +951,13 @@ int ofnode_read_simple_size_cells(ofnode node); * There are 4 settings currently in use * - u-boot,dm-pre-proper: U-Boot proper pre-relocation only * - u-boot,dm-pre-reloc: legacy and indicates any of TPL or SPL - * Existing platforms only use it to indicate nodes needed in - * SPL. Should probably be replaced by u-boot,dm-spl for - * new platforms. + * Existing platforms only use it to indicate nodes needed in + * SPL. Should probably be replaced by u-boot,dm-spl for new platforms. * - u-boot,dm-spl: SPL and U-Boot pre-relocation * - u-boot,dm-tpl: TPL and U-Boot pre-relocation * * @node: node to check - * @return true if node is needed in SPL/TL, false otherwise + * Return: true if node is needed in SPL/TL, false otherwise */ bool ofnode_pre_reloc(ofnode node); @@ -941,7 +969,7 @@ bool ofnode_pre_reloc(ofnode node); * @node: Node to read from * @index: Index of resource to read (0 = first) * @res: Returns resource that was read, on success - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int ofnode_read_resource(ofnode node, uint index, struct resource *res); @@ -955,7 +983,7 @@ int ofnode_read_resource(ofnode node, uint index, struct resource *res); * @node: Node to read from * @name: Name of resource to read * @res: Returns resource that was read, on success - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int ofnode_read_resource_byname(ofnode node, const char *name, struct resource *res); @@ -967,7 +995,7 @@ int ofnode_read_resource_byname(ofnode node, const char *name, * * @from: ofnode to start from (use ofnode_null() to start at the beginning) * @compat: Compatible string to match - * @return ofnode found, or ofnode_null() if none + * Return: ofnode found, or ofnode_null() if none */ ofnode ofnode_by_compatible(ofnode from, const char *compat); @@ -978,9 +1006,11 @@ ofnode ofnode_by_compatible(ofnode from, const char *compat); * @propval and a length @proplen. * * @from: ofnode to start from (use ofnode_null() to start at the - * beginning) @propname: property name to check @propval: property value to - * search for @proplen: length of the value in propval @return ofnode - * found, or ofnode_null() if none + * beginning) + * @propname: property name to check + * @propval: property value to search for + * @proplen: length of the value in propval + * Return: ofnode found, or ofnode_null() if none */ ofnode ofnode_by_prop_value(ofnode from, const char *propname, const void *propval, int proplen); @@ -991,14 +1021,13 @@ ofnode ofnode_by_prop_value(ofnode from, const char *propname, * @node: child node (ofnode, lvalue) * @parent: parent node (ofnode) * - * This is a wrapper around a for loop and is used like so: + * This is a wrapper around a for loop and is used like so:: * - * ofnode node; - * - * ofnode_for_each_subnode(node, parent) { - * Use node - * ... - * } + * ofnode node; + * ofnode_for_each_subnode(node, parent) { + * Use node + * ... + * } * * Note that this is implemented as a macro and @node is used as * iterator in the loop. The parent variable can be a constant or even a @@ -1016,14 +1045,13 @@ ofnode ofnode_by_prop_value(ofnode from, const char *propname, * @node: child node (ofnode, lvalue) * @compat: compatible string to match * - * This is a wrapper around a for loop and is used like so: - * - * ofnode node; + * This is a wrapper around a for loop and is used like so:: * - * ofnode_for_each_compatible_node(node, parent, compatible) { - * Use node - * ... - * } + * ofnode node; + * ofnode_for_each_compatible_node(node, parent, compatible) { + * Use node + * ... + * } * * Note that this is implemented as a macro and @node is used as * iterator in the loop. @@ -1036,8 +1064,8 @@ ofnode ofnode_by_prop_value(ofnode from, const char *propname, /** * ofnode_get_child_count() - get the child count of a ofnode * - * @node: valid node to get its child count - * @return the number of subnodes + * @parent: valid node to get its child count + * Return: the number of subnodes */ int ofnode_get_child_count(ofnode parent); @@ -1048,10 +1076,9 @@ int ofnode_get_child_count(ofnode parent); * function walks up the tree and applies the various bus mappings along the * way. * - * @ofnode: Device tree node giving the context in which to translate the - * address + * @node: Device tree node giving the context in which to translate the address * @in_addr: pointer to the address to translate - * @return the translated address; OF_BAD_ADDR on error + * Return: the translated address; OF_BAD_ADDR on error */ u64 ofnode_translate_address(ofnode node, const fdt32_t *in_addr); @@ -1062,10 +1089,10 @@ u64 ofnode_translate_address(ofnode node, const fdt32_t *in_addr); * This function walks up the tree and applies the various bus mappings along * the way. * - * @ofnode: Device tree node giving the context in which to translate the - * DMA address + * @node: Device tree node giving the context in which to translate the + * DMA address * @in_addr: pointer to the DMA address to translate - * @return the translated DMA address; OF_BAD_ADDR on error + * Return: the translated DMA address; OF_BAD_ADDR on error */ u64 ofnode_translate_dma_address(ofnode node, const fdt32_t *in_addr); @@ -1075,12 +1102,11 @@ u64 ofnode_translate_dma_address(ofnode node, const fdt32_t *in_addr); * Get DMA ranges for a specifc node, this is useful to perform bus->cpu and * cpu->bus address translations * - * @param blob Pointer to device tree blob - * @param node_offset Node DT offset - * @param cpu Pointer to variable storing the range's cpu address - * @param bus Pointer to variable storing the range's bus address - * @param size Pointer to variable storing the range's size - * @return translated DMA address or OF_BAD_ADDR on error + * @node: Device tree node + * @cpu: Pointer to variable storing the range's cpu address + * @bus: Pointer to variable storing the range's bus address + * @size: Pointer to variable storing the range's size + * Return: translated DMA address or OF_BAD_ADDR on error */ int ofnode_get_dma_range(ofnode node, phys_addr_t *cpu, dma_addr_t *bus, u64 *size); @@ -1092,7 +1118,7 @@ int ofnode_get_dma_range(ofnode node, phys_addr_t *cpu, dma_addr_t *bus, * * @node: Device tree node for which compatible needs to be verified. * @compat: Compatible string which needs to verified in the given node. - * @return true if OK, false if the compatible is not found + * Return: true if OK, false if the compatible is not found */ int ofnode_device_is_compatible(ofnode node, const char *compat); @@ -1107,7 +1133,7 @@ int ofnode_device_is_compatible(ofnode node, const char *compat); * @len: The length of the new value of the property * @value: The new value of the property (must be valid prior to calling * the function) - * @return 0 if successful, -ve on error + * Return: 0 if successful, -ve on error */ int ofnode_write_prop(ofnode node, const char *propname, int len, const void *value); @@ -1122,7 +1148,7 @@ int ofnode_write_prop(ofnode node, const char *propname, int len, * @propname: The name of the string property to set * @value: The new value of the string property (must be valid prior to * calling the function) - * @return 0 if successful, -ve on error + * Return: 0 if successful, -ve on error */ int ofnode_write_string(ofnode node, const char *propname, const char *value); @@ -1137,7 +1163,7 @@ int ofnode_write_string(ofnode node, const char *propname, const char *value); * @node: The node to enable * @value: Flag that tells the function to either disable or enable the * node - * @return 0 if successful, -ve on error + * Return: 0 if successful, -ve on error */ int ofnode_set_enabled(ofnode node, bool value); @@ -1148,8 +1174,8 @@ int ofnode_set_enabled(ofnode node, bool value); * * See doc/config.txt for bindings * - * @prop_name property name to look up - * @return true, if it exists, false if not + * @prop_name: property name to look up + * Return: true, if it exists, false if not */ bool ofnode_conf_read_bool(const char *prop_name); @@ -1162,7 +1188,7 @@ bool ofnode_conf_read_bool(const char *prop_name); * * @prop_name: property name to look up * @default_val: default value to return if the property is not found - * @return integer value, if found, or @default_val if not + * Return: integer value, if found, or @default_val if not */ int ofnode_conf_read_int(const char *prop_name, int default_val); @@ -1174,7 +1200,7 @@ int ofnode_conf_read_int(const char *prop_name, int default_val); * See doc/config.txt for bindings * * @prop_name: property name to look up - * @return string value, if found, or NULL if not + * Return: string value, if found, or NULL if not */ const char *ofnode_conf_read_str(const char *prop_name); diff --git a/include/dm/pinctrl.h b/include/dm/pinctrl.h index 695e78ad0de..8b869c4fbfb 100644 --- a/include/dm/pinctrl.h +++ b/include/dm/pinctrl.h @@ -495,7 +495,7 @@ int pinctrl_generic_set_state(struct udevice *pctldev, struct udevice *config); static inline int pinctrl_generic_set_state(struct udevice *pctldev, struct udevice *config) { - return -EINVAL; + return -ENOSYS; } #endif @@ -512,7 +512,7 @@ int pinctrl_select_state(struct udevice *dev, const char *statename); static inline int pinctrl_select_state(struct udevice *dev, const char *statename) { - return -EINVAL; + return -ENOSYS; } #endif diff --git a/include/dm/platdata.h b/include/dm/platdata.h index 4efb1dfe12d..47ba8aab7ae 100644 --- a/include/dm/platdata.h +++ b/include/dm/platdata.h @@ -40,7 +40,7 @@ struct driver_info { #endif /** - * driver_rt - runtime information set up by U-Boot + * struct driver_rt - runtime information set up by U-Boot * * There is one of these for every driver_info in the linker list, indexed by * the driver_info idx value. @@ -51,7 +51,7 @@ struct driver_rt { struct udevice *dev; }; -/** +/* * NOTE: Avoid using these except in extreme circumstances, where device tree * is not feasible (e.g. serial driver in SPL where <8KB of SRAM is * available). U-Boot's driver model uses device tree for configuration. diff --git a/include/dm/read.h b/include/dm/read.h index 890bf3d8472..233af3c0634 100644 --- a/include/dm/read.h +++ b/include/dm/read.h @@ -37,7 +37,7 @@ static inline const struct device_node *dev_np(const struct udevice *dev) * @dev: device to read DT property from * @propname: name of the property to read from * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dev_read_u32(const struct udevice *dev, const char *propname, u32 *outp); @@ -47,7 +47,7 @@ int dev_read_u32(const struct udevice *dev, const char *propname, u32 *outp); * @dev: device to read DT property from * @propname: name of the property to read from * @def: default value to return if the property has no value - * @return property value, or @def if not found + * Return: property value, or @def if not found */ int dev_read_u32_default(const struct udevice *dev, const char *propname, int def); @@ -60,7 +60,7 @@ int dev_read_u32_default(const struct udevice *dev, const char *propname, * @propname: name of the property to read from * @index: index of the integer to return * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dev_read_u32_index(struct udevice *dev, const char *propname, int index, u32 *outp); @@ -73,7 +73,7 @@ int dev_read_u32_index(struct udevice *dev, const char *propname, int index, * @propname: name of the property to read from * @index: index of the integer to return * @def: default value to return if the property has no value - * @return property value, or @def if not found + * Return: property value, or @def if not found */ u32 dev_read_u32_index_default(struct udevice *dev, const char *propname, int index, u32 def); @@ -84,7 +84,7 @@ u32 dev_read_u32_index_default(struct udevice *dev, const char *propname, * @dev: device to read DT property from * @propname: name of the property to read from * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dev_read_s32(const struct udevice *dev, const char *propname, s32 *outp); @@ -94,7 +94,7 @@ int dev_read_s32(const struct udevice *dev, const char *propname, s32 *outp); * @dev: device to read DT property from * @propname: name of the property to read from * @def: default value to return if the property has no value - * @return property value, or @def if not found + * Return: property value, or @def if not found */ int dev_read_s32_default(const struct udevice *dev, const char *propname, int def); @@ -107,7 +107,7 @@ int dev_read_s32_default(const struct udevice *dev, const char *propname, * @dev: device to read DT property from * @propname: name of the property to read from * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dev_read_u32u(const struct udevice *dev, const char *propname, uint *outp); @@ -117,7 +117,7 @@ int dev_read_u32u(const struct udevice *dev, const char *propname, uint *outp); * @dev: device to read DT property from * @propname: name of the property to read from * @outp: place to put value (if found) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dev_read_u64(const struct udevice *dev, const char *propname, u64 *outp); @@ -127,7 +127,7 @@ int dev_read_u64(const struct udevice *dev, const char *propname, u64 *outp); * @dev: device to read DT property from * @propname: name of the property to read from * @def: default value to return if the property has no value - * @return property value, or @def if not found + * Return: property value, or @def if not found */ u64 dev_read_u64_default(const struct udevice *dev, const char *propname, u64 def); @@ -137,7 +137,7 @@ u64 dev_read_u64_default(const struct udevice *dev, const char *propname, * * @dev: device to read DT property from * @propname: name of the property to read - * @return string from property value, or NULL if there is no such property + * Return: string from property value, or NULL if there is no such property */ const char *dev_read_string(const struct udevice *dev, const char *propname); @@ -146,7 +146,7 @@ const char *dev_read_string(const struct udevice *dev, const char *propname); * * @dev: device to read DT property from * @propname: name of property to read - * @return true if property is present (meaning true), false if not present + * Return: true if property is present (meaning true), false if not present */ bool dev_read_bool(const struct udevice *dev, const char *propname); @@ -155,17 +155,17 @@ bool dev_read_bool(const struct udevice *dev, const char *propname); * * @dev: device whose DT node contains the subnode * @subnode_name: name of subnode to find - * @return reference to subnode (which can be invalid if there is no such + * Return: reference to subnode (which can be invalid if there is no such * subnode) */ -ofnode dev_read_subnode(const struct udevice *dev, const char *subbnode_name); +ofnode dev_read_subnode(const struct udevice *dev, const char *subnode_name); /** * dev_read_size() - read the size of a property * * @dev: device to check * @propname: property to check - * @return size of property if present, or -EINVAL if not + * Return: size of property if present, or -EINVAL if not */ int dev_read_size(const struct udevice *dev, const char *propname); @@ -176,7 +176,7 @@ int dev_read_size(const struct udevice *dev, const char *propname); * @index: the 'reg' property can hold a list of <addr, size> pairs * and @index is used to select which one is required * - * @return address or FDT_ADDR_T_NONE if not found + * Return: address or FDT_ADDR_T_NONE if not found */ fdt_addr_t dev_read_addr_index(const struct udevice *dev, int index); @@ -188,7 +188,7 @@ fdt_addr_t dev_read_addr_index(const struct udevice *dev, int index); * @index: the 'reg' property can hold a list of <addr, size> pairs * and @index is used to select which one is required * - * @return pointer or NULL if not found + * Return: pointer or NULL if not found */ void *dev_read_addr_index_ptr(const struct udevice *dev, int index); @@ -200,7 +200,7 @@ void *dev_read_addr_index_ptr(const struct udevice *dev, int index); * and @index is used to select which one is required * @size: place to put size value (on success) * - * @return address or FDT_ADDR_T_NONE if not found + * Return: address or FDT_ADDR_T_NONE if not found */ fdt_addr_t dev_read_addr_size_index(const struct udevice *dev, int index, fdt_size_t *size); @@ -213,7 +213,7 @@ fdt_addr_t dev_read_addr_size_index(const struct udevice *dev, int index, * @index: the 'reg' property can hold a list of <addr, size> pairs * and @index is used to select which one is required * - * @return pointer or NULL if not found + * Return: pointer or NULL if not found */ void *dev_remap_addr_index(const struct udevice *dev, int index); @@ -225,7 +225,7 @@ void *dev_remap_addr_index(const struct udevice *dev, int index); * 'reg-names' property providing named-based identification. @index * indicates the value to search for in 'reg-names'. * - * @return address or FDT_ADDR_T_NONE if not found + * Return: address or FDT_ADDR_T_NONE if not found */ fdt_addr_t dev_read_addr_name(const struct udevice *dev, const char *name); @@ -238,7 +238,7 @@ fdt_addr_t dev_read_addr_name(const struct udevice *dev, const char *name); * indicates the value to search for in 'reg-names'. * @size: place to put size value (on success) * - * @return address or FDT_ADDR_T_NONE if not found + * Return: address or FDT_ADDR_T_NONE if not found */ fdt_addr_t dev_read_addr_size_name(const struct udevice *dev, const char *name, fdt_size_t *size); @@ -252,7 +252,7 @@ fdt_addr_t dev_read_addr_size_name(const struct udevice *dev, const char *name, * 'reg-names' property providing named-based identification. @index * indicates the value to search for in 'reg-names'. * - * @return pointer or NULL if not found + * Return: pointer or NULL if not found */ void *dev_remap_addr_name(const struct udevice *dev, const char *name); @@ -261,7 +261,7 @@ void *dev_remap_addr_name(const struct udevice *dev, const char *name); * * @dev: Device to read from * - * @return address or FDT_ADDR_T_NONE if not found + * Return: address or FDT_ADDR_T_NONE if not found */ fdt_addr_t dev_read_addr(const struct udevice *dev); @@ -271,7 +271,7 @@ fdt_addr_t dev_read_addr(const struct udevice *dev); * * @dev: Device to read from * - * @return pointer or NULL if not found + * Return: pointer or NULL if not found */ void *dev_read_addr_ptr(const struct udevice *dev); @@ -291,7 +291,7 @@ void *dev_read_addr_ptr(const struct udevice *dev); * fdtdec_get_addr() and friends. * * @dev: Device to read from - * @return address or FDT_ADDR_T_NONE if not found + * Return: address or FDT_ADDR_T_NONE if not found */ fdt_addr_t dev_read_addr_pci(const struct udevice *dev); @@ -301,7 +301,7 @@ fdt_addr_t dev_read_addr_pci(const struct udevice *dev); * * @dev: Device to read from * - * @return pointer or NULL if not found + * Return: pointer or NULL if not found */ void *dev_remap_addr(const struct udevice *dev); @@ -314,7 +314,7 @@ void *dev_remap_addr(const struct udevice *dev); * @dev: Device to read from * @propname: property to read * @sizep: place to put size value (on success) - * @return address value, or FDT_ADDR_T_NONE on error + * Return: address value, or FDT_ADDR_T_NONE on error */ fdt_addr_t dev_read_addr_size(const struct udevice *dev, const char *propname, fdt_size_t *sizep); @@ -323,7 +323,7 @@ fdt_addr_t dev_read_addr_size(const struct udevice *dev, const char *propname, * dev_read_name() - get the name of a device's node * * @dev: Device to read from - * @return name of node + * Return: name of node */ const char *dev_read_name(const struct udevice *dev); @@ -340,12 +340,12 @@ const char *dev_read_name(const struct udevice *dev); * @propname: name of the property containing the string list * @string: string to look up in the string list * - * @return: + * Return: * the index of the string in the list of strings * -ENODATA if the property is not found * -EINVAL on some other error */ -int dev_read_stringlist_search(const struct udevice *dev, const char *property, +int dev_read_stringlist_search(const struct udevice *dev, const char *propname, const char *string); /** @@ -354,9 +354,9 @@ int dev_read_stringlist_search(const struct udevice *dev, const char *property, * @dev: device to examine * @propname: name of the property containing the string list * @index: index of the string to return - * @out: return location for the string + * @outp: return location for the string * - * @return: + * Return: * length of string, if found or -ve error value if not found */ int dev_read_string_index(const struct udevice *dev, const char *propname, @@ -367,10 +367,32 @@ int dev_read_string_index(const struct udevice *dev, const char *propname, * * @dev: device to examine * @propname: name of the property containing the string list - * @return: + * Return: * number of strings in the list, or -ve error value if not found */ int dev_read_string_count(const struct udevice *dev, const char *propname); + +/** + * dev_read_string_list() - read a list of strings + * + * This produces a list of string pointers with each one pointing to a string + * in the string list. If the property does not exist, it returns {NULL}. + * + * The data is allocated and the caller is reponsible for freeing the return + * value (the list of string pointers). The strings themselves may not be + * changed as they point directly into the devicetree property. + * + * @dev: device to examine + * @propname: name of the property containing the string list + * @listp: returns an allocated, NULL-terminated list of strings if the return + * value is > 0, else is set to NULL + * Return: + * number of strings in list, 0 if none, -ENOMEM if out of memory, + * -ENOENT if no such property + */ +int dev_read_string_list(const struct udevice *dev, const char *propname, + const char ***listp); + /** * dev_read_phandle_with_args() - Find a node pointed by phandle in a list * @@ -383,17 +405,17 @@ int dev_read_string_count(const struct udevice *dev, const char *propname); * * Example: * - * phandle1: node1 { - * #list-cells = <2>; - * } - * - * phandle2: node2 { - * #list-cells = <1>; - * } + * .. code-block:: * - * node3 { - * list = <&phandle1 1 2 &phandle2 3>; - * } + * phandle1: node1 { + * #list-cells = <2>; + * }; + * phandle2: node2 { + * #list-cells = <1>; + * }; + * node3 { + * list = <&phandle1 1 2 &phandle2 3>; + * }; * * To get a device_node of the `node2' node you may call this: * dev_read_phandle_with_args(dev, "list", "#list-cells", 0, 1, &args); @@ -401,10 +423,10 @@ int dev_read_string_count(const struct udevice *dev, const char *propname); * @dev: device whose node containing a list * @list_name: property name that contains a list * @cells_name: property name that specifies phandles' arguments count - * @cells_count: Cell count to use if @cells_name is NULL + * @cell_count: Cell count to use if @cells_name is NULL * @index: index of a phandle to parse out * @out_args: optional pointer to output arguments structure (will be filled) - * @return 0 on success (with @out_args filled out if not NULL), -ENOENT if + * Return: 0 on success (with @out_args filled out if not NULL), -ENOENT if * @list_name does not exist, -EINVAL if a phandle was not found, * @cells_name could not be found, the arguments were truncated or there * were too many arguments. @@ -420,12 +442,11 @@ int dev_read_phandle_with_args(const struct udevice *dev, const char *list_name, * For example, this allows to allocate the right amount of memory to keep * clock's reference contained into the "clocks" property. * - * * @dev: device whose node containing a list * @list_name: property name that contains a list * @cells_name: property name that specifies phandles' arguments count - * @cells_count: Cell count to use if @cells_name is NULL - * @Returns number of phandle found on success, on error returns appropriate + * @cell_count: Cell count to use if @cells_name is NULL + * Return: number of phandle found on success, on error returns appropriate * errno value. */ @@ -440,7 +461,7 @@ int dev_count_phandle_with_args(const struct udevice *dev, * which controls the given node. * * @dev: device to check - * @return number of address cells this node uses + * Return: number of address cells this node uses */ int dev_read_addr_cells(const struct udevice *dev); @@ -451,7 +472,7 @@ int dev_read_addr_cells(const struct udevice *dev); * which controls the given node. * * @dev: device to check - * @return number of size cells this node uses + * Return: number of size cells this node uses */ int dev_read_size_cells(const struct udevice *dev); @@ -461,7 +482,7 @@ int dev_read_size_cells(const struct udevice *dev); * This function matches fdt_address_cells(). * * @dev: device to check - * @return number of address cells this node uses + * Return: number of address cells this node uses */ int dev_read_simple_addr_cells(const struct udevice *dev); @@ -471,7 +492,7 @@ int dev_read_simple_addr_cells(const struct udevice *dev); * This function matches fdt_size_cells(). * * @dev: device to check - * @return number of size cells this node uses + * Return: number of size cells this node uses */ int dev_read_simple_size_cells(const struct udevice *dev); @@ -479,7 +500,7 @@ int dev_read_simple_size_cells(const struct udevice *dev); * dev_read_phandle() - Get the phandle from a device * * @dev: device to check - * @return phandle (1 or greater), or 0 if no phandle or other error + * Return: phandle (1 or greater), or 0 if no phandle or other error */ int dev_read_phandle(const struct udevice *dev); @@ -489,7 +510,7 @@ int dev_read_phandle(const struct udevice *dev); * @dev: device to check * @propname: property to read * @lenp: place to put length on success - * @return pointer to property, or NULL if not found + * Return: pointer to property, or NULL if not found */ const void *dev_read_prop(const struct udevice *dev, const char *propname, int *lenp); @@ -502,7 +523,7 @@ const void *dev_read_prop(const struct udevice *dev, const char *propname, * * @dev: device to check * @prop: place to put argument reference - * @return 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found + * Return: 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found */ int dev_read_first_prop(const struct udevice *dev, struct ofprop *prop); @@ -513,7 +534,7 @@ int dev_read_first_prop(const struct udevice *dev, struct ofprop *prop); * and read all the property with dev_read_prop_by_prop(). * * @prop: reference of current argument and place to put reference of next one - * @return 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found + * Return: 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found */ int dev_read_next_prop(struct ofprop *prop); @@ -525,7 +546,7 @@ int dev_read_next_prop(struct ofprop *prop); * @prop: reference on property * @propname: If non-NULL, place to property name on success, * @lenp: If non-NULL, place to put length on success - * @return 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found + * Return: 0 if OK, -ve on error. -FDT_ERR_NOTFOUND if not found */ const void *dev_read_prop_by_prop(struct ofprop *prop, const char **propname, int *lenp); @@ -539,7 +560,7 @@ const void *dev_read_prop_by_prop(struct ofprop *prop, * * @dev: device to look up * @devnump: set to the sequence number if one is found - * @return 0 if a sequence was found, -ve if not + * Return: 0 if a sequence was found, -ve if not */ int dev_read_alias_seq(const struct udevice *dev, int *devnump); @@ -555,7 +576,7 @@ int dev_read_alias_seq(const struct udevice *dev, int *devnump); * @propname: name of the property to read * @out_values: pointer to return value, modified only if return value is 0 * @sz: number of array elements to read - * @return 0 on success, -EINVAL if the property does not exist, -ENODATA if + * Return: 0 on success, -EINVAL if the property does not exist, -ENODATA if * property does not have a value, and -EOVERFLOW if the property data isn't * large enough. */ @@ -566,7 +587,7 @@ int dev_read_u32_array(const struct udevice *dev, const char *propname, * dev_read_first_subnode() - find the first subnode of a device's node * * @dev: device to look up - * @return reference to the first subnode (which can be invalid if the device's + * Return: reference to the first subnode (which can be invalid if the device's * node has no subnodes) */ ofnode dev_read_first_subnode(const struct udevice *dev); @@ -575,7 +596,7 @@ ofnode dev_read_first_subnode(const struct udevice *dev); * ofnode_next_subnode() - find the next sibling of a subnode * * @node: valid reference to previous node (sibling) - * @return reference to the next subnode (which can be invalid if the node + * Return: reference to the next subnode (which can be invalid if the node * has no more siblings) */ ofnode dev_read_next_subnode(ofnode node); @@ -591,8 +612,9 @@ ofnode dev_read_next_subnode(ofnode node); * @dev: device to look up * @propname: name of property to find * @sz: number of array elements - * @return pointer to byte array if found, or NULL if the property is not - * found or there is not enough data + * Return: + * pointer to byte array if found, or NULL if the property is not found or + * there is not enough data */ const uint8_t *dev_read_u8_array_ptr(const struct udevice *dev, const char *propname, size_t sz); @@ -606,7 +628,7 @@ const uint8_t *dev_read_u8_array_ptr(const struct udevice *dev, * by default. * * @dev: device to examine - * @return integer value 0 (not enabled) or 1 (enabled) + * Return: integer value 0 (not enabled) or 1 (enabled) */ int dev_read_enabled(const struct udevice *dev); @@ -614,9 +636,9 @@ int dev_read_enabled(const struct udevice *dev); * dev_read_resource() - obtain an indexed resource from a device. * * @dev: device to examine - * @index index of the resource to retrieve (0 = first) - * @res returns the resource - * @return 0 if ok, negative on error + * @index: index of the resource to retrieve (0 = first) + * @res: returns the resource + * Return: 0 if ok, negative on error */ int dev_read_resource(const struct udevice *dev, uint index, struct resource *res); @@ -627,7 +649,7 @@ int dev_read_resource(const struct udevice *dev, uint index, * @dev: device to examine * @name: name of the resource to retrieve * @res: returns the resource - * @return 0 if ok, negative on error + * Return: 0 if ok, negative on error */ int dev_read_resource_byname(const struct udevice *dev, const char *name, struct resource *res); @@ -641,7 +663,7 @@ int dev_read_resource_byname(const struct udevice *dev, const char *name, * * @dev: device giving the context in which to translate the address * @in_addr: pointer to the address to translate - * @return the translated address; OF_BAD_ADDR on error + * Return: the translated address; OF_BAD_ADDR on error */ u64 dev_translate_address(const struct udevice *dev, const fdt32_t *in_addr); @@ -654,7 +676,7 @@ u64 dev_translate_address(const struct udevice *dev, const fdt32_t *in_addr); * * @dev: device giving the context in which to translate the DMA address * @in_addr: pointer to the DMA address to translate - * @return the translated DMA address; OF_BAD_ADDR on error + * Return: the translated DMA address; OF_BAD_ADDR on error */ u64 dev_translate_dma_address(const struct udevice *dev, const fdt32_t *in_addr); @@ -669,7 +691,7 @@ u64 dev_translate_dma_address(const struct udevice *dev, * @cpu: base address for CPU's view of memory * @bus: base address for BUS's view of memory * @size: size of the address space - * @return 0 if ok, negative on error + * Return: 0 if ok, negative on error */ int dev_get_dma_range(const struct udevice *dev, phys_addr_t *cpu, dma_addr_t *bus, u64 *size); @@ -680,15 +702,15 @@ int dev_get_dma_range(const struct udevice *dev, phys_addr_t *cpu, * * The function travels the lookup table to get the highest alias id for the * given alias stem. - * @return alias ID, if found, else -1 + * Return: alias ID, if found, else -1 */ int dev_read_alias_highest_id(const char *stem); /** * dev_get_child_count() - get the child count of a device * - * @dev: device to use for interation (struct udevice *) - * @return the count of child subnode + * @dev: device to use for interation (`struct udevice *`) + * Return: the count of child subnode */ int dev_get_child_count(const struct udevice *dev); @@ -699,8 +721,8 @@ int dev_get_child_count(const struct udevice *dev); * range for this node. * * @dev: device to examine - * @res returns the resource - * @return 0 if ok, negative on error + * @res: returns the resource + * Return: 0 if ok, negative on error */ int dev_read_pci_bus_range(const struct udevice *dev, struct resource *res); @@ -716,7 +738,7 @@ int dev_read_pci_bus_range(const struct udevice *dev, struct resource *res); * one or more display timing nodes. * @index: index number to read (0=first timing subnode) * @config: place to put timings - * @return 0 if OK, -FDT_ERR_NOTFOUND if not found + * Return: 0 if OK, -FDT_ERR_NOTFOUND if not found */ int dev_decode_display_timing(const struct udevice *dev, int index, struct display_timing *config); @@ -906,6 +928,13 @@ static inline int dev_read_string_count(const struct udevice *dev, return ofnode_read_string_count(dev_ofnode(dev), propname); } +static inline int dev_read_string_list(const struct udevice *dev, + const char *propname, + const char ***listp) +{ + return ofnode_read_string_list(dev_ofnode(dev), propname, listp); +} + static inline int dev_read_phandle_with_args(const struct udevice *dev, const char *list_name, const char *cells_name, int cell_count, int index, struct ofnode_phandle_args *out_args) @@ -1072,7 +1101,7 @@ static inline int dev_decode_display_timing(const struct udevice *dev, * device-tree node. * * @subnode: ofnode holding the current subnode - * @dev: device to use for interation (struct udevice *) + * @dev: device to use for interation (`struct udevice *`) */ #define dev_for_each_subnode(subnode, dev) \ for (subnode = dev_read_first_subnode(dev); \ @@ -1086,7 +1115,7 @@ static inline int dev_decode_display_timing(const struct udevice *dev, * device-tree node. * * @prop: struct ofprop holding the current property - * @dev: device to use for interation (struct udevice *) + * @dev: device to use for interation (`struct udevice *`) */ #define dev_for_each_property(prop, dev) \ for (int ret_prop = dev_read_first_prop(dev, &prop); \ diff --git a/include/dm/root.h b/include/dm/root.h index 42510b106ab..e888fb993c0 100644 --- a/include/dm/root.h +++ b/include/dm/root.h @@ -19,7 +19,7 @@ extern struct list_head uclass_head; * * This function returns pointer to the root node of the driver tree, * - * @return pointer to root device, or NULL if not inited yet + * Return: pointer to root device, or NULL if not inited yet */ struct udevice *dm_root(void); @@ -27,6 +27,8 @@ struct global_data; /** * dm_fixup_for_gd_move() - Handle global_data moving to a new place * + * @new_gd: Pointer to the new global data + * * The uclass list is part of global_data. Due to the way lists work, moving * the list will cause it to become invalid. This function fixes that up so * that the uclass list will work correctly. @@ -40,7 +42,7 @@ void dm_fixup_for_gd_move(struct global_data *new_gd); * * @pre_reloc_only: If true, bind only drivers with the DM_FLAG_PRE_RELOC * flag. If false bind all drivers. - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_scan_plat(bool pre_reloc_only); @@ -52,7 +54,7 @@ int dm_scan_plat(bool pre_reloc_only); * * @pre_reloc_only: If true, bind only nodes with special devicetree properties, * or drivers with the DM_FLAG_PRE_RELOC flag. If false bind all drivers. - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_scan_fdt(bool pre_reloc_only); @@ -65,7 +67,7 @@ int dm_scan_fdt(bool pre_reloc_only); * * @pre_reloc_only: If true, bind only nodes with special devicetree properties, * or drivers with the DM_FLAG_PRE_RELOC flag. If false bind all drivers. - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_extended_scan(bool pre_reloc_only); @@ -79,7 +81,7 @@ int dm_extended_scan(bool pre_reloc_only); * * @pre_reloc_only: If true, bind only nodes with special devicetree properties, * or drivers with the DM_FLAG_PRE_RELOC flag. If false bind all drivers. - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_scan_other(bool pre_reloc_only); @@ -92,7 +94,7 @@ int dm_scan_other(bool pre_reloc_only); * * @pre_reloc_only: If true, bind only nodes with special devicetree properties, * or drivers with the DM_FLAG_PRE_RELOC flag. If false bind all drivers. - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_init_and_scan(bool pre_reloc_only); @@ -103,7 +105,7 @@ int dm_init_and_scan(bool pre_reloc_only); * This needs to be called before anything uses the DM * * @of_live: Enable live device tree - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_init(bool of_live); @@ -111,7 +113,7 @@ int dm_init(bool of_live); * dm_uninit - Uninitialise Driver Model structures * * All devices will be removed and unbound - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_uninit(void); @@ -124,11 +126,19 @@ int dm_uninit(void); * All devices with the matching flags set will be removed * * @flags: Flags for selective device removal - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int dm_remove_devices_flags(uint flags); #else static inline int dm_remove_devices_flags(uint flags) { return 0; } #endif +/** + * dm_get_stats() - Get some stats for driver mode + * + * @device_countp: Returns total number of devices that are bound + * @uclass_countp: Returns total number of uclasses in use + */ +void dm_get_stats(int *device_countp, int *uclass_countp); + #endif diff --git a/include/dm/uclass-id.h b/include/dm/uclass-id.h index fd139b9b2a0..0e26e1d1382 100644 --- a/include/dm/uclass-id.h +++ b/include/dm/uclass-id.h @@ -48,7 +48,8 @@ enum uclass_id { UCLASS_DMA, /* Direct Memory Access */ UCLASS_DSA, /* Distributed (Ethernet) Switch Architecture */ UCLASS_ECDSA, /* Elliptic curve cryptographic device */ - UCLASS_EFI, /* EFI managed devices */ + UCLASS_EFI_LOADER, /* Devices created by UEFI applications */ + UCLASS_EFI_MEDIA, /* Devices provided by UEFI firmware */ UCLASS_ETH, /* Ethernet device */ UCLASS_ETH_PHY, /* Ethernet PHY device */ UCLASS_FIRMWARE, /* Firmware */ diff --git a/include/dm/uclass-internal.h b/include/dm/uclass-internal.h index 57c664c6daa..fb0edcc2969 100644 --- a/include/dm/uclass-internal.h +++ b/include/dm/uclass-internal.h @@ -243,6 +243,17 @@ int uclass_find_device_by_phandle(enum uclass_id id, struct udevice *parent, */ int uclass_bind_device(struct udevice *dev); +#if CONFIG_IS_ENABLED(DM_DEVICE_REMOVE) +/** + * uclass_pre_unbind_device() - Prepare to deassociate device with a uclass + * + * Call any handled needed before uclass_unbind_device() is called + * + * @dev: Pointer to the device + * #return 0 on success, -ve on error + */ +int uclass_pre_unbind_device(struct udevice *dev); + /** * uclass_unbind_device() - Deassociate device with a uclass * @@ -251,9 +262,10 @@ int uclass_bind_device(struct udevice *dev); * @dev: Pointer to the device * #return 0 on success, -ve on error */ -#if CONFIG_IS_ENABLED(DM_DEVICE_REMOVE) int uclass_unbind_device(struct udevice *dev); + #else +static inline int uclass_pre_unbind_device(struct udevice *dev) { return 0; } static inline int uclass_unbind_device(struct udevice *dev) { return 0; } #endif @@ -295,6 +307,13 @@ static inline int uclass_pre_remove_device(struct udevice *dev) { return 0; } #endif /** + * uclass_get_count() - Get the number of uclasses + * + * Returns the number of uclasses instantiated in driver model + */ +int uclass_get_count(void); + +/** * uclass_find() - Find uclass by its id * * @id: Id to serach for diff --git a/include/dm/uclass.h b/include/dm/uclass.h index 15e5f9ef5bc..7f33c34214e 100644 --- a/include/dm/uclass.h +++ b/include/dm/uclass.h @@ -84,7 +84,7 @@ struct udevice; * its children. If non-zero this is the size of this data, to be allocated * in the child device's parent_plat pointer. This value is only used as * a fallback if this member is 0 in the driver. - * @flags: Flags for this uclass (DM_UC_...) + * @flags: Flags for this uclass ``(DM_UC_...)`` */ struct uclass_driver { const char *name; @@ -127,17 +127,16 @@ struct uclass_driver { * build time. Before this is used, an extern UCLASS_DRIVER() must have been * declared. * - * For example: + * For example:: * - * extern UCLASS_DRIVER(clk); - * - * struct uclass_driver *drvs[] = { - * DM_UCLASS_DRIVER_REF(clk), - * }; + * extern UCLASS_DRIVER(clk); + * struct uclass_driver *drvs[] = { + * DM_UCLASS_DRIVER_REF(clk), + * }; * * @_name: Name of the uclass_driver. This must be a valid C identifier, used by * the linker_list. - * @returns struct uclass_driver * for the uclass driver + * Return: struct uclass_driver * for the uclass driver */ #define DM_UCLASS_DRIVER_REF(_name) \ ll_entry_ref(struct uclass_driver, _name, uclass_driver) @@ -145,8 +144,8 @@ struct uclass_driver { /** * uclass_get_priv() - Get the private data for a uclass * - * @uc Uclass to check - * @return private data, or NULL if none + * @uc: Uclass to check + * Return: private data, or NULL if none */ void *uclass_get_priv(const struct uclass *uc); @@ -159,8 +158,9 @@ void *uclass_get_priv(const struct uclass *uc); * * @key: ID to look up * @ucp: Returns pointer to uclass (there is only one per ID) - * @return 0 if OK, -EDEADLK if driver model is not yet inited, other -ve on - * other error + * Return: + * 0 if OK, -EDEADLK if driver model is not yet inited, + * other -ve on other error */ int uclass_get(enum uclass_id key, struct uclass **ucp); @@ -168,15 +168,24 @@ int uclass_get(enum uclass_id key, struct uclass **ucp); * uclass_get_name() - Get the name of a uclass driver * * @id: ID to look up - * @returns the name of the uclass driver for that ID, or NULL if none + * Return: the name of the uclass driver for that ID, or NULL if none */ const char *uclass_get_name(enum uclass_id id); /** + * uclass_get_by_name_len() - Look up a uclass by its partial driver name + * + * @name: Name to look up + * @len: Length of the partial name + * Return: the associated uclass ID, or UCLASS_INVALID if not found + */ +enum uclass_id uclass_get_by_name_len(const char *name, int len); + +/** * uclass_get_by_name() - Look up a uclass by its driver name * * @name: Name to look up - * @returns the associated uclass ID, or UCLASS_INVALID if not found + * Return: the associated uclass ID, or UCLASS_INVALID if not found */ enum uclass_id uclass_get_by_name(const char *name); @@ -188,7 +197,7 @@ enum uclass_id uclass_get_by_name(const char *name); * @id: ID to look up * @index: Device number within that uclass (0=first) * @devp: Returns pointer to device (there is only one per for each ID) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int uclass_get_device(enum uclass_id id, int index, struct udevice **devp); @@ -202,7 +211,7 @@ int uclass_get_device(enum uclass_id id, int index, struct udevice **devp); * @id: ID to look up * @name: name of a device to get * @devp: Returns pointer to device (the first one with the name) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int uclass_get_device_by_name(enum uclass_id id, const char *name, struct udevice **devp); @@ -219,7 +228,7 @@ int uclass_get_device_by_name(enum uclass_id id, const char *name, * @id: ID to look up * @seq: Sequence number to find (0=first) * @devp: Returns pointer to device (there is only one for each seq) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int uclass_get_device_by_seq(enum uclass_id id, int seq, struct udevice **devp); @@ -234,7 +243,7 @@ int uclass_get_device_by_seq(enum uclass_id id, int seq, struct udevice **devp); * @id: ID to look up * @node: Device tree offset to search for (if -ve then -ENODEV is returned) * @devp: Returns pointer to device (there is only one for each node) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int uclass_get_device_by_of_offset(enum uclass_id id, int node, struct udevice **devp); @@ -248,9 +257,9 @@ int uclass_get_device_by_of_offset(enum uclass_id id, int node, * The device is probed to activate it ready for use. * * @id: ID to look up - * @np: Device tree node to search for (if NULL then -ENODEV is returned) + * @node: Device tree node to search for (if NULL then -ENODEV is returned) * @devp: Returns pointer to device (there is only one for each node) - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int uclass_get_device_by_ofnode(enum uclass_id id, ofnode node, struct udevice **devp); @@ -262,12 +271,13 @@ int uclass_get_device_by_ofnode(enum uclass_id id, ofnode node, * * The device is probed to activate it ready for use. * - * @id: uclass ID to look up + * @id: uclass ID to look up * @phandle_id: the phandle id to look up - * @devp: Returns pointer to device (there is only one for each node). NULL if - * there is no such device. - * @return 0 if OK, -ENODEV if there is no device match the phandle, other - * -ve on error + * @devp: Returns pointer to device (there is only one for each node). + * NULL if there is no such device. + * Return: + * 0 if OK, -ENODEV if there is no device match the phandle, + * other -ve on error */ int uclass_get_device_by_phandle_id(enum uclass_id id, uint phandle_id, struct udevice **devp); @@ -283,8 +293,8 @@ int uclass_get_device_by_phandle_id(enum uclass_id id, uint phandle_id, * @parent: Parent device containing the phandle pointer * @name: Name of property in the parent device node * @devp: Returns pointer to device (there is only one for each node) - * @return 0 if OK, -ENOENT if there is no @name present in the node, other - * -ve on error + * Return: 0 if OK, -ENOENT if there is no @name present in the node, other + * -ve on error */ int uclass_get_device_by_phandle(enum uclass_id id, struct udevice *parent, const char *name, struct udevice **devp); @@ -301,7 +311,7 @@ int uclass_get_device_by_phandle(enum uclass_id id, struct udevice *parent, * @id: ID to look up * @drv: Driver to look for * @devp: Returns pointer to the first device with that driver - * @return 0 if OK, -ve on error + * Return: 0 if OK, -ve on error */ int uclass_get_device_by_driver(enum uclass_id id, const struct driver *drv, struct udevice **devp); @@ -318,7 +328,7 @@ int uclass_get_device_by_driver(enum uclass_id id, const struct driver *drv, * @devp: Returns pointer to the first device in that uclass if no error * occurred, or NULL if there is no first device, or an error occurred with * that device. - * @return 0 if OK (found or not found), other -ve on error + * Return: 0 if OK (found or not found), other -ve on error */ int uclass_first_device(enum uclass_id id, struct udevice **devp); @@ -329,7 +339,7 @@ int uclass_first_device(enum uclass_id id, struct udevice **devp); * * @id: Uclass ID to look up * @devp: Returns pointer to the first device in that uclass, or NULL if none - * @return 0 if found, -ENODEV if not found, other -ve on error + * Return: 0 if found, -ENODEV if not found, other -ve on error */ int uclass_first_device_err(enum uclass_id id, struct udevice **devp); @@ -344,7 +354,7 @@ int uclass_first_device_err(enum uclass_id id, struct udevice **devp); * @devp: On entry, pointer to device to lookup. On exit, returns pointer * to the next device in the uclass if no error occurred, or NULL if there is * no next device, or an error occurred with that next device. - * @return 0 if OK (found or not found), other -ve on error + * Return: 0 if OK (found or not found), other -ve on error */ int uclass_next_device(struct udevice **devp); @@ -356,7 +366,7 @@ int uclass_next_device(struct udevice **devp); * @devp: On entry, pointer to device to lookup. On exit, returns pointer * to the next device in the uclass if no error occurred, or NULL if * there is no next device. - * @return 0 if found, -ENODEV if not found, other -ve on error + * Return: 0 if found, -ENODEV if not found, other -ve on error */ int uclass_next_device_err(struct udevice **devp); @@ -371,7 +381,7 @@ int uclass_next_device_err(struct udevice **devp); * @id: Uclass ID to look up * @devp: Returns pointer to the first device in that uclass, or NULL if there * is no first device - * @return 0 if OK (found or not found), other -ve on error. If an error occurs + * Return: 0 if OK (found or not found), other -ve on error. If an error occurs * it is still possible to move to the next device. */ int uclass_first_device_check(enum uclass_id id, struct udevice **devp); @@ -386,7 +396,7 @@ int uclass_first_device_check(enum uclass_id id, struct udevice **devp); * * @devp: On entry, pointer to device to lookup. On exit, returns pointer * to the next device in the uclass if any - * @return 0 if OK (found or not found), other -ve on error. If an error occurs + * Return: 0 if OK (found or not found), other -ve on error. If an error occurs * it is still possible to move to the next device. */ int uclass_next_device_check(struct udevice **devp); @@ -400,7 +410,7 @@ int uclass_next_device_check(struct udevice **devp); * @id: Uclass ID to check * @driver_data: Driver data to search for * @devp: Returns pointer to the first matching device in that uclass, if found - * @return 0 if found, -ENODEV if not found, other -ve on error + * Return: 0 if found, -ENODEV if not found, other -ve on error */ int uclass_first_device_drvdata(enum uclass_id id, ulong driver_data, struct udevice **devp); @@ -412,11 +422,19 @@ int uclass_first_device_drvdata(enum uclass_id id, ulong driver_data, * looking for its ID. * * @id: uclass ID to look up - * @return 0 if OK, other -ve on error + * Return: 0 if OK, other -ve on error */ int uclass_probe_all(enum uclass_id id); /** + * uclass_id_count() - Count the number of devices in a uclass + * + * @id: uclass ID to look up + * Return: number of devices in that uclass (0 if none) + */ +int uclass_id_count(enum uclass_id id); + +/** * uclass_id_foreach_dev() - Helper function to iteration through devices * * This creates a for() loop which works through the available devices in @@ -427,7 +445,7 @@ int uclass_probe_all(enum uclass_id id); * @id: enum uclass_id ID to use * @pos: struct udevice * to hold the current device. Set to NULL when there * are no more devices. - * @uc: temporary uclass variable (struct uclass *) + * @uc: temporary uclass variable (``struct uclass *``) */ #define uclass_id_foreach_dev(id, pos, uc) \ if (!uclass_get(id, &uc)) \ diff --git a/include/dt-bindings/clock/bcm2835.h b/include/dt-bindings/clock/bcm2835.h index 2cec01f9689..b60c03430cf 100644 --- a/include/dt-bindings/clock/bcm2835.h +++ b/include/dt-bindings/clock/bcm2835.h @@ -58,3 +58,5 @@ #define BCM2835_CLOCK_DSI1E 48 #define BCM2835_CLOCK_DSI0P 49 #define BCM2835_CLOCK_DSI1P 50 + +#define BCM2711_CLOCK_EMMC2 51 diff --git a/include/dt-bindings/interrupt-controller/microchip-mpfs-plic.h b/include/dt-bindings/interrupt-controller/microchip-mpfs-plic.h new file mode 100644 index 00000000000..eba1bac7dfb --- /dev/null +++ b/include/dt-bindings/interrupt-controller/microchip-mpfs-plic.h @@ -0,0 +1,196 @@ +/* SPDX-License-Identifier: (GPL-2.0+ OR MIT) */ +/* Copyright (c) 2020-2021 Microchip Technology Inc */ + +#ifndef _DT_BINDINGS_INTERRUPT_CONTROLLER_MICROCHIP_MPFS_PLIC_H +#define _DT_BINDINGS_INTERRUPT_CONTROLLER_MICROCHIP_MPFS_PLIC_H + +#define PLIC_INT_INVALID 0 +#define PLIC_INT_L2_METADATA_CORR 1 +#define PLIC_INT_L2_METADATA_UNCORR 2 +#define PLIC_INT_L2_DATA_CORR 3 +#define PLIC_INT_L2_DATA_UNCORR 4 +#define PLIC_INT_DMA_CH0_DONE 5 +#define PLIC_INT_DMA_CH0_ERR 6 +#define PLIC_INT_DMA_CH1_DONE 7 +#define PLIC_INT_DMA_CH1_ERR 8 +#define PLIC_INT_DMA_CH2_DONE 9 +#define PLIC_INT_DMA_CH2_ERR 10 +#define PLIC_INT_DMA_CH3_DONE 11 +#define PLIC_INT_DMA_CH3_ERR 12 + +#define PLIC_INT_GPIO0_BIT0_OR_GPIO2_BIT0 13 +#define PLIC_INT_GPIO0_BIT1_OR_GPIO2_BIT1 14 +#define PLIC_INT_GPIO0_BIT2_OR_GPIO2_BIT2 15 +#define PLIC_INT_GPIO0_BIT3_OR_GPIO2_BIT3 16 +#define PLIC_INT_GPIO0_BIT4_OR_GPIO2_BIT4 17 +#define PLIC_INT_GPIO0_BIT5_OR_GPIO2_BIT5 18 +#define PLIC_INT_GPIO0_BIT6_OR_GPIO2_BIT6 19 +#define PLIC_INT_GPIO0_BIT7_OR_GPIO2_BIT7 20 +#define PLIC_INT_GPIO0_BIT8_OR_GPIO2_BIT8 21 +#define PLIC_INT_GPIO0_BIT9_OR_GPIO2_BIT9 22 +#define PLIC_INT_GPIO0_BIT10_OR_GPIO2_BIT10 23 +#define PLIC_INT_GPIO0_BIT11_OR_GPIO2_BIT11 24 +#define PLIC_INT_GPIO0_BIT12_OR_GPIO2_BIT12 25 +#define PLIC_INT_GPIO0_BIT13_OR_GPIO2_BIT13 26 +#define PLIC_INT_GPIO1_BIT0_OR_GPIO2_BIT14 27 +#define PLIC_INT_GPIO1_BIT1_OR_GPIO2_BIT15 28 +#define PLIC_INT_GPIO1_BIT2_OR_GPIO2_BIT16 29 +#define PLIC_INT_GPIO1_BIT3_OR_GPIO2_BIT17 30 +#define PLIC_INT_GPIO1_BIT4_OR_GPIO2_BIT18 31 +#define PLIC_INT_GPIO1_BIT5_OR_GPIO2_BIT19 32 +#define PLIC_INT_GPIO1_BIT6_OR_GPIO2_BIT20 33 +#define PLIC_INT_GPIO1_BIT7_OR_GPIO2_BIT21 34 +#define PLIC_INT_GPIO1_BIT8_OR_GPIO2_BIT22 35 +#define PLIC_INT_GPIO1_BIT9_OR_GPIO2_BIT23 36 +#define PLIC_INT_GPIO1_BIT10_OR_GPIO2_BIT24 37 +#define PLIC_INT_GPIO1_BIT11_OR_GPIO2_BIT25 38 +#define PLIC_INT_GPIO1_BIT12_OR_GPIO2_BIT26 39 +#define PLIC_INT_GPIO1_BIT13_OR_GPIO2_BIT27 40 +#define PLIC_INT_GPIO1_BIT14_OR_GPIO2_BIT28 41 +#define PLIC_INT_GPIO1_BIT15_OR_GPIO2_BIT29 42 +#define PLIC_INT_GPIO1_BIT16_OR_GPIO2_BIT30 43 +#define PLIC_INT_GPIO1_BIT17_OR_GPIO2_BIT31 44 +#define PLIC_INT_GPIO1_BIT18 45 +#define PLIC_INT_GPIO1_BIT19 46 +#define PLIC_INT_GPIO1_BIT20 47 +#define PLIC_INT_GPIO1_BIT21 48 +#define PLIC_INT_GPIO1_BIT22 49 +#define PLIC_INT_GPIO1_BIT23 50 +#define PLIC_INT_GPIO0_NON_DIRECT 51 +#define PLIC_INT_GPIO1_NON_DIRECT 52 +#define PLIC_INT_GPIO2_NON_DIRECT 53 +#define PLIC_INT_SPI0 54 +#define PLIC_INT_SPI1 55 +#define PLIC_INT_CAN0 56 +#define PLIC_INT_CAN1 57 +#define PLIC_INT_I2C0_MAIN 58 +#define PLIC_INT_I2C0_ALERT 59 +#define PLIC_INT_I2C0_SUS 60 +#define PLIC_INT_I2C1_MAIN 61 +#define PLIC_INT_I2C1_ALERT 62 +#define PLIC_INT_I2C1_SUS 63 +#define PLIC_INT_MAC0_INT 64 +#define PLIC_INT_MAC0_QUEUE1 65 +#define PLIC_INT_MAC0_QUEUE2 66 +#define PLIC_INT_MAC0_QUEUE3 67 +#define PLIC_INT_MAC0_EMAC 68 +#define PLIC_INT_MAC0_MMSL 69 +#define PLIC_INT_MAC1_INT 70 +#define PLIC_INT_MAC1_QUEUE1 71 +#define PLIC_INT_MAC1_QUEUE2 72 +#define PLIC_INT_MAC1_QUEUE3 73 +#define PLIC_INT_MAC1_EMAC 74 +#define PLIC_INT_MAC1_MMSL 75 +#define PLIC_INT_DDRC_TRAIN 76 +#define PLIC_INT_SCB_INTERRUPT 77 +#define PLIC_INT_ECC_ERROR 78 +#define PLIC_INT_ECC_CORRECT 79 +#define PLIC_INT_RTC_WAKEUP 80 +#define PLIC_INT_RTC_MATCH 81 +#define PLIC_INT_TIMER1 82 +#define PLIC_INT_TIMER2 83 +#define PLIC_INT_ENVM 84 +#define PLIC_INT_QSPI 85 +#define PLIC_INT_USB_DMA 86 +#define PLIC_INT_USB_MC 87 +#define PLIC_INT_MMC_MAIN 88 +#define PLIC_INT_MMC_WAKEUP 89 +#define PLIC_INT_MMUART0 90 +#define PLIC_INT_MMUART1 91 +#define PLIC_INT_MMUART2 92 +#define PLIC_INT_MMUART3 93 +#define PLIC_INT_MMUART4 94 +#define PLIC_INT_G5C_DEVRST 95 +#define PLIC_INT_G5C_MESSAGE 96 +#define PLIC_INT_USOC_VC_INTERRUPT 97 +#define PLIC_INT_USOC_SMB_INTERRUPT 98 +#define PLIC_INT_E51_0_MAINTENACE 99 +#define PLIC_INT_WDOG0_MRVP 100 +#define PLIC_INT_WDOG1_MRVP 101 +#define PLIC_INT_WDOG2_MRVP 102 +#define PLIC_INT_WDOG3_MRVP 103 +#define PLIC_INT_WDOG4_MRVP 104 +#define PLIC_INT_WDOG0_TOUT 105 +#define PLIC_INT_WDOG1_TOUT 106 +#define PLIC_INT_WDOG2_TOUT 107 +#define PLIC_INT_WDOG3_TOUT 108 +#define PLIC_INT_WDOG4_TOUT 109 +#define PLIC_INT_G5C_MSS_SPI 110 +#define PLIC_INT_VOLT_TEMP_ALARM 111 +#define PLIC_INT_ATHENA_COMPLETE 112 +#define PLIC_INT_ATHENA_ALARM 113 +#define PLIC_INT_ATHENA_BUS_ERROR 114 +#define PLIC_INT_USOC_AXIC_US 115 +#define PLIC_INT_USOC_AXIC_DS 116 +#define PLIC_INT_SPARE 117 +#define PLIC_INT_FABRIC_F2H_0 118 +#define PLIC_INT_FABRIC_F2H_1 119 +#define PLIC_INT_FABRIC_F2H_2 120 +#define PLIC_INT_FABRIC_F2H_3 121 +#define PLIC_INT_FABRIC_F2H_4 122 +#define PLIC_INT_FABRIC_F2H_5 123 +#define PLIC_INT_FABRIC_F2H_6 124 +#define PLIC_INT_FABRIC_F2H_7 125 +#define PLIC_INT_FABRIC_F2H_8 126 +#define PLIC_INT_FABRIC_F2H_9 127 +#define PLIC_INT_FABRIC_F2H_10 128 +#define PLIC_INT_FABRIC_F2H_11 129 +#define PLIC_INT_FABRIC_F2H_12 130 +#define PLIC_INT_FABRIC_F2H_13 131 +#define PLIC_INT_FABRIC_F2H_14 132 +#define PLIC_INT_FABRIC_F2H_15 133 +#define PLIC_INT_FABRIC_F2H_16 134 +#define PLIC_INT_FABRIC_F2H_17 135 +#define PLIC_INT_FABRIC_F2H_18 136 +#define PLIC_INT_FABRIC_F2H_19 137 +#define PLIC_INT_FABRIC_F2H_20 138 +#define PLIC_INT_FABRIC_F2H_21 139 +#define PLIC_INT_FABRIC_F2H_22 140 +#define PLIC_INT_FABRIC_F2H_23 141 +#define PLIC_INT_FABRIC_F2H_24 142 +#define PLIC_INT_FABRIC_F2H_25 143 +#define PLIC_INT_FABRIC_F2H_26 144 +#define PLIC_INT_FABRIC_F2H_27 145 +#define PLIC_INT_FABRIC_F2H_28 146 +#define PLIC_INT_FABRIC_F2H_29 147 +#define PLIC_INT_FABRIC_F2H_30 148 +#define PLIC_INT_FABRIC_F2H_31 149 +#define PLIC_INT_FABRIC_F2H_32 150 +#define PLIC_INT_FABRIC_F2H_33 151 +#define PLIC_INT_FABRIC_F2H_34 152 +#define PLIC_INT_FABRIC_F2H_35 153 +#define PLIC_INT_FABRIC_F2H_36 154 +#define PLIC_INT_FABRIC_F2H_37 155 +#define PLIC_INT_FABRIC_F2H_38 156 +#define PLIC_INT_FABRIC_F2H_39 157 +#define PLIC_INT_FABRIC_F2H_40 158 +#define PLIC_INT_FABRIC_F2H_41 159 +#define PLIC_INT_FABRIC_F2H_42 160 +#define PLIC_INT_FABRIC_F2H_43 161 +#define PLIC_INT_FABRIC_F2H_44 162 +#define PLIC_INT_FABRIC_F2H_45 163 +#define PLIC_INT_FABRIC_F2H_46 164 +#define PLIC_INT_FABRIC_F2H_47 165 +#define PLIC_INT_FABRIC_F2H_48 166 +#define PLIC_INT_FABRIC_F2H_49 167 +#define PLIC_INT_FABRIC_F2H_50 168 +#define PLIC_INT_FABRIC_F2H_51 169 +#define PLIC_INT_FABRIC_F2H_52 170 +#define PLIC_INT_FABRIC_F2H_53 171 +#define PLIC_INT_FABRIC_F2H_54 172 +#define PLIC_INT_FABRIC_F2H_55 173 +#define PLIC_INT_FABRIC_F2H_56 174 +#define PLIC_INT_FABRIC_F2H_57 175 +#define PLIC_INT_FABRIC_F2H_58 176 +#define PLIC_INT_FABRIC_F2H_59 177 +#define PLIC_INT_FABRIC_F2H_60 178 +#define PLIC_INT_FABRIC_F2H_61 179 +#define PLIC_INT_FABRIC_F2H_62 180 +#define PLIC_INT_FABRIC_F2H_63 181 +#define PLIC_INT_BUS_ERROR_UNIT_HART_0 182 +#define PLIC_INT_BUS_ERROR_UNIT_HART_1 183 +#define PLIC_INT_BUS_ERROR_UNIT_HART_2 184 +#define PLIC_INT_BUS_ERROR_UNIT_HART_3 185 +#define PLIC_INT_BUS_ERROR_UNIT_HART_4 186 + +#endif /* _DT_BINDINGS_INTERRUPT_CONTROLLER_MICROCHIP_MPFS_PLIC_H */ diff --git a/include/dt-bindings/interrupt-controller/riscv-hart.h b/include/dt-bindings/interrupt-controller/riscv-hart.h new file mode 100644 index 00000000000..c4331b8521b --- /dev/null +++ b/include/dt-bindings/interrupt-controller/riscv-hart.h @@ -0,0 +1,17 @@ +/* SPDX-License-Identifier: (GPL-2.0+ OR MIT) */ +/* Copyright (c) 2020-2021 Microchip Technology Inc */ + +#ifndef _DT_BINDINGS_INTERRUPT_CONTROLLER_RISCV_HART_H +#define _DT_BINDINGS_INTERRUPT_CONTROLLER_RISCV_HART_H + +#define HART_INT_U_SOFT 0 +#define HART_INT_S_SOFT 1 +#define HART_INT_M_SOFT 3 +#define HART_INT_U_TIMER 4 +#define HART_INT_S_TIMER 5 +#define HART_INT_M_TIMER 7 +#define HART_INT_U_EXT 8 +#define HART_INT_S_EXT 9 +#define HART_INT_M_EXT 11 + +#endif /* _DT_BINDINGS_INTERRUPT_CONTROLLER_RISCV_HART_H */ diff --git a/include/dt-bindings/net/ti-dp83869.h b/include/dt-bindings/net/ti-dp83869.h new file mode 100644 index 00000000000..b3a5ac4a17b --- /dev/null +++ b/include/dt-bindings/net/ti-dp83869.h @@ -0,0 +1,60 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * TI DP83869 PHY drivers + * + */ + +#ifndef _DT_BINDINGS_TI_DP83869_H +#define _DT_BINDINGS_TI_DP83869_H + +/* PHY CTRL bits */ +#define DP83869_PHYCR_FIFO_DEPTH_3_B_NIB 0x00 +#define DP83869_PHYCR_FIFO_DEPTH_4_B_NIB 0x01 +#define DP83869_PHYCR_FIFO_DEPTH_6_B_NIB 0x02 +#define DP83869_PHYCR_FIFO_DEPTH_8_B_NIB 0x03 + +/* RGMIIDCTL internal delay for rx and tx */ +#define DP83869_RGMIIDCTL_250_PS 0x0 +#define DP83869_RGMIIDCTL_500_PS 0x1 +#define DP83869_RGMIIDCTL_750_PS 0x2 +#define DP83869_RGMIIDCTL_1_NS 0x3 +#define DP83869_RGMIIDCTL_1_25_NS 0x4 +#define DP83869_RGMIIDCTL_1_50_NS 0x5 +#define DP83869_RGMIIDCTL_1_75_NS 0x6 +#define DP83869_RGMIIDCTL_2_00_NS 0x7 +#define DP83869_RGMIIDCTL_2_25_NS 0x8 +#define DP83869_RGMIIDCTL_2_50_NS 0x9 +#define DP83869_RGMIIDCTL_2_75_NS 0xa +#define DP83869_RGMIIDCTL_3_00_NS 0xb +#define DP83869_RGMIIDCTL_3_25_NS 0xc +#define DP83869_RGMIIDCTL_3_50_NS 0xd +#define DP83869_RGMIIDCTL_3_75_NS 0xe +#define DP83869_RGMIIDCTL_4_00_NS 0xf + +/* IO_MUX_CFG - Clock output selection */ +#define DP83869_CLK_O_SEL_CHN_A_RCLK 0x0 +#define DP83869_CLK_O_SEL_CHN_B_RCLK 0x1 +#define DP83869_CLK_O_SEL_CHN_C_RCLK 0x2 +#define DP83869_CLK_O_SEL_CHN_D_RCLK 0x3 +#define DP83869_CLK_O_SEL_CHN_A_RCLK_DIV5 0x4 +#define DP83869_CLK_O_SEL_CHN_B_RCLK_DIV5 0x5 +#define DP83869_CLK_O_SEL_CHN_C_RCLK_DIV5 0x6 +#define DP83869_CLK_O_SEL_CHN_D_RCLK_DIV5 0x7 +#define DP83869_CLK_O_SEL_CHN_A_TCLK 0x8 +#define DP83869_CLK_O_SEL_CHN_B_TCLK 0x9 +#define DP83869_CLK_O_SEL_CHN_C_TCLK 0xA +#define DP83869_CLK_O_SEL_CHN_D_TCLK 0xB +#define DP83869_CLK_O_SEL_REF_CLK 0xC +/* Special flag to indicate clock should be off */ +#define DP83869_CLK_O_SEL_OFF 0xFFFFFFFF + +/* OPMODE - Operation mode */ +#define DP83869_RGMII_COPPER_ETHERNET 0x00 +#define DP83869_RGMII_1000_BASE 0x01 +#define DP83869_RGMII_100_BASE 0x02 +#define DP83869_RGMII_SGMII_BRIDGE 0x03 +#define DP83869_1000M_MEDIA_CONVERT 0x04 +#define DP83869_100M_MEDIA_CONVERT 0x05 +#define DP83869_SGMII_COPPER_ETHERNET 0x06 + +#endif diff --git a/include/dt-bindings/power/owl-s700-powergate.h b/include/dt-bindings/power/owl-s700-powergate.h new file mode 100644 index 00000000000..4cf1aefbf09 --- /dev/null +++ b/include/dt-bindings/power/owl-s700-powergate.h @@ -0,0 +1,19 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) +/* + * Actions Semi S700 SPS + * + * Copyright (c) 2017 Andreas Färber + */ +#ifndef DT_BINDINGS_POWER_OWL_S700_POWERGATE_H +#define DT_BINDINGS_POWER_OWL_S700_POWERGATE_H + +#define S700_PD_VDE 0 +#define S700_PD_VCE_SI 1 +#define S700_PD_USB2_1 2 +#define S700_PD_HDE 3 +#define S700_PD_DMA 4 +#define S700_PD_DS 5 +#define S700_PD_USB3 6 +#define S700_PD_USB2_0 7 + +#endif diff --git a/include/efi.h b/include/efi.h index b5835422b95..6159f34ad2b 100644 --- a/include/efi.h +++ b/include/efi.h @@ -321,7 +321,7 @@ struct efi_info_hdr { * struct efi_entry_hdr - Header for a table entry * * @type: enum eft_entry_t - * @size size of entry bytes excluding header and padding + * @size: size of entry bytes excluding header and padding * @addr: address of this entry (0 if it follows the header ) * @link: size of entry including header and padding * @spare1: Spare space for expansion @@ -395,25 +395,72 @@ struct efi_entry_systable { }; static inline struct efi_mem_desc *efi_get_next_mem_desc( - struct efi_entry_memmap *map, struct efi_mem_desc *desc) + struct efi_mem_desc *desc, int desc_size) { - return (struct efi_mem_desc *)((ulong)desc + map->desc_size); + return (struct efi_mem_desc *)((ulong)desc + desc_size); } +/** + * struct efi_priv - Information about the environment provided by EFI + * + * @parent_image: image passed into the EFI app or stub + * @sys_table: Pointer to system table + * @boot: Pointer to boot-services table + * @run: Pointer to runtime-services table + * @memmap_key: Key returned from get_memory_map() + * @memmap_desc: List of memory-map records + * @memmap_alloc: Amount of memory allocated for memory map list + * @memmap_size Size of memory-map list in bytes + * @memmap_desc_size: Size of an individual memory-map record, in bytes + * @memmap_version: Memory-map version + * + * @use_pool_for_malloc: true if all allocation should go through the EFI 'pool' + * methods allocate_pool() and free_pool(); false to use 'pages' methods + * allocate_pages() and free_pages() + * @ram_base: Base address of RAM (size CONFIG_EFI_RAM_SIZE) + * @image_data_type: Type of the loaded image (e.g. EFI_LOADER_CODE) + * + * @info: Header of the info list, holding info collected by the stub and passed + * to U-Boot + * @info_size: Size of the info list @info in bytes + * @next_hdr: Pointer to where to put the next header when adding to the list + */ struct efi_priv { efi_handle_t parent_image; - struct efi_device_path *device_path; struct efi_system_table *sys_table; struct efi_boot_services *boot; struct efi_runtime_services *run; + efi_uintn_t memmap_key; + struct efi_mem_desc *memmap_desc; + efi_uintn_t memmap_alloc; + efi_uintn_t memmap_size; + efi_uintn_t memmap_desc_size; + u32 memmap_version; + + /* app: */ bool use_pool_for_malloc; unsigned long ram_base; unsigned int image_data_type; + + /* stub: */ struct efi_info_hdr *info; unsigned int info_size; void *next_hdr; }; +/* + * EFI attributes of the udevice handled by efi_media driver + * + * @handle: handle of the controller on which this driver is installed + * @blkio: block io protocol proxied by this driver + * @device_path: EFI path to the device + */ +struct efi_media_plat { + efi_handle_t handle; + struct efi_block_io *blkio; + struct efi_device_path *device_path; +}; + /* Base address of the EFI image */ extern char image_base[]; @@ -440,16 +487,37 @@ extern char _binary_u_boot_bin_start[], _binary_u_boot_bin_end[]; EFI_VARIABLE_APPEND_WRITE) /** + * efi_get_priv() - Get access to the EFI-private information + * + * This struct it used by both the stub and the app to record things about the + * EFI environment. It is not available in U-Boot proper after the stub has + * jumped there. Use efi_info_get() to obtain info in that case. + * + * Return: pointer to private info + */ +struct efi_priv *efi_get_priv(void); + +/** + * efi_set_priv() - Set up a pointer to the EFI-private information + * + * This is called in the stub and app to record the location of this + * information. + * + * @priv: New location of private data + */ +void efi_set_priv(struct efi_priv *priv); + +/** * efi_get_sys_table() - Get access to the main EFI system table * - * @return pointer to EFI system table + * Returns: pointer to EFI system table */ struct efi_system_table *efi_get_sys_table(void); /** * efi_get_boot() - Get access to the EFI boot services table * - * @return pointer to EFI boot services table + * Returns: pointer to EFI boot services table */ struct efi_boot_services *efi_get_boot(void); @@ -458,7 +526,7 @@ struct efi_boot_services *efi_get_boot(void); * * This is used when U-Boot is built as an EFI application. * - * @return the base of RAM as known to U-Boot + * Returns: the base of RAM as known to U-Boot */ unsigned long efi_get_ram_base(void); @@ -469,6 +537,7 @@ unsigned long efi_get_ram_base(void); * @banner: Banner to display when starting * @image: The image handle passed to efi_main() * @sys_table: The EFI system table pointer passed to efi_main() + * Return: 0 on succcess, EFI error code on failure */ int efi_init(struct efi_priv *priv, const char *banner, efi_handle_t image, struct efi_system_table *sys_table); @@ -479,7 +548,7 @@ int efi_init(struct efi_priv *priv, const char *banner, efi_handle_t image, * @priv: Pointer to private EFI structure * @size: Number of bytes to allocate * @retp: Return EFI status result - * @return pointer to memory allocated, or NULL on error + * Returns: pointer to memory allocated, or NULL on error */ void *efi_malloc(struct efi_priv *priv, int size, efi_status_t *retp); @@ -510,12 +579,51 @@ void efi_putc(struct efi_priv *priv, const char ch); /** * efi_info_get() - get an entry from an EFI table * + * This function is called from U-Boot proper to read information set up by the + * EFI stub. It can only be used when running from the EFI stub, not when U-Boot + * is running as an app. + * * @type: Entry type to search for * @datap: Returns pointer to entry data - * @sizep: Returns pointer to entry size - * @return 0 if OK, -ENODATA if there is no table, -ENOENT if there is no entry + * @sizep: Returns entry size + * Return: 0 if OK, -ENODATA if there is no table, -ENOENT if there is no entry * of the requested type, -EPROTONOSUPPORT if the table has the wrong version */ int efi_info_get(enum efi_entry_t type, void **datap, int *sizep); +/** + * efi_store_memory_map() - Collect the memory-map info from EFI + * + * Collect the memory info and store it for later use, e.g. in calling + * exit_boot_services() + * + * @priv: Pointer to private EFI structure + * Returns: 0 if OK, non-zero on error + */ +int efi_store_memory_map(struct efi_priv *priv); + +/** + * efi_call_exit_boot_services() - Handle the exit-boot-service procedure + * + * Tell EFI we don't want their boot services anymore + * + * Return: 0 if OK, non-zero on error + */ +int efi_call_exit_boot_services(void); + +/** + * efi_get_mmap() - Get the memory map from EFI + * + * This is used in the app. The caller must free *@descp when done + * + * @descp: Returns allocated pointer to EFI memory map table + * @sizep: Returns size of table in bytes + * @keyp: Returns memory-map key + * @desc_sizep: Returns size of each @desc_base record + * @versionp: Returns version number of memory map + * Returns: 0 on success, -ve on error + */ +int efi_get_mmap(struct efi_mem_desc **descp, int *sizep, uint *keyp, + int *desc_sizep, uint *versionp); + #endif /* _LINUX_EFI_H */ diff --git a/include/efi_api.h b/include/efi_api.h index 80109f012bc..ec9fa89a935 100644 --- a/include/efi_api.h +++ b/include/efi_api.h @@ -2035,4 +2035,19 @@ struct efi_firmware_management_protocol { const u16 *package_version_name); }; +#define EFI_DISK_IO_PROTOCOL_GUID \ + EFI_GUID(0xce345171, 0xba0b, 0x11d2, 0x8e, 0x4f, \ + 0x00, 0xa0, 0xc9, 0x69, 0x72, 0x3b) + +struct efi_disk { + u64 revision; + efi_status_t (EFIAPI *read_disk)(struct efi_disk *this, u32 media_id, + u64 offset, efi_uintn_t buffer_size, + void *buffer); + + efi_status_t (EFIAPI *write_disk)(struct efi_disk *this, u32 media_id, + u64 offset, efi_uintn_t buffer_size, + void *buffer); +}; + #endif diff --git a/include/efi_loader.h b/include/efi_loader.h index d52e399841b..f20d3618765 100644 --- a/include/efi_loader.h +++ b/include/efi_loader.h @@ -517,6 +517,8 @@ efi_status_t EFIAPI efi_convert_pointer(efi_uintn_t debug_disposition, void **address); /* Carve out DT reserved memory ranges */ void efi_carve_out_dt_rsv(void *fdt); +/* Purge unused kaslr-seed */ +void efi_try_purge_kaslr_seed(void *fdt); /* Called by bootefi to make console interface available */ efi_status_t efi_console_register(void); /* Called by bootefi to make all disk storage accessible as EFI objects */ @@ -525,6 +527,8 @@ efi_status_t efi_disk_register(void); efi_status_t efi_rng_register(void); /* Called by efi_init_obj_list() to install EFI_TCG2_PROTOCOL */ efi_status_t efi_tcg2_register(void); +/* Called by efi_init_obj_list() to do initial measurement */ +efi_status_t efi_tcg2_do_initial_measurement(void); /* measure the pe-coff image, extend PCR and add Event Log */ efi_status_t tcg2_measure_pe_image(void *efi, u64 efi_size, struct efi_loaded_image_obj *handle, @@ -988,4 +992,6 @@ efi_status_t efi_esrt_register(void); */ efi_status_t efi_esrt_populate(void); efi_status_t efi_load_capsule_drivers(void); + +efi_status_t platform_get_eventlog(struct udevice *dev, u64 *addr, u32 *sz); #endif /* _EFI_LOADER_H */ diff --git a/include/env.h b/include/env.h index ee5e30d036d..ff8943ed96c 100644 --- a/include/env.h +++ b/include/env.h @@ -134,6 +134,13 @@ int env_get_f(const char *name, char *buf, unsigned int len); int env_get_yesno(const char *var); /** + * env_get_autostart() - Check if autostart is enabled + * + * @return true if the "autostart" env var exists and is set to "yes" + */ +bool env_get_autostart(void); + +/** * env_set() - set an environment variable * * This sets or deletes the value of an environment variable. For setting the diff --git a/include/env_default.h b/include/env_default.h index 23430dc70d7..21afd7f7dcf 100644 --- a/include/env_default.h +++ b/include/env_default.h @@ -10,6 +10,10 @@ #include <env_callback.h> #include <linux/stringify.h> +#ifndef USE_HOSTCC +#include <generated/environment.h> +#endif + #ifdef DEFAULT_ENV_INSTANCE_EMBEDDED env_t embedded_environment __UBOOT_ENV_SECTION__(environment) = { ENV_CRC, /* CRC Sum */ @@ -37,12 +41,6 @@ const char default_environment[] = { #ifdef CONFIG_BOOTCOMMAND "bootcmd=" CONFIG_BOOTCOMMAND "\0" #endif -#ifdef CONFIG_RAMBOOTCOMMAND - "ramboot=" CONFIG_RAMBOOTCOMMAND "\0" -#endif -#ifdef CONFIG_NFSBOOTCOMMAND - "nfsboot=" CONFIG_NFSBOOTCOMMAND "\0" -#endif #if defined(CONFIG_BOOTDELAY) "bootdelay=" __stringify(CONFIG_BOOTDELAY) "\0" #endif @@ -110,6 +108,13 @@ const char default_environment[] = { #if defined(CONFIG_BOOTCOUNT_BOOTLIMIT) && (CONFIG_BOOTCOUNT_BOOTLIMIT > 0) "bootlimit=" __stringify(CONFIG_BOOTCOUNT_BOOTLIMIT)"\0" #endif +#ifdef CONFIG_EXTRA_ENV_TEXT +# ifdef CONFIG_EXTRA_ENV_SETTINGS +# error "Your board uses a text-file environment, so must not define CONFIG_EXTRA_ENV_SETTINGS" +# endif + /* This is created in the Makefile */ + CONFIG_EXTRA_ENV_TEXT +#endif #ifdef CONFIG_EXTRA_ENV_SETTINGS CONFIG_EXTRA_ENV_SETTINGS #endif diff --git a/include/faraday/ftwdt010_wdt.h b/include/faraday/ftwdt010_wdt.h index 20bf6d31252..804907d6455 100644 --- a/include/faraday/ftwdt010_wdt.h +++ b/include/faraday/ftwdt010_wdt.h @@ -16,6 +16,8 @@ #ifndef __FTWDT010_H #define __FTWDT010_H +#include <clock_legacy.h> + struct ftwdt010_wdt { unsigned int wdcounter; /* Counter Reg - 0x00 */ unsigned int wdload; /* Counter Auto Reload Reg - 0x04 */ @@ -82,10 +84,10 @@ struct ftwdt010_wdt { /* * Variable timeout should be set in ms. - * (CONFIG_SYS_CLK_FREQ/1000) equals 1 ms. + * (get_board_sys_clk()/1000) equals 1 ms. * WDLOAD = timeout * TIMEOUT_FACTOR. */ -#define FTWDT010_TIMEOUT_FACTOR (CONFIG_SYS_CLK_FREQ / 1000) /* 1 ms */ +#define FTWDT010_TIMEOUT_FACTOR (get_board_sys_clk() / 1000) /* 1 ms */ void ftwdt010_wdt_reset(void); void ftwdt010_wdt_disable(void); diff --git a/include/fdt_region.h b/include/fdt_region.h index ff7a1ccb9af..d0c68760f78 100644 --- a/include/fdt_region.h +++ b/include/fdt_region.h @@ -77,6 +77,7 @@ struct fdt_region_state { int max_regions; /* Maximum regions to find */ int can_merge; /* 1 if we can merge with previous region */ int start; /* Start position of current region */ + bool have_node; /* True if any node is included */ struct fdt_region_ptrs ptrs; /* Pointers for what we are up to */ }; diff --git a/include/fdt_simplefb.h b/include/fdt_simplefb.h index 7cc305e1fd5..41cd740ac05 100644 --- a/include/fdt_simplefb.h +++ b/include/fdt_simplefb.h @@ -8,6 +8,7 @@ #ifndef _FDT_SIMPLEFB_H_ #define _FDT_SIMPLEFB_H_ -int lcd_dt_simplefb_add_node(void *blob); -int lcd_dt_simplefb_enable_existing_node(void *blob); +int fdt_simplefb_add_node(void *blob); +int fdt_simplefb_enable_existing_node(void *blob); +int fdt_simplefb_enable_and_mem_rsv(void *blob); #endif diff --git a/include/fdt_support.h b/include/fdt_support.h index 88d129c8038..8ec461af6c3 100644 --- a/include/fdt_support.h +++ b/include/fdt_support.h @@ -228,6 +228,8 @@ void set_working_fdt_addr(ulong addr); int fdt_shrink_to_minimum(void *blob, uint extrasize); int fdt_increase_size(void *fdt, int add_len); +int fdt_delete_disabled_nodes(void *blob); + int fdt_fixup_nor_flash_size(void *blob); struct node_info; @@ -285,9 +287,13 @@ int fdt_get_dma_range(const void *blob, int node_offset, phys_addr_t *cpu, int fdt_node_offset_by_compat_reg(void *blob, const char *compat, phys_addr_t compat_off); -int fdt_alloc_phandle(void *blob); +int fdt_node_offset_by_pathf(void *blob, const char *fmt, ...) + __attribute__ ((format (printf, 2, 3))); int fdt_set_phandle(void *fdt, int nodeoffset, uint32_t phandle); unsigned int fdt_create_phandle(void *fdt, int nodeoffset); +unsigned int fdt_create_phandle_by_compatible(void *fdt, const char *compat); +unsigned int fdt_create_phandle_by_pathf(void *fdt, const char *fmt, ...) + __attribute__ ((format (printf, 2, 3))); int fdt_add_edid(void *blob, const char *compat, unsigned char *buf); int fdt_verify_alias_address(void *fdt, int anode, const char *alias, @@ -300,38 +306,61 @@ enum fdt_status { FDT_STATUS_OKAY, FDT_STATUS_DISABLED, FDT_STATUS_FAIL, - FDT_STATUS_FAIL_ERROR_CODE, }; -int fdt_set_node_status(void *fdt, int nodeoffset, - enum fdt_status status, unsigned int error_code); +int fdt_set_node_status(void *fdt, int nodeoffset, enum fdt_status status); static inline int fdt_status_okay(void *fdt, int nodeoffset) { - return fdt_set_node_status(fdt, nodeoffset, FDT_STATUS_OKAY, 0); + return fdt_set_node_status(fdt, nodeoffset, FDT_STATUS_OKAY); } static inline int fdt_status_disabled(void *fdt, int nodeoffset) { - return fdt_set_node_status(fdt, nodeoffset, FDT_STATUS_DISABLED, 0); + return fdt_set_node_status(fdt, nodeoffset, FDT_STATUS_DISABLED); } static inline int fdt_status_fail(void *fdt, int nodeoffset) { - return fdt_set_node_status(fdt, nodeoffset, FDT_STATUS_FAIL, 0); + return fdt_set_node_status(fdt, nodeoffset, FDT_STATUS_FAIL); } int fdt_set_status_by_alias(void *fdt, const char *alias, - enum fdt_status status, unsigned int error_code); + enum fdt_status status); static inline int fdt_status_okay_by_alias(void *fdt, const char *alias) { - return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_OKAY, 0); + return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_OKAY); } static inline int fdt_status_disabled_by_alias(void *fdt, const char *alias) { - return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_DISABLED, 0); + return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_DISABLED); } static inline int fdt_status_fail_by_alias(void *fdt, const char *alias) { - return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_FAIL, 0); + return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_FAIL); } +int fdt_set_status_by_compatible(void *fdt, const char *compat, + enum fdt_status status); +static inline int fdt_status_okay_by_compatible(void *fdt, const char *compat) +{ + return fdt_set_status_by_compatible(fdt, compat, FDT_STATUS_OKAY); +} +static inline int fdt_status_disabled_by_compatible(void *fdt, + const char *compat) +{ + return fdt_set_status_by_compatible(fdt, compat, FDT_STATUS_DISABLED); +} +static inline int fdt_status_fail_by_compatible(void *fdt, const char *compat) +{ + return fdt_set_status_by_compatible(fdt, compat, FDT_STATUS_FAIL); +} + +int fdt_set_status_by_pathf(void *fdt, enum fdt_status status, const char *fmt, + ...) __attribute__ ((format (printf, 3, 4))); +#define fdt_status_okay_by_pathf(fdt, fmt, ...) \ + fdt_set_status_by_pathf((fdt), FDT_STATUS_OKAY, (fmt), ##__VA_ARGS__) +#define fdt_status_disabled_by_pathf(fdt, fmt, ...) \ + fdt_set_status_by_pathf((fdt), FDT_STATUS_DISABLED, (fmt), ##__VA_ARGS__) +#define fdt_status_fail_by_pathf(fdt, fmt, ...) \ + fdt_set_status_by_pathf((fdt), FDT_STATUS_FAIL, (fmt), ##__VA_ARGS__) + /* Helper to read a big number; size is in cells (not bytes) */ static inline u64 fdt_read_number(const fdt32_t *cell, int size) { diff --git a/include/fdtdec.h b/include/fdtdec.h index 6c7ab887b20..15f2d2bbbaa 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -49,11 +49,30 @@ struct fdt_memory { struct bd_info; -#ifdef CONFIG_SPL_BUILD -#define SPL_BUILD 1 -#else -#define SPL_BUILD 0 -#endif +/** + * enum fdt_source_t - indicates where the devicetree came from + * + * These are listed in approximate order of desirability after FDTSRC_NONE + * + * @FDTSRC_SEPARATE: Appended to U-Boot. This is the normal approach if U-Boot + * is the only firmware being booted + * @FDTSRC_FIT: Found in a multi-dtb FIT. This should be used when U-Boot must + * select a devicetree from many options + * @FDTSRC_BOARD: Located by custom board code. This should only be used when + * the prior stage does not support FDTSRC_PASSAGE + * @FDTSRC_EMBED: Embedded into U-Boot executable. This should onyl be used when + * U-Boot is packaged as an ELF file, e.g. for debugging purposes + * @FDTSRC_ENV: Provided by the fdtcontroladdr environment variable. This should + * be used for debugging/development only + * @FDTSRC_NONE: No devicetree at all + */ +enum fdt_source_t { + FDTSRC_SEPARATE, + FDTSRC_FIT, + FDTSRC_BOARD, + FDTSRC_EMBED, + FDTSRC_ENV, +}; /* * Information about a resource. start is the first address of the resource @@ -111,6 +130,20 @@ struct fdt_pci_addr { extern u8 __dtb_dt_begin[]; /* embedded device tree blob */ extern u8 __dtb_dt_spl_begin[]; /* embedded device tree blob for SPL/TPL */ +/* Get a pointer to the embedded devicetree, if there is one, else NULL */ +static inline u8 *dtb_dt_embedded(void) +{ +#ifdef CONFIG_OF_EMBED +# ifdef CONFIG_SPL_BUILD + return __dtb_dt_spl_begin; +# else + return __dtb_dt_begin; +# endif +#else + return NULL; +#endif +} + /** * Compute the size of a resource. * @@ -1156,10 +1189,13 @@ int fdtdec_resetup(int *rescan); /** * Board-specific FDT initialization. Returns the address to a device tree blob. - * Called when CONFIG_OF_BOARD is defined, or if CONFIG_OF_SEPARATE is defined - * and the board implements it. + * + * Called when CONFIG_OF_BOARD is defined. + * + * The existing devicetree is available at gd->fdt_blob * * @err internal error code if we fail to setup a DTB + * @returns new devicetree blob pointer */ void *board_fdt_blob_setup(int *err); @@ -1198,4 +1234,11 @@ int fdtdec_decode_ram_size(const void *blob, const char *area, int board_id, phys_addr_t *basep, phys_size_t *sizep, struct bd_info *bd); +/** + * fdtdec_get_srcname() - Get the name of where the devicetree comes from + * + * @return source name + */ +const char *fdtdec_get_srcname(void); + #endif diff --git a/include/fsl_esdhc_imx.h b/include/fsl_esdhc_imx.h index 12e91633826..2153f29bef2 100644 --- a/include/fsl_esdhc_imx.h +++ b/include/fsl_esdhc_imx.h @@ -24,12 +24,10 @@ #define SYSCTL_INITA 0x08000000 #define SYSCTL_TIMEOUT_MASK 0x000f0000 #define SYSCTL_CLOCK_MASK 0x0000fff0 -#if !defined(CONFIG_FSL_USDHC) #define SYSCTL_CKEN 0x00000008 #define SYSCTL_PEREN 0x00000004 #define SYSCTL_HCKEN 0x00000002 #define SYSCTL_IPGEN 0x00000001 -#endif #define SYSCTL_RSTA 0x01000000 #define SYSCTL_RSTC 0x02000000 #define SYSCTL_RSTD 0x04000000 @@ -164,12 +162,12 @@ #define BLKATTR_SIZE(x) (x & 0x1fff) #define MAX_BLK_CNT 0x7fff /* so malloc will have enough room with 32M */ -#define ESDHC_HOSTCAPBLT_VS18 0x04000000 -#define ESDHC_HOSTCAPBLT_VS30 0x02000000 -#define ESDHC_HOSTCAPBLT_VS33 0x01000000 -#define ESDHC_HOSTCAPBLT_SRS 0x00800000 -#define ESDHC_HOSTCAPBLT_DMAS 0x00400000 -#define ESDHC_HOSTCAPBLT_HSS 0x00200000 +#define HOSTCAPBLT_VS18 0x04000000 +#define HOSTCAPBLT_VS30 0x02000000 +#define HOSTCAPBLT_VS33 0x01000000 +#define HOSTCAPBLT_SRS 0x00800000 +#define HOSTCAPBLT_DMAS 0x00400000 +#define HOSTCAPBLT_HSS 0x00200000 #define ESDHC_VENDORSPEC_VSELECT 0x00000002 /* Use 1.8V */ diff --git a/include/fsl_memac.h b/include/fsl_memac.h index d067f1511c6..6ac1e558b97 100644 --- a/include/fsl_memac.h +++ b/include/fsl_memac.h @@ -254,7 +254,6 @@ struct memac_mdio_controller { #define MDIO_CTL_READ (1 << 15) #define MDIO_DATA(x) (x & 0xffff) -#define MDIO_DATA_BSY (1 << 31) struct fsl_enet_mac; diff --git a/include/gt64120.h b/include/gt64120.h index 0b577f3f44b..b58afe3c4af 100644 --- a/include/gt64120.h +++ b/include/gt64120.h @@ -491,18 +491,6 @@ #define GT_INTRCAUSE_TARABORT0_BIT GT_INTRCAUSE_TARABORT0_MSK -#define GT_PCI0_CFGADDR_REGNUM_SHF 2 -#define GT_PCI0_CFGADDR_REGNUM_MSK (MSK(6) << GT_PCI0_CFGADDR_REGNUM_SHF) -#define GT_PCI0_CFGADDR_FUNCTNUM_SHF 8 -#define GT_PCI0_CFGADDR_FUNCTNUM_MSK (MSK(3) << GT_PCI0_CFGADDR_FUNCTNUM_SHF) -#define GT_PCI0_CFGADDR_DEVNUM_SHF 11 -#define GT_PCI0_CFGADDR_DEVNUM_MSK (MSK(5) << GT_PCI0_CFGADDR_DEVNUM_SHF) -#define GT_PCI0_CFGADDR_BUSNUM_SHF 16 -#define GT_PCI0_CFGADDR_BUSNUM_MSK (MSK(8) << GT_PCI0_CFGADDR_BUSNUM_SHF) -#define GT_PCI0_CFGADDR_CONFIGEN_SHF 31 -#define GT_PCI0_CFGADDR_CONFIGEN_MSK (MSK(1) << GT_PCI0_CFGADDR_CONFIGEN_SHF) -#define GT_PCI0_CFGADDR_CONFIGEN_BIT GT_PCI0_CFGADDR_CONFIGEN_MSK - #define GT_PCI0_CMD_MBYTESWAP_SHF 0 #define GT_PCI0_CMD_MBYTESWAP_MSK (MSK(1) << GT_PCI0_CMD_MBYTESWAP_SHF) #define GT_PCI0_CMD_MBYTESWAP_BIT GT_PCI0_CMD_MBYTESWAP_MSK diff --git a/include/init.h b/include/init.h index f2cd46dead0..20c3976af09 100644 --- a/include/init.h +++ b/include/init.h @@ -14,8 +14,11 @@ #include <linux/types.h> -/* Avoid using CONFIG_EFI_STUB directly as we may boot from other loaders */ -#ifdef CONFIG_EFI_STUB +/* + * In case of the EFI app the UEFI firmware provides the low-level + * initialisation. + */ +#ifdef CONFIG_EFI #define ll_boot_init() false #else #include <asm/global_data.h> @@ -308,6 +311,16 @@ int board_early_init_r(void); int arch_initr_trap(void); /** + * init_addr_map() + * + * Initialize non-identity virtual-physical memory mappings for 32bit CPUs. + * It is called during the generic board init sequence, after relocation. + * + * Return: 0 if OK + */ +int init_addr_map(void); + +/** * main_loop() - Enter the main loop of U-Boot * * This normally runs the command line. diff --git a/include/kgdb.h b/include/kgdb.h index 616ce4451f1..bdba347a7f3 100644 --- a/include/kgdb.h +++ b/include/kgdb.h @@ -39,7 +39,16 @@ typedef kgdb_data; /* these functions are provided by the generic kgdb support */ -extern void kgdb_init(void); +/** + * kgdb_init() + * + * Perform initializations to allow debugging U-Boot with gdb over a serial + * link. It is called during the generic board init sequence. + * + * Return: 0 if OK + */ +int kgdb_init(void); + extern void kgdb_error(int); extern int kgdb_output_string(const char *, unsigned int); extern void breakpoint(void); diff --git a/include/linux/byteorder/swab.h b/include/linux/byteorder/swab.h index 4334fa77e3f..5efc252acfc 100644 --- a/include/linux/byteorder/swab.h +++ b/include/linux/byteorder/swab.h @@ -39,6 +39,10 @@ (__u64)(((__u64)(x) & (__u64)0x00ff000000000000ULL) >> 40) | \ (__u64)(((__u64)(x) & (__u64)0xff00000000000000ULL) >> 56) )) +#define ___constant_swab16(x) ___swab16(x) +#define ___constant_swab32(x) ___swab32(x) +#define ___constant_swab64(x) ___swab64(x) + /* * provide defaults when no architecture-specific optimization is detected */ diff --git a/include/linux/if_vlan.h b/include/linux/if_vlan.h new file mode 100644 index 00000000000..cbc82f4cc21 --- /dev/null +++ b/include/linux/if_vlan.h @@ -0,0 +1,26 @@ +/* SPDX-License-Identifier: GPL-2.0-or-later */ +/* + * VLAN An implementation of 802.1Q VLAN tagging. + * + * Authors: Ben Greear <greearb@candelatech.com> + */ +#ifndef _LINUX_IF_VLAN_H_ +#define _LINUX_IF_VLAN_H_ + +/** + * struct vlan_ethhdr - vlan ethernet header (ethhdr + vlan_hdr) + * @h_dest: destination ethernet address + * @h_source: source ethernet address + * @h_vlan_proto: ethernet protocol + * @h_vlan_TCI: priority and VLAN ID + * @h_vlan_encapsulated_proto: packet type ID or len + */ +struct vlan_ethhdr { + unsigned char h_dest[ETH_ALEN]; + unsigned char h_source[ETH_ALEN]; + __be16 h_vlan_proto; + __be16 h_vlan_TCI; + __be16 h_vlan_encapsulated_proto; +}; + +#endif /* !(_LINUX_IF_VLAN_H_) */ diff --git a/include/linux/stddef.h b/include/linux/stddef.h index c540f6100d4..a7f546fdfe5 100644 --- a/include/linux/stddef.h +++ b/include/linux/stddef.h @@ -1,6 +1,8 @@ #ifndef _LINUX_STDDEF_H #define _LINUX_STDDEF_H +#include <linux/compiler_types.h> + #undef NULL #if defined(__cplusplus) #define NULL 0 @@ -14,7 +16,11 @@ #ifndef __CHECKER__ #undef offsetof -#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER) +#ifdef __compiler_offsetof +#define offsetof(TYPE, MEMBER) __compiler_offsetof(TYPE, MEMBER) +#else +#define offsetof(TYPE, MEMBER) ((size_t)&((TYPE *)0)->MEMBER) +#endif #endif #endif diff --git a/include/miiphy.h b/include/miiphy.h index 8b77bac01e6..77a00359587 100644 --- a/include/miiphy.h +++ b/include/miiphy.h @@ -126,8 +126,6 @@ int bb_miiphy_write(struct mii_dev *miidev, int addr, int devad, int reg, #define ESTATUS_1000XF 0x8000 #define ESTATUS_1000XH 0x4000 -#ifdef CONFIG_DM_MDIO - /** * struct mdio_perdev_priv - Per-device class data for MDIO DM * @@ -185,10 +183,6 @@ struct phy_device *dm_mdio_phy_connect(struct udevice *mdiodev, int phyaddr, */ struct phy_device *dm_eth_phy_connect(struct udevice *ethdev); -#endif - -#ifdef CONFIG_DM_MDIO_MUX - /* indicates none of the child buses is selected */ #define MDIO_MUX_SELECT_NONE -1 @@ -206,5 +200,3 @@ struct mdio_mux_ops { #define mdio_mux_get_ops(dev) ((struct mdio_mux_ops *)(dev)->driver->ops) #endif - -#endif diff --git a/include/mmc.h b/include/mmc.h index b92e2553402..244d2dc5921 100644 --- a/include/mmc.h +++ b/include/mmc.h @@ -786,12 +786,7 @@ int mmc_init_device(int num); int mmc_init(struct mmc *mmc); int mmc_send_tuning(struct mmc *mmc, u32 opcode, int *cmd_error); int mmc_send_cmd(struct mmc *mmc, struct mmc_cmd *cmd, struct mmc_data *data); - -#if CONFIG_IS_ENABLED(MMC_UHS_SUPPORT) || \ - CONFIG_IS_ENABLED(MMC_HS200_SUPPORT) || \ - CONFIG_IS_ENABLED(MMC_HS400_SUPPORT) int mmc_deinit(struct mmc *mmc); -#endif /** * mmc_of_parse() - Parse the device tree to get the capabilities of the host diff --git a/include/mpc85xx.h b/include/mpc85xx.h index ce6d083effa..2c69a60de63 100644 --- a/include/mpc85xx.h +++ b/include/mpc85xx.h @@ -60,8 +60,4 @@ CONFIG_SYS_CCSRBAR_PHYS_LOW and/or CONFIG_SYS_CCSRBAR_PHYS_HIGH instead." #define CONFIG_SYS_CCSRBAR_PHYS ((CONFIG_SYS_CCSRBAR_PHYS_HIGH * 1ull) << 32 | \ CONFIG_SYS_CCSRBAR_PHYS_LOW) -#ifndef CONFIG_SYS_IMMR -#define CONFIG_SYS_IMMR CONFIG_SYS_CCSRBAR -#endif - #endif /* __MPC85xx_H__ */ diff --git a/include/msc01.h b/include/msc01.h index ec18a724eb9..20158123494 100644 --- a/include/msc01.h +++ b/include/msc01.h @@ -71,15 +71,6 @@ #define MSC01_PCI_INTSTAT_MA_SHF 7 #define MSC01_PCI_INTSTAT_MA_MSK (0x1 << MSC01_PCI_INTSTAT_MA_SHF) -#define MSC01_PCI_CFGADDR_BNUM_SHF 16 -#define MSC01_PCI_CFGADDR_BNUM_MSK (0xff << MSC01_PCI_CFGADDR_BNUM_SHF) -#define MSC01_PCI_CFGADDR_DNUM_SHF 11 -#define MSC01_PCI_CFGADDR_DNUM_MSK (0x1f << MSC01_PCI_CFGADDR_DNUM_SHF) -#define MSC01_PCI_CFGADDR_FNUM_SHF 8 -#define MSC01_PCI_CFGADDR_FNUM_MSK (0x3 << MSC01_PCI_CFGADDR_FNUM_SHF) -#define MSC01_PCI_CFGADDR_RNUM_SHF 2 -#define MSC01_PCI_CFGADDR_RNUM_MSK (0x3f << MSC01_PCI_CFGADDR_RNUM_SHF) - #define MSC01_PCI_HEAD0_VENDORID_SHF 0 #define MSC01_PCI_HEAD0_DEVICEID_SHF 16 diff --git a/include/nand.h b/include/nand.h index 09dbda4e81b..70c1286ccb4 100644 --- a/include/nand.h +++ b/include/nand.h @@ -10,22 +10,6 @@ #include <config.h> -/* - * All boards using a given driver must convert to self-init - * at the same time, so do it here. When all drivers are - * converted, this will go away. - */ -#ifdef CONFIG_SPL_BUILD -#if defined(CONFIG_NAND_FSL_ELBC) || defined(CONFIG_NAND_FSL_IFC) -#define CONFIG_SYS_NAND_SELF_INIT -#endif -#else -#if defined(CONFIG_NAND_FSL_ELBC) || defined(CONFIG_NAND_ATMEL)\ - || defined(CONFIG_NAND_FSL_IFC) -#define CONFIG_SYS_NAND_SELF_INIT -#endif -#endif - extern void nand_init(void); unsigned long nand_size(void); @@ -34,7 +18,7 @@ unsigned long nand_size(void); int nand_mtd_to_devnum(struct mtd_info *mtd); -#ifdef CONFIG_SYS_NAND_SELF_INIT +#if CONFIG_IS_ENABLED(SYS_NAND_SELF_INIT) void board_nand_init(void); int nand_register(int devnum, struct mtd_info *mtd); #else diff --git a/include/net/dsa.h b/include/net/dsa.h index a339a497303..1b1068cd88c 100644 --- a/include/net/dsa.h +++ b/include/net/dsa.h @@ -6,6 +6,7 @@ #ifndef __DSA_H__ #define __DSA_H__ +#include <dm/ofnode.h> #include <phy.h> #include <net.h> @@ -146,6 +147,17 @@ int dsa_set_tagging(struct udevice *dev, ushort headroom, ushort tailroom); struct udevice *dsa_get_master(struct udevice *dev); /** + * dsa_port_get_ofnode() - Return a reference to the given port's OF node + * + * Can be called at driver probe time or later. + * + * @dev: DSA switch udevice pointer + * @port: Port index + * @return OF node reference if OK, NULL on error + */ +ofnode dsa_port_get_ofnode(struct udevice *dev, int port); + +/** * dsa_port_get_pdata() - Helper that returns the platdata of an active * (non-CPU) DSA port device. * diff --git a/include/os.h b/include/os.h index 770d76e02f7..10e198cf503 100644 --- a/include/os.h +++ b/include/os.h @@ -266,7 +266,7 @@ const char *os_dirent_get_typename(enum os_dirent_t type); * @size: size of file is returned if no error * Return: 0 on success or -1 if an error ocurred */ -int os_get_filesize(const char *fname, loff_t *size); +int os_get_filesize(const char *fname, long long *size); /** * os_putc() - write a character to the controlling OS terminal @@ -419,6 +419,15 @@ int os_read_file(const char *name, void **bufp, int *sizep); */ int os_map_file(const char *pathname, int os_flags, void **bufp, int *sizep); +/** + * os_unmap() - Unmap a file previously mapped + * + * @buf: Mapped address + * @size: Size in bytes + * Return: 0 if OK, -ve on error + */ +int os_unmap(void *buf, int size); + /* * os_find_text_base() - Find the text section in this running process * diff --git a/include/part.h b/include/part.h index b66b07a1f04..b8d8e1ff0de 100644 --- a/include/part.h +++ b/include/part.h @@ -50,7 +50,7 @@ struct block_drvr { #define PART_NAME_LEN 32 #define PART_TYPE_LEN 32 -#define MAX_SEARCH_PARTITIONS 64 +#define MAX_SEARCH_PARTITIONS 128 #define PART_BOOTABLE ((int)BIT(0)) #define PART_EFI_SYSTEM_PARTITION ((int)BIT(1)) diff --git a/include/pci.h b/include/pci.h index 797f224e2fc..ad1171b0a2a 100644 --- a/include/pci.h +++ b/include/pci.h @@ -5,6 +5,7 @@ * * (C) Copyright 2002 * Wolfgang Denk, DENX Software Engineering, wd@denx.de. + * Copyright (c) 2021 Maciej W. Rozycki <macro@orcam.me.uk> */ #ifndef _PCI_H @@ -475,16 +476,24 @@ /* PCI Express capabilities */ #define PCI_EXP_FLAGS 2 /* Capabilities register */ +#define PCI_EXP_FLAGS_VERS 0x000f /* Capability Version */ #define PCI_EXP_FLAGS_TYPE 0x00f0 /* Device/Port type */ -#define PCI_EXP_TYPE_ROOT_PORT 0x4 /* Root Port */ +#define PCI_EXP_TYPE_ROOT_PORT 0x4 /* Root Port */ +#define PCI_EXP_TYPE_DOWNSTREAM 0x6 /* Downstream Port */ +#define PCI_EXP_TYPE_PCIE_BRIDGE 0x8 /* PCI/PCI-X to PCIe Bridge */ #define PCI_EXP_DEVCAP 4 /* Device capabilities */ #define PCI_EXP_DEVCAP_FLR 0x10000000 /* Function Level Reset */ #define PCI_EXP_DEVCTL 8 /* Device Control */ #define PCI_EXP_DEVCTL_BCR_FLR 0x8000 /* Bridge Configuration Retry / FLR */ #define PCI_EXP_LNKCAP 12 /* Link Capabilities */ #define PCI_EXP_LNKCAP_SLS 0x0000000f /* Supported Link Speeds */ +#define PCI_EXP_LNKCAP_SLS_2_5GB 0x00000001 /* LNKCAP2 SLS Vector bit 0 */ +#define PCI_EXP_LNKCAP_SLS_5_0GB 0x00000002 /* LNKCAP2 SLS Vector bit 1 */ +#define PCI_EXP_LNKCAP_SLS_8_0GB 0x00000003 /* LNKCAP2 SLS Vector bit 2 */ #define PCI_EXP_LNKCAP_MLW 0x000003f0 /* Maximum Link Width */ #define PCI_EXP_LNKCAP_DLLLARC 0x00100000 /* Data Link Layer Link Active Reporting Capable */ +#define PCI_EXP_LNKCTL 16 /* Link Control */ +#define PCI_EXP_LNKCTL_RL 0x0020 /* Retrain Link */ #define PCI_EXP_LNKSTA 18 /* Link Status */ #define PCI_EXP_LNKSTA_CLS 0x000f /* Current Link Speed */ #define PCI_EXP_LNKSTA_CLS_2_5GB 0x0001 /* Current Link Speed 2.5GT/s */ @@ -492,7 +501,9 @@ #define PCI_EXP_LNKSTA_CLS_8_0GB 0x0003 /* Current Link Speed 8.0GT/s */ #define PCI_EXP_LNKSTA_NLW 0x03f0 /* Negotiated Link Width */ #define PCI_EXP_LNKSTA_NLW_SHIFT 4 /* start of NLW mask in link status */ +#define PCI_EXP_LNKSTA_LT 0x0800 /* Link Training */ #define PCI_EXP_LNKSTA_DLLLA 0x2000 /* Data Link Layer Link Active */ +#define PCI_EXP_LNKSTA_LBMS 0x4000 /* Link Bandwidth Management Status */ #define PCI_EXP_SLTCAP 20 /* Slot Capabilities */ #define PCI_EXP_SLTCAP_PSN 0xfff80000 /* Physical Slot Number */ #define PCI_EXP_RTCTL 28 /* Root Control */ @@ -503,8 +514,14 @@ #define PCI_EXP_DEVCAP2_ARI 0x00000020 /* ARI Forwarding Supported */ #define PCI_EXP_DEVCTL2 40 /* Device Control 2 */ #define PCI_EXP_DEVCTL2_ARI 0x0020 /* Alternative Routing-ID */ - +#define PCI_EXP_LNKCAP2 44 /* Link Capability 2 */ +#define PCI_EXP_LNKCAP2_SLS 0x000000fe /* Supported Link Speeds Vector */ #define PCI_EXP_LNKCTL2 48 /* Link Control 2 */ +#define PCI_EXP_LNKCTL2_TLS 0x000f /* Target Link Speed */ +#define PCI_EXP_LNKCTL2_TLS_2_5GT 0x0001 /* Target Link Speed 2.5GT/s */ +#define PCI_EXP_LNKCTL2_TLS_5_0GT 0x0002 /* Target Link Speed 5.0GT/s */ +#define PCI_EXP_LNKCTL2_TLS_8_0GT 0x0003 /* Target Link Speed 8.0GT/s */ + /* Single Root I/O Virtualization Registers */ #define PCI_SRIOV_CAP 0x04 /* SR-IOV Capabilities */ #define PCI_SRIOV_CTRL 0x08 /* SR-IOV Control */ @@ -522,6 +539,77 @@ #include <pci_ids.h> +/* + * Config Address for PCI Configuration Mechanism #1 + * + * See PCI Local Bus Specification, Revision 3.0, + * Section 3.2.2.3.2, Figure 3-2, p. 50. + */ + +#define PCI_CONF1_BUS_SHIFT 16 /* Bus number */ +#define PCI_CONF1_DEV_SHIFT 11 /* Device number */ +#define PCI_CONF1_FUNC_SHIFT 8 /* Function number */ + +#define PCI_CONF1_BUS_MASK 0xff +#define PCI_CONF1_DEV_MASK 0x1f +#define PCI_CONF1_FUNC_MASK 0x7 +#define PCI_CONF1_REG_MASK 0xfc /* Limit aligned offset to a maximum of 256B */ + +#define PCI_CONF1_ENABLE BIT(31) +#define PCI_CONF1_BUS(x) (((x) & PCI_CONF1_BUS_MASK) << PCI_CONF1_BUS_SHIFT) +#define PCI_CONF1_DEV(x) (((x) & PCI_CONF1_DEV_MASK) << PCI_CONF1_DEV_SHIFT) +#define PCI_CONF1_FUNC(x) (((x) & PCI_CONF1_FUNC_MASK) << PCI_CONF1_FUNC_SHIFT) +#define PCI_CONF1_REG(x) ((x) & PCI_CONF1_REG_MASK) + +#define PCI_CONF1_ADDRESS(bus, dev, func, reg) \ + (PCI_CONF1_ENABLE | \ + PCI_CONF1_BUS(bus) | \ + PCI_CONF1_DEV(dev) | \ + PCI_CONF1_FUNC(func) | \ + PCI_CONF1_REG(reg)) + +/* + * Extension of PCI Config Address for accessing extended PCIe registers + * + * No standardized specification, but used on lot of non-ECAM-compliant ARM SoCs + * or on AMD Barcelona and new CPUs. Reserved bits [27:24] of PCI Config Address + * are used for specifying additional 4 high bits of PCI Express register. + */ + +#define PCI_CONF1_EXT_REG_SHIFT 16 +#define PCI_CONF1_EXT_REG_MASK 0xf00 +#define PCI_CONF1_EXT_REG(x) (((x) & PCI_CONF1_EXT_REG_MASK) << PCI_CONF1_EXT_REG_SHIFT) + +#define PCI_CONF1_EXT_ADDRESS(bus, dev, func, reg) \ + (PCI_CONF1_ADDRESS(bus, dev, func, reg) | \ + PCI_CONF1_EXT_REG(reg)) + +/* + * Enhanced Configuration Access Mechanism (ECAM) + * + * See PCI Express Base Specification, Revision 5.0, Version 1.0, + * Section 7.2.2, Table 7-1, p. 677. + */ +#define PCIE_ECAM_BUS_SHIFT 20 /* Bus number */ +#define PCIE_ECAM_DEV_SHIFT 15 /* Device number */ +#define PCIE_ECAM_FUNC_SHIFT 12 /* Function number */ + +#define PCIE_ECAM_BUS_MASK 0xff +#define PCIE_ECAM_DEV_MASK 0x1f +#define PCIE_ECAM_FUNC_MASK 0x7 +#define PCIE_ECAM_REG_MASK 0xfff /* Limit offset to a maximum of 4K */ + +#define PCIE_ECAM_BUS(x) (((x) & PCIE_ECAM_BUS_MASK) << PCIE_ECAM_BUS_SHIFT) +#define PCIE_ECAM_DEV(x) (((x) & PCIE_ECAM_DEV_MASK) << PCIE_ECAM_DEV_SHIFT) +#define PCIE_ECAM_FUNC(x) (((x) & PCIE_ECAM_FUNC_MASK) << PCIE_ECAM_FUNC_SHIFT) +#define PCIE_ECAM_REG(x) ((x) & PCIE_ECAM_REG_MASK) + +#define PCIE_ECAM_OFFSET(bus, dev, func, where) \ + (PCIE_ECAM_BUS(bus) | \ + PCIE_ECAM_DEV(dev) | \ + PCIE_ECAM_FUNC(func) | \ + PCIE_ECAM_REG(where)) + #ifndef __ASSEMBLY__ #include <dm/pci.h> diff --git a/include/pci_ids.h b/include/pci_ids.h index 7ecedc7f04c..3c5434c0eda 100644 --- a/include/pci_ids.h +++ b/include/pci_ids.h @@ -151,6 +151,9 @@ #define PCI_DEVICE_ID_BERKOM_A4T 0xffa4 #define PCI_DEVICE_ID_BERKOM_SCITEL_QUADRO 0xffa8 +#define PCI_VENDOR_ID_BROADCOM 0x14e4 +#define PCI_DEVICE_ID_NXT_57320 0x16F0 + #define PCI_VENDOR_ID_COMPAQ 0x0e11 #define PCI_DEVICE_ID_COMPAQ_TOKENRING 0x0508 #define PCI_DEVICE_ID_COMPAQ_TACHYON 0xa0fc diff --git a/include/sandboxblockdev.h b/include/sandboxblockdev.h index 4006e942a02..4ca9554e38a 100644 --- a/include/sandboxblockdev.h +++ b/include/sandboxblockdev.h @@ -6,6 +6,9 @@ #ifndef __SANDBOX_BLOCK_DEV__ #define __SANDBOX_BLOCK_DEV__ +/* Maximum number of host devices - see drivers/block/sandbox.c */ +#define SANDBOX_HOST_MAX_DEVICES 4 + struct host_block_dev { #ifndef CONFIG_BLK struct blk_desc blk_dev; diff --git a/include/scmi_agent.h b/include/scmi_agent.h index f1be9ff2091..ed40c7360a9 100644 --- a/include/scmi_agent.h +++ b/include/scmi_agent.h @@ -45,9 +45,9 @@ struct scmi_msg { } /** - * scmi_send_and_process_msg() - send and process a SCMI message + * devm_scmi_process_msg() - Send and process an SCMI message * - * Send a message to a SCMI server through a target SCMI agent device. + * Send a message to an SCMI server through a target SCMI agent device. * Caller sets scmi_msg::out_msg_sz to the output message buffer size. * On return, scmi_msg::out_msg_sz stores the response payload size. * diff --git a/include/spi_flash.h b/include/spi_flash.h index 4d4ae89c192..4566feab631 100644 --- a/include/spi_flash.h +++ b/include/spi_flash.h @@ -14,20 +14,6 @@ struct udevice; -/* by default ENV use the same parameters than SF command */ -#ifndef CONFIG_ENV_SPI_BUS -# define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS -#endif -#ifndef CONFIG_ENV_SPI_CS -# define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS -#endif -#ifndef CONFIG_ENV_SPI_MAX_HZ -# define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED -#endif -#ifndef CONFIG_ENV_SPI_MODE -# define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE -#endif - struct spi_slave; struct dm_spi_flash_ops { diff --git a/include/splash.h b/include/splash.h index 7fd2de8fea1..33e45e69416 100644 --- a/include/splash.h +++ b/include/splash.h @@ -30,6 +30,7 @@ enum splash_storage { SPLASH_STORAGE_MMC, SPLASH_STORAGE_USB, SPLASH_STORAGE_SATA, + SPLASH_STORAGE_VIRTIO, }; enum splash_flags { diff --git a/include/tee.h b/include/tee.h index 44e9cd4321b..13f6096b9a6 100644 --- a/include/tee.h +++ b/include/tee.h @@ -32,6 +32,25 @@ TEE_PARAM_ATTR_META) /* + * Global Platform login identifiers for tee_open_session_arg::clnt_login + */ +#define TEE_LOGIN_PUBLIC 0x00000000 +#define TEE_LOGIN_USER 0x00000001 +#define TEE_LOGIN_GROUP 0x00000002 +#define TEE_LOGIN_APPLICATION 0x00000004 +#define TEE_LOGIN_APPLICATION_USER 0x00000005 +#define TEE_LOGIN_APPLICATION_GROUP 0x00000006 +/* + * Reserve use of GP implementation specific login method range + * (0x80000000 - 0xBFFFFFFF). This range is rather being used + * for REE kernel clients or TEE implementation. + */ +#define TEE_LOGIN_REE_KERNEL_MIN 0x80000000 +#define TEE_LOGIN_REE_KERNEL_MAX 0xBFFFFFFF +/* Private login method for REE kernel/privileged clients */ +#define TEE_LOGIN_REE_KERNEL 0x80000000 + +/* * Some Global Platform error codes which has a meaning if the * TEE_GEN_CAP_GP bit is returned by the driver in * struct tee_version_data::gen_caps @@ -39,12 +58,14 @@ #define TEE_SUCCESS 0x00000000 #define TEE_ERROR_STORAGE_NOT_AVAILABLE 0xf0100003 #define TEE_ERROR_GENERIC 0xffff0000 +#define TEE_ERROR_EXCESS_DATA 0xffff0004 #define TEE_ERROR_BAD_PARAMETERS 0xffff0006 #define TEE_ERROR_ITEM_NOT_FOUND 0xffff0008 #define TEE_ERROR_NOT_IMPLEMENTED 0xffff0009 #define TEE_ERROR_NOT_SUPPORTED 0xffff000a #define TEE_ERROR_COMMUNICATION 0xffff000e #define TEE_ERROR_SECURITY 0xffff000f +#define TEE_ERROR_SHORT_BUFFER 0xffff0010 #define TEE_ERROR_OUT_OF_MEMORY 0xffff000c #define TEE_ERROR_OVERFLOW 0xffff300f #define TEE_ERROR_TARGET_DEAD 0xffff3024 @@ -135,8 +156,8 @@ struct tee_param { /** * struct tee_open_session_arg - extra arguments for tee_open_session() * @uuid: [in] UUID of the Trusted Application - * @clnt_uuid: [in] Normally zeroes - * @clnt_login: [in] Normally 0 + * @clnt_uuid: [in] UUID of client, zeroes for PUBLIC/REE_KERNEL + * @clnt_login: [in] Class of client TEE_LOGIN_* * @session: [out] Session id * @ret: [out] return value * @ret_origin: [out] origin of the return value diff --git a/include/tpm-v2.h b/include/tpm-v2.h index ceff7d245ed..4e9dd52cb6c 100644 --- a/include/tpm-v2.h +++ b/include/tpm-v2.h @@ -512,13 +512,16 @@ u32 tpm2_nv_write_value(struct udevice *dev, u32 index, const void *data, * @dev TPM device * @idx Index of the PCR * @idx_min_sz Minimum size in bytes of the pcrSelect array + * @algorithm Algorithm used, defined in 'enum tpm2_algorithms' * @data Output buffer for contents of the named PCR + * @digest_len len of the data * @updates Optional out parameter: number of updates for this PCR * * @return code of the operation */ u32 tpm2_pcr_read(struct udevice *dev, u32 idx, unsigned int idx_min_sz, - void *data, unsigned int *updates); + u16 algorithm, void *data, u32 digest_len, + unsigned int *updates); /** * Issue a TPM2_GetCapability command. This implementation is limited diff --git a/include/tsec.h b/include/tsec.h index c301c28d3d5..72f34851ad1 100644 --- a/include/tsec.h +++ b/include/tsec.h @@ -122,6 +122,8 @@ #define ECNTRL_REDUCED_MII_MODE 0x00000004 #define ECNTRL_SGMII_MODE 0x00000002 +#define RCTRL_PROM 0x00000008 + #ifndef CONFIG_SYS_TBIPA_VALUE # define CONFIG_SYS_TBIPA_VALUE 0x1f #endif diff --git a/include/u-boot/blake2.h b/include/u-boot/blake2.h new file mode 100644 index 00000000000..4984023a1a2 --- /dev/null +++ b/include/u-boot/blake2.h @@ -0,0 +1,94 @@ +/* SPDX-License-Identifier: CC0-1.0 */ +/* + BLAKE2 reference source code package - reference C implementations + + Copyright 2012, Samuel Neves <sneves@dei.uc.pt>. You may use this under the + terms of the CC0, the OpenSSL Licence, or the Apache Public License 2.0, at + your option. The terms of these licenses can be found at: + + - CC0 1.0 Universal : http://creativecommons.org/publicdomain/zero/1.0 + - OpenSSL license : https://www.openssl.org/source/license.html + - Apache 2.0 : http://www.apache.org/licenses/LICENSE-2.0 + + More information about the BLAKE2 hash function can be found at + https://blake2.net. +*/ + +/* + * Cross-ported from BLAKE2 (https://github.com/BLAKE2/BLAKE2). + * Modifications includes: + * + * - Remove unsupported compilers like MSC/CPP + * - Remove blake2s/blake2sp/blake2bp + * This blake2 implementation is mostly for btrfs, which only utilizes + * blake2b. + */ +#ifndef BLAKE2_H +#define BLAKE2_H + +#include <stddef.h> +#include <stdint.h> + +#if defined(_MSC_VER) +#define BLAKE2_PACKED(x) __pragma(pack(push, 1)) x __pragma(pack(pop)) +#else +#define BLAKE2_PACKED(x) x __attribute__((packed)) +#endif + + enum blake2b_constant + { + BLAKE2B_BLOCKBYTES = 128, + BLAKE2B_OUTBYTES = 64, + BLAKE2B_KEYBYTES = 64, + BLAKE2B_SALTBYTES = 16, + BLAKE2B_PERSONALBYTES = 16 + }; + + typedef struct blake2b_state__ + { + uint64_t h[8]; + uint64_t t[2]; + uint64_t f[2]; + uint8_t buf[BLAKE2B_BLOCKBYTES]; + size_t buflen; + size_t outlen; + uint8_t last_node; + } blake2b_state; + + BLAKE2_PACKED(struct blake2b_param__ + { + uint8_t digest_length; /* 1 */ + uint8_t key_length; /* 2 */ + uint8_t fanout; /* 3 */ + uint8_t depth; /* 4 */ + uint32_t leaf_length; /* 8 */ + uint32_t node_offset; /* 12 */ + uint32_t xof_length; /* 16 */ + uint8_t node_depth; /* 17 */ + uint8_t inner_length; /* 18 */ + uint8_t reserved[14]; /* 32 */ + uint8_t salt[BLAKE2B_SALTBYTES]; /* 48 */ + uint8_t personal[BLAKE2B_PERSONALBYTES]; /* 64 */ + }); + + typedef struct blake2b_param__ blake2b_param; + + /* Padded structs result in a compile-time error */ + enum { + BLAKE2_DUMMY_2 = 1/(int)(sizeof(blake2b_param) == BLAKE2B_OUTBYTES) + }; + + /* Streaming API */ + int blake2b_init( blake2b_state *S, size_t outlen ); + int blake2b_init_key( blake2b_state *S, size_t outlen, const void *key, size_t keylen ); + int blake2b_init_param( blake2b_state *S, const blake2b_param *P ); + int blake2b_update( blake2b_state *S, const void *in, size_t inlen ); + int blake2b_final( blake2b_state *S, void *out, size_t outlen ); + + /* Simple API */ + int blake2b( void *out, size_t outlen, const void *in, size_t inlen, const void *key, size_t keylen ); + + /* This is simply an alias for blake2b */ + int blake2( void *out, size_t outlen, const void *in, size_t inlen, const void *key, size_t keylen ); + +#endif diff --git a/include/video.h b/include/video.h index f14fb15f84f..1d75a90510c 100644 --- a/include/video.h +++ b/include/video.h @@ -30,12 +30,14 @@ struct udevice; * @base: Base address of frame buffer, 0 if not yet known * @copy_base: Base address of a hardware copy of the frame buffer. See * CONFIG_VIDEO_COPY. + * @hide_logo: Hide the logo (used for testing) */ struct video_uc_plat { uint align; uint size; ulong base; ulong copy_base; + bool hide_logo; }; enum video_polarity { @@ -93,7 +95,6 @@ enum video_format { * @colour_bg: Background colour (pixel value) * @flush_dcache: true to enable flushing of the data cache after * the LCD is updated - * @cmap: Colour map for 8-bit-per-pixel displays * @fg_col_idx: Foreground color code (bit 3 = bold, bit 0-2 = color) * @bg_col_idx: Background color code (bit 3 = bold, bit 0-2 = color) */ @@ -118,7 +119,6 @@ struct video_priv { u32 colour_fg; u32 colour_bg; bool flush_dcache; - ushort *cmap; u8 fg_col_idx; u8 bg_col_idx; }; @@ -276,6 +276,13 @@ static inline int video_sync_copy_all(struct udevice *dev) #endif +/** + * video_is_active() - Test if one video device it active + * + * @return true if at least one video device is active, else false. + */ +bool video_is_active(void); + #ifndef CONFIG_DM_VIDEO /* Video functions */ diff --git a/include/virtio.h b/include/virtio.h index a42bdad6b87..34e2bfdcdd3 100644 --- a/include/virtio.h +++ b/include/virtio.h @@ -20,6 +20,7 @@ #ifndef __VIRTIO_H__ #define __VIRTIO_H__ +#include <virtio_types.h> #include <linux/bitops.h> #include <linux/bug.h> #define VIRTIO_ID_NET 1 /* virtio net */ diff --git a/include/vsprintf.h b/include/vsprintf.h index b4746301462..8bfafa0d33f 100644 --- a/include/vsprintf.h +++ b/include/vsprintf.h @@ -308,6 +308,14 @@ char *strmhz(char *buf, unsigned long hz); void str_to_upper(const char *in, char *out, size_t len); /** + * vsscanf - Unformat a buffer into a list of arguments + * @buf: input buffer + * @fmt: format of buffer + * @args: arguments + */ +int vsscanf(const char *inp, char const *fmt0, va_list ap); + +/** * sscanf - Unformat a buffer into a list of arguments * @buf: input buffer * @fmt: formatting of buffer |