Re: [U-Boot] [PATCH v2] ARMV7: Add support For Logic OMAP35x/DM37x modules
Hi Peter, On 12/16/11 08:09, Peter Barada wrote: On 12/15/2011 01:30 PM, Tom Rini wrote: On Thu, Dec 15, 2011 at 10:15 AM, Peter Barada peter.bar...@logicpd.com wrote: This patch adds basic support for OMAP35x/DM37x SOM LV/Torpedo reference boards. It assumes U-boot is loaded to SDRAM with the help of another small bootloader (x-load) running from SRAM. [...] As for the function, in arch/arm/cpu/armv7/omap3/board.c there's already a checkboard() function that is called early (before relocation) that prints out the banner. I tried to make that a weak alias and override it in my board file, but when its called, gd-bd is not setup so that code aborts when it tries to set gd-bd-bi_arch_number. I then tried storing the value in a global and then set gd-bd-bi_arch_number in board_init(), but between the call to checkboard() and board_init() the BSS section is zeroed. If I stored/load the computed bi_arch_number into a non-zero static value it works, but I feel that is really fragile. This make me wonder, should we move the checkboard() call further in the init sequence? Because, IIRC, it stayed in the same place, where it was, before the relocation feature was introduced and board_init() was called before the checkboard() (as board_init_f() does now). Also, the struct bd_info (bd_t) should have the board data and ironically it is not available in checkboard() function. So, Albert, Wolfgang, the question is, should we move the checkboard() call after the gd-bd pointer initialization or are there any cases where it is not appropriate? -- Regards, Igor. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] ARMV7: Add support For Logic OMAP35x/DM37x modules
Hi Peter, Some comments (hopefully last ones) in addition to Wolfgang's and Tom's: On 12/16/11 22:31, Peter Barada wrote: This patch adds basic support for OMAP35x/DM37x SOM LV/Torpedo reference boards. It assumes U-boot is loaded to SDRAM with the help of another small bootloader (x-load) running from SRAM. Signed-off-by: Peter Barada peter.bar...@logicpd.com Cc: Tom Rini tom.r...@gmail.com Cc: Igor Grinberg grinb...@compulab.co.il --- Changes for V3: Inline identify_board() into board_init() Remove triple empty lines Use sdelay() instead of naked delay loop Use enable_gpmc_cs_config() to setup GPMC CS1 access to LAN92xx Remove CONFIG_L2_OFF - holdover from previous work in u-boot-2011.06 where adding 270p 32bpp frambuffer support cause failure while booting linux kernel. Will address when I add video support Reduce CONFIG_SYS_MAXARGS to 16 Changes for V2: Rework logic_identify() into identify_board() - can't use checkboard() since its enabled by CONFIG_DISPLAY_BOARDINFO Properly indent comments in set_muxconf_regs() Move setup_net_chip() call from misc_init_r to board_eth_init() Remove triple empty line spacing Pass gpio_request(189) non-empty description Remove board/logicpd/omap3som/config.mk Remove clean/distclean from board/logicpd/omap3som/Makefile Modify board_mmc_init() to be one line function Modify include/configs/omap3_logic.h to use on/off #defines board/logicpd/omap3som/Makefile | 42 +++ board/logicpd/omap3som/omap3logic.c | 523 +++ board/logicpd/omap3som/omap3logic.h | 35 +++ boards.cfg |1 + include/configs/omap3_logic.h | 351 +++ 5 files changed, 952 insertions(+), 0 deletions(-) create mode 100644 board/logicpd/omap3som/Makefile create mode 100644 board/logicpd/omap3som/omap3logic.c create mode 100644 board/logicpd/omap3som/omap3logic.h create mode 100644 include/configs/omap3_logic.h [...] diff --git a/board/logicpd/omap3som/omap3logic.c b/board/logicpd/omap3som/omap3logic.c new file mode 100644 index 000..eb051db --- /dev/null +++ b/board/logicpd/omap3som/omap3logic.c [...] +/* + * Routine: board_init + * Description: Early hardware init. + */ +int board_init(void) +{ + struct board_id *board; + unsigned int val; + + gpmc_init(); /* in SRAM or SDRAM, finish GPMC */ + + /* boot param addr */ + gd-bd-bi_boot_params = (OMAP34XX_SDRC_CS0 + 0x100); + + /* + * To identify between a SOM LV and Torpedo module, + * a pulldown resistor is on hsusb0_data5 for the SOM LV module. + * Drive the pin (and let it soak), then read it back. + * If the pin is still high its a Torpedo. If low its a SOM LV + */ + + /* Mux hsusb0_data5 as a GPIO */ + MUX_VAL(CP(HSUSB0_DATA5), (IEN | PTD | DIS | M4)); + + if (gpio_request(GPIO_189, husb0_data5.gpio_189) == 0) { Usually, by the label goes the functionality it is used for in current request, but af course it is up to you, it is not a blocker as long as the label is valid. + + /* Drive GPIO_189 - the pulldown resistor on the SOM LV + * will drain the voltage */ incorrect multi-line comment (fix globally) and probably, the empty line before it can be removed. + gpio_direction_output(GPIO_189, 0); + gpio_set_value(GPIO_189, 1); + + /* Let it soak for a bit */ + sdelay(0x100); + + /* Read state of GPIO_189 as an input and if its set. + * If so the board is a Torpedo */ + gpio_direction_input(GPIO_189); + val = gpio_get_value(GPIO_189); + gpio_free(GPIO_189); + + board = boards[!!(get_cpu_family() == CPU_OMAP36XX)][!!val]; + printf(Board: %s\n, board-name); + + /* Set the machine_id passed to Linux */ + gd-bd-bi_arch_number = board-machine_id; + } + + /* restore hsusb0_data5 pin as hsusb0_data5 */ + MUX_VAL(CP(HSUSB0_DATA5), (IEN | PTD | DIS | M0)); + + return 0; +} [...] +/* + * Routine: misc_init_r + * Description: Init ethernet (done here so udelay works) Function changed, comment left... + */ +int misc_init_r(void) +{ + dieid_num_r(); + + return 0; +} [...] -- Regards, Igor. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] OMAP3: Remove unused define CONFIG_OMAP3_*_DDR
On 12/16/11 11:00, Thomas Weber wrote: This patch removes the unused definitions: CONFIG_OMAP3_MICRON_DDR CONFIG_OMAP3_NUMONYX_DDR CONFIG_OMAP3_INFINEON_DDR Signed-off-by: Thomas Weber we...@corscience.de Acked-by: Igor Grinberg grinb...@compulab.co.il Thanks Thomas. -- Regards, Igor. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] OMAP3: Add Corscience Tricorder board
Hi Thomas, Several comments in addition to Tom's comments: On 12/15/11 12:16, Thomas Weber wrote: Tricorder is a board which is very similar to the Devkit8000. It is designed as a base platform for further medical devices. www.corscience.de/en/medical-engineering/products/multiparameter/mp10-board.html Signed-off-by: Thomas Weber we...@corscience.de --- MAINTAINERS|1 + board/corscience/tricorder/Makefile| 46 board/corscience/tricorder/tricorder.c | 114 ++ board/corscience/tricorder/tricorder.h | 375 boards.cfg |1 + include/configs/tricorder.h| 325 +++ 6 files changed, 862 insertions(+), 0 deletions(-) create mode 100644 board/corscience/tricorder/Makefile create mode 100644 board/corscience/tricorder/tricorder.c create mode 100644 board/corscience/tricorder/tricorder.h create mode 100644 include/configs/tricorder.h [...] diff --git a/board/corscience/tricorder/tricorder.c b/board/corscience/tricorder/tricorder.c new file mode 100644 index 000..3426f2e --- /dev/null +++ b/board/corscience/tricorder/tricorder.c @@ -0,0 +1,114 @@ +/* + * (C) Copyright 2004-2008 + * Texas Instruments, www.ti.com + * + * Author : + * Sunil Kumar sunilsain...@gmail.com + * Shashi Ranjan shashiranjanmc...@gmail.com + * + * (C) Copyright 2011 + * Corscience GmbH Co. KG, www.corscience.de + * Thomas Weber we...@corscience.de Something is wrong here with authorship... IMO, you should be the author, and people above listed in derived from ... or something. + * + * Derived from Devkit8000 code by + * Frederik Kriewitz frede...@kriewitz.eu + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, + * MA 02111-1307 USA I would also, remove the postal address, as it may change (and did in the past), but it is your call. + */ +#include common.h +#include twl4030.h +#include asm/io.h +#include asm/arch/mmc_host_def.h +#include asm/arch/mux.h +#include asm/arch/sys_proto.h +#include asm/arch/mem.h +#include asm/mach-types.h +#include tricorder.h + +DECLARE_GLOBAL_DATA_PTR; + +/* + * Routine: board_init + * Description: Early hardware init. + */ +int board_init(void) +{ + gpmc_init(); /* in SRAM or SDRAM, finish GPMC */ + /* board id for Linux */ + gd-bd-bi_arch_number = MACH_TYPE_TRICORDER; This should be done in board config file (see the README). Also, after moving this to config file, I think, the include for mach-types.h can be removed. + /* boot param addr */ + gd-bd-bi_boot_params = (OMAP34XX_SDRC_CS0 + 0x100); + + return 0; +} [...] diff --git a/board/corscience/tricorder/tricorder.h b/board/corscience/tricorder/tricorder.h new file mode 100644 index 000..c875dfa --- /dev/null +++ b/board/corscience/tricorder/tricorder.h [...] +#define MUX_TRICORDER() \ + /* SDRC */\ Please, use tabs for indentation and please fix globally. [...] + /* */\ This is really a nice comment, but... That is one of the reasons I like the whole thing done in a function or an array rather than in a multi-line macro... [...] diff --git a/include/configs/tricorder.h b/include/configs/tricorder.h new file mode 100644 index 000..6a66bee --- /dev/null +++ b/include/configs/tricorder.h [...] +/* I2C */ +#define CONFIG_HARD_I2C +#define CONFIG_SYS_I2C_SPEED 10 +#define CONFIG_SYS_I2C_SLAVE 1 +#define CONFIG_SYS_I2C_BUS 0 +#define CONFIG_SYS_I2C_BUS_SELECT1 +#define CONFIG_DRIVER_OMAP34XX_I2C 1 Some of these should not have a value, right? +#define CONFIG_ENV_IS_IN_NAND1 +#define SMNAND_ENV_OFFSET0x26 /* environment starts here */ + +#define CONFIG_ENV_OFFSETSMNAND_ENV_OFFSET Can't the above be inlined? [...] -- Regards, Igor. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v2] ARMV7: Add support For Logic OMAP35x/DM37x modules
Dear Igor Grinberg, In message 4eedaba8.4010...@compulab.co.il you wrote: As for the function, in arch/arm/cpu/armv7/omap3/board.c there's already a checkboard() function that is called early (before relocation) that And keep in mind: before relocation means that the BSS segment is not available, and data segment is read-only. [You may be lucky on some systems that things appear to be different, but this is nothing you should take granted, and it is definitely nothing that should be used for common code.] code aborts when it tries to set gd-bd-bi_arch_number. I then tried storing the value in a global and then set gd-bd-bi_arch_number in board_init(), but between the call to checkboard() and board_init() the BSS section is zeroed. If I stored/load the computed bi_arch_number into a non-zero static value it works, but I feel that is really fragile. It is not only fragile, but broken. See above: the data ssegment must not be written before relocation. This make me wonder, should we move the checkboard() call further in the init sequence? No, it should not. It is part of the very early init code, and should remain where it is. Just don't add any code that does not belong there. Also, the struct bd_info (bd_t) should have the board data and ironically it is not available in checkboard() function. I don't see what is ironically about thaat. bd_info does not exist at that point of time. You misinterpret the purpose of the checkboard() function, it seems. So, Albert, Wolfgang, the question is, should we move the checkboard() call after the gd-bd pointer initialization or are there any cases where it is not appropriate? Please leave as is, it is perfectly intentional. Just don't place any code in checkboard() which does not fit there. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de A stone was placed at a ford in a river with the inscription: When this stone is covered it is dangerous to ford here. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] U-Boot on Nokia RX-51 (aka N900)
Dear Pali =?ISO-8859-1?Q?Roh=E1r?=, please do not full-quote. Quote only as much of the mail you are replying to as is needed to give enough context. It makes no sense to quoted hundrets of lines which you are not referring to in your reply. Thanks. In message 17199828.H8TsXDWnq5@pali-elitebook you wrote: WARNING: space prohibited between function name and open parenthesis '(' #130: FILE: arch/arm/lib/bootm.c:128: + s = getenv (atagaddr); see file arch/arm/lib/bootm.c - it has this code styling. so this is not error unless you want to mix more code styling in one file. If you find broken code, then please help fixing it. Never try to use this as an excuse to add even more broken code. WARNING: consider using kstrto* in preference to simple_strtoul ... really? I was not able to find kstrtoul function False positive. WARNING: space prohibited between function name and open parenthesis '(' ... WARNING: please, no spaces at the start of a line ... same - see my first comment See my comment. All these must be fixed. see commit message - this patch is from linux upstream and uf u-boot has same styling this should be ok too. Linux is not always as strict as we tend to be. Also, if this code has been copied from Linux, then youi missed to properly reference it. See http://www.denx.de/wiki/view/U-Boot/Patches#Attributing_Code_Copyrights_Sign WARNING: line over 80 characters #117: FILE: common/main.c:1028: + case '\e': /* ANSI escape char */ again - same formating in file common/main.c Fix it! WARNING: line over 80 characters ... If you want I remove above comments /* ... */ If these comments are considered useful, then they should be kept. In any case, the line length must not be exceeded. ERROR: do not initialise statics to 0 or NULL #113: FILE: drivers/video/cfb_console.c:382: +static int ansi_colors_need_revert = 0; what is problem with initialising to 0? It's redundant, we don't like it, and it triggers a checkpatch warning :-) Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de When it is incorrect, it is, at least *authoritatively* incorrect. - Hitchiker's Guide To The Galaxy ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] Some thoughts on SPL
On Sun, Dec 18, 2011 at 12:55 AM, Simon Glass s...@chromium.org wrote: Hi Wolfgang, On Sat, Dec 17, 2011 at 12:08 PM, Wolfgang Denk w...@denx.de wrote: Dear Simon Glass, In message CAPnjgZ0E4RfzzL2tfff=cn0xq5ov+v-qtqny3s3zb6hn7sv...@mail.gmail.com you wrote: On Fri, Dec 16, 2011 at 9:20 AM, jonsm...@gmail.com jonsm...@gmail.com wr= ote: ... The concept is to remove SPL as a special class and turn it into the base layer that everything builds on. Changing the model in this was should make the config files easier to understand. Instead of having a single file combining SPL and full u-boot you'd have two independent ones. In my case I'd build one u-boot config that fits into 96K and another full 250K one. Of course the two config files could each include a common base config. ... That's one way to do it, and makes more and more sense as the amount of available SRAM increases. Of course some SOCs can even set up their SDRAM and read entire programs in, so there are no restrictions. But for those with limitations, it makes sense to me to make SPL more a cut down build of U-Boot than a special program that pulls in #ifdefed code from various places. Another approach is to just have one U-Boot, but keep everything you need to get started in the first 96KB. Please keep in mind that there is also a large number of boards that boot form some boot ROM (like NOR flash), i. e. that can directly execute _all_ U-Boot code, without need of any SPL at all. Any changes to the design of the SPL must not have any adverse effects on such XIP booting systems. This is a degenerate case for the system I describe - where all the code is in the first part and the second part is empty. It adds nothing but for the extra build complexity already mentioned. I'm not involved enough in SPL yet to be able to say how useful all this is, perhaps later. I agree, we are thinking about a change in the build process. The binaries produced would still function as they currently do. Regards, Simon Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de More software projects have gone awry for lack of calendar time than for all other causes combined. - Fred Brooks, Jr., _The Mythical Man Month_ -- Jon Smirl jonsm...@gmail.com ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v4] ARMV7: Add support For Logic OMAP35x/DM37x modules
This patch adds basic support for OMAP35x/DM37x SOM LV/Torpedo reference boards. It assumes U-boot is loaded to SDRAM with the help of another small bootloader (x-load) running from SRAM. Signed-off-by: Peter Barada peter.bar...@logicpd.com Cc: Tom Rini tom.r...@gmail.com Cc: Igor Grinberg grinb...@compulab.co.il Cc: Wolfgang Denk w...@denx.de --- Changes for V4: Use #defines for LAN92XX GPMC register settings Add myself to MAINTAINERS Fix multiline comments Remove switch values in on/off macro definitions Modify CONFIG_PREBOOT to make it clear the 4.3 display is the default Rework name of GPIO_189 to better describe what its used for Fix misc_init_r comment Changes for V3: Inline identify_board() into board_init() Remove triple empty lines Use sdelay() instead of naked delay loop Use enable_gpmc_cs_config() to setup GPMC CS1 access to LAN92xx Remove CONFIG_L2_OFF - holdover from previous work in u-boot-2011.06 where adding 270p 32bpp frambuffer support cause failure while booting linux kernel. Will address when I add video support Reduce CONFIG_SYS_MAXARGS to 16 Changes for V2: Rework logic_identify() into identify_board() - can't use checkboard() since its enabled but CONFIG_DISPLAY_BOARDINFO. Properly indent comments in set_muxconf_regs() Move setup_net_chip() call from misc_init_r to board_eth_init() Remove triple empty line spacing Pass gpio_request(189) non-empty description Remove board/logicpd/omap3som/config.mk Remove clean/distclean from board/logicpd/omap3som/Makefile Modify board_mmc_init() to be one line function Modify include/configs/omap3_logic.h to use on/off #defines MAINTAINERS |4 + board/logicpd/omap3som/Makefile | 42 +++ board/logicpd/omap3som/omap3logic.c | 532 +++ board/logicpd/omap3som/omap3logic.h | 47 +++ boards.cfg |1 + include/configs/omap3_logic.h | 358 +++ 6 files changed, 984 insertions(+), 0 deletions(-) create mode 100644 board/logicpd/omap3som/Makefile create mode 100644 board/logicpd/omap3som/omap3logic.c create mode 100644 board/logicpd/omap3som/omap3logic.h create mode 100644 include/configs/omap3_logic.h diff --git a/MAINTAINERS b/MAINTAINERS index a56ca10..c37bf11 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -41,6 +41,10 @@ Reinhard Arlt reinhard.a...@esd-electronics.com CPCI750 PPC750FX/GX +Peter Barada peter.bar...@logicpd.com + + omap3_logic ARM ARMV7 (Logic OMAP35xx/DM37xx) + Yuli Barcohen y...@arabellasw.com Adder MPC87x/MPC852T diff --git a/board/logicpd/omap3som/Makefile b/board/logicpd/omap3som/Makefile new file mode 100644 index 000..75e237b --- /dev/null +++ b/board/logicpd/omap3som/Makefile @@ -0,0 +1,42 @@ +# +# (C) Copyright 2000, 2001, 2002 +# Wolfgang Denk, DENX Software Engineering, w...@denx.de. +# +# See file CREDITS for list of people who contributed to this +# project. +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, +# MA 02111-1307 USA +# + +include $(TOPDIR)/config.mk + +LIB= $(obj)lib$(BOARD).o + +COBJS-y:= omap3logic.o + +COBJS := $(sort $(COBJS-y)) +SRCS := $(COBJS:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS)) + +$(LIB):$(obj).depend $(OBJS) + $(call cmd_link_o_target, $(OBJS)) + +# + +# defines $(obj).depend target +include $(SRCTREE)/rules.mk + +sinclude $(obj).depend diff --git a/board/logicpd/omap3som/omap3logic.c b/board/logicpd/omap3som/omap3logic.c new file mode 100644 index 000..3a5d3d5 --- /dev/null +++ b/board/logicpd/omap3som/omap3logic.c @@ -0,0 +1,532 @@ +/* + * (C) Copyright 2011 + * Logic Product Development www.logicpd.com + * + * Author : + * Peter Barada peter.bar...@logicpd.com + * + * Derived from Beagle Board and 3430 SDP code by + * Richard Woodruff r-woodru...@ti.com + * Syed Mohammed Khasim kha...@ti.com + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software
[U-Boot] [PATCH] MXS-NAND: Backport ecc.size from linux kernel
The ecc.size for mxs NAND driver is set to 1 in Linux kernel and to 512 in U-Boot, which causes ubi part command malfunction due to wrong subpage size. Signed-off-by: Marek Vasut marek.va...@gmail.com Cc: Wolfgang Denk w...@denx.de Cc: Detlev Zundel d...@denx.de Cc: Stefan Roese s...@denx.de Cc: Scott Wood scottw...@freescale.com Cc: Veli-Pekka Peltola veli-pekka.pelt...@bluegiga.com --- drivers/mtd/nand/mxs_nand.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/mtd/nand/mxs_nand.c b/drivers/mtd/nand/mxs_nand.c index ce2a326..26778ac 100644 --- a/drivers/mtd/nand/mxs_nand.c +++ b/drivers/mtd/nand/mxs_nand.c @@ -1105,7 +1105,7 @@ int board_nand_init(struct nand_chip *nand) nand-ecc.layout= fake_ecc_layout; nand-ecc.mode = NAND_ECC_HW; nand-ecc.bytes = 9; - nand-ecc.size = 512; + nand-ecc.size = 1; return 0; -- 1.7.7.3 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] __mmc_get_env_addr() is not being called?
On Dec 16, 2011, at 3:42 AM, Stefano Babic wrote: On 16/12/2011 10:33, Fabio Estevam wrote: The weak function was introduced by this commit: http://git.denx.de/?p=u-boot.git;a=commitdiff;h=97039ab98c551c7860bc0977d684ef686159e0d7 which breaks non CONFIG_FSL_ESDHC users. Ok, I see - the patch is more related to Freescale SOCs as to the MMC, and it is sometimes unknown who whould pick it up. Andy, not CONFIG_FSL_ESDHC means IMX users - if you do not complain, I merge it into u-boot-imx. Thanks, Stefano If I'm reading the patch correct it will break things (or I'm not sure which patch you're referring to). How would the PPC specific version ever get called? - k ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 02/16] arch/arm/lib/bootm.c: Optionally use existing atags
On Saturday 17 December 2011 12:03:04 Pali Rohár wrote: + s = getenv (atagaddr); no space before the ( #if defined (CONFIG_SETUP_MEMORY_TAGS) || \ defined (CONFIG_CMDLINE_TAG) || \ defined (CONFIG_INITRD_TAG) || \ defined (CONFIG_SERIAL_TAG) || \ defined (CONFIG_REVISION_TAG) ... +#if defined (CONFIG_SETUP_MEMORY_TAGS) || \ +defined (CONFIG_CMDLINE_TAG) || \ +defined (CONFIG_INITRD_TAG) || \ +defined (CONFIG_SERIAL_TAG) || \ +defined (CONFIG_REVISION_TAG) rather than duplicating the same list in multiple places, why not setup a local define in this file and then use that everywhere else. -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 11/16] New command clr: Clear the ANSI terminal
On Saturday 17 December 2011 12:03:13 Pali Rohár wrote: --- /dev/null +++ b/common/cmd_clr.c +int do_clr(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) static + printf(ANSI_CLEAR_CONSOLE); puts() +U_BOOT_CMD( + clr,CONFIG_SYS_MAXARGS, 1, do_clr, + clr, + \n + - clear screen and move cursor to top of screen +); clr is unusual. name it clear instead. that's what all the standard *nix systems use after all. -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 07/16] drivers/video/cfb_console.c: Add function console_swap_colors
On Saturday 17 December 2011 12:03:09 Pali Rohár wrote: --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c +static void console_swap_colors(void) +{ + eorx = fgx; + fgx = bgx; + bgx = eorx; + eorx = fgx ^ bgx; +} there's nothing calling this new func in this patch ... -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 05/16] common/main.c: Fix function readline
On Saturday 17 December 2011 12:03:07 Pali Rohár wrote: * Ignore ANSI escape sequences for moving cursor, which are generated by keyboard you need to line wrap your changelogs -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 08/16] drivers/video/cfb_console.c: Add function console_clear and console_clear_line
On Saturday 17 December 2011 12:03:10 Pali Rohár wrote: --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c +static void console_clear_line(int line, int begin, int end) +{ +#ifdef VIDEO_HW_RECTFILL + video_hw_rectfill(VIDEO_PIXEL_SIZE, /* bytes per pixel */ + VIDEO_FONT_WIDTH * begin, /* dest pos x */ /* FIXME: correct? */ + video_logo_height + CONSOLE_ROW_SIZE * line, /* dest pos y */ /* FIXME: correct? */ +VIDEO_FONT_WIDTH * ( end - begin ), /* frame width */ /* FIXME: correct? */ +VIDEO_FONT_HEIGHT, /* frame height */ + bgx /* fill color */ + ); +#else + int i; + if ( begin == 0 end == CONSOLE_COLS ) + memsetl(CONSOLE_ROW_FIRST + CONSOLE_ROW_SIZE * line,/* offset of row */ + CONSOLE_ROW_SIZE 2, /* length of row */ + bgx /* fill color */ + ); + else + for ( i = 0; i VIDEO_FONT_HEIGHT; ++i ) + memsetl(CONSOLE_ROW_FIRST + CONSOLE_ROW_SIZE * line + /* offset of row */ + VIDEO_FONT_WIDTH * VIDEO_PIXEL_SIZE * begin + /* offset of col */ + i * VIDEO_LINE_LEN, /* col offset of i-th line */ + (VIDEO_FONT_WIDTH * VIDEO_PIXEL_SIZE * ( end - begin + 1)) 2, /* length to end of line */ +bgx /* fill color */ + ); these lines are way too long -- notice how my e-mail client craps everywhere because of it ;). put the comments on their own line, move them all to before the func call, or drop them. -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 09/16] drivers/video/cfb_console.c: Add functions for moving with cursor
On Saturday 17 December 2011 12:03:11 Pali Rohár wrote: * console_cursor_fix - check and fix cursor position (if it is not out of screen) * console_cursor_up, console_cursor_down, console_cursor_left, console_cursor_right and console_cursor_set_position for changing cursor position * console_newline - added param to specify count of creating new lines * console_previewsline - opposite of console_newline you need to line wrap your changelogs -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 10/16] drivers/video/cfb_console.c: Add support for some ANSI terminal escape codes
On Saturday 17 December 2011 12:03:12 Pali Rohár wrote: * This patch add support for cursor move and reverse colors via ANSI espace codes in cfb_console driver * ANSI escape codes can be enabled/disabled via CONFIG_CFB_CONSOLE_ANSI your changelog needs to be line wrapped + case 7: + if ((ansi_buf[i] = 'A' ansi_buf[i] = 'H') || ansi_buf[i] == 'J' || ansi_buf[i] == 'K' || ansi_buf[i] == 'm') { + cchar = ansi_buf[i]; this line is way too long -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] U-Boot on Nokia RX-51 (aka N900)
On Saturday 17 December 2011 11:59:14 Pali Rohár wrote: I'm sending new patch series, which add Nokia RX-51 support to U-Boot. This patches are based on master commit 06e42c6e2ce269667daecd6229d0b7c813838203 and now U-Boot working on Nokia RX-51. please run all your patches through ./tools/checkpatch.pl. you've got a lot of common issues here. -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 13/16] New config variable CONFIG_PREMONITOR
On Saturday 17 December 2011 12:03:15 Pali Rohár wrote: --- a/common/env_common.c +++ b/common/env_common.c +#ifdef CONFIG_PREMONITOR + premonitor= CONFIG_PREMONITOR \0 +#endif --- a/common/main.c +++ b/common/main.c +#ifdef CONFIG_PREMONITOR + if ((s = getenv (premonitor)) != NULL) { i don't these should be the same define. one is to control the default env var value only. i would just drop the check in main.c. +# ifndef CONFIG_SYS_HUSH_PARSER + run_command (s, 0); no space before the ( -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 14/16] New board support: Nokia RX-51 aka N900
On Saturday 17 December 2011 12:03:16 Pali Rohár wrote: --- /dev/null +++ b/board/nokia/rx51/Makefile +clean: + rm -f $(OBJS) + +distclean: clean + rm -f $(LIB) core *.bak $(obj).depend these are unused. delete these targets. this file def needs checkpatch.pl run on it ... many long lines -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 15/16] New command bootmenu: ANSI terminal Boot Menu support
this needs checkpatch for sure seems like this doesn't use the existing common/menu.c code ... shouldn't it ? -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 07/16] drivers/video/cfb_console.c: Add function console_swap_colors
On Sunday 18 December 2011 13:57:40 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:09 Pali Rohár wrote: --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c +static void console_swap_colors(void) +{ + eorx = fgx; + fgx = bgx; + bgx = eorx; + eorx = fgx ^ bgx; +} there's nothing calling this new func in this patch ... -mike This function in needed for ANSI terminal support in Patch 10. -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 15/16] New command bootmenu: ANSI terminal Boot Menu support
On Sunday 18 December 2011 14:07:37 Mike Frysinger wrote: this needs checkpatch for sure seems like this doesn't use the existing common/menu.c code ... shouldn't it ? -mike No my ANSI terminal bootmenu does not use common/menu.c (4 months ago, there was no menu.c file) -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 11/16] New command clr: Clear the ANSI terminal
On Sunday 18 December 2011 13:56:12 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:13 Pali Rohár wrote: --- /dev/null +++ b/common/cmd_clr.c +int do_clr(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) static + printf(ANSI_CLEAR_CONSOLE); puts() puts(s) will output s + '\n'. And we do not want newline after clear screen. +U_BOOT_CMD( + clr,CONFIG_SYS_MAXARGS, 1, do_clr, + clr, + \n + - clear screen and move cursor to top of screen +); clr is unusual. name it clear instead. that's what all the standard *nix systems use after all. -mike ok, I will rename clr to clear. -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 07/16] drivers/video/cfb_console.c: Add function console_swap_colors
On Sunday 18 December 2011 14:00:10 Pali Rohár wrote: On Sunday 18 December 2011 13:57:40 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:09 Pali Rohár wrote: --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c +static void console_swap_colors(void) +{ + eorx = fgx; + fgx = bgx; + bgx = eorx; + eorx = fgx ^ bgx; +} there's nothing calling this new func in this patch ... This function in needed for ANSI terminal support in Patch 10. so squash it into the patch where it actually gets used -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 15/16] New command bootmenu: ANSI terminal Boot Menu support
On Sunday 18 December 2011 14:12:38 Pali Rohár wrote: On Sunday 18 December 2011 14:07:37 Mike Frysinger wrote: this needs checkpatch for sure seems like this doesn't use the existing common/menu.c code ... shouldn't it ? No my ANSI terminal bootmenu does not use common/menu.c (4 months ago, there was no menu.c file) so you'll be updating the patchseries to utilize common code that now exists ? -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 11/16] New command clr: Clear the ANSI terminal
On Sunday 18 December 2011 14:20:35 Pali Rohár wrote: On Sunday 18 December 2011 13:56:12 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:13 Pali Rohár wrote: --- /dev/null +++ b/common/cmd_clr.c +int do_clr(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) static + printf(ANSI_CLEAR_CONSOLE); puts() puts(s) will output s + '\n'. And we do not want newline after clear screen. no it won't. u-boot's puts() is diff from the POSIX puts(). -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 13/16] New config variable CONFIG_PREMONITOR
On Sunday 18 December 2011 14:37:12 Pali Rohár wrote: On Sunday 18 December 2011 14:05:17 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:15 Pali Rohár wrote: --- a/common/env_common.c +++ b/common/env_common.c +#ifdef CONFIG_PREMONITOR + premonitor= CONFIG_PREMONITOR \0 +#endif --- a/common/main.c +++ b/common/main.c +#ifdef CONFIG_PREMONITOR + if ((s = getenv (premonitor)) != NULL) { i don't these should be the same define. one is to control the default env var value only. i would just drop the check in main.c. So do you think that I should delete changes in env_common.c and add to main.c only this code? i mean keep the code in env_common.c, and delete the #ifdef CONFIG_PREMONITOR line from main.c -mike signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 13/16] New config variable CONFIG_PREMONITOR
On Sunday 18 December 2011 14:05:17 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:15 Pali Rohár wrote: --- a/common/env_common.c +++ b/common/env_common.c +#ifdef CONFIG_PREMONITOR + premonitor= CONFIG_PREMONITOR \0 +#endif --- a/common/main.c +++ b/common/main.c +#ifdef CONFIG_PREMONITOR + if ((s = getenv (premonitor)) != NULL) { i don't these should be the same define. one is to control the default env var value only. i would just drop the check in main.c. +# ifndef CONFIG_SYS_HUSH_PARSER + run_command (s, 0); no space before the ( -mike So do you think that I should delete changes in env_common.c and add to main.c only this code? +#ifdef CONFIG_PREMONITOR + run_command2(CONFIG_PREMONITOR, 0); +#endif -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] U-Boot on Nokia RX-51 (aka N900)
On Sunday 18 December 2011 14:01:54 Mike Frysinger wrote: On Saturday 17 December 2011 11:59:14 Pali Rohár wrote: I'm sending new patch series, which add Nokia RX-51 support to U-Boot. This patches are based on master commit 06e42c6e2ce269667daecd6229d0b7c813838203 and now U-Boot working on Nokia RX-51. please run all your patches through ./tools/checkpatch.pl. you've got a lot of common issues here. -mike Ok, I will fix all problems detected by checkpatch.pl -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 02/16] arch/arm/lib/bootm.c: Optionally use existing atags
On Sunday 18 December 2011 13:54:21 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:04 Pali Rohár wrote: + s = getenv (atagaddr); no space before the ( #if defined (CONFIG_SETUP_MEMORY_TAGS) || \ defined (CONFIG_CMDLINE_TAG) || \ defined (CONFIG_INITRD_TAG) || \ defined (CONFIG_SERIAL_TAG) || \ defined (CONFIG_REVISION_TAG) ... +#if defined (CONFIG_SETUP_MEMORY_TAGS) || \ +defined (CONFIG_CMDLINE_TAG) || \ +defined (CONFIG_INITRD_TAG) || \ +defined (CONFIG_SERIAL_TAG) || \ +defined (CONFIG_REVISION_TAG) rather than duplicating the same list in multiple places, why not setup a local define in this file and then use that everywhere else. -mike I will add local define CONFIG_ANY_TAG to bootm.c +#if defined (CONFIG_SETUP_MEMORY_TAGS) || \ +defined (CONFIG_CMDLINE_TAG) || \ +defined (CONFIG_INITRD_TAG) || \ +defined (CONFIG_SERIAL_TAG) || \ +defined (CONFIG_REVISION_TAG) +#define CONFIG_ANY_TAG +#endif -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 05/16] common/main.c: Fix function readline
On Sunday 18 December 2011 13:58:30 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:07 Pali Rohár wrote: * Ignore ANSI escape sequences for moving cursor, which are generated by keyboard you need to line wrap your changelogs -mike I will fix all commit messages. -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 13/16] New config variable CONFIG_PREMONITOR
On Sunday 18 December 2011 15:08:30 Mike Frysinger wrote: On Sunday 18 December 2011 14:37:12 Pali Rohár wrote: On Sunday 18 December 2011 14:05:17 Mike Frysinger wrote: On Saturday 17 December 2011 12:03:15 Pali Rohár wrote: --- a/common/env_common.c +++ b/common/env_common.c +#ifdef CONFIG_PREMONITOR + premonitor= CONFIG_PREMONITOR \0 +#endif --- a/common/main.c +++ b/common/main.c +#ifdef CONFIG_PREMONITOR + if ((s = getenv (premonitor)) != NULL) { i don't these should be the same define. one is to control the default env var value only. i would just drop the check in main.c. So do you think that I should delete changes in env_common.c and add to main.c only this code? i mean keep the code in env_common.c, and delete the #ifdef CONFIG_PREMONITOR line from main.c -mike Ok. -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 15/16] New command bootmenu: ANSI terminal Boot Menu support
On Sunday 18 December 2011 15:07:25 Mike Frysinger wrote: On Sunday 18 December 2011 14:12:38 Pali Rohár wrote: On Sunday 18 December 2011 14:07:37 Mike Frysinger wrote: this needs checkpatch for sure seems like this doesn't use the existing common/menu.c code ... shouldn't it ? No my ANSI terminal bootmenu does not use common/menu.c (4 months ago, there was no menu.c file) so you'll be updating the patchseries to utilize common code that now exists ? -mike What is implemented in that file common/menu.c? It here any info/doc? -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v3] U-Boot on Nokia RX-51 (aka N900)
Hello, I'm sending third version of rx51 patches for u-boot. All patches was checked by checkpatch.pl and no error or warning was appeared. Last 2 patches (0014 and 0015) adding ANSI terminal bootmenu support for rx51 and can be reviewed separatly (patches 0001-0013 adding nokia rx51 board support and working without that last two). -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 01/15] arch/arm/cpu/armv7/omap3/lowlevel_init.S: save_boot_params
* Hide function save_boot_params if CONFIG_SPL_BUILD is not defined (function do nothing) * Same behaviour as in file arch/arm/cpu/armv7/omap4/lowlevel_init.S * This allow to implement board specified function save_boot_params in board code Signed-off-by: Pali Rohár pali.ro...@gmail.com --- arch/arm/cpu/armv7/omap3/lowlevel_init.S |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/cpu/armv7/omap3/lowlevel_init.S b/arch/arm/cpu/armv7/omap3/lowlevel_init.S index 2f6930b..c42c5dd 100644 --- a/arch/arm/cpu/armv7/omap3/lowlevel_init.S +++ b/arch/arm/cpu/armv7/omap3/lowlevel_init.S @@ -35,15 +35,15 @@ _TEXT_BASE: .word CONFIG_SYS_TEXT_BASE/* sdram load addr from config.mk */ +#ifdef CONFIG_SPL_BUILD .global save_boot_params save_boot_params: -#ifdef CONFIG_SPL_BUILD ldr r4, =omap3_boot_device ldr r5, [r0, #0x4] and r5, r5, #0xff str r5, [r4] -#endif bx lr +#endif .global omap3_gp_romcode_call omap3_gp_romcode_call: -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 02/15] arch/arm/lib/bootm.c: Optionally use existing atags
This patch adapts the bootm command so that it can use an existing atags command set up by a previous bootloader. If the environment variable atagaddr is unset, bootm behaves as normal. If atagaddr is set, bootm will use atags address from environment variable and also append new boot args (if specified in u-boot). For example, if a previous boot loader already set up the atags struct at 0x8100: setenv atagaddr 0x8100; bootm 0x80008000 Signed-off-by: Pali Rohár pali.ro...@gmail.com --- README |2 ++ arch/arm/lib/bootm.c | 37 ++--- 2 files changed, 32 insertions(+), 7 deletions(-) diff --git a/README b/README index ff72e47..3dd5a97 100644 --- a/README +++ b/README @@ -3564,6 +3564,8 @@ Some configuration options can be set using Environment Variables. List of environment variables (most likely not complete): + atagaddr - bootm will use ATAGs struct from specified address (arm only) + baudrate - see CONFIG_BAUDRATE bootdelay- see CONFIG_BOOTDELAY diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c index 802e833..1d76774 100644 --- a/arch/arm/lib/bootm.c +++ b/arch/arm/lib/bootm.c @@ -93,6 +93,14 @@ static void announce_and_cleanup(void) cleanup_before_linux(); } +#if defined(CONFIG_SETUP_MEMORY_TAGS) || \ +defined(CONFIG_CMDLINE_TAG) || \ +defined(CONFIG_INITRD_TAG) || \ +defined(CONFIG_SERIAL_TAG) || \ +defined(CONFIG_REVISION_TAG) +#define CONFIG_SETUP_ANY_TAG +#endif + int do_bootm_linux(int flag, int argc, char *argv[], bootm_headers_t *images) { bd_t*bd = gd-bd; @@ -125,12 +133,20 @@ int do_bootm_linux(int flag, int argc, char *argv[], bootm_headers_t *images) debug (## Transferring control to Linux (at address %08lx) ...\n, (ulong) kernel_entry); -#if defined (CONFIG_SETUP_MEMORY_TAGS) || \ -defined (CONFIG_CMDLINE_TAG) || \ -defined (CONFIG_INITRD_TAG) || \ -defined (CONFIG_SERIAL_TAG) || \ -defined (CONFIG_REVISION_TAG) - setup_start_tag (bd); + s = getenv(atagaddr); + if (s) { + bd-bi_boot_params = simple_strtoul(s, NULL, 16); + printf(Using existing atags at %#x\n, bd-bi_boot_params); + + params = (struct tag *) bd-bi_boot_params; + while (params-hdr.size 0) + params = tag_next(params); + } else { +#ifdef CONFIG_SETUP_ANY_TAG + setup_start_tag(bd); +#endif + } + #ifdef CONFIG_SERIAL_TAG setup_serial_tag (params); #endif @@ -147,8 +163,15 @@ int do_bootm_linux(int flag, int argc, char *argv[], bootm_headers_t *images) if (images-rd_start images-rd_end) setup_initrd_tag (bd, images-rd_start, images-rd_end); #endif - setup_end_tag(bd); + + if (s) { + if (params-hdr.size 0) + setup_end_tag(bd); + } else { +#ifdef CONFIG_SETUP_ANY_TAG + setup_end_tag(bd); #endif + } announce_and_cleanup(); -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 03/15] include/twl4030.h: Add power bus message definitions
* Code copied from linux kernel 3.0.0 from file include/linux/i2c/twl.h Signed-off-by: Pali Rohár pali.ro...@gmail.com --- include/twl4030.h | 98 + 1 files changed, 98 insertions(+), 0 deletions(-) diff --git a/include/twl4030.h b/include/twl4030.h index 9cd32ab..0c17f59 100644 --- a/include/twl4030.h +++ b/include/twl4030.h @@ -151,6 +151,103 @@ #define TWL4030_PM_MASTER_SW_EVENTS_DEVSLP (1 1) #define TWL4030_PM_MASTER_SW_EVENTS_DEVOFF (1 0) +/* Power bus message definitions */ + +/* The TWL4030/5030 splits its power-management resources (the various + * regulators, clock and reset lines) into 3 processor groups - P1, P2 and + * P3. These groups can then be configured to transition between sleep, wait-on + * and active states by sending messages to the power bus. See Section 5.4.2 + * Power Resources of TWL4030 TRM + */ + +/* Processor groups */ +#define DEV_GRP_NULL 0x0 +#define DEV_GRP_P1 0x1 /* P1: all OMAP devices */ +#define DEV_GRP_P2 0x2 /* P2: all Modem devices */ +#define DEV_GRP_P3 0x4 /* P3: all peripheral devices */ + +/* Resource groups */ +#define RES_GRP_RES0x0 /* Reserved */ +#define RES_GRP_PP 0x1 /* Power providers */ +#define RES_GRP_RC 0x2 /* Reset and control */ +#define RES_GRP_PP_RC 0x3 +#define RES_GRP_PR 0x4 /* Power references */ +#define RES_GRP_PP_PR 0x5 +#define RES_GRP_RC_PR 0x6 +#define RES_GRP_ALL0x7 /* All resource groups */ + +#define RES_TYPE2_R0 0x0 + +#define RES_TYPE_ALL 0x7 + +/* Resource states */ +#define RES_STATE_WRST 0xF +#define RES_STATE_ACTIVE 0xE +#define RES_STATE_SLEEP0x8 +#define RES_STATE_OFF 0x0 + +/* Power resources */ + +/* Power providers */ +#define RES_VAUX1 1 +#define RES_VAUX2 2 +#define RES_VAUX3 3 +#define RES_VAUX4 4 +#define RES_VMMC1 5 +#define RES_VMMC2 6 +#define RES_VPLL1 7 +#define RES_VPLL2 8 +#define RES_VSIM9 +#define RES_VDAC10 +#define RES_VINTANA111 +#define RES_VINTANA212 +#define RES_VINTDIG 13 +#define RES_VIO 14 +#define RES_VDD115 +#define RES_VDD216 +#define RES_VUSB_1V517 +#define RES_VUSB_1V818 +#define RES_VUSB_3V119 +#define RES_VUSBCP 20 +#define RES_REGEN 21 +/* Reset and control */ +#define RES_NRES_PWRON 22 +#define RES_CLKEN 23 +#define RES_SYSEN 24 +#define RES_HFCLKOUT25 +#define RES_32KCLKOUT 26 +#define RES_RESET 27 +/* Power Reference */ +#define RES_Main_Ref28 + +#define TOTAL_RESOURCES28 +/* + * Power Bus Message Format ... these can be sent individually by Linux, + * but are usually part of downloaded scripts that are run when various + * power events are triggered. + * + * Broadcast Message (16 Bits): + *DEV_GRP[15:13] MT[12] RES_GRP[11:9] RES_TYPE2[8:7] RES_TYPE[6:4] + *RES_STATE[3:0] + * + * Singular Message (16 Bits): + *DEV_GRP[15:13] MT[12] RES_ID[11:4] RES_STATE[3:0] + */ + +#define MSG_BROADCAST(devgrp, grp, type, type2, state) \ + ((devgrp) 13 | 1 12 | (grp) 9 | (type2) 7 \ + | (type) 4 | (state)) + +#define MSG_SINGULAR(devgrp, id, state) \ + ((devgrp) 13 | 0 12 | (id) 4 | (state)) + +#define MSG_BROADCAST_ALL(devgrp, state) \ + ((devgrp) 5 | (state)) + +#define MSG_BROADCAST_REF MSG_BROADCAST_ALL +#define MSG_BROADCAST_PROV MSG_BROADCAST_ALL +#define MSG_BROADCAST__CLK_RST MSG_BROADCAST_ALL + /* Power Managment Receiver */ #define TWL4030_PM_RECEIVER_SC_CONFIG 0x5B #define TWL4030_PM_RECEIVER_SC_DETECT1 0x5C @@ -311,6 +408,7 @@ #define TWL4030_PM_RECEIVER_VDAC_VSEL_18 0x03 #define TWL4030_PM_RECEIVER_VMMC1_VSEL_30 0x02 #define TWL4030_PM_RECEIVER_VMMC1_VSEL_32 0x03 +#define TWL4030_PM_RECEIVER_VSIM_VSEL_18 0x03 /* Device Selection in PM Receiver Module */ #define TWL4030_PM_RECEIVER_DEV_GRP_P1 0x20 -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 04/15] include/common.h: Add some ANSI escape codes definitions
Signed-off-by: Pali Rohár pali.ro...@gmail.com --- include/common.h | 20 1 files changed, 20 insertions(+), 0 deletions(-) diff --git a/include/common.h b/include/common.h index 5cfdd76..640d15c 100644 --- a/include/common.h +++ b/include/common.h @@ -760,6 +760,26 @@ void clear_ctrlc (void); /* clear the Control-C condition */ intdisable_ctrlc (int);/* 1 to disable, 0 to enable Control-C detect */ /* + * ANSI terminal + */ + +#define ANSI_CURSOR_UP \e[%dA +#define ANSI_CURSOR_DOWN \e[%dB +#define ANSI_CURSOR_FORWARD\e[%dC +#define ANSI_CURSOR_BACK \e[%dD +#define ANSI_CURSOR_NEXTLINE \e[%dE +#define ANSI_CURSOR_PREVIOUSLINE \e[%dF +#define ANSI_CURSOR_COLUMN \e[%dG +#define ANSI_CURSOR_POSITION \e[%d;%dH +#define ANSI_CURSOR_SHOW \e[?25h +#define ANSI_CURSOR_HIDE \e[?25l +#define ANSI_CLEAR_CONSOLE \e[2J +#define ANSI_CLEAR_LINE_TO_END \e[0K +#define ANSI_CLEAR_LINE\e[2K +#define ANSI_COLOR_RESET \e[0m +#define ANSI_COLOR_REVERSE \e[7m + +/* * STDIO based functions (can always be used) */ /* serial stuff */ -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 06/15] drivers/video/cfb_console.c: Fix function console_scrollup
* Use correct buffer size, do not damage screen output Signed-off-by: Pali Rohár pali.ro...@gmail.com --- drivers/video/cfb_console.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c index 904caf7..9092399 100644 --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c @@ -701,7 +701,7 @@ static void console_scrollup(void) ); #else memcpyl(CONSOLE_ROW_FIRST, CONSOLE_ROW_SECOND, - CONSOLE_SCROLL_SIZE 2); + CONSOLE_SCROLL_SIZE); #endif /* clear the last one */ -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 05/15] common/main.c: Fix function readline
* Ignore ANSI escape codes for moving cursor, which are generated by keyboard Signed-off-by: Pali Rohár pali.ro...@gmail.com --- common/main.c | 51 +++ 1 files changed, 51 insertions(+), 0 deletions(-) diff --git a/common/main.c b/common/main.c index e96c95a..e7b5516 100644 --- a/common/main.c +++ b/common/main.c @@ -958,6 +958,7 @@ int readline_into_buffer (const char *const prompt, char * buffer) int n = 0; /* buffer index */ int plen = 0; /* prompt length*/ int col;/* output column cnt*/ + int esc = 0;/* ansi escape char */ charc; /* print prompt */ @@ -1024,7 +1025,57 @@ int readline_into_buffer (const char *const prompt, char * buffer) p=delete_char(p_buf, p, col, n, plen); continue; + case '\e': /* ANSI escape char */ + esc = 1; + continue; + default: + + /* +* Check for ANSI escape chars +*/ + if (esc == 0 c == '\e') { + esc = 1; + continue; + } else if (esc == 1) { + if (c == '[') { + esc = 2; + continue; + } + if (n CONFIG_SYS_CBSIZE-2) { + ++n; + *p++ = '\e'; + putc('\e'); + } + esc = 0; + } else if (esc == 2 || esc == 3) { + if (esc == 2 c == '1') { + esc = 3; + continue; + } + /* Ignore ANSI escape sequences */ + /* generated by keyboard */ + /* \e [ 1 A-D and \e [ A-D */ + if (c = 'A' c = 'D') { + esc = 0; + continue; + } + if (esc == 2 n CONFIG_SYS_CBSIZE-3) { + n += 2; + *p++ = '\e'; + *p++ = '['; + puts(\e[); + } else if (esc == 3 + n CONFIG_SYS_CBSIZE-4) { + n += 3; + *p++ = '\e'; + *p++ = '['; + *p++ = '1'; + puts(\e[1); + } + esc = 0; + } + /* * Must be a normal character then */ -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 08/15] drivers/video/cfb_console.c: Add functions for moving with cursor
* console_cursor_fix - fix cursor position (check for out of screen) * console_cursor_up, console_cursor_down, console_cursor_left, console_cursor_right, console_cursor_set_position for change cursor position * console_newline - added param to specify count of creating new lines * console_previewsline - opposite of console_newline Signed-off-by: Pali Rohár pali.ro...@gmail.com --- drivers/video/cfb_console.c | 64 +++ 1 files changed, 58 insertions(+), 6 deletions(-) diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c index b74d6d0..3823eae 100644 --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c @@ -773,9 +773,54 @@ static void console_back(void) CURSOR_SET; } -static void console_newline(void) +static void console_cursor_fix(void) { - console_row++; + if (console_row 0) + console_row = 0; + if (console_row = CONSOLE_ROWS) + console_row = CONSOLE_ROWS-1; + if (console_col 0) + console_col = 0; + if (console_col = CONSOLE_COLS) + console_col = CONSOLE_COLS-1; +} + +static void console_cursor_up(int n) +{ + console_row -= n; + console_cursor_fix(); +} + +static void console_cursor_down(int n) +{ + console_row += n; + console_cursor_fix(); +} + +static void console_cursor_left(int n) +{ + console_col -= n; + console_cursor_fix(); +} + +static void console_cursor_right(int n) +{ + console_col += n; + console_cursor_fix(); +} + +static void console_cursor_set_position(int row, int col) +{ + if (console_row != -1) + console_row = row; + if (console_col != -1) + console_col = col; + console_cursor_fix(); +} + +static void console_newline(int n) +{ + console_row += n; console_col = 0; /* Check if we need to scroll the terminal */ @@ -784,10 +829,17 @@ static void console_newline(void) console_scrollup(); /* Decrement row number */ - console_row--; + console_row = CONSOLE_ROWS-1; } } +static void console_previewsline(int n) +{ + /* FIXME: also scroll terminal ? */ + console_row -= n; + console_cursor_fix(); +} + static void console_cr(void) { console_col = 0; @@ -806,7 +858,7 @@ void video_putc(const char c) case '\n': /* next line */ if (console_col || (!console_col nl)) - console_newline(); + console_newline(1); nl = 1; break; @@ -815,7 +867,7 @@ void video_putc(const char c) console_col = ~0x0007; if (console_col = CONSOLE_COLS) - console_newline(); + console_newline(1); break; case 8: /* backspace */ @@ -829,7 +881,7 @@ void video_putc(const char c) /* check for newline */ if (console_col = CONSOLE_COLS) { - console_newline(); + console_newline(1); nl = 0; } } -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 07/15] drivers/video/cfb_console.c: Add function console_clear and console_clear_line
* console_clear - clear full console framebuffer output * console_clear_line - clear part of specified line (or full) Signed-off-by: Pali Rohár pali.ro...@gmail.com --- drivers/video/cfb_console.c | 64 +++ 1 files changed, 52 insertions(+), 12 deletions(-) diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c index 9092399..b74d6d0 100644 --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c @@ -683,6 +683,57 @@ static void memcpyl(int *d, int *s, int c) } #endif +static void console_clear(void) +{ +#ifdef VIDEO_HW_RECTFILL + video_hw_rectfill(VIDEO_PIXEL_SIZE, /* bytes per pixel */ + 0,/* dest pos x */ + video_logo_height,/* dest pos y */ + VIDEO_VISIBLE_COLS, /* frame width */ + VIDEO_VISIBLE_ROWS, /* frame height */ + bgx /* fill color */ + ); +#else + memsetl(CONSOLE_ROW_FIRST, CONSOLE_SIZE, bgx); +#endif +} + +static void console_clear_line(int line, int begin, int end) +{ +#ifdef VIDEO_HW_RECTFILL + video_hw_rectfill(VIDEO_PIXEL_SIZE, /* bytes per pixel */ + /* FIXME: correct? */ + VIDEO_FONT_WIDTH * begin, /* dest pos x */ + /* FIXME: correct? */ + video_logo_height + + CONSOLE_ROW_SIZE * line, /* dest pos y */ + /* FIXME: correct? */ + VIDEO_FONT_WIDTH * (end - begin), /* frame width */ + VIDEO_FONT_HEIGHT,/* frame height */ + bgx /* fill color */ + ); +#else + int i; + if (begin == 0 end == CONSOLE_COLS) + memsetl(CONSOLE_ROW_FIRST + + CONSOLE_ROW_SIZE * line,/* offset of row */ + CONSOLE_ROW_SIZE 2, /* length of row */ + bgx /* fill color */ + ); + else + for (i = 0; i VIDEO_FONT_HEIGHT; ++i) + memsetl(CONSOLE_ROW_FIRST + + CONSOLE_ROW_SIZE * line + /* offset of row */ + VIDEO_FONT_WIDTH * + VIDEO_PIXEL_SIZE * begin + /* offset of col */ + i * VIDEO_LINE_LEN, /* col offset of i line */ + (VIDEO_FONT_WIDTH * VIDEO_PIXEL_SIZE * + (end - begin + 1)) 2, /* length to end */ + bgx /* fill color */ + ); +#endif +} + static void console_scrollup(void) { /* copy up rows ignoring the first one */ @@ -705,18 +756,7 @@ static void console_scrollup(void) #endif /* clear the last one */ -#ifdef VIDEO_HW_RECTFILL - video_hw_rectfill(VIDEO_PIXEL_SIZE, /* bytes per pixel */ - 0,/* dest pos x */ - VIDEO_VISIBLE_ROWS - - VIDEO_FONT_HEIGHT, /* dest pos y */ - VIDEO_VISIBLE_COLS, /* frame width */ - VIDEO_FONT_HEIGHT,/* frame height */ - CONSOLE_BG_COL/* fill color */ - ); -#else - memsetl(CONSOLE_ROW_LAST, CONSOLE_ROW_SIZE 2, CONSOLE_BG_COL); -#endif + console_clear_line(CONSOLE_ROWS-1, 0, CONSOLE_COLS); } static void console_back(void) -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 09/15] drivers/video/cfb_console.c: Add support for some ANSI terminal escape codes
* This patch add support for move cursor and reverse colors via ANSI espace codes in cfb_console driver * ANSI escape codes can be enabled/disabled via CONFIG_CFB_CONSOLE_ANSI Signed-off-by: Pali Rohár pali.ro...@gmail.com --- drivers/video/cfb_console.c | 216 ++- 1 files changed, 215 insertions(+), 1 deletions(-) diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c index 3823eae..dc8d99b 100644 --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c @@ -377,6 +377,10 @@ static int console_row;/* cursor row */ static u32 eorx, fgx, bgx; /* color pats */ +static char ansi_buf[10] = { 0, }; +static int ansi_buf_size; +static int ansi_colors_need_revert; + static const int video_font_draw_table8[] = { 0x, 0x00ff, 0xff00, 0x, 0x00ff, 0x00ff00ff, 0x0000, 0x00ff, @@ -602,6 +606,14 @@ static void video_putchar(int xx, int yy, unsigned char c) video_drawchars(xx, yy + video_logo_height, c, 1); } +static void console_swap_colors(void) +{ + eorx = fgx; + fgx = bgx; + bgx = eorx; + eorx = fgx ^ bgx; +} + #if defined(CONFIG_CONSOLE_CURSOR) || defined(CONFIG_VIDEO_SW_CURSOR) static void video_set_cursor(void) { @@ -845,7 +857,7 @@ static void console_cr(void) console_col = 0; } -void video_putc(const char c) +static void parse_putc(const char c) { static int nl = 1; @@ -888,6 +900,208 @@ void video_putc(const char c) CURSOR_SET; } +void video_putc(const char c) +{ +#ifdef CONFIG_CFB_CONSOLE_ANSI + int i; + + if (c == 27) { + for (i = 0; i ansi_buf_size; ++i) + parse_putc(ansi_buf[i]); + ansi_buf[0] = 27; + ansi_buf_size = 1; + return; + } + + if (ansi_buf_size 0) { + /* + 0 - ESC + 1 - [ + 2 - num1 + 3 - .. + 4 - ; + 5 - num2 + 6 - .. + 7 - cchar + */ + int next = 0; + + int flush = 0; + int fail = 0; + + int num1 = 0; + int num2 = 0; + int cchar = 0; + + ansi_buf[ansi_buf_size++] = c; + + if (ansi_buf_size = sizeof(ansi_buf)) + fail = 1; + + for (i = 0; i ansi_buf_size; ++i) { + if (fail) + break; + + switch (next) { + case 0: + if (ansi_buf[i] == 27) + next = 1; + else + fail = 1; + break; + + case 1: + if (ansi_buf[i] == '[') + next = 2; + else + fail = 1; + break; + + case 2: + if (ansi_buf[i] = '0' ansi_buf[i] = '9') { + num1 = ansi_buf[i]-'0'; + next = 3; + } else { + --i; + num1 = 1; + next = 4; + } + break; + + case 3: + if (ansi_buf[i] = '0' ansi_buf[i] = '9') { + num1 *= 10; + num1 += ansi_buf[i]-'0'; + } else { + --i; + next = 4; + } + break; + + case 4: + if (ansi_buf[i] != ';') { + --i; + next = 7; + } else + next = 5; + break; + + case 5: + if (ansi_buf[i] = '0' ansi_buf[i] = '9') { + num2 = ansi_buf[i]-'0'; + next = 6; + } else + fail = 1; + break; + + case 6: + if (ansi_buf[i] = '0' ansi_buf[i] = '9') { + num2 *= 10; + num2 += ansi_buf[i]-'0'; +
[U-Boot] [PATCH 10/15] New command clear: Clear the ANSI terminal
* Command can be enabled by CONFIG_CMD_CLEAR Signed-off-by: Pali Rohár pali.ro...@gmail.com Cc: Marcel Mol mar...@mesa.nl --- common/Makefile |1 + common/cmd_clear.c | 42 ++ include/config_cmd_all.h |1 + 3 files changed, 44 insertions(+), 0 deletions(-) create mode 100644 common/cmd_clear.c diff --git a/common/Makefile b/common/Makefile index 2d9ae8c..e1efd45 100644 --- a/common/Makefile +++ b/common/Makefile @@ -69,6 +69,7 @@ COBJS-$(CONFIG_CMD_BEDBUG) += bedbug.o cmd_bedbug.o COBJS-$(CONFIG_CMD_BMP) += cmd_bmp.o COBJS-$(CONFIG_CMD_BOOTLDR) += cmd_bootldr.o COBJS-$(CONFIG_CMD_CACHE) += cmd_cache.o +COBJS-$(CONFIG_CMD_CLEAR) += cmd_clear.o COBJS-$(CONFIG_CMD_CONSOLE) += cmd_console.o COBJS-$(CONFIG_CMD_CPLBINFO) += cmd_cplbinfo.o COBJS-$(CONFIG_DATAFLASH_MMC_SELECT) += cmd_dataflash_mmc_mux.o diff --git a/common/cmd_clear.c b/common/cmd_clear.c new file mode 100644 index 000..597611e --- /dev/null +++ b/common/cmd_clear.c @@ -0,0 +1,42 @@ +/* + * Copyright 2011 + * Marcel Mol, MESA Consulting, mar...@mesa.nl + * + * Copyright 2011 + * Pali Rohár, pali.ro...@gmail.com + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, + * MA 02111-1307 USA + */ + +#include common.h +#include command.h + +static int do_clear(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) +{ + puts(ANSI_CLEAR_CONSOLE); + printf(ANSI_CURSOR_POSITION, 1, 1); + return 0; +} + +U_BOOT_CMD( + clear,CONFIG_SYS_MAXARGS, 1, do_clear, + clear, + \n + - clear screen and move cursor to top of screen +); diff --git a/include/config_cmd_all.h b/include/config_cmd_all.h index 9716f9c..3f25eba 100644 --- a/include/config_cmd_all.h +++ b/include/config_cmd_all.h @@ -23,6 +23,7 @@ #define CONFIG_CMD_BSP /* Board Specific functions */ #define CONFIG_CMD_CACHE /* icache, dcache */ #define CONFIG_CMD_CDP /* Cisco Discovery Protocol */ +#define CONFIG_CMD_CLEAR /* ANSI clear screen command*/ #define CONFIG_CMD_CONSOLE /* coninfo */ #define CONFIG_CMD_DATE/* support for RTC, date/time...*/ #define CONFIG_CMD_DHCP/* DHCP Support */ -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 11/15] New config variable CONFIG_MENUCMD
* If not defined CONFIG_MENUCMD do nothing * If CONFIG_MENUKEY is 0 and was pressed any key run env menu_cmd * If pressed key was CONFIG_MENUKEY run env menu_cmd * If CONFIG_MENUKEY is not defined run env menu_cmd always * CONFIG_MENUKEY working if defined CONFIG_MENUCMD and CONFIG_BOOTDELAY = 0 Signed-off-by: Pali Rohár pali.ro...@gmail.com --- common/main.c | 34 +++--- 1 files changed, 23 insertions(+), 11 deletions(-) diff --git a/common/main.c b/common/main.c index e7b5516..503d6c4 100644 --- a/common/main.c +++ b/common/main.c @@ -82,6 +82,20 @@ int do_mdm_init = 0; extern void mdm_init(void); /* defined in board.c */ #endif +#if defined(CONFIG_MENUKEY) !defined(CONFIG_MENUCMD) \ +(!defined(CONFIG_BOOTDELAY) || CONFIG_BOOTDELAY 0) +#error CONFIG_MENUKEY defined, but not CONFIG_MENUCMD or CONFIG_BOOTDELAY = 0 +#error define CONFIG_MENUCMD and CONFIG_BOOTDELAY too +#endif + +#ifdef CONFIG_MENUCMD +# ifdef CONFIG_MENUKEY +static int menucmd; +# else +static int menucmd = 1; +# endif +#endif + /*** * Watch for 'delay' seconds for autoboot stop or autoboot delay string. * returns: 0 - no key string, allow autoboot 1 - got key string, abort @@ -201,10 +215,6 @@ int abortboot(int bootdelay) # else /* !defined(CONFIG_AUTOBOOT_KEYED) */ -#ifdef CONFIG_MENUKEY -static int menukey = 0; -#endif - #ifndef CONFIG_MENU static inline #endif @@ -241,8 +251,10 @@ int abortboot(int bootdelay) if (tstc()) { /* we got a key press */ abort = 1; /* don't auto boot */ bootdelay = 0; /* no more delay*/ -# ifdef CONFIG_MENUKEY - menukey = getc(); +# if defined(CONFIG_MENUCMD) defined(CONFIG_MENUKEY) + if (CONFIG_MENUKEY == 0 || + CONFIG_MENUKEY == getc()) + menucmd = 1; # else (void) getc(); /* consume input*/ # endif @@ -292,6 +304,7 @@ int run_command2(const char *cmd, int flag) void main_loop (void) { + char *s; #ifndef CONFIG_SYS_HUSH_PARSER static char lastcommand[CONFIG_SYS_CBSIZE] = { 0, }; int len; @@ -300,7 +313,6 @@ void main_loop (void) #endif #if defined(CONFIG_BOOTDELAY) (CONFIG_BOOTDELAY = 0) - char *s; int bootdelay; #endif #ifdef CONFIG_PREBOOT @@ -405,15 +417,15 @@ void main_loop (void) disable_ctrlc(prev);/* restore Control C checking */ # endif } +#endif /* CONFIG_BOOTDELAY */ -# ifdef CONFIG_MENUKEY - if (menukey == CONFIG_MENUKEY) { +#ifdef CONFIG_MENUCMD + if (menucmd == 1) { s = getenv(menucmd); if (s) run_command2(s, 0); } -#endif /* CONFIG_MENUKEY */ -#endif /* CONFIG_BOOTDELAY */ +#endif /* * Main Loop for Monitor Command Processing -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 12/15] New config variable CONFIG_PREMONITOR
* if defined run env premonitor before Main Loop for Monitor Processing Signed-off-by: Pali Rohár pali.ro...@gmail.com --- common/env_common.c |3 +++ common/main.c |4 2 files changed, 7 insertions(+), 0 deletions(-) diff --git a/common/env_common.c b/common/env_common.c index 8a71096..1ef8ecc 100644 --- a/common/env_common.c +++ b/common/env_common.c @@ -92,6 +92,9 @@ const uchar default_environment[] = { #ifdef CONFIG_PREBOOT preboot= CONFIG_PREBOOT \0 #endif +#ifdef CONFIG_PREMONITOR + premonitor= CONFIG_PREMONITOR \0 +#endif #ifdef CONFIG_ROOTPATH rootpath= CONFIG_ROOTPATH \0 #endif diff --git a/common/main.c b/common/main.c index 503d6c4..e0c262c 100644 --- a/common/main.c +++ b/common/main.c @@ -427,6 +427,10 @@ void main_loop (void) } #endif + s = getenv(premonitor); + if (s) + run_command2(s, 0); + /* * Main Loop for Monitor Command Processing */ -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 14/15] New command bootmenu: ANSI terminal Boot Menu support
* Configuration is done via env variables bootmenu_delay and bootmenu_num: bootmenu_delay=delay bootmenu_num=title=commands (title and commands are separated by first char '=') delay is delay in seconds of autobooting first entry num is boot menu entry, starting from zero title is text shown in boot screen commands are commands which will be executed when menu entry is selected * First argument of bootmenu command override bootmenu_delay env * If env bootmenu_delay or bootmenu arg is not specified, delay is 10 seconds * If delay is 0, no entry will be shown on screen and first will be called * If delay is less then 0, no autoboot delay will be used * Boot Menu will stop finding next menu entry if last was not defined * Boot Menu always add menu entry U-Boot console at end of all entries * Example using: setenv bootmenu_0 Boot 1. kernel=bootm 0x8200 # Set first menu entry setenv bootmenu_1 Boot 2. kernel=bootm 0x8300 # Set second menu entry setenv bootmenu_2 Reset board=reset# Set third menu entry setenv bootmenu_3 U-Boot boot order=boot # Set fourth menu entry setenv bootmenu_4 # Empty string is end of all bootmenu entries bootmenu 20# Run bootmenu with autoboot delay 20s Signed-off-by: Pali Rohár pali.ro...@gmail.com --- common/Makefile |1 + common/cmd_bootmenu.c| 366 ++ include/config_cmd_all.h |1 + 3 files changed, 368 insertions(+), 0 deletions(-) create mode 100644 common/cmd_bootmenu.c diff --git a/common/Makefile b/common/Makefile index e1efd45..7402bfb 100644 --- a/common/Makefile +++ b/common/Makefile @@ -67,6 +67,7 @@ COBJS-$(CONFIG_CMD_SOURCE) += cmd_source.o COBJS-$(CONFIG_CMD_BDI) += cmd_bdinfo.o COBJS-$(CONFIG_CMD_BEDBUG) += bedbug.o cmd_bedbug.o COBJS-$(CONFIG_CMD_BMP) += cmd_bmp.o +COBJS-$(CONFIG_CMD_BOOTMENU) += cmd_bootmenu.o COBJS-$(CONFIG_CMD_BOOTLDR) += cmd_bootldr.o COBJS-$(CONFIG_CMD_CACHE) += cmd_cache.o COBJS-$(CONFIG_CMD_CLEAR) += cmd_clear.o diff --git a/common/cmd_bootmenu.c b/common/cmd_bootmenu.c new file mode 100644 index 000..931ed18 --- /dev/null +++ b/common/cmd_bootmenu.c @@ -0,0 +1,366 @@ +/* + * (C) Copyright 2011 Pali Rohár pali.ro...@gmail.com + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, + * MA 02111-1307 USA + */ + +#include common.h +#include command.h +#include watchdog.h +#include linux/string.h + +#ifdef CONFIG_SYS_HUSH_PARSER +#include hush.h +#endif + +static char *get_option(int n) +{ + + char name[] = bootmenu_\0\0; + + if (n 0 || n 99) + return NULL; + + sprintf(name+9, %d, n); + + return getenv(name); + +} + +static char *get_end_of_title(char *str) +{ + + if (!str) + return NULL; + + return strchr(str, '='); + +} + +static int print_title(char *begin, char *end) +{ + + if (!begin || !end || end begin) + return 1; + + while (begin != end) + putc(*(begin++)); + + return 0; + +} + +static int print_entry(int n, int reverse) +{ + + char *str = get_option(n); + char *end = get_end_of_title(str); + + if (!end) + return 1; + + printf(ANSI_CURSOR_POSITION, n+4, 1); + + if (reverse) + puts(ANSI_COLOR_REVERSE); + + puts( ); + print_title(str, end); + puts(ANSI_CLEAR_LINE_TO_END); + + if (reverse) + puts(ANSI_COLOR_RESET); + + return 0; + +} + +static int print_menu(int active) +{ + + int n = 0; + + printf(ANSI_CURSOR_POSITION, 1, 1); + puts(ANSI_CLEAR_LINE); + printf(ANSI_CURSOR_POSITION, 2, 1); + puts( *** U-Boot BOOT MENU ***); + puts(ANSI_CLEAR_LINE_TO_END); + printf(ANSI_CURSOR_POSITION, 3, 1); + puts(ANSI_CLEAR_LINE); + + while (1) { + + int ret = print_entry(n, n == active ? 1 : 0); + + if (ret == 1) + break; + + ++n; + + } + + printf(ANSI_CURSOR_POSITION, n+4, 1); + + if (n == active) + puts(ANSI_COLOR_REVERSE); + + puts( U-Boot console); +
[U-Boot] [PATCH 15/15] RX-51: Add support for bootmenu
* default bootmenu entries: NOLO kernel, internal eMMC memory, external SD card, u-boot boot order * when keyboard slide is closed always boot NOLO kernel * when keyborad slide is open in CONFIG_PREBOOT try load bootmenu.scr from first FAT partition of internal eMMC memory (also known as MyDocs) which (should) overwrite default bootmenu entries Signed-off-by: Pali Rohár pali.ro...@gmail.com --- include/configs/nokia_rx51.h | 22 ++ 1 files changed, 18 insertions(+), 4 deletions(-) diff --git a/include/configs/nokia_rx51.h b/include/configs/nokia_rx51.h index c892f65..2a1de85 100644 --- a/include/configs/nokia_rx51.h +++ b/include/configs/nokia_rx51.h @@ -134,6 +134,7 @@ #define CONFIG_CMD_MMC /* MMC support */ #undef CONFIG_CMD_ONENAND /* NAND support */ +#define CONFIG_CMD_BOOTMENU/* ANSI terminal Boot Menu */ #define CONFIG_CMD_CLEAR /* ANSI terminal clear screen command */ #undef CONFIG_CMD_FLASH/* flinfo, erase, protect */ @@ -185,8 +186,6 @@ int rx51_kp_getc(void); #endif /* Environment information */ -#define CONFIG_BOOTDELAY 3 - #define CONFIG_EXTRA_ENV_SETTINGS \ usbtty=cdc_acm\0 \ stdin=vga\0 \ @@ -232,10 +231,22 @@ int rx51_kp_getc(void); fi; \ fi\0 \ immcboot=setenv mmcnum 1; run trymmcboot\0 \ - emmcboot=setenv mmcnum 0; run trymmcboot\0 + emmcboot=setenv mmcnum 0; run trymmcboot\0 \ + menucmd=bootmenu\0 \ + bootmenu_0=Internal flash=run noloboot\0 \ + bootmenu_1=Internal eMMC=run immcboot\0 \ + bootmenu_2=External SD card=run emmcboot\0 \ + bootmenu_3=U-Boot boot order=boot\0 \ + bootmenu_delay=3\0 #define CONFIG_PREBOOT \ - if test $slide_sw != open; then run noloboot; fi; + if test $slide_sw = open; then \ + setenv mmcnum 1; setenv mmcpart 1; setenv mmctype fat; \ + setenv mmcfile bootmenu.scr; \ + run trymmcscript; \ + else \ + setenv bootmenu_delay 0; \ + fi #define CONFIG_PREMONITOR \ echo Extra commands:; \ @@ -253,7 +264,10 @@ int rx51_kp_getc(void); run noloboot; \ echo +#define CONFIG_MENUCMD + #define CONFIG_AUTO_COMPLETE + /* * Miscellaneous configurable options */ -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] arm, arm-kirkwood: disable l2c before linux boot
The decompressor expects the L2 cache to be disabled. This fixes booting some kernels, which have CONFIG_ARM_PATCH_PHYS_VIRT enabled. Signed-off-by: Michael Walle mich...@walle.cc Cc: Albert ARIBAUD albert.u.b...@aribaud.net Cc: Prafulla Wadaskar prafu...@marvell.com --- arch/arm/cpu/arm926ejs/cache.c | 15 +++ arch/arm/cpu/arm926ejs/cpu.c |2 + arch/arm/cpu/arm926ejs/kirkwood/Makefile |1 + arch/arm/cpu/arm926ejs/kirkwood/cache.c | 41 ++ 4 files changed, 59 insertions(+), 0 deletions(-) create mode 100644 arch/arm/cpu/arm926ejs/kirkwood/cache.c diff --git a/arch/arm/cpu/arm926ejs/cache.c b/arch/arm/cpu/arm926ejs/cache.c index 4415642..7a7d0a6 100644 --- a/arch/arm/cpu/arm926ejs/cache.c +++ b/arch/arm/cpu/arm926ejs/cache.c @@ -73,3 +73,18 @@ void flush_cache(unsigned long start, unsigned long size) { } #endif /* #ifndef CONFIG_SYS_DCACHE_OFF */ + +/* + * Stub implementations for l2 cache operations + */ +void __l2_cache_enable(void) +{ +} +void l2_cache_enable(void) +__attribute__((weak, alias(__l2_cache_enable))); + +void __l2_cache_disable(void) +{ +} +void l2_cache_disable(void) +__attribute__((weak, alias(__l2_cache_disable))); diff --git a/arch/arm/cpu/arm926ejs/cpu.c b/arch/arm/cpu/arm926ejs/cpu.c index 5c902df..626384c 100644 --- a/arch/arm/cpu/arm926ejs/cpu.c +++ b/arch/arm/cpu/arm926ejs/cpu.c @@ -50,6 +50,8 @@ int cleanup_before_linux (void) /* turn off I/D-cache */ icache_disable(); dcache_disable(); + l2_cache_disable(); + /* flush I/D-cache */ cache_flush(); diff --git a/arch/arm/cpu/arm926ejs/kirkwood/Makefile b/arch/arm/cpu/arm926ejs/kirkwood/Makefile index 0754297..777006c 100644 --- a/arch/arm/cpu/arm926ejs/kirkwood/Makefile +++ b/arch/arm/cpu/arm926ejs/kirkwood/Makefile @@ -30,6 +30,7 @@ COBJS-y = cpu.o COBJS-y+= dram.o COBJS-y+= mpp.o COBJS-y+= timer.o +COBJS-y+= cache.o SRCS := $(SOBJS:.o=.S) $(COBJS-y:.o=.c) OBJS := $(addprefix $(obj),$(SOBJS) $(COBJS-y)) diff --git a/arch/arm/cpu/arm926ejs/kirkwood/cache.c b/arch/arm/cpu/arm926ejs/kirkwood/cache.c new file mode 100644 index 000..84207f7 --- /dev/null +++ b/arch/arm/cpu/arm926ejs/kirkwood/cache.c @@ -0,0 +1,41 @@ +/* + * Copyright (c) 2011 Michael Walle + * Michael Walle mich...@walle.cc + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc. + */ +#include common.h +#include asm/arch/cpu.h + +void l2_cache_enable() +{ + u32 ctrl; + + ctrl = readfr_extra_feature_reg(); + ctrl |= 1 22;/* enable l2 cache */ + writefr_extra_feature_reg(ctrl); +} + +void l2_cache_disable() +{ + u32 ctrl; + + ctrl = readfr_extra_feature_reg(); + ctrl = ~(1 22); /* disable l2 cache */ + writefr_extra_feature_reg(ctrl); +} -- 1.7.2.5 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] arm, arm-kirkwood: disable l2c before linux boot
Am Sonntag 18 Dezember 2011, 23:09:51 schrieb Michael Walle: The decompressor expects the L2 cache to be disabled. This fixes booting some kernels, which have CONFIG_ARM_PATCH_PHYS_VIRT enabled. You should consider applying this patch to the RC, too. CONFIG_ARM_PATCH_PHYS_VIRT is enabled by default since 3.2-rc1. -- michael ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [STATUS] next branch started
Please feel free to send pull-requests for next, or to point me to patches that should go into next (or even into the upcoming release). http://patchwork.ozlabs.org/patch/126328/ http://patchwork.ozlabs.org/patch/122253/ -- Michael ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] arm, arm-kirkwood: disable l2c before linux boot
The decompressor expects the L2 cache to be disabled. This fixes booting some kernels, which have CONFIG_ARM_PATCH_PHYS_VIRT enabled. Signed-off-by: Michael Walle mich...@walle.cc Cc: Albert ARIBAUD albert.u.b...@aribaud.net Cc: Prafulla Wadaskar prafu...@marvell.com --- arch/arm/cpu/arm926ejs/cache.c | 15 +++ arch/arm/cpu/arm926ejs/cpu.c |2 + arch/arm/cpu/arm926ejs/kirkwood/Makefile |1 + arch/arm/cpu/arm926ejs/kirkwood/cache.c | 41 ++ 4 files changed, 59 insertions(+), 0 deletions(-) create mode 100644 arch/arm/cpu/arm926ejs/kirkwood/cache.c diff --git a/arch/arm/cpu/arm926ejs/cache.c b/arch/arm/cpu/arm926ejs/cache.c index 4415642..7a7d0a6 100644 --- a/arch/arm/cpu/arm926ejs/cache.c +++ b/arch/arm/cpu/arm926ejs/cache.c @@ -73,3 +73,18 @@ void flush_cache(unsigned long start, unsigned long size) { } #endif /* #ifndef CONFIG_SYS_DCACHE_OFF */ + +/* + * Stub implementations for l2 cache operations + */ +void __l2_cache_enable(void) +{ +} +void l2_cache_enable(void) +__attribute__((weak, alias(__l2_cache_enable))); + +void __l2_cache_disable(void) +{ +} +void l2_cache_disable(void) +__attribute__((weak, alias(__l2_cache_disable))); diff --git a/arch/arm/cpu/arm926ejs/cpu.c b/arch/arm/cpu/arm926ejs/cpu.c index 5c902df..626384c 100644 --- a/arch/arm/cpu/arm926ejs/cpu.c +++ b/arch/arm/cpu/arm926ejs/cpu.c @@ -50,6 +50,8 @@ int cleanup_before_linux (void) /* turn off I/D-cache */ icache_disable(); dcache_disable(); + l2_cache_disable(); + /* flush I/D-cache */ cache_flush(); diff --git a/arch/arm/cpu/arm926ejs/kirkwood/Makefile b/arch/arm/cpu/arm926ejs/kirkwood/Makefile index 0754297..777006c 100644 --- a/arch/arm/cpu/arm926ejs/kirkwood/Makefile +++ b/arch/arm/cpu/arm926ejs/kirkwood/Makefile @@ -30,6 +30,7 @@ COBJS-y = cpu.o COBJS-y += dram.o COBJS-y += mpp.o COBJS-y += timer.o +COBJS-y += cache.o SRCS := $(SOBJS:.o=.S) $(COBJS-y:.o=.c) OBJS := $(addprefix $(obj),$(SOBJS) $(COBJS-y)) diff --git a/arch/arm/cpu/arm926ejs/kirkwood/cache.c b/arch/arm/cpu/arm926ejs/kirkwood/cache.c new file mode 100644 index 000..84207f7 --- /dev/null +++ b/arch/arm/cpu/arm926ejs/kirkwood/cache.c @@ -0,0 +1,41 @@ +/* + * Copyright (c) 2011 Michael Walle + * Michael Walle mich...@walle.cc + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc. + */ +#include common.h +#include asm/arch/cpu.h + +void l2_cache_enable() +{ + u32 ctrl; + + ctrl = readfr_extra_feature_reg(); + ctrl |= 1 22;/* enable l2 cache */ + writefr_extra_feature_reg(ctrl); +} + +void l2_cache_disable() +{ + u32 ctrl; + + ctrl = readfr_extra_feature_reg(); + ctrl = ~(1 22); /* disable l2 cache */ + writefr_extra_feature_reg(ctrl); +} Please use #define name to define the magic value above (1 22) and then use it. M ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] arm, arm-kirkwood: disable l2c before linux boot
Am Montag 19 Dezember 2011, 00:04:18 schrieb Marek Vasut: [..snip..] Please use #define name to define the magic value above (1 22) and then use it. M The bit was taken from arch/arm/cpu/arm926ejs/kirkwood/cpu.c. Unfortunately there is no documentation publicly available, so i can only guess names. FEROCEON_EXTRA_FEATURE_L2C_EN ? Even the linux kernel has no proper macro names :( -- Michael ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v3] U-Boot on Nokia RX-51 (aka N900)
Dear Pali =?ISO-8859-1?Q?Roh=E1r?=, In message 1778406.ezGto4lKnu@pali-elitebook you wrote: I'm sending third version of rx51 patches for u-boot. All patches was checked by checkpatch.pl and no error or warning was appeared. Last 2 patches (0014 and 0015) adding ANSI terminal bootmenu support for rx51 and can be reviewed separatly (patches 0001-0013 adding nokia rx51 board support and working without that last two). It seems you did not bother to read http://www.denx.de/wiki/view/U-Boot/Patches#Sending_updated_patch_versions I do not have the time to try to find out what you might have changed compared top your previous submission, and others are in the same situation. Why did you not provide any change logs? Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de To live is always desirable. -- Eleen the Capellan, Friday's Child, stardate 3498.9 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] Pull request: u-boot-x86/next
Hi Wolfgang: The following changes since commit 7b725f8485bcdd0be3cda40e435b783882bf18ec: CHECKPATCH: ./board/esd/hh405/logo_320_240_8bpp.c (2011-12-18 00:14:46 +0100) are available in the git repository at: git://git.denx.de/u-boot-x86.git next Gabe Black (7): x86: Initial commit for running as a coreboot payload x86: Import code from coreboot's libpayload to parse the coreboot table x86: Clean up the x86 zimage code in preparation to extend it x86: Add support for booting Linux using the 32 bit boot protocol x86: Add infrastructure to extract an e820 table from the coreboot tables x86: Refactor the zboot innards so they can be reused with a vboot image x86: Add support for specifying an initrd with the zboot command arch/x86/cpu/coreboot/Makefile | 58 + arch/x86/cpu/coreboot/asm-offsets.c | 25 ++ arch/x86/cpu/coreboot/coreboot_car.S | 29 +++ arch/x86/cpu/coreboot/ipchecksum.c | 54 + arch/x86/cpu/coreboot/sdram.c| 75 ++ arch/x86/cpu/coreboot/sysinfo.c | 39 +++ arch/x86/cpu/coreboot/tables.c | 183 ++ arch/x86/include/asm/arch-coreboot/ipchecksum.h | 37 +++ arch/x86/include/asm/arch-coreboot/sysinfo.h | 63 + arch/x86/include/asm/arch-coreboot/tables.h | 241 +++ arch/x86/include/asm/zimage.h| 36 +-- arch/x86/lib/bootm.c | 21 ++- arch/x86/lib/zimage.c| 276 ++ board/chromebook-x86/coreboot/Makefile | 53 board/chromebook-x86/coreboot/coreboot.c | 87 +++ board/chromebook-x86/coreboot/coreboot_pci.c | 30 +++ board/chromebook-x86/coreboot/coreboot_start.S | 29 +++ board/chromebook-x86/coreboot/coreboot_start16.S | 46 boards.cfg |1 + include/configs/coreboot.h | 225 ++ include/serial.h |2 +- 21 files changed, 1482 insertions(+), 128 deletions(-) create mode 100644 arch/x86/cpu/coreboot/Makefile create mode 100644 arch/x86/cpu/coreboot/asm-offsets.c create mode 100644 arch/x86/cpu/coreboot/coreboot_car.S create mode 100644 arch/x86/cpu/coreboot/ipchecksum.c create mode 100644 arch/x86/cpu/coreboot/sdram.c create mode 100644 arch/x86/cpu/coreboot/sysinfo.c create mode 100644 arch/x86/cpu/coreboot/tables.c create mode 100644 arch/x86/include/asm/arch-coreboot/ipchecksum.h create mode 100644 arch/x86/include/asm/arch-coreboot/sysinfo.h create mode 100644 arch/x86/include/asm/arch-coreboot/tables.h create mode 100644 board/chromebook-x86/coreboot/Makefile create mode 100644 board/chromebook-x86/coreboot/coreboot.c create mode 100644 board/chromebook-x86/coreboot/coreboot_pci.c create mode 100644 board/chromebook-x86/coreboot/coreboot_start.S create mode 100644 board/chromebook-x86/coreboot/coreboot_start16.S create mode 100644 include/configs/coreboot.h ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] u-boot-x86/next has been rebased - push forced
Hi All, Please note that the 'next' branch of u-boot-x86 has been rebased against u-boot/next published to git://git.denx.de/u-boot-x86.git via a forced push If you have cloned u-boot-x86/next, please be aware that you will need to update your local repo Regards, Graeme ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] __mmc_get_env_addr() is not being called?
2011/12/16 Stefano Babic sba...@denx.de: On 16/12/2011 06:54, Shawn Guo wrote: Hi, Hi Shawn, I'm running v2011.12-rc1 (with one missing usdhc patch applied) on mx6qarm2 board, and seeing a problem. When I install u-boot on a blank SD card, it boots fine with messge *** Warning - bad CRC, using default environment seen as expected. But once I run command 'save' to write envs to the card, the card stop booting. I tracked the issue a little bit, and found __mmc_get_env_addr() does not get called at all. Therefore when I run 'save' for the first time, the envs are written to offset 0 of the card, which in turn overwrites the boot image. I have not figured out why it does. But the following change fixes the problem for me. diff --git a/common/env_mmc.c b/common/env_mmc.c index 8441c77..3832fe4 100644 --- a/common/env_mmc.c +++ b/common/env_mmc.c @@ -46,13 +46,11 @@ DECLARE_GLOBAL_DATA_PTR; #define CONFIG_ENV_OFFSET 0 #endif -static int __mmc_get_env_addr(struct mmc *mmc, u32 *env_addr) +static int mmc_get_env_addr(struct mmc *mmc, u32 *env_addr) { *env_addr = CONFIG_ENV_OFFSET; return 0; } -int mmc_get_env_addr(struct mmc *mmc, u32 *env_addr) - __attribute__((weak, alias(__mmc_get_env_addr))); Any comment on why the change fixes the problem is appreciated. The function is declared weak, this means that a specific architecture could implement its own version. The reason why it does not work is that there is a specific implementation in board/freescale/sdhc_boot.c, and the mmc_get_env_addr() in this file is taken instead of the default when CONFIG_ENV_IS_IN_MMC (as in our case) is set. Instead of your proposal, we should surround mmc_get_env_addr() in sdhc_boot.c with something like #ifndef CONFIG_MX6Q, or check if we can reuse this function, that really does not use CONFIG_ENV_OFFSET at all. I put Jason (board maintainer) in CC - Jason, what do mind ? Do you get the same issue when you tested the board ? Stefano, I saw the issue. Fabio's patch can fix the i.mx28evk issue, but can't fix the following platforms: 11144 include/configs/efikamx.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC 12 86 include/configs/mx51evk.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC 13 58 include/configs/mx53ard.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC 14 68 include/configs/mx53evk.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC 15 51 include/configs/mx53loco.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC 16 58 include/configs/mx53smd.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC 17 48 include/configs/mx6qarm2.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC 18 48 include/configs/mx6qsabrelite.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC 20105 include/configs/vision2.h CONFIG_FSL_ESDHC #define CONFIG_FSL_ESDHC The commit 97039ab98 (env_mmc: Allow board code to override the environment address) break the i.mx5/6 boards support. BR, Jason Best regards, Stefano Babic -- = DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] Origen: Select SCLKMPLL as FIMD0 parent clock
Signed-off-by: Chander Kashyap chander.kash...@linaro.org --- board/samsung/origen/lowlevel_init.S |5 + board/samsung/origen/origen_setup.h | 12 2 files changed, 17 insertions(+), 0 deletions(-) diff --git a/board/samsung/origen/lowlevel_init.S b/board/samsung/origen/lowlevel_init.S index 0eebbfc..9283201 100644 --- a/board/samsung/origen/lowlevel_init.S +++ b/board/samsung/origen/lowlevel_init.S @@ -158,6 +158,11 @@ system_clock_init: ldr r2, =CLK_SRC_PERIL0_OFFSET str r1, [r0, r2] + /* FIMD0 */ + ldr r1, =CLK_SRC_LCD0_VAL + ldr r2, =CLK_SRC_LCD0_OFFSET + str r1, [r0, r2] + /* wait ?us */ mov r1, #0x1 3: subsr1, r1, #1 diff --git a/board/samsung/origen/origen_setup.h b/board/samsung/origen/origen_setup.h index d949ad2..94a 100644 --- a/board/samsung/origen/origen_setup.h +++ b/board/samsung/origen/origen_setup.h @@ -56,6 +56,8 @@ #define CLK_SRC_PERIL0_OFFSET 0xC250 #define CLK_DIV_PERIL0_OFFSET 0xC550 +#define CLK_SRC_LCD0_OFFSET0xC234 + #define APLL_LOCK_OFFSET 0x14000 #define MPLL_LOCK_OFFSET 0x14008 #define APLL_CON0_OFFSET 0x14100 @@ -351,6 +353,16 @@ | (UART1_RATIO 4) \ | (UART0_RATIO 0)) +/* CLK_SRC_LCD0 */ +#define FIMD_SEL_SCLKMPLL 6 +#define MDNIE0_SEL_XUSBXTI 1 +#define MDNIE_PWM0_SEL_XUSBXTI 1 +#define MIPI0_SEL_XUSBXTI 1 +#define CLK_SRC_LCD0_VAL ((MIPI0_SEL_XUSBXTI 12) \ + | (MDNIE_PWM0_SEL_XUSBXTI 8) \ + | (MDNIE0_SEL_XUSBXTI 4) \ + | (FIMD_SEL_SCLKMPLL 0)) + /* Required period to generate a stable clock output */ /* PLL_LOCK_TIME */ #define PLL_LOCKTIME 0x1C20 -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 0/2] Exynos Related fixes
Chander Kashyap (2): Exynos: PWM: Add TCMPB3 field in pwm structure Exynos: Fix ARM Clock frequency calculation arch/arm/cpu/armv7/exynos/clock.c |9 ++--- arch/arm/include/asm/arch-exynos/pwm.h |2 +- 2 files changed, 7 insertions(+), 4 deletions(-) -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 1/2] Exynos: PWM: Add TCMPB3 field in pwm structure
Add TCMPB3 field in pwm structure, earliar this was res1. Signed-off-by: Chander Kashyap chander.kash...@linaro.org --- arch/arm/include/asm/arch-exynos/pwm.h |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/arm/include/asm/arch-exynos/pwm.h b/arch/arm/include/asm/arch-exynos/pwm.h index d0cf3cb..3e95160 100644 --- a/arch/arm/include/asm/arch-exynos/pwm.h +++ b/arch/arm/include/asm/arch-exynos/pwm.h @@ -57,7 +57,7 @@ struct s5p_timer { unsigned inttcmpb2; unsigned inttcnto2; unsigned inttcntb3; - unsigned intres1; + unsigned inttcmpb3; unsigned inttcnto3; unsigned inttcntb4; unsigned inttcnto4; -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 2/2] Exynos: Fix ARM Clock frequency calculation
Earliar ARM clock frequency was calculated by: MOUTAPLL/(DIVAPLL + 1) which is actually returning SCLKAPLL. It is fixed by calcuating it as follows: ARMCLK=MOUTCORE/(DIVCORE + 1)/DIVCORE2 + 1) Signed-off-by: Chander Kashyap chander.kash...@linaro.org --- arch/arm/cpu/armv7/exynos/clock.c |9 ++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/arch/arm/cpu/armv7/exynos/clock.c b/arch/arm/cpu/armv7/exynos/clock.c index 64de262..17ff012 100644 --- a/arch/arm/cpu/armv7/exynos/clock.c +++ b/arch/arm/cpu/armv7/exynos/clock.c @@ -103,14 +103,17 @@ static unsigned long exynos4_get_arm_clk(void) (struct exynos4_clock *)samsung_get_base_clock(); unsigned long div; unsigned long dout_apll; - unsigned int apll_ratio; + unsigned int core_ratio; + unsigned int core2_ratio; div = readl(clk-div_cpu0); /* APLL_RATIO: [26:24] */ - apll_ratio = (div 24) 0x7; + core_ratio = (div 0) 0x7; + core2_ratio = (div 28) 0x7; - dout_apll = get_pll_clk(APLL) / (apll_ratio + 1); + dout_apll = get_pll_clk(APLL) / (core_ratio + 1); + dout_apll /= (core2_ratio + 1); return dout_apll; } -- 1.7.5.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] __mmc_get_env_addr() is not being called?
On 18/12/2011 18:56, Kumar Gala wrote: On Dec 16, 2011, at 3:42 AM, Stefano Babic wrote: On 16/12/2011 10:33, Fabio Estevam wrote: The weak function was introduced by this commit: http://git.denx.de/?p=u-boot.git;a=commitdiff;h=97039ab98c551c7860bc0977d684ef686159e0d7 which breaks non CONFIG_FSL_ESDHC users. Ok, I see - the patch is more related to Freescale SOCs as to the MMC, and it is sometimes unknown who whould pick it up. Andy, not CONFIG_FSL_ESDHC means IMX users - if you do not complain, I merge it into u-boot-imx. Thanks, Stefano If I'm reading the patch correct it will break things (or I'm not sure which patch you're referring to). How would the PPC specific version ever get called? Yes, I was too optimistic with the patch, I have myself seen that the patch then break PowerPC boards. Reading sdhc_boot.c, this file is not strictly related to PowerPC or IMX hardware, but where u-boot image is stored on PowerPC code. This is like a specific feature, but there is not a specific CONFIG_ for it. In fact, in board/freescale/common/Makefile the file is always compiled if CONFIG_RAMBOOT_PBL (not significant for imx) is not set if the environment is in MMC: ifndef CONFIG_RAMBOOT_PBL COBJS-$(CONFIG_ENV_IS_IN_MMC) += sdhc_boot.o endif What about to have a specific CONFIG_FSL_* for this file ? It can be defined for PowerPC boards, and it will not for IMX. Any thoughts ? Stefano -- = DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v2 2/3] fec: add the i.mx6q enet driver support
On 16/12/2011 16:17, Jason Liu wrote: Cc: Stefano Babic sba...@denx.de Signed-off-by: Jason Liu jason@linaro.org Acked-by: Stefano Babic sba...@denx.de Applied to u-boot-imx, next branch, thanks. Best regards, Stefano Babic -- = DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v2 1/3] i.mx: i.mx6q: Add the enet clock function
On 16/12/2011 16:17, Jason Liu wrote: Cc: Stefano Babic sba...@denx.de Signed-off-by: Jason Liu jason@linaro.org Acked-by: Stefano Babic sba...@denx.de --- v2: Add Stefano's ack --- Applied to u-boot-imx, next branch, thanks. Best regards, Stefano Babic -- = DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v2 3/3] i.mx6q: arm2: Add the enet function support
On 16/12/2011 16:17, Jason Liu wrote: This enable the network function on the i.mx6q armadillo2 board(arm2), thus we can use tftp to load image from network. Cc: Stefano Babic sba...@denx.de Signed-off-by: Jason Liu jason@linaro.org Tested-by: Dirk Behme dirk.be...@de.bosch.com --- Applied to u-boot-imx, next branch, thanks. Best regards, Stefano Babic -- = DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] __mmc_get_env_addr() is not being called?
On Mon, Dec 19, 2011 at 2:37 PM, Stefano Babic sba...@denx.de wrote: On 18/12/2011 18:56, Kumar Gala wrote: On Dec 16, 2011, at 3:42 AM, Stefano Babic wrote: On 16/12/2011 10:33, Fabio Estevam wrote: The weak function was introduced by this commit: http://git.denx.de/?p=u-boot.git;a=commitdiff;h=97039ab98c551c7860bc0977d684ef686159e0d7 which breaks non CONFIG_FSL_ESDHC users. Ok, I see - the patch is more related to Freescale SOCs as to the MMC, and it is sometimes unknown who whould pick it up. Andy, not CONFIG_FSL_ESDHC means IMX users - if you do not complain, I merge it into u-boot-imx. Thanks, Stefano If I'm reading the patch correct it will break things (or I'm not sure which patch you're referring to). How would the PPC specific version ever get called? Yes, I was too optimistic with the patch, I have myself seen that the patch then break PowerPC boards. Reading sdhc_boot.c, this file is not strictly related to PowerPC or IMX hardware, but where u-boot image is stored on PowerPC code. This is like a specific feature, but there is not a specific CONFIG_ for it. In fact, in board/freescale/common/Makefile the file is always compiled if CONFIG_RAMBOOT_PBL (not significant for imx) is not set if the environment is in MMC: ifndef CONFIG_RAMBOOT_PBL COBJS-$(CONFIG_ENV_IS_IN_MMC) += sdhc_boot.o endif What about to have a specific CONFIG_FSL_* for this file ? It can be defined for PowerPC boards, and it will not for IMX. Any thoughts ? I agree with this option. Also Cced: chang-ming.hu...@freescale.com Stefano -- = DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v3] U-Boot on Nokia RX-51 (aka N900)
On Monday 19 December 2011 00:57:27 Wolfgang Denk wrote: Dear Pali =?ISO-8859-1?Q?Rohár?=, In message 1778406.ezGto4lKnu@pali-elitebook you wrote: I'm sending third version of rx51 patches for u-boot. All patches was checked by checkpatch.pl and no error or warning was appeared. Last 2 patches (0014 and 0015) adding ANSI terminal bootmenu support for rx51 and can be reviewed separatly (patches 0001-0013 adding nokia rx51 board support and working without that last two). It seems you did not bother to read http://www.denx.de/wiki/view/U-Boot/Patches#Sending_updated_patch_versions I do not have the time to try to find out what you might have changed compared top your previous submission, and others are in the same situation. Why did you not provide any change logs? Best regards, Wolfgang Denk Here is changelog v2:v3 * fixed all problems detected by checkpatch.pl * wrapped long commit messages * in arch/arm/lib/bootm.c added local define CONFIG_SETUP_ANY_TAG * Patch cfb_console.c: Add function console_swap_colors squashed into cfb_console.c: Add support for ANSI terminal * renamed command clr to clear; use puts instead printf; move cursor to pos1,1 * removed check #ifdef CONFIG_PREMONITOR in main.c * rx51 board code: removed Makefile targets: clean and distclean * ansi bootmenu command: use puts instead printf -- Pali Rohár pali.ro...@gmail.com signature.asc Description: This is a digitally signed message part. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v4] ARMV7: Add support For Logic OMAP35x/DM37x modules
Hi Peter, Thanks for fixing all the issues pointed. I have one last question (sorry for not seeing it earlier) and one neat below. On 12/18/11 19:25, Peter Barada wrote: This patch adds basic support for OMAP35x/DM37x SOM LV/Torpedo reference boards. It assumes U-boot is loaded to SDRAM with the help of another small bootloader (x-load) running from SRAM. Signed-off-by: Peter Barada peter.bar...@logicpd.com Cc: Tom Rini tom.r...@gmail.com Cc: Igor Grinberg grinb...@compulab.co.il Cc: Wolfgang Denk w...@denx.de --- [...] diff --git a/board/logicpd/omap3som/omap3logic.c b/board/logicpd/omap3som/omap3logic.c new file mode 100644 index 000..3a5d3d5 --- /dev/null +++ b/board/logicpd/omap3som/omap3logic.c [...] +/* + * Routine: set_muxconf_regs + * Description: Setting up the configuration Mux registers specific to the + * hardware. Many pins need to be moved from protect to primary + * mode. + */ +void set_muxconf_regs(void) +{ [...] + MUX_VAL(CP(GPMC_NCS6), (IEN | PTU | EN | M7)); /*safe mode */ [...] + MUX_VAL(CP(GPMC_WAIT2), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(GPMC_WAIT3), (IEN | PTU | EN | M7)); /*safe mode */ + /*DSS*/ + MUX_VAL(CP(DSS_PCLK), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_HSYNC), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_VSYNC), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_ACBIAS), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA0), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA1), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA2), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA3), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA4), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA5), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA6), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA7), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA8), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA9), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA10), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA11), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA12), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA13), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA14), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA15), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA16), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA17), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA18), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA19), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA20), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA21), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA22), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(DSS_DATA23), (IEN | PTD | EN | M7)); /*safe mode */ + /*CAMERA*/ + MUX_VAL(CP(CAM_HS), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_VS), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_XCLKA), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_PCLK), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_FLD),(IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D0), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D1), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D2), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D3), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D4), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D5), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D6), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D7), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D8), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D9), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D10),(IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_D11),(IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_XCLKB), (IEN | PTD | EN | M7)); /*safe mode */ + MUX_VAL(CP(CAM_WEN),
[U-Boot] [GIT PULL] Pull request: u-boot-imx
Hi Albert, please pull from u-boot-imx (a couple of fixes): The following changes since commit a7b39185338c333a052728a7952b5f1cba4fc22a: tools/setlocalversion: Update from the Linux Kernel (2011-12-17 20:58:48 +0100) are available in the git repository at: git://www.denx.de/git/u-boot-imx.git master Anatolij Gustschin (1): Fix building for mx51evk board Marek Vasut (1): M28: Fix tab indent in u-boot.bd board/denx/m28evk/u-boot.bd |8 board/freescale/mx51evk/mx51evk.c |3 ++- board/freescale/mx53loco/mx53loco.c |3 ++- 3 files changed, 8 insertions(+), 6 deletions(-) -- = DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] Exynos: Fix ARM Clock frequency calculation
Dear Chander Kashyap, In message 1324275424-29468-3-git-send-email-chander.kash...@linaro.org you wrote: Earliar ARM clock frequency was calculated by: MOUTAPLL/(DIVAPLL + 1) which is actually returning SCLKAPLL. It is fixed by calcuating it as follows: Um Comment and code disagree: ARMCLK=MOUTCORE/(DIVCORE + 1)/DIVCORE2 + 1) ...or is this just missing a paren? + dout_apll = get_pll_clk(APLL) / (core_ratio + 1); + dout_apll /= (core2_ratio + 1); This gives ARMCLK=MOUTCORE/(DIVCORE + 1)/ (DIVCORE2 + 1) Please check if this is correct. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de Bus error -- driver executed. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot