Re: [U-Boot] 9c11135 breaks bootz
Hi Matthias, 2016-02-05 2:41 GMT+09:00 Tom Rini : > On Tue, Feb 02, 2016 at 03:49:07PM +0100, Matthias Weißer wrote: > >> Hi >> >> 9c11135 image: fix getenv_bootm_size() function breaks the bootz >> command for me on a custom hardware (very similar to mx6sxsabresd but >> with only 256MB RAM). I don't have bootm_size or bootm_low defined. >> >> After reading zImage and dtb from serial flash I run >> >> => bootz 0x8080 - 0x8300 >> Kernel image @ 0x8080 [ 0x00 - 0x1e5f48 ] >> ## Flattened Device Tree blob at 8300 >>Booting using the fdt blob at 0x8300 >> ERROR: Failed to allocate 0xb28a bytes below 0x1000. >> device tree - allocation error >> FDT creation failed! hanging...### ERROR ### Please RESET the board ### >> >> I am totally unsure what the commit intents but subtracting the ram >> start address from its size doesn't make much sense to me. >> >> + return gd->bd->bi_dram[0].size - (tmp - gd->bd->bi_dram[0].start); >> >> Maybe someone can shed some light on this issue for me. > > Masahiro? Please try this patch: http://patchwork.ozlabs.org/patch/579391/ -- Best Regards Masahiro Yamada ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] image: fix getenv_bootm_size() function again
Commit 9c11135ce053 ("image: fix getenv_bootm_size() function") fixed the case where "bootm_low" is defined, but "bootm_size" is not. Instead, it broke the case where neither "bootm_low" nor "bootm_size" is defined. Fix this function again. Fixes: 9c11135ce053 ("image: fix getenv_bootm_size() function") Signed-off-by: Masahiro Yamada --- common/image.c | 21 + 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/common/image.c b/common/image.c index f4a1dc8..82ace38 100644 --- a/common/image.c +++ b/common/image.c @@ -458,24 +458,29 @@ ulong getenv_bootm_low(void) phys_size_t getenv_bootm_size(void) { - phys_size_t tmp; + phys_size_t tmp, size; + phys_addr_t start; char *s = getenv("bootm_size"); if (s) { tmp = (phys_size_t)simple_strtoull(s, NULL, 16); return tmp; } + +#if defined(CONFIG_ARM) && defined(CONFIG_NR_DRAM_BANKS) + start = gd->bd->bi_dram[0].start; + size = gd->bd->bi_dram[0].size; +#else + start = gd->bd->bi_memstart; + size = gd->bd->bi_memsize; +#endif + s = getenv("bootm_low"); if (s) tmp = (phys_size_t)simple_strtoull(s, NULL, 16); else - tmp = 0; - + tmp = start; -#if defined(CONFIG_ARM) && defined(CONFIG_NR_DRAM_BANKS) - return gd->bd->bi_dram[0].size - (tmp - gd->bd->bi_dram[0].start); -#else - return gd->bd->bi_memsize - (tmp - gd->bd->bi_memstart); -#endif + return size - (tmp - start); } phys_size_t getenv_bootm_mapsize(void) -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support
> -Original Message- > From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of > Prabhakar Kushwaha > Sent: Friday, February 05, 2016 6:49 AM > To: york sun ; Harninder Rai ; > u-boot@lists.denx.de > Subject: Re: [U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support > > > > -Original Message- > > From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of york > > sun > > Sent: Thursday, February 04, 2016 10:15 PM > > To: Harninder Rai ; u-boot@lists.denx.de > > Subject: Re: [U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support > > > > Rai, > > > > On 02/04/2016 06:25 AM, Rai Harninder wrote: > > > The fuse status register provides the values from on-chip voltage ID > > > efuses programmed at the factory. These values define the voltage > > > requirements for the chip. u-boot reads FUSESR and translates the > > > values into the appropriate commands to set the voltage output value > > > of an external voltage regulator. > > > > No need to repeat what VID feature is. Instead, please focus on what > > this patch does. > > > > > > > > Signed-off-by: Rai Harninder > > > --- > > > .../include/asm/arch-fsl-layerscape/immap_lsch3.h |4 > > > board/freescale/common/vid.c | 15 ++- > > > board/freescale/ls2080ardb/ls2080ardb.c|5 + > > > include/configs/ls2080ardb.h | 16 > > > > > > 4 files changed, 39 insertions(+), 1 deletions(-) > > > > > > diff --git a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > > > b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > > > index 91f3ce8..4fd58ee 100644 > > > --- a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > > > +++ b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > > > @@ -146,6 +146,10 @@ struct ccsr_gur { > > > u8 res_008[0x20-0x8]; > > > u32 gpporcr1; /* General-purpose POR configuration */ > > > u32 gpporcr2; /* General-purpose POR configuration 2 */ > > > +#define FSL_CHASSIS3_DCFG_FUSESR_VID_SHIFT 25 > > > +#define FSL_CHASSIS3_DCFG_FUSESR_VID_MASK0x1F > > > +#define FSL_CHASSIS3_DCFG_FUSESR_ALTVID_SHIFT20 > > > +#define FSL_CHASSIS3_DCFG_FUSESR_ALTVID_MASK 0x1F > > > u32 dcfg_fusesr;/* Fuse status register */ > > > u32 gpporcr3; > > > u32 gpporcr4; > > > diff --git a/board/freescale/common/vid.c > > > b/board/freescale/common/vid.c index 1bd65a8..16ae177 100644 > > > --- a/board/freescale/common/vid.c > > > +++ b/board/freescale/common/vid.c > > > @@ -10,6 +10,8 @@ > > > #include > > > #ifdef CONFIG_LS1043A > > > #include > > > +#elif defined(CONFIG_FSL_LAYERSCAPE) #include > > > + > > > > It is not appropriate to use macro CONFIG_FSL_LAYERSCAPE here. It is > > defined for both LS1043 and LS2080. > > > > Oh... > Then LS2080 and LS2085 config needs to used. Also need to use LS2088A and > LS1088A. > > LS1043 is Chassis Gen2 and Other are Chassis Gen3 so different address etc. > How to avoid adding SoC config for each Chassis Gen3 SoC. We need to > define some config used across Gen3 SoCs. > We do have such config CONFIG_FSL_LSCH3. --prabhakar ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] help on using patman
Hi Simon On Thursday 04 February 2016 09:21 PM, Simon Glass wrote: > Hi Mugunthan, > > On 4 February 2016 at 08:09, Mugunthan V N wrote: >> Hi Simon >> >> I tried to use patman with a sample commit, below is the commit >> with the tag patmantest >> >> Commit: >> ~~~ >> $ git show patmantest >> tag patmantest >> Tagger: Mugunthan V N >> Date: Thu Feb 4 11:51:48 2016 +0530 >> >> Series-to: me >> Series-prefix: RFC >> Cover-letter: >> Unified command execution in one place >> >> At present two parsers have similar code to execute commands. Also >> cmd_usage() is called all over the place. This series adds a single >> function which processes commands called cmd_process(). >> END >> >> commit 02c23a9b585d91272befb8fe43d21fe52e1fd139 >> Author: Mugunthan V N >> Date: Mon Jan 18 14:17:43 2016 +0530 >> >> defconfig: dra72_evm: enable disk driver model >> >> Enable disk driver model for dra72_evm as dwc_ahci supports >> driver model >> >> Signed-off-by: Mugunthan V N >> Reviewed-by: Tom Rini >> >> diff --git a/configs/dra72_evm_defconfig b/configs/dra72_evm_defconfig >> index 32d1dc1..7ff2a4e 100644 >> --- a/configs/dra72_evm_defconfig >> +++ b/configs/dra72_evm_defconfig >> @@ -24,3 +24,5 @@ CONFIG_DM_SPI=y >> CONFIG_DM_SPI_FLASH=y >> CONFIG_TIMER=y >> CONFIG_OMAP_TIMER=y >> +CONFIG_DISK=y >> +CONFIG_DWC_AHCI=y >> ~~~ >> >> But when I patman -n, it throws below error >> >> $ ./tools/patman/patman -n >> Cleaned 1 patches >> total: 0 errors, 0 warnings, 0 checks, 5 lines checked >> >> NOTE: Ignored message types: COMPLEX_MACRO CONSIDER_KSTRTO MINMAX >> MULTISTATEMENT_MACRO_USE_DO_WHILE NETWORKING_BLOCK_COMMENT_STYLE >> PREFER_ETHER_ADDR_COPY USLEEP_RANGE > > I'm not sure where this message comes from - I don't see it. I suppose > it is checkpatch.pl. Yep this is from checkpatch.pl > >> >> 0001-defconfig-dra72_evm-enable-disk-driver-model.patch has no obvious style >> problems and is ready for submission. >> Traceback (most recent call last): >> File "./tools/patman/patman", line 158, in >> options.add_maintainers) >> File >> "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/series.py", >> line 222, in MakeCcFile >> raise_on_error=raise_on_error) >> File >> "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/gitutil.py", >> line 321, in BuildEmailList >> raw += LookupEmail(item, alias, raise_on_error=raise_on_error) >> File >> "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/gitutil.py", >> line 495, in LookupEmail >> raise ValueError, msg >> ValueError: Alias 'defconfig' not found > > This means it couldn't find the alias 'defconfig' :-) > > You have a defconfig: tag in your subject so patman will Cc that > alias. Since it doesn't exist you get an error. You can use the -t > option to ignore bad takes, or add an alias to .patman, like this: > > defconfig: Fred Bloggs > > Also see 'Where Patches Are Sent' in the README. Hmmm, I was basically misunderstood that I need to add patman notes in a tag, but it has to be present in commit message itself wright. Then when you want to publish your branch with logs, its not possible as to remove patman notes from commit in this process commit ids will change. > >> >> >> Then I tried with patman setting ignore_errors: True and >> process_tags: False, then the out seems fine but the tag >> is not processed. Do you find any thing I missed? > > Well only that you told it not to process the tag. I don't think it's > a good idea to add those settings. > > Try 'patman -nt' to use tags if they can be found, and ignore tags > that can't be found. Thanks, Now it worked for me. Regards Mugunthan V N > >> >> Output with modified patman settings: >> ~ >> $ ./tools/patman/patman -n >> Cleaned 1 patches >> total: 0 errors, 0 warnings, 0 checks, 5 lines checked >> >> NOTE: Ignored message types: COMPLEX_MACRO CONSIDER_KSTRTO MINMAX >> MULTISTATEMENT_MACRO_USE_DO_WHILE NETWORKING_BLOCK_COMMENT_STYLE >> PREFER_ETHER_ADDR_COPY USLEEP_RANGE >> >> 0001-defconfig-dra72_evm-enable-disk-driver-model.patch has no obvious style >> problems and is ready for submission. >> No recipient. >> Please add something like this to a commit >> Series-to: Fred Bloggs >> Or do something like this >> git config sendemail.to u-boot@lists.denx.de >> Dry run, so not doing much. But I would do this: >> >> Send a total of 1 patch with no cover letter. >>0001-defconfig-dra72_evm-enable-disk-driver-model.patch >> Cc: u-boot@lists.denx.de >> Cc: Lokesh Vutla >> >> Version: None >> Prefix: None >> >> Here is my patman config >> $ cat ~/.patman >> [alias] >> me: Mugunthan V N >> >> [settings] >> ignore_errors: True >> process_tags: False >> verbose: True >> >> Regards >> Mugunthan V N > > Regards, > Simon > _
[U-Boot] [PATCH v2 2/4] kbuild: sunxi: fix build rule of sunxi-spl.bin
The build command for sunxi-spl.bin is constant, so it is pointless to use $(call if_changed,...). $(call cmd,...) is enough. On the other hand, if the tools/mksunxiboot is updated, the resulted output may be different. Make the output image dependent on tools/mksunxiboot. Signed-off-by: Masahiro Yamada --- Changes in v2: None scripts/Makefile.spl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/Makefile.spl b/scripts/Makefile.spl index adabfcf..d8b3947 100644 --- a/scripts/Makefile.spl +++ b/scripts/Makefile.spl @@ -234,8 +234,8 @@ $(obj)/$(SPL_BIN).sfp: $(obj)/$(SPL_BIN).bin FORCE quiet_cmd_mksunxiboot = MKSUNXI $@ cmd_mksunxiboot = $(objtree)/tools/mksunxiboot $< $@ -$(obj)/sunxi-spl.bin: $(obj)/$(SPL_BIN).bin - $(call if_changed,mksunxiboot) +$(obj)/sunxi-spl.bin: $(obj)/$(SPL_BIN).bin $(objtree)/tools/mksunxiboot + $(call cmd,mksunxiboot) quiet_cmd_u-boot-spl = LD $@ cmd_u-boot-spl = (cd $(obj) && $(LD) $(LDFLAGS) $(LDFLAGS_$(@F)) \ -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v2 3/4] kbuild: add missing FORCE where $(call if_changed, ) is used
FORCE is needed for $(call if_changed,...) to be evaluated every time. Otherwise, the command is not executed when the command line has changed but any prerequisite has not been updated. Signed-off-by: Masahiro Yamada --- Changes in v2: None Makefile | 12 ++-- scripts/Makefile.spl | 8 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/Makefile b/Makefile index 430dd4f..a46c1ae 100644 --- a/Makefile +++ b/Makefile @@ -924,7 +924,7 @@ u-boot.sha1:u-boot.bin u-boot.dis:u-boot $(OBJDUMP) -d $< > $@ -u-boot.cfg:include/config.h +u-boot.cfg:include/config.h FORCE $(call if_changed,cpp_cfg) ifdef CONFIG_TPL @@ -945,15 +945,15 @@ lpc32xx-spl.img: spl/u-boot-spl.bin FORCE OBJCOPYFLAGS_lpc32xx-boot-0.bin = -I binary -O binary --pad-to=$(CONFIG_SPL_PAD_TO) -lpc32xx-boot-0.bin: lpc32xx-spl.img +lpc32xx-boot-0.bin: lpc32xx-spl.img FORCE $(call if_changed,objcopy) OBJCOPYFLAGS_lpc32xx-boot-1.bin = -I binary -O binary --pad-to=$(CONFIG_SPL_PAD_TO) -lpc32xx-boot-1.bin: lpc32xx-spl.img +lpc32xx-boot-1.bin: lpc32xx-spl.img FORCE $(call if_changed,objcopy) -lpc32xx-full.bin: lpc32xx-boot-0.bin lpc32xx-boot-1.bin u-boot.img +lpc32xx-full.bin: lpc32xx-boot-0.bin lpc32xx-boot-1.bin u-boot.img FORCE $(call if_changed,cat) CLEAN_FILES += lpc32xx-* @@ -1056,7 +1056,7 @@ endif cmd_ifdtool += $(IFDTOOL) $(IFDTOOL_FLAGS) u-boot.tmp; cmd_ifdtool += mv u-boot.tmp $@ -u-boot.rom: u-boot-x86-16bit.bin u-boot.bin +u-boot.rom: u-boot-x86-16bit.bin u-boot.bin FORCE $(call if_changed,ifdtool) OBJCOPYFLAGS_u-boot-x86-16bit.bin := -O binary -j .start16 -j .resetvec @@ -1171,7 +1171,7 @@ cmd_smap = \ $(CC) $(c_flags) -DSYSTEM_MAP="\"$${smap}\"" \ -c $(srctree)/common/system_map.c -o common/system_map.o -u-boot:$(u-boot-init) $(u-boot-main) u-boot.lds +u-boot:$(u-boot-init) $(u-boot-main) u-boot.lds FORCE $(call if_changed,u-boot__) ifeq ($(CONFIG_KALLSYMS),y) $(call cmd,smap) diff --git a/scripts/Makefile.spl b/scripts/Makefile.spl index d8b3947..d21c278 100644 --- a/scripts/Makefile.spl +++ b/scripts/Makefile.spl @@ -114,7 +114,7 @@ MKIMAGEFLAGS_MLO = -T omapimage -a $(CONFIG_SPL_TEXT_BASE) MKIMAGEFLAGS_MLO.byteswap = -T omapimage -n byteswap -a $(CONFIG_SPL_TEXT_BASE) -MLO MLO.byteswap: $(obj)/u-boot-spl.bin +MLO MLO.byteswap: $(obj)/u-boot-spl.bin FORCE $(call if_changed,mkimage) ifeq ($(CONFIG_SYS_SOC),"at91") @@ -126,12 +126,12 @@ MKIMAGEFLAGS_boot.bin += -n $(shell $(obj)/../tools/atmel_pmecc_params) boot.bin: $(obj)/../tools/atmel_pmecc_params endif -boot.bin: $(obj)/u-boot-spl.bin +boot.bin: $(obj)/u-boot-spl.bin FORCE $(call if_changed,mkimage) else MKIMAGEFLAGS_boot.bin = -T zynqimage -spl/boot.bin: $(obj)/u-boot-spl.bin +spl/boot.bin: $(obj)/u-boot-spl.bin FORCE $(call if_changed,mkimage) endif @@ -200,7 +200,7 @@ quiet_cmd_cpp_cfg = CFG $@ cmd_cpp_cfg = $(CPP) -Wp,-MD,$(depfile) $(cpp_flags) $(LDPPFLAGS) -ansi \ -DDO_DEPS_ONLY -D__ASSEMBLY__ -x assembler-with-cpp -P -dM -E -o $@ $< -$(obj)/$(SPL_BIN).cfg: include/config.h +$(obj)/$(SPL_BIN).cfg: include/config.h FORCE $(call if_changed,cpp_cfg) ifdef CONFIG_SAMSUNG -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v2 4/4] kbuild: fix build rule of u-boot-spl.dtb
The build command of u-boot-spl.dtb is not constant, but dependent on CONFIG_OF_SPL_REMOVE_PROPS. Use $(call if_changed,...) so that the change of CONFIG_OF_SPL_REMOVE_PROPS is detected. Also, add tools/fdtgrep to the dependency to make sure u-boot-spl.dtb is generated by the up-to-date fdtgrep in case the tool is modified. Signed-off-by: Masahiro Yamada --- Changes in v2: - add tools/fdtgrep to the dependency scripts/Makefile.spl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/Makefile.spl b/scripts/Makefile.spl index d21c278..43df675 100644 --- a/scripts/Makefile.spl +++ b/scripts/Makefile.spl @@ -193,8 +193,8 @@ quiet_cmd_fdtgrep = FDTGREP $@ $(objtree)/tools/fdtgrep -r -O dtb - -o $@ \ $(addprefix -P ,$(subst $\",,$(CONFIG_OF_SPL_REMOVE_PROPS))) -$(obj)/$(SPL_BIN).dtb: dts/dt.dtb - $(call cmd,fdtgrep) +$(obj)/$(SPL_BIN).dtb: dts/dt.dtb $(objtree)/tools/fdtgrep FORCE + $(call if_changed,fdtgrep) quiet_cmd_cpp_cfg = CFG $@ cmd_cpp_cfg = $(CPP) -Wp,-MD,$(depfile) $(cpp_flags) $(LDPPFLAGS) -ansi \ -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v2 1/4] kbuild: remove unneeded ifdef conditionals around build rules
These rules are only used for SOCFPGA, SUNXI, but no need to hide them from other SoCs. Signed-off-by: Masahiro Yamada --- Changes in v2: - Drop 3/5 ("kbuild: use $(call cmd, ) rather than $(call if_changed, ) where possible") scripts/Makefile.spl | 4 1 file changed, 4 deletions(-) diff --git a/scripts/Makefile.spl b/scripts/Makefile.spl index f486feb..adabfcf 100644 --- a/scripts/Makefile.spl +++ b/scripts/Makefile.spl @@ -228,18 +228,14 @@ ifneq ($(CONFIG_SPL_TEXT_BASE),) LDFLAGS_$(SPL_BIN) += -Ttext $(CONFIG_SPL_TEXT_BASE) endif -ifdef CONFIG_ARCH_SOCFPGA MKIMAGEFLAGS_$(SPL_BIN).sfp = -T socfpgaimage $(obj)/$(SPL_BIN).sfp: $(obj)/$(SPL_BIN).bin FORCE $(call if_changed,mkimage) -endif -ifdef CONFIG_SUNXI quiet_cmd_mksunxiboot = MKSUNXI $@ cmd_mksunxiboot = $(objtree)/tools/mksunxiboot $< $@ $(obj)/sunxi-spl.bin: $(obj)/$(SPL_BIN).bin $(call if_changed,mksunxiboot) -endif quiet_cmd_u-boot-spl = LD $@ cmd_u-boot-spl = (cd $(obj) && $(LD) $(LDFLAGS) $(LDFLAGS_$(@F)) \ -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v2 0/4] Kbuild fixes
Changes in v2: - Drop 3/5 ("kbuild: use $(call cmd, ) rather than $(call if_changed, ) where possible") - add tools/fdtgrep to the dependency Masahiro Yamada (4): kbuild: remove unneeded ifdef conditionals around build rules kbuild: sunxi: fix build rule of sunxi-spl.bin kbuild: add missing FORCE where $(call if_changed, ) is used kbuild: fix build rule of u-boot-spl.dtb Makefile | 12 ++-- scripts/Makefile.spl | 20 2 files changed, 14 insertions(+), 18 deletions(-) -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] 64-bit x86 U-Boot?
On Fri, Feb 5, 2016 at 1:41 AM, Tom Rini wrote: > On Wed, Feb 03, 2016 at 12:42:44PM +0800, Bin Meng wrote: >> Hi Simon, >> >> On Wed, Feb 3, 2016 at 12:31 PM, Simon Glass wrote: >> > Hi Bin, >> > >> > On 2 February 2016 at 08:02, Bin Meng wrote: >> >> Hi Albert, >> >> >> >> On Tue, Feb 2, 2016 at 5:53 PM, Albert ARIBAUD >> >> wrote: >> >>> Hello Bin and Simon, >> >>> >> >>> On Tue, 2 Feb 2016 15:25:48 +0800, Bin Meng wrote: >> Hi Simon, >> >> On Tue, Feb 2, 2016 at 11:58 AM, Simon Glass wrote: >> > +Bin (sorry, meant to copy you before) >> >>> >> >>> For non-FSP devices we don't init the RAM until much later - >> >>> dram_init(). That means that a significant portion of the init >> >>> sequence would be 32-bit code. I'm not sure that will work. >> >>> >> >> I believe we can do dram_init() in 64-bit mode as well if MRC is >> written in pure C. >> >>> >> >>> Bin: not sure what you mean by "if MRC is written in pure C" -- there >> >>> is no C construct that can even approach the mrc instruction, which can >> >>> only be emitted through an asm statement. >> >> >> >> You are exposed as an ARM guy :-) I was talking about an Intel term >> >> Memory Reference Code which are a amount of magic codes to initialize >> >> system RAM. >> >> >> >>> >> > I wonder whether we might need to resort to SPL for the 32-bit >> > portion, and jump to a 64-bit U-Boot from there? Tegra does something >> > similar to that. >> >>> >> >>> Simon: seems like a sensible approach, as it does not mix 32 and 64 >> >>> bits in one "build artefact", plus it seems logical in that SPL's >> >>> role is to get the platform ready for U-Boot; switching from >> >>> power-on32-bit mode to 64-bit mode belongs quite "naturally" in SPL. >> >>> >> What's the benefit of doing a 64-bit bootloader? Intel's UEFI BIOS has >> a 32-bit and 64-bit version, and has caused some troubles for the next >> stage loader (bootia32.efi vs. bootx64.efi). I know for PowerPC, a >> 64-bit U-Boot does not exist as 32-bit U-Boot can load 32-bit and >> 64-bit kernel, just like what we have for x86. 64-bit U-Boot was only >> seen on ARMv8, but that's the architecture limitation I believe, and >> we have to do that. >> >>> >> >>> Some U-Boot users who might want to get rid of x86 32-bit code in >> >>> x86 64-bit platforms just like in the past some people must have wanted >> >>> to get rid of real-mode 16-bit x86 code in order to run pure 32-bit; the >> >> >> >> Yep, but unfortunately we still cannot get rid of real-mode 16-bit x86 >> >> code even today :( >> >> >> >>> idea is that if you can do with as well as without a feature, then that >> >>> feature is potential dead code, and is candidate for removal, all the >> >>> more when that feature partly collides with another feature, as here >> >>> where 32-bit and 64-bit support sort of overlap partially. >> >>> >> >> >> >> I wonder if some day these processors (arm, x86, whatever else?) will >> >> come out of reset in the 64-bit mode directly. No more any legacy >> >> modes. At that time, 64-bit mode bootloader is definitely a must. >> > >> > ARM does. Not sure if Intel will, but they should IMO! >> > >> >> Agreed. But guess Intel won't do that due to whatever backward >> compatible reasons.. >> >> >> >> >>> Now, we can wait until x86 32-bit is really dead (as in "not used >> >>> except in a few legacy projects whose engineers' children are about to >> >>> retire") and then scrape dead code parts which no one really understands >> >>> any more, or we can try and anticipate and replace code while we still >> >>> have a grasp of what it does. I personally like the idea of anticipating >> >>> better. >> >>> >> >>> Just in case, note that I do not mean x86 32-bit support should be >> >>> removed from U-Boot now or later. I mean that if we can make x86 64-bit >> >>> support in U-Boot less and less dependent on x86 32-bit support, then I >> >>> think we should, so that the day we completely drop x86 32-bit support, >> >>> x86 64-bit support will be (as) unaffected (as possible). >> >>> >> >> >> >> I agree with the philosophy here. But I sense this might be too >> >> anticipating as there are some other tasks to do for U-Boot 32-bit >> >> like ACPI and SMM. 32-bit is enough for now, unless we want to access >> >>>4GB memory in U-Boot shell? >> > >> > Yes, I suppose there are more important things. The 32/64-bit split >> > bothers me. For example with the EFI loader series, U-Boot runs in >> > 32-bit mode so can only run a 32-bit EFI application (e.g. grub). That >> > seems like an annoying limitation. We don't have that limitation when >> > booting a kernel. >> >> Isn't the limitation coming from UEFI itself? My understanding is that >> we cannot boot a 64-bit EFI application from a 32-bit UEFI BIOS as >> well. > > Well, how much are distros going to dislike having to provide 32bit EFI > grub, for the x86 case here? > See a bl
Re: [U-Boot] [PATCH v2] arm: use common instructions applicable to armv7m & other arm archs
Hello Vikas, Am 04.02.2016 um 21:41 schrieb Vikas Manocha: This patch cleans the code by using instructions allowed for armv7m as well as other Arm archs. Signed-off-by: Vikas Manocha Reviewed-by: Simon Glass --- Changes in v2: reword message commit. Removed info regarding BIC instruction on SP, was creating confusion. arch/arm/lib/crt0.S | 25 +++-- 1 file changed, 7 insertions(+), 18 deletions(-) diff --git a/arch/arm/lib/crt0.S b/arch/arm/lib/crt0.S index 2f4c14e..3731d0c 100644 --- a/arch/arm/lib/crt0.S +++ b/arch/arm/lib/crt0.S @@ -71,18 +71,12 @@ ENTRY(_main) */ #if defined(CONFIG_SPL_BUILD) && defined(CONFIG_SPL_STACK) - ldr sp, =(CONFIG_SPL_STACK) + ldr r0, =(CONFIG_SPL_STACK) #else - ldr sp, =(CONFIG_SYS_INIT_SP_ADDR) + ldr r0, =(CONFIG_SYS_INIT_SP_ADDR) #endif -#if defined(CONFIG_CPU_V7M)/* v7M forbids using SP as BIC destination */ - mov r3, sp - bic r3, r3, #7 - mov sp, r3 -#else - bic sp, sp, #7 /* 8-byte alignment for ABI compliance */ -#endif - mov r0, sp + bic r0, r0, #7 /* 8-byte alignment for ABI compliance */ + mov sp, r0 bl board_init_f_alloc_reserve mov sp, r0 /* set up gd here, outside any C code */ @@ -100,14 +94,9 @@ ENTRY(_main) * 'here' but relocated. */ - ldr sp, [r9, #GD_START_ADDR_SP] /* sp = gd->start_addr_sp */ -#if defined(CONFIG_CPU_V7M)/* v7M forbids using SP as BIC destination */ - mov r3, sp - bic r3, r3, #7 - mov sp, r3 -#else - bic sp, sp, #7 /* 8-byte alignment for ABI compliance */ -#endif + ldr r0, [r9, #GD_START_ADDR_SP] /* sp = gd->start_addr_sp */ + bic r0, r0, #7 + mov sp, r0 /* 8-byte alignment for ABI compliance */ Why do you move this comment to the mov instruction? the "bic r0, r0, #7" does the 8-byte alignment ... please add this comment to this line, thanks! ldr r9, [r9, #GD_BD]/* r9 = gd->bd */ sub r9, r9, #GD_SIZE/* new GD is below bd */ Beside of this nitpick: Reviewed-by: Heiko Schocher bye, Heiko -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 3/5] kbuild: use $(call cmd, ) rather than $(call if_changed, ) where possible
Hi Stephen, 2016-02-04 0:57 GMT+09:00 Stephen Warren : > On 02/03/2016 05:05 AM, Masahiro Yamada wrote: >> >> These build commands are constant (mostly, just concatenating images, >> or just copying). No need to use $(call if_changed,...) for them. > > > I disagree, since I believe this change means that if someone /does/ change > the command in the future (e.g. to replace it with more complex processing, > or add additional dependencies), then the Makefile will/may not > automatically rebuild those targets, which is the entire point of using > if_changed, and is a huge benefit of using Kbuild. I do not a strong opinion about this, so I will drop 3/5 and submit v2. > In my opinion, every rule should use if_changed, and contain a single > command at the Makefile level; i.e. I noticed the following somewhere, which > also doesn't rebuild the target in all cases if the commands are changed, > which is bad: > > target: sources FORCE > $(call if_changed,xxx) > something_else > yet_more_cmds > > If "something_else" or "yet_more_cmds" are edited, the target won't get > rebuilt unless some other modification causes it to be. Patch are welcome to clean up them. -- Best Regards Masahiro Yamada ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] .travis.yml: explicitly request sudo
Hello Stephen, Am 04.02.2016 um 17:33 schrieb Stephen Warren: On 02/04/2016 02:00 AM, Heiko Schocher wrote: Hello Stephen, Am 03.02.2016 um 18:41 schrieb Stephen Warren: From: Stephen Warren Without this, builds default to using new Travis CI infra-structure which does no allow sudo. The builds need sudo in order to install the ELDK compilers. Consequently, almost all builds fail without this. I suspect that existing Travis CI users have not noticed this because their accounts or builds have been grand-fathered into backwards- compatible default settings, whereas I just set up a new build from scratch and received new default settings. Did you tried it with current ML? Or at last with the patch from Roger? http://lists.denx.de/pipermail/u-boot/2016-January/243115.html [U-Boot] [PATCH] .travis.yml: rework according to new travis-ci infra Both:-) That patch is already applied in mainline, and was included in the branch I pushed "to" Travis. If I look into: https://travis-ci.org/u-boot/u-boot There are only mips and m68k for which the build fail ... Yes. With the addition of the sudo tag, the same is now true for my branch. Great! So I would say: Acked-by: Heiko Schocher bye, Heiko -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] armv7: ls102xa: Move smmu and stream id initialization into the common soc code
The initialization for smmu and stream id is moved into the common soc code. Signed-off-by: Alison Wang --- arch/arm/cpu/armv7/ls102xa/soc.c| 48 + arch/arm/include/asm/arch-ls102xa/ls102xa_soc.h | 2 ++ board/freescale/ls1021aqds/ls1021aqds.c | 42 +- board/freescale/ls1021atwr/ls1021atwr.c | 43 +- 4 files changed, 52 insertions(+), 83 deletions(-) diff --git a/arch/arm/cpu/armv7/ls102xa/soc.c b/arch/arm/cpu/armv7/ls102xa/soc.c index 79ae883..b1b0c71 100644 --- a/arch/arm/cpu/armv7/ls102xa/soc.c +++ b/arch/arm/cpu/armv7/ls102xa/soc.c @@ -9,6 +9,43 @@ #include #include #include +#include + +struct liodn_id_table sec_liodn_tbl[] = { + SET_SEC_JR_LIODN_ENTRY(0, 0x10, 0x10), + SET_SEC_JR_LIODN_ENTRY(1, 0x10, 0x10), + SET_SEC_JR_LIODN_ENTRY(2, 0x10, 0x10), + SET_SEC_JR_LIODN_ENTRY(3, 0x10, 0x10), + SET_SEC_RTIC_LIODN_ENTRY(a, 0x10), + SET_SEC_RTIC_LIODN_ENTRY(b, 0x10), + SET_SEC_RTIC_LIODN_ENTRY(c, 0x10), + SET_SEC_RTIC_LIODN_ENTRY(d, 0x10), + SET_SEC_DECO_LIODN_ENTRY(0, 0x10, 0x10), + SET_SEC_DECO_LIODN_ENTRY(1, 0x10, 0x10), + SET_SEC_DECO_LIODN_ENTRY(2, 0x10, 0x10), + SET_SEC_DECO_LIODN_ENTRY(3, 0x10, 0x10), + SET_SEC_DECO_LIODN_ENTRY(4, 0x10, 0x10), + SET_SEC_DECO_LIODN_ENTRY(5, 0x10, 0x10), + SET_SEC_DECO_LIODN_ENTRY(6, 0x10, 0x10), + SET_SEC_DECO_LIODN_ENTRY(7, 0x10, 0x10), +}; + +struct smmu_stream_id dev_stream_id[] = { + { 0x100, 0x01, "ETSEC MAC1" }, + { 0x104, 0x02, "ETSEC MAC2" }, + { 0x108, 0x03, "ETSEC MAC3" }, + { 0x10c, 0x04, "PEX1" }, + { 0x110, 0x05, "PEX2" }, + { 0x114, 0x06, "qDMA" }, + { 0x118, 0x07, "SATA" }, + { 0x11c, 0x08, "USB3" }, + { 0x120, 0x09, "QE" }, + { 0x124, 0x0a, "eSDHC" }, + { 0x128, 0x0b, "eMA" }, + { 0x14c, 0x0c, "2D-ACE" }, + { 0x150, 0x0d, "USB2" }, + { 0x18c, 0x0e, "DEBUG" }, +}; unsigned int get_soc_major_rev(void) { @@ -88,3 +125,14 @@ int arch_soc_init(void) return 0; } + +int ls102xa_smmu_stream_id_init(void) +{ + ls1021x_config_caam_stream_id(sec_liodn_tbl, + ARRAY_SIZE(sec_liodn_tbl)); + + ls102xa_config_smmu_stream_id(dev_stream_id, + ARRAY_SIZE(dev_stream_id)); + + return 0; +} diff --git a/arch/arm/include/asm/arch-ls102xa/ls102xa_soc.h b/arch/arm/include/asm/arch-ls102xa/ls102xa_soc.h index f10cb91..a354684 100644 --- a/arch/arm/include/asm/arch-ls102xa/ls102xa_soc.h +++ b/arch/arm/include/asm/arch-ls102xa/ls102xa_soc.h @@ -9,4 +9,6 @@ unsigned int get_soc_major_rev(void); int arch_soc_init(void); +int ls102xa_smmu_stream_id_init(void); + #endif /* __FSL_LS102XA_SOC_H */ diff --git a/board/freescale/ls1021aqds/ls1021aqds.c b/board/freescale/ls1021aqds/ls1021aqds.c index 5f4ec9d..b0a1d3e 100644 --- a/board/freescale/ls1021aqds/ls1021aqds.c +++ b/board/freescale/ls1021aqds/ls1021aqds.c @@ -10,7 +10,6 @@ #include #include #include -#include #include #include #include @@ -426,42 +425,6 @@ int misc_init_r(void) return 0; } -struct liodn_id_table sec_liodn_tbl[] = { - SET_SEC_JR_LIODN_ENTRY(0, 0x10, 0x10), - SET_SEC_JR_LIODN_ENTRY(1, 0x10, 0x10), - SET_SEC_JR_LIODN_ENTRY(2, 0x10, 0x10), - SET_SEC_JR_LIODN_ENTRY(3, 0x10, 0x10), - SET_SEC_RTIC_LIODN_ENTRY(a, 0x10), - SET_SEC_RTIC_LIODN_ENTRY(b, 0x10), - SET_SEC_RTIC_LIODN_ENTRY(c, 0x10), - SET_SEC_RTIC_LIODN_ENTRY(d, 0x10), - SET_SEC_DECO_LIODN_ENTRY(0, 0x10, 0x10), - SET_SEC_DECO_LIODN_ENTRY(1, 0x10, 0x10), - SET_SEC_DECO_LIODN_ENTRY(2, 0x10, 0x10), - SET_SEC_DECO_LIODN_ENTRY(3, 0x10, 0x10), - SET_SEC_DECO_LIODN_ENTRY(4, 0x10, 0x10), - SET_SEC_DECO_LIODN_ENTRY(5, 0x10, 0x10), - SET_SEC_DECO_LIODN_ENTRY(6, 0x10, 0x10), - SET_SEC_DECO_LIODN_ENTRY(7, 0x10, 0x10), -}; - -struct smmu_stream_id dev_stream_id[] = { - { 0x100, 0x01, "ETSEC MAC1" }, - { 0x104, 0x02, "ETSEC MAC2" }, - { 0x108, 0x03, "ETSEC MAC3" }, - { 0x10c, 0x04, "PEX1" }, - { 0x110, 0x05, "PEX2" }, - { 0x114, 0x06, "qDMA" }, - { 0x118, 0x07, "SATA" }, - { 0x11c, 0x08, "USB3" }, - { 0x120, 0x09, "QE" }, - { 0x124, 0x0a, "eSDHC" }, - { 0x128, 0x0b, "eMA" }, - { 0x14c, 0x0c, "2D-ACE" }, - { 0x150, 0x0d, "USB2" }, - { 0x18c, 0x0e, "DEBUG" }, -}; - int board_init(void) { struct ccsr_cci400 *cci = (struct ccsr_cci400 *)CONFIG_SYS_CCI400_ADDR; @@ -481,10 +444,7 @@ int board_init(void) config_serdes_mux(); #endif - ls1021x_config_caam_stream_id(sec_liodn_tbl, - ARRAY_SIZE(sec_liodn_tbl)); - ls102xa_config_smmu_stream_id(dev_stream_id, - ARRAY_SIZE(dev_stream_id)); +
[U-Boot] Please pull u-boot-x86
Hi Tom, This includes changes to move all x86 codes to use DM PCI APIs completely. Now DM_PCI_COMPAT is disabled in the x86 build. The following changes since commit 94985cc9d3d7ed991ca8b2627d5894df5ea68f49: Merge branch 'master' of git://git.denx.de/u-boot-usb (2016-02-04 06:56:23 -0500) are available in the git repository at: git://git.denx.de/u-boot-x86.git master for you to fetch changes up to 5c884420a5752163ce738701701ae1874d8f466d: x86: Drop pci_type1.c and DEFINE_PCI_DEVICE_TABLE (2016-02-05 12:47:24 +0800) Bin Meng (34): spi: ich: Some clean up spi: ich: Use compatible strings to distinguish controller version spi: ich: Change PCHV_ to ICHV_ x86: tnc: Drop unprotect_spi_flash() x86: quark: Drop unprotect_spi_flash() dm: pch: Remove pch_get_version op dm: pch: Rename get_sbase op to get_spi_base dm: pch: Add get_gpio_base op x86: pch: Implement get_gpio_base op dm: pch: Add get_io_base op x86: pch9: Implement get_io_base op x86: ich6_gpio: Convert to use proper DM API x86: Drop asm/arch/gpio.h x86: minnowmax: Drop io-base property in the pch_pinctrl node x86: irq: Get irq_router's bdf via dm_pci_get_bdf() x86: irq: Move irq_router to a per driver priv x86: irq: Convert to use DM PCI API x86: tnc: Change disable_igd() to have a return value x86: tnc: Use DM PCI API in disable_igd() x86: tnc: Remove IGD and SDVO devices from driver model x86: qemu: Convert to use DM PCI API x86: pci: Use DM PCI APIs in pci_assign_irqs() x86: pci: Drop legacy PCI APIs net: pch_gbe: Convert to use DM PCI API net: designware: Use dm_pci_mem_to_phys() in the probe routine net: e1000: Convert to use DM PCI API x86: quark: Use Quark's own PCI config APIs efi: app: Clean up defconfig efi: app: Disable CONFIG_USB_EHCI_PCI x86: chromebox_panther: Drop the cache line size hack x86: chromebox_panther: Convert to use driver model ethernet dm: pci: Add missing forward declarations x86: Disable DM_PCI_COMPAT x86: Drop pci_type1.c and DEFINE_PCI_DEVICE_TABLE Stefan Roese (2): autoboot.c: Fill env vars in process_fdt_options() only if TEXT_BASE is set x86: x86-common.h: Add CONFIG_BOOTDELAY arch/x86/Kconfig | 3 --- arch/x86/cpu/irq.c | 80 ++- arch/x86/cpu/ivybridge/bd82x6x.c | 43 +++--- arch/x86/cpu/pci.c | 59 +++ arch/x86/cpu/qemu/qemu.c | 34 +-- arch/x86/cpu/quark/mrc_util.c | 5 ++-- arch/x86/cpu/quark/quark.c | 17 -- arch/x86/cpu/queensbay/irq.c | 2 +- arch/x86/cpu/queensbay/tnc.c | 80 +++ arch/x86/dts/bayleybay.dts | 88 +++-- arch/x86/dts/broadwell_som-6896.dts| 2 +- arch/x86/dts/chromebook_link.dts | 44 +-- arch/x86/dts/chromebox_panther.dts | 46 +++-- arch/x86/dts/crownbay.dts | 32 ++ arch/x86/dts/galileo.dts | 30 +--- arch/x86/dts/minnowmax.dts | 89 +++--- arch/x86/include/asm/arch-baytrail/gpio.h | 13 --- arch/x86/include/asm/arch-coreboot/gpio.h | 13 --- arch/x86/include/asm/arch-efi/gpio.h | 10 arch/x86/include/asm/arch-ivybridge/gpio.h | 13 --- arch/x86/include/asm/arch-qemu/gpio.h | 13 --- arch/x86/include/asm/arch-quark/gpio.h | 13 --- arch/x86/include/asm/arch-queensbay/gpio.h | 13 --- arch/x86/include/asm/gpio.h| 1 - arch/x86/include/asm/pci.h | 19 --- arch/x86/include/asm/pirq_routing.h| 12 ++ arch/x86/lib/Makefile | 3 --- arch/x86/lib/pci_type1.c | 50 arch/x86/lib/pirq_routing.c| 12 +- board/intel/galileo/galileo.c | 5 ++-- common/autoboot.c | 4 ++-- configs/chromebox_panther_defconfig| 1 + configs/efi-x86_defconfig | 2 +- drivers/gpio/intel_ich6_gpio.c | 125 +++ drivers/net/designware.c | 4 +--- drivers/net/e1000.c
Re: [U-Boot] [PATCH 11/11] x86: Drop pci_type1.c and DEFINE_PCI_DEVICE_TABLE
On Wed, Feb 3, 2016 at 11:28 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> Now that we have converted all x86 codes to DM PCI, drop pci_type1.c >> which is only built for legacy PCI. Also per checkpatch.pl warning, >> DEFINE_PCI_DEVICE_TABLE is now deprecated so drop that too. >> >> Signed-off-by: Bin Meng >> >> --- >> >> arch/x86/include/asm/pci.h | 7 --- >> arch/x86/lib/Makefile | 3 --- >> arch/x86/lib/pci_type1.c | 50 >> -- >> 3 files changed, 60 deletions(-) >> delete mode 100644 arch/x86/lib/pci_type1.c > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 08/11] x86: chromebox_panther: Convert to use driver model ethernet
On Wed, Feb 3, 2016 at 11:27 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> This board uses RTL8169 which is a driver model ethernet driver. >> >> Signed-off-by: Bin Meng >> --- >> >> configs/chromebox_panther_defconfig | 1 + >> 1 file changed, 1 insertion(+) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 07/11] x86: chromebox_panther: Drop the cache line size hack
On Wed, Feb 3, 2016 at 11:27 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> Now that the RTL8169 driver warning is fixed we can drop this. >> >> Signed-off-by: Bin Meng >> --- >> >> include/configs/chromebox_panther.h | 2 -- >> 1 file changed, 2 deletions(-) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 09/11] dm: pci: Add missing forward declarations
On Wed, Feb 3, 2016 at 11:28 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> When CONFIG_DM_PCI_COMPAT is not on, there is only a forward declaration >> for pci_write_config32(). Add other missing ones. >> >> Signed-off-by: Bin Meng >> --- >> >> include/pci.h | 16 +--- >> 1 file changed, 5 insertions(+), 11 deletions(-) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 10/11] x86: Disable DM_PCI_COMPAT
On Tue, Feb 2, 2016 at 9:58 PM, Bin Meng wrote: > Now that all x86 codes have been converted to use proper DM PCI APIs, > it's time to disable the legacy compatible layer. > > Signed-off-by: Bin Meng > --- > > arch/x86/Kconfig | 3 --- > 1 file changed, 3 deletions(-) > applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 04/11] x86: quark: Use Quark's own PCI config APIs
On Wed, Feb 3, 2016 at 11:27 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> There are still two places in Quark's MRC codes that use the generic >> legacy PCI APIs, but as we are phasing out these legacy APIs, switch >> to use Quark's own PCI config routines. >> >> Signed-off-by: Bin Meng >> --- >> >> arch/x86/cpu/quark/mrc_util.c | 5 +++-- >> 1 file changed, 3 insertions(+), 2 deletions(-) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 03/11] net: e1000: Convert to use DM PCI API
On Wed, Feb 3, 2016 at 11:27 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> Update this driver to use proper DM PCI APIs. >> >> Signed-off-by: Bin Meng >> --- >> >> drivers/net/e1000.c | 75 >> - >> drivers/net/e1000.h | 4 +++ >> 2 files changed, 78 insertions(+), 1 deletion(-) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 01/11] net: pch_gbe: Convert to use DM PCI API
On Wed, Feb 3, 2016 at 11:27 AM, Simon Glass wrote: > On 2 February 2016 at 06:57, Bin Meng wrote: >> Use native DM PCI APIs instead of legacy compatible ones. >> >> Signed-off-by: Bin Meng >> --- >> >> drivers/net/pch_gbe.c | 27 --- >> drivers/net/pch_gbe.h | 2 +- >> 2 files changed, 13 insertions(+), 16 deletions(-) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 05/11] efi: app: Clean up defconfig
On Wed, Feb 3, 2016 at 11:27 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> Move some #undef from efi-x86.h to efi-x86_defconfig as these are >> already Kconfig options. >> >> Signed-off-by: Bin Meng >> --- >> >> configs/efi-x86_defconfig | 2 +- >> include/configs/efi-x86.h | 3 --- >> 2 files changed, 1 insertion(+), 4 deletions(-) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 06/11] efi: app: Disable CONFIG_USB_EHCI_PCI
On Wed, Feb 3, 2016 at 11:27 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> It does not build if without CONFIG_DM_PCI_COMPAT. For now we just >> disable it, until some day we add USB support to EFI application. >> >> Signed-off-by: Bin Meng >> --- >> >> include/configs/efi-x86.h | 1 + >> 1 file changed, 1 insertion(+) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 02/11] net: designware: Use dm_pci_mem_to_phys() in the probe routine
On Wed, Feb 3, 2016 at 11:27 AM, Simon Glass wrote: > On 2 February 2016 at 06:58, Bin Meng wrote: >> Convert to use native DM PCI API dm_pci_mem_to_phys(). >> >> Signed-off-by: Bin Meng >> --- >> >> drivers/net/designware.c | 4 +--- >> 1 file changed, 1 insertion(+), 3 deletions(-) > > Reviewed-by: Simon Glass applied to u-boot-x86/master, thanks! ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v2 2/2] ARM: uniphier: move cmd_ddrmphy.c to fix build error
If CONFIG_CMD_DDRMPHY_DUMP is enabled, the build fails. Fixes: 93d92d46cd01 ("ARM: uniphier: add dump command for DDR Multi PHY registers") Signed-off-by: Masahiro Yamada --- Changes in v2: None arch/arm/mach-uniphier/{ => dram}/cmd_ddrmphy.c | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename arch/arm/mach-uniphier/{ => dram}/cmd_ddrmphy.c (100%) diff --git a/arch/arm/mach-uniphier/cmd_ddrmphy.c b/arch/arm/mach-uniphier/dram/cmd_ddrmphy.c similarity index 100% rename from arch/arm/mach-uniphier/cmd_ddrmphy.c rename to arch/arm/mach-uniphier/dram/cmd_ddrmphy.c -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v2 1/2] ARM: uniphier: fix makefiles to build cmd_ddr(m)phy.c
The U-Boot proper building needs to descend arch/arm/mach-uniphier/dram to build these commands. Fixes: 93d92d46cd01 ("ARM: uniphier: add dump command for DDR Multi PHY registers") Signed-off-by: Masahiro Yamada --- Changes in v2: - Newly added arch/arm/mach-uniphier/Makefile | 3 ++- arch/arm/mach-uniphier/dram/Makefile | 6 ++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-uniphier/Makefile b/arch/arm/mach-uniphier/Makefile index 491e78e..e65d602 100644 --- a/arch/arm/mach-uniphier/Makefile +++ b/arch/arm/mach-uniphier/Makefile @@ -6,7 +6,7 @@ ifdef CONFIG_SPL_BUILD obj-y += lowlevel_init.o -obj-y += init/ bcu/ memconf/ pll/ early-clk/ early-pinctrl/ dram/ +obj-y += init/ bcu/ memconf/ pll/ early-clk/ early-pinctrl/ obj-$(CONFIG_MICRO_SUPPORT_CARD) += sbc/ obj-$(CONFIG_DEBUG_LL) += debug_ll.o @@ -32,5 +32,6 @@ obj-y += timer.o obj-y += boards.o obj-y += soc_info.o obj-y += boot-mode/ +obj-y += dram/ obj-$(CONFIG_MICRO_SUPPORT_CARD) += micro-support-card.o diff --git a/arch/arm/mach-uniphier/dram/Makefile b/arch/arm/mach-uniphier/dram/Makefile index cab7df1..a0a6003 100644 --- a/arch/arm/mach-uniphier/dram/Makefile +++ b/arch/arm/mach-uniphier/dram/Makefile @@ -2,6 +2,8 @@ # SPDX-License-Identifier: GPL-2.0+ # +ifdef CONFIG_SPL_BUILD + obj-$(CONFIG_ARCH_UNIPHIER_PH1_LD4)+= umc-ph1-ld4.o \ ddrphy-training.o ddrphy-ph1-ld4.o obj-$(CONFIG_ARCH_UNIPHIER_PH1_PRO4) += umc-ph1-pro4.o \ @@ -11,5 +13,9 @@ obj-$(CONFIG_ARCH_UNIPHIER_PH1_SLD8) += umc-ph1-sld8.o \ obj-$(CONFIG_ARCH_UNIPHIER_PROXSTREAM2)+= umc-proxstream2.o obj-$(CONFIG_ARCH_UNIPHIER_PH1_LD6B) += umc-proxstream2.o +else + obj-$(CONFIG_CMD_DDRPHY_DUMP) += cmd_ddrphy.o obj-$(CONFIG_CMD_DDRMPHY_DUMP) += cmd_ddrmphy.o + +endif -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] ARM: uniphier: adjust DDR clock delay line for ProXstream2
It turned out that DDR channel 2 was not working on ProXstream2 Vodka board. Add the missing ACBLDR0 register setting to adjust the delay between the clock lines and the address/command lines. Signed-off-by: Masahiro Yamada --- arch/arm/mach-uniphier/dram/umc-proxstream2.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-uniphier/dram/umc-proxstream2.c b/arch/arm/mach-uniphier/dram/umc-proxstream2.c index bb7acde..6e7fa88 100644 --- a/arch/arm/mach-uniphier/dram/umc-proxstream2.c +++ b/arch/arm/mach-uniphier/dram/umc-proxstream2.c @@ -18,6 +18,8 @@ #include "ddrmphy-regs.h" #include "umc-regs.h" +#define CH_NR 3 + enum dram_freq { FREQ_1866M, FREQ_2133M, @@ -43,6 +45,9 @@ static u32 ddrphy_dtpr3[FREQ_NR] = {0x0010cb49, 0x0010ec89}; static u32 ddrphy_mr0[FREQ_NR] = {0x0115, 0x0125}; static u32 ddrphy_mr2[FREQ_NR] = {0x02a0, 0x02a8}; +/* dependent on package and board design */ +static u32 ddrphy_acbdlr0[CH_NR] = {0x000c, 0x000c, 0x0009}; + static u32 umc_cmdctla[FREQ_NR] = {0x66DD131D, 0x77EE1722}; /* * The ch2 is a different generation UMC core. @@ -150,7 +155,8 @@ static int ddrphy_get_system_latency(void __iomem *phy_base, int width) return dgsl_max; } -static void ddrphy_init(void __iomem *phy_base, enum dram_freq freq, int width) +static void ddrphy_init(void __iomem *phy_base, enum dram_freq freq, int width, + int ch) { u32 tmp; void __iomem *zq_base, *dx_base; @@ -178,6 +184,8 @@ static void ddrphy_init(void __iomem *phy_base, enum dram_freq freq, int width) writel(ddrphy_ptr3[freq], phy_base + DMPHY_PTR3); writel(ddrphy_ptr4[freq], phy_base + DMPHY_PTR4); + writel(ddrphy_acbdlr0[ch], phy_base + DMPHY_ACBDLR0); + writel(0x, phy_base + DMPHY_ACIOCR1); writel(0x, phy_base + DMPHY_ACIOCR2); writel(0x, phy_base + DMPHY_ACIOCR3); @@ -528,7 +536,7 @@ static int umc_init(void __iomem *umc_base, enum dram_freq freq, int ch, writel(UMC_DIOCTLA_CTL_NRST | UMC_DIOCTLA_CFG_NRST, umc_dc_base + UMC_DIOCTLA); - ddrphy_init(phy_base, freq, width); + ddrphy_init(phy_base, freq, width, ch); ret = ddrphy_impedance_calibration(phy_base); if (ret) -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v5 2/4] board: ls1043ardb: Add micro QE support for ls1043ardb
There are uQE on ls1043ardb board, add uQE support for the board. Call u_qe_init in ls1043ardb's board_init. Signed-off-by: Zhao Qiang --- Changes for v2: - get qe_immr directly instead of qe_base Changes for v3: - NA Changes for v4: - NA Changes for v5: - rebase on patch http://patchwork.ozlabs.org/patch/572697/ - modify commit message board/freescale/ls1043ardb/ls1043ardb.c | 8 drivers/qe/qe.c | 6 ++ include/configs/ls1043ardb.h| 7 +++ 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/board/freescale/ls1043ardb/ls1043ardb.c b/board/freescale/ls1043ardb/ls1043ardb.c index c8f723a..2e61f3a 100644 --- a/board/freescale/ls1043ardb/ls1043ardb.c +++ b/board/freescale/ls1043ardb/ls1043ardb.c @@ -21,6 +21,10 @@ #include #include #include "cpld.h" +#ifdef CONFIG_U_QE +#include +#endif + DECLARE_GLOBAL_DATA_PTR; @@ -113,6 +117,10 @@ int board_init(void) enable_layerscape_ns_access(); #endif +#ifdef CONFIG_U_QE + u_qe_init(); +#endif + return 0; } diff --git a/drivers/qe/qe.c b/drivers/qe/qe.c index 2a9e61b..8a432a8 100644 --- a/drivers/qe/qe.c +++ b/drivers/qe/qe.c @@ -192,8 +192,7 @@ void qe_init(uint qe_base) #ifdef CONFIG_U_QE void u_qe_init(void) { - uint qe_base = CONFIG_SYS_IMMR + 0x0140; /* QE immr base */ - qe_immr = (qe_map_t *)qe_base; + qe_immr = (qe_map_t *)(CONFIG_SYS_IMMR + QE_IMMR_OFFSET); u_qe_upload_firmware((const void *)CONFIG_SYS_QE_FW_ADDR); out_be32(&qe_immr->iram.iready, QE_IRAM_READY); @@ -204,9 +203,8 @@ void u_qe_init(void) void u_qe_resume(void) { qe_map_t *qe_immrr; - uint qe_base = CONFIG_SYS_IMMR + QE_IMMR_OFFSET; /* QE immr base */ - qe_immrr = (qe_map_t *)qe_base; + qe_immrr = (qe_map_t *)(CONFIG_SYS_IMMR + QE_IMMR_OFFSET); u_qe_firmware_resume((const void *)CONFIG_SYS_QE_FW_ADDR, qe_immrr); out_be32(&qe_immrr->iram.iready, QE_IRAM_READY); } diff --git a/include/configs/ls1043ardb.h b/include/configs/ls1043ardb.h index 506f50d..bc40b06 100644 --- a/include/configs/ls1043ardb.h +++ b/include/configs/ls1043ardb.h @@ -268,6 +268,13 @@ #define CONFIG_ETHPRIME"FM1@DTSEC3" #endif +/* QE */ +#if !defined(CONFIG_SD_BOOT) && !defined(CONFIG_NAND_BOOT) && \ + !defined(CONFIG_QSPI_BOOT) +#define CONFIG_U_QE +#endif +#define CONFIG_SYS_QE_FW_ADDR 0x6060 + /* USB */ #define CONFIG_HAS_FSL_XHCI_USB #ifdef CONFIG_HAS_FSL_XHCI_USB -- 2.1.0.27.g96db324 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v5 3/4] borad: ls1043rdb: Move USB muxing config to config_board_mux
Pin-muxing code should be in config_board_mux, move USB muxing config to config_board_mux. Signed-off-by: Zhao Qiang --- Changes for v2: - NA Changes for v3: - split from "[PATCH v2 3/3] QE: assgin pins to QE-HDLC" Changes for v4: - NA Changes for v5: - modify the commit message board/freescale/ls1043ardb/ls1043ardb.c | 30 +++--- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/board/freescale/ls1043ardb/ls1043ardb.c b/board/freescale/ls1043ardb/ls1043ardb.c index 2e61f3a..dafe7c9 100644 --- a/board/freescale/ls1043ardb/ls1043ardb.c +++ b/board/freescale/ls1043ardb/ls1043ardb.c @@ -75,23 +75,8 @@ int dram_init(void) int board_early_init_f(void) { - struct ccsr_scfg *scfg = (struct ccsr_scfg *)CONFIG_SYS_FSL_SCFG_ADDR; - u32 usb_pwrfault; - fsl_lsch2_early_init_f(); -#ifdef CONFIG_HAS_FSL_XHCI_USB - out_be32(&scfg->rcwpmuxcr0, 0x); - out_be32(&scfg->usbdrvvbus_selcr, SCFG_USBDRVVBUS_SELCR_USB1); - usb_pwrfault = (SCFG_USBPWRFAULT_DEDICATED << - SCFG_USBPWRFAULT_USB3_SHIFT) | - (SCFG_USBPWRFAULT_DEDICATED << - SCFG_USBPWRFAULT_USB2_SHIFT) | - (SCFG_USBPWRFAULT_SHARED << -SCFG_USBPWRFAULT_USB1_SHIFT); - out_be32(&scfg->usbpwrfault_selcr, usb_pwrfault); -#endif - return 0; } @@ -126,6 +111,21 @@ int board_init(void) int config_board_mux(void) { + struct ccsr_scfg *scfg = (struct ccsr_scfg *)CONFIG_SYS_FSL_SCFG_ADDR; + u32 usb_pwrfault; + +#ifdef CONFIG_HAS_FSL_XHCI_USB + out_be32(&scfg->rcwpmuxcr0, 0x); + out_be32(&scfg->usbdrvvbus_selcr, SCFG_USBDRVVBUS_SELCR_USB1); + usb_pwrfault = (SCFG_USBPWRFAULT_DEDICATED << + SCFG_USBPWRFAULT_USB3_SHIFT) | + (SCFG_USBPWRFAULT_DEDICATED << + SCFG_USBPWRFAULT_USB2_SHIFT) | + (SCFG_USBPWRFAULT_SHARED << +SCFG_USBPWRFAULT_USB1_SHIFT); + out_be32(&scfg->usbpwrfault_selcr, usb_pwrfault); +#endif + return 0; } -- 2.1.0.27.g96db324 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v5 4/4] board: ls1043ardb: Modify pin-muxing code for USB and QE-HDLC
QE-HDLC and USB multi-use the pins, modify the pin-muxing code for them, when set "hwconfig=qe-hdlc" in uboot, assign the pins to QE-HDLC, if not, assgin it to USB Signed-off-by: Zhao Qiang --- Changes for v2: - NA Changes for v3: - split from "[PATCH v2 3/3] QE: assgin pins to QE-HDLC" Changes for v4: - modify the format of multi-line comments Changes for v5: - modify the commit message board/freescale/ls1043ardb/ls1043ardb.c | 53 ++--- 1 file changed, 43 insertions(+), 10 deletions(-) diff --git a/board/freescale/ls1043ardb/ls1043ardb.c b/board/freescale/ls1043ardb/ls1043ardb.c index dafe7c9..66d974a 100644 --- a/board/freescale/ls1043ardb/ls1043ardb.c +++ b/board/freescale/ls1043ardb/ls1043ardb.c @@ -114,18 +114,24 @@ int config_board_mux(void) struct ccsr_scfg *scfg = (struct ccsr_scfg *)CONFIG_SYS_FSL_SCFG_ADDR; u32 usb_pwrfault; + if (hwconfig("qe-hdlc")) { + out_be32(&scfg->rcwpmuxcr0, +(in_be32(&scfg->rcwpmuxcr0) & ~0xff00) | 0x6600); + printf("Assign to qe-hdlc clk, rcwpmuxcr0=%x\n", + in_be32(&scfg->rcwpmuxcr0)); + } else { #ifdef CONFIG_HAS_FSL_XHCI_USB - out_be32(&scfg->rcwpmuxcr0, 0x); - out_be32(&scfg->usbdrvvbus_selcr, SCFG_USBDRVVBUS_SELCR_USB1); - usb_pwrfault = (SCFG_USBPWRFAULT_DEDICATED << - SCFG_USBPWRFAULT_USB3_SHIFT) | - (SCFG_USBPWRFAULT_DEDICATED << - SCFG_USBPWRFAULT_USB2_SHIFT) | - (SCFG_USBPWRFAULT_SHARED << -SCFG_USBPWRFAULT_USB1_SHIFT); - out_be32(&scfg->usbpwrfault_selcr, usb_pwrfault); + out_be32(&scfg->rcwpmuxcr0, 0x); + out_be32(&scfg->usbdrvvbus_selcr, SCFG_USBDRVVBUS_SELCR_USB1); + usb_pwrfault = (SCFG_USBPWRFAULT_DEDICATED << + SCFG_USBPWRFAULT_USB3_SHIFT) | + (SCFG_USBPWRFAULT_DEDICATED << + SCFG_USBPWRFAULT_USB2_SHIFT) | + (SCFG_USBPWRFAULT_SHARED << +SCFG_USBPWRFAULT_USB1_SHIFT); + out_be32(&scfg->usbpwrfault_selcr, usb_pwrfault); #endif - + } return 0; } @@ -152,6 +158,16 @@ int misc_init_r(void) } #endif +void fdt_del_qe(void *blob) +{ + int nodeoff = 0; + + while ((nodeoff = fdt_node_offset_by_compatible(blob, 0, + "fsl,qe")) >= 0) { + fdt_del_node(blob, nodeoff); + } +} + int ft_board_setup(void *blob, bd_t *bd) { u64 base[CONFIG_NR_DRAM_BANKS]; @@ -169,6 +185,23 @@ int ft_board_setup(void *blob, bd_t *bd) #ifdef CONFIG_SYS_DPAA_FMAN fdt_fixup_fman_ethernet(blob); #endif + + /* +* qe-hdlc and usb multi-use the pins, +* when set hwconfig to qe-hdlc, delete usb node. +*/ + if (hwconfig("qe-hdlc")) +#ifdef CONFIG_HAS_FSL_XHCI_USB + fdt_del_node_and_alias(blob, "usb1"); +#endif + /* +* qe just support qe-uart and qe-hdlc, +* if qe-uart and qe-hdlc are not set in hwconfig, +* delete qe node. +*/ + if (!hwconfig("qe-uart") && !hwconfig("qe-hdlc")) + fdt_del_qe(blob); + return 0; } -- 2.1.0.27.g96db324 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v5 1/4] driver: qe: Mask the codes not used for micro QE
there are some code in qe.c not used for micro QE, use "#ifdef CONFIG_QE" to mask them. Signed-off-by: Zhao Qiang --- Changes for v2: - new added Changes for v3: - NA Changes for v4: - NA Changes for v5: - modify commit message drivers/qe/qe.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/qe/qe.c b/drivers/qe/qe.c index 08620b2..2a9e61b 100644 --- a/drivers/qe/qe.c +++ b/drivers/qe/qe.c @@ -20,7 +20,9 @@ #define MPC85xx_DEVDISR_QE_DISABLE 0x1 qe_map_t *qe_immr = NULL; +#ifdef CONFIG_QE static qe_snum_t snums[QE_NUM_OF_SNUM]; +#endif DECLARE_GLOBAL_DATA_PTR; @@ -81,6 +83,7 @@ void *qe_muram_addr(uint offset) return (void *)&qe_immr->muram[offset]; } +#ifdef CONFIG_QE static void qe_sdma_init(void) { volatile sdma_t *p; @@ -184,6 +187,7 @@ void qe_init(uint qe_base) qe_sdma_init(); qe_snums_init(); } +#endif #ifdef CONFIG_U_QE void u_qe_init(void) @@ -214,6 +218,7 @@ void qe_reset(void) (u8) QE_CR_PROTOCOL_UNSPECIFIED, 0); } +#ifdef CONFIG_QE void qe_assign_page(uint snum, uint para_ram_base) { u32 cecr; @@ -229,6 +234,7 @@ void qe_assign_page(uint snum, uint para_ram_base) return; } +#endif /* * brg: 0~15 as BRG1~BRG16 -- 2.1.0.27.g96db324 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support
> -Original Message- > From: york sun > Sent: Thursday, February 04, 2016 10:15 PM > To: Harninder Rai; u-boot@lists.denx.de > Subject: Re: [U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support > > Rai, > > On 02/04/2016 06:25 AM, Rai Harninder wrote: > > The fuse status register provides the values from on-chip voltage ID > > efuses programmed at the factory. These values define the voltage > > requirements for the chip. u-boot reads FUSESR and translates the > > values into the appropriate commands to set the voltage output value > > of an external voltage regulator. > > No need to repeat what VID feature is. Instead, please focus on what this > patch > does. Ok. Will fix it in next revision of the patch > > > > > #include > > #ifdef CONFIG_LS1043A > > #include > > +#elif defined(CONFIG_FSL_LAYERSCAPE) > > +#include > > It is not appropriate to use macro CONFIG_FSL_LAYERSCAPE here. It is defined > for > both LS1043 and LS2080. Ok. I will instead use CONFIG_LS2080A > > > #else > > #include > > #endif > > @@ -285,7 +287,7 @@ static int set_voltage(int i2caddress, int vdd) > > int adjust_vdd(ulong vdd_override) { > > int re_enable = disable_interrupts(); -#ifdef CONFIG_LS1043A > > +#if defined(CONFIG_LS1043A) || defined(CONFIG_FSL_LAYERSCAPE) > > struct ccsr_gur *gur = (void *)(CONFIG_SYS_FSL_GUTS_ADDR); #else > > Same here. > > > > +#ifdef CONFIG_FSL_LAYERSCAPE > > + fusesr = in_le32(&gur->dcfg_fusesr); #else > > fusesr = in_be32(&gur->dcfg_fusesr); > > +#endif > > Are you sure you are not breaking LS1043 here? My bad. As per your earlier comment, I shouldn't have used CONFIG_LAYERSCAPE. > > > + > > #ifndef __ASSEMBLY__ > > unsigned long get_board_sys_clk(void); #endif > > > > While you debug this feature on RDB board, please take a look at QDS as well. Ok. Thanks for pointing out > > York ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support
> -Original Message- > From: U-Boot [mailto:u-boot-boun...@lists.denx.de] On Behalf Of york sun > Sent: Thursday, February 04, 2016 10:15 PM > To: Harninder Rai ; u-boot@lists.denx.de > Subject: Re: [U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support > > Rai, > > On 02/04/2016 06:25 AM, Rai Harninder wrote: > > The fuse status register provides the values from on-chip voltage ID > > efuses programmed at the factory. These values define the voltage > > requirements for the chip. u-boot reads FUSESR and translates the > > values into the appropriate commands to set the voltage output value > > of an external voltage regulator. > > No need to repeat what VID feature is. Instead, please focus on what this > patch does. > > > > > Signed-off-by: Rai Harninder > > --- > > .../include/asm/arch-fsl-layerscape/immap_lsch3.h |4 > > board/freescale/common/vid.c | 15 ++- > > board/freescale/ls2080ardb/ls2080ardb.c|5 + > > include/configs/ls2080ardb.h | 16 > > 4 files changed, 39 insertions(+), 1 deletions(-) > > > > diff --git a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > > b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > > index 91f3ce8..4fd58ee 100644 > > --- a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > > +++ b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > > @@ -146,6 +146,10 @@ struct ccsr_gur { > > u8 res_008[0x20-0x8]; > > u32 gpporcr1; /* General-purpose POR configuration */ > > u32 gpporcr2; /* General-purpose POR configuration 2 */ > > +#define FSL_CHASSIS3_DCFG_FUSESR_VID_SHIFT 25 > > +#define FSL_CHASSIS3_DCFG_FUSESR_VID_MASK 0x1F > > +#define FSL_CHASSIS3_DCFG_FUSESR_ALTVID_SHIFT 20 > > +#define FSL_CHASSIS3_DCFG_FUSESR_ALTVID_MASK 0x1F > > u32 dcfg_fusesr;/* Fuse status register */ > > u32 gpporcr3; > > u32 gpporcr4; > > diff --git a/board/freescale/common/vid.c > > b/board/freescale/common/vid.c index 1bd65a8..16ae177 100644 > > --- a/board/freescale/common/vid.c > > +++ b/board/freescale/common/vid.c > > @@ -10,6 +10,8 @@ > > #include > > #ifdef CONFIG_LS1043A > > #include > > +#elif defined(CONFIG_FSL_LAYERSCAPE) > > +#include > > It is not appropriate to use macro CONFIG_FSL_LAYERSCAPE here. It is > defined for both LS1043 and LS2080. > Oh... Then LS2080 and LS2085 config needs to used. Also need to use LS2088A and LS1088A. LS1043 is Chassis Gen2 and Other are Chassis Gen3 so different address etc. How to avoid adding SoC config for each Chassis Gen3 SoC. We need to define some config used across Gen3 SoCs. --prabhakar ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] I need help linking a standalone program
Hi all, I'm trying to create a standalone program that runs a rigorous memory test. I'm having trouble linking in the rand() functions, getting "undefined reference errors from GCC". I am using the Freescale/NXP LS1021ATWR dev board. I'm working with U-boot through Yocto and the Freescale QorIQ SDK. * I started by copying the "example" directory to a "vpg-apps" directory and have proceeded slowly from there * I believe I'm near success - if I comment out the rand() functions in my code, the application builds the vpg-mem-test.bin image (the app name is vpg-mem-test). * I'm including * I've added the define CONFIG_LIB_RAND to my board header file, and rand.o is being built and placed in my ls1021adeg_nor_config/lib/ * In my vpg-apps/api/Makefile, I added the line EXT_COBJ-y += lib/rand.o just under the line EXT_COBJ-y += lib/vsprintf.o I would appreciate any advice. Thanks. -Jason ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] fastboot: sparse: remove unnecessary logging
Hi Maxime, On Thu, Feb 4, 2016 at 4:20 AM, Maxime Ripard < maxime.rip...@free-electrons.com> wrote: > Hi Steve, > > On Wed, Feb 03, 2016 at 12:46:02PM -0800, Steve Rae wrote: > > remove logging of the 'skipped' blocks > > > > Signed-off-by: Steve Rae > > --- > > > > common/image-sparse.c | 6 ++ > > 1 file changed, 2 insertions(+), 4 deletions(-) > > > > diff --git a/common/image-sparse.c b/common/image-sparse.c > > index f02aee4..594bf4e 100644 > > --- a/common/image-sparse.c > > +++ b/common/image-sparse.c > > @@ -275,7 +275,6 @@ int store_sparse_image(sparse_storage_t *storage, > void *storage_priv, > > sparse_buffer_t *buffer; > > uint32_t start; > > uint32_t total_blocks = 0; > > - uint32_t skipped = 0; > > int i; > > > > debug("=== Storage ===\n"); > > @@ -334,7 +333,6 @@ int store_sparse_image(sparse_storage_t *storage, > void *storage_priv, > > storage, > > > sparse_header); > > total_blocks += blkcnt; > This change (in the first patch), updates the "total_blocks" value, so that the "next" chunk has the proper "starting block" address (see these line 363...) 362 ret = storage->write(storage, storage_priv, 363 start + total_blocks, 364 buffer_blk_cnt, 365 buffer->data); Without this change, all the blocks written to the partition after the CHUNK_TYPE_DONT_CARE blocks are corrupted (they are not in the correct location). So, even though we are not actually writing any blocks to this space, the space must be maintained! (Recently, I am now understanding that with NAND, there may be more complications; probably cannot just increment the "total_blocks" -- I suspect that it is required to actually determine if there are bad blocks in this space, and update the "total_blocks" value accordingly) > - skipped += blkcnt; > > continue; > > } > > > > @@ -375,8 +373,8 @@ int store_sparse_image(sparse_storage_t *storage, > void *storage_priv, > > sparse_put_data_buffer(buffer); > > } > > > > - debug("Wrote %d blocks, skipped %d, expected to write %d blocks\n", > > - total_blocks, skipped, > > + debug("Wrote %d blocks, expected to write %d blocks\n", > > + total_blocks, > > What's the rationale between those two patches? > see inline comment above > > Do we really want to treat the DONT_CARE chunks as if they were > written? > I suspect that we do, and "sparse_header->total_blks" actually includes them in the count too... This "total_blocks" count is actually the number of blocks "processed" (which may or may not include actually writing to the partition). IMO - I think counting the "skipped blocks is unnecessary. Thanks, Steve > Maxime > > -- > Maxime Ripard, Free Electrons > Embedded Linux, Kernel and Android engineering > http://free-electrons.com > ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] test/py: support running sandbox under gdbserver
From: Stephen Warren Implement command--line option --gdbserver COMM, which does two things: a) Run the sandbox process under gdbserver, using COMM as gdbserver's communication channel. b) Disables all timeouts, so that if U-Boot is halted under the debugger, tests don't fail. If the user gives up in the middle of a debugging session, they can simply CTRL-C the test script to abort it. This allows easy debugging of test failures without having to manually re-create the failure conditions. Usage is: Window 1: ./test/py/test.py --bd sandbox --gdbserver localhost:1234 Window 2: gdb ./build-sandbox/u-boot -ex 'target remote localhost:1234' When using this option, it likely makes sense to use pytest's -k option to limit the set of tests that are executed. Simply running U-Boot directly under gdb (rather than gdbserver) was also considered. However, this was rejected because: a) gdb's output would then be processed by the test script, and likely confuse it causing false failures. b) pytest by default hides stdout from tests, which would prevent the user from interacting with gdb. While gdb can be told to redirect the debugee's stdio to a separate PTY, this would appear to leave gdb's stdio directed at the test scripts and the debugee's stdio directed elsewhere, which is the opposite of the desired effect. Perhaps some complicated PTY muxing and process hierarchy could invert this. However, the current scheme is simple to implement and use, so it doesn't seem worth complicating matters. c) Using gdbserver allows arbitrary debuggers to be used, even those with a GUI. If the test scripts invoked the debugger themselves, they'd have to know how to execute arbitary applications. While the user could hide this all in a wrapper script, this feels like extra complication. An interesting future idea might be a --gdb-screen option, which could spawn both U-Boot and gdb separately, and spawn the screen into a newly created window under screen. Similar options could be envisaged for creating a new xterm/... too. --gdbserver currently only supports sandbox, and not real hardware. That's primarily because the test hooks are responsible for all aspects of hardware control, so there's nothing for the test scripts themselves can do to enable gdbserver on real hardware. We might consider introducing a separate --disable-timeouts option to support use of debuggers on real hardware, and having --gdbserver imply that option. Signed-off-by: Stephen Warren --- test/py/conftest.py | 8 test/py/tests/test_sleep.py | 7 --- test/py/u_boot_console_base.py| 3 ++- test/py/u_boot_console_sandbox.py | 5 - test/py/u_boot_spawn.py | 12 5 files changed, 26 insertions(+), 9 deletions(-) diff --git a/test/py/conftest.py b/test/py/conftest.py index f55bf68686ba..bf8d735b83cb 100644 --- a/test/py/conftest.py +++ b/test/py/conftest.py @@ -72,6 +72,9 @@ def pytest_addoption(parser): help='U-Boot board identity/instance') parser.addoption('--build', default=False, action='store_true', help='Compile U-Boot before running tests') +parser.addoption('--gdbserver', default=None, +help='Run sandbox under gdbserver. The argument is the channel '+ +'over which gdbserver should communicate, e.g. localhost:1234') def pytest_configure(config): """pytest hook: Perform custom initialization at startup time. @@ -111,6 +114,10 @@ def pytest_configure(config): persistent_data_dir = build_dir + '/persistent-data' mkdir_p(persistent_data_dir) +gdbserver = config.getoption('gdbserver') +if gdbserver and board_type != 'sandbox': +raise Exception('--gdbserver only supported with sandbox') + import multiplexed_log log = multiplexed_log.Logfile(result_dir + '/test-log.html') @@ -172,6 +179,7 @@ def pytest_configure(config): ubconfig.persistent_data_dir = persistent_data_dir ubconfig.board_type = board_type ubconfig.board_identity = board_identity +ubconfig.gdbserver = gdbserver env_vars = ( 'board_type', diff --git a/test/py/tests/test_sleep.py b/test/py/tests/test_sleep.py index 74add891c333..5c1a2623fefa 100644 --- a/test/py/tests/test_sleep.py +++ b/test/py/tests/test_sleep.py @@ -15,6 +15,7 @@ def test_sleep(u_boot_console): u_boot_console.run_command('sleep %d' % sleep_time) tend = time.time() elapsed = tend - tstart -delta_to_expected = abs(elapsed - sleep_time) -# 0.25s margin is hopefully enough to account for any system overhead. -assert delta_to_expected < 0.25 +assert elapsed >= sleep_time +if not u_boot_console.config.gdbserver: +# 0.25s margin is hopefully enough to account for any system overhead. +assert elapsed < (sleep_time + 0.25) diff --git a/test/py/u_boot_console_base.py b/test/py/u_boot_console_base.py index 392f8cb88532..cc5427335177 100644
Re: [U-Boot] [PATCHv2 1/3] arm: socfpga: add reset manager defines for Arria10
On 02/04/2016 05:46 AM, Marek Vasut wrote: > > A10 branch is now u-boot-socfpga/01-arria10 . > Thanks for carrying this. > What is the current status of Arria10 please ? > I haven't had time to work on Arria10 in the last 2 weeks. I hope to get back to it next week. I think I may have to slim the patches down to just fixing building for it. Dinh ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] ARM: zynq: Remove unused SPI base addresses
On Thu, Feb 4, 2016 at 1:07 AM, Michal Simek wrote: > Remove unused macros. Adresses are taken from DT. > > Signed-off-by: Michal Simek Reviewed-by: Moritz Fischer > --- > > arch/arm/include/asm/arch-zynqmp/hardware.h | 3 --- > arch/arm/mach-zynq/include/mach/hardware.h | 2 -- > 2 files changed, 5 deletions(-) > > diff --git a/arch/arm/include/asm/arch-zynqmp/hardware.h > b/arch/arm/include/asm/arch-zynqmp/hardware.h > index 587938249e8f..1ab301f0d21f 100644 > --- a/arch/arm/include/asm/arch-zynqmp/hardware.h > +++ b/arch/arm/include/asm/arch-zynqmp/hardware.h > @@ -13,9 +13,6 @@ > #define ZYNQ_GEM_BASEADDR2 0xFF0D > #define ZYNQ_GEM_BASEADDR3 0xFF0E > > -#define ZYNQ_SPI_BASEADDR0 0xFF04 > -#define ZYNQ_SPI_BASEADDR1 0xFF05 > - > #define ZYNQ_I2C_BASEADDR0 0xFF02 > #define ZYNQ_I2C_BASEADDR1 0xFF03 > > diff --git a/arch/arm/mach-zynq/include/mach/hardware.h > b/arch/arm/mach-zynq/include/mach/hardware.h > index 830e1fea1809..79347a83eaff 100644 > --- a/arch/arm/mach-zynq/include/mach/hardware.h > +++ b/arch/arm/mach-zynq/include/mach/hardware.h > @@ -14,8 +14,6 @@ > #define ZYNQ_GEM_BASEADDR1 0xE000C000 > #define ZYNQ_I2C_BASEADDR0 0xE0004000 > #define ZYNQ_I2C_BASEADDR1 0xE0005000 > -#define ZYNQ_SPI_BASEADDR0 0xE0006000 > -#define ZYNQ_SPI_BASEADDR1 0xE0007000 > #define ZYNQ_QSPI_BASEADDR 0xE000D000 > #define ZYNQ_SMC_BASEADDR 0xE000E000 > #define ZYNQ_NAND_BASEADDR 0xE100 > -- > 1.9.1 > > ___ > 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 v2] arm: use common instructions applicable to armv7m & other arm archs
This patch cleans the code by using instructions allowed for armv7m as well as other Arm archs. Signed-off-by: Vikas Manocha Reviewed-by: Simon Glass --- Changes in v2: reword message commit. Removed info regarding BIC instruction on SP, was creating confusion. arch/arm/lib/crt0.S | 25 +++-- 1 file changed, 7 insertions(+), 18 deletions(-) diff --git a/arch/arm/lib/crt0.S b/arch/arm/lib/crt0.S index 2f4c14e..3731d0c 100644 --- a/arch/arm/lib/crt0.S +++ b/arch/arm/lib/crt0.S @@ -71,18 +71,12 @@ ENTRY(_main) */ #if defined(CONFIG_SPL_BUILD) && defined(CONFIG_SPL_STACK) - ldr sp, =(CONFIG_SPL_STACK) + ldr r0, =(CONFIG_SPL_STACK) #else - ldr sp, =(CONFIG_SYS_INIT_SP_ADDR) + ldr r0, =(CONFIG_SYS_INIT_SP_ADDR) #endif -#if defined(CONFIG_CPU_V7M)/* v7M forbids using SP as BIC destination */ - mov r3, sp - bic r3, r3, #7 - mov sp, r3 -#else - bic sp, sp, #7 /* 8-byte alignment for ABI compliance */ -#endif - mov r0, sp + bic r0, r0, #7 /* 8-byte alignment for ABI compliance */ + mov sp, r0 bl board_init_f_alloc_reserve mov sp, r0 /* set up gd here, outside any C code */ @@ -100,14 +94,9 @@ ENTRY(_main) * 'here' but relocated. */ - ldr sp, [r9, #GD_START_ADDR_SP] /* sp = gd->start_addr_sp */ -#if defined(CONFIG_CPU_V7M)/* v7M forbids using SP as BIC destination */ - mov r3, sp - bic r3, r3, #7 - mov sp, r3 -#else - bic sp, sp, #7 /* 8-byte alignment for ABI compliance */ -#endif + ldr r0, [r9, #GD_START_ADDR_SP] /* sp = gd->start_addr_sp */ + bic r0, r0, #7 + mov sp, r0 /* 8-byte alignment for ABI compliance */ ldr r9, [r9, #GD_BD]/* r9 = gd->bd */ sub r9, r9, #GD_SIZE/* new GD is below bd */ -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] malloc: solve dead code issue in memalign()
On Thu, Feb 04, 2016 at 11:54:20AM -0700, Stephen Warren wrote: > From: Stephen Warren > > The recent change to memalign() caused the allocation failure detection > code to be dead code; the "retry" logic is always activated under the same > condition that the original failure detection code is, and also fully > handles any possible failures. This patch solves the presence of dead > code. > > Two alternatives are possible: > > a) Delete the now-dead test, and rely on the "retry" path to handle any > allocation problems, as it does. > > b) Make the "retry" path fall through to the existing (currently dead) > failure detection code, thus making it not-dead. > > (b) was chosen since it reduces the diff between U-Boot's and the upstream > dlmalloc. This should make it marginally easier to import a new version of > dlmalloc in the future. > > Reported by: Coverity Scan > Fixes: 4f144a416469 ("malloc: work around some memalign fragmentation issues") > Signed-off-by: Stephen Warren Thanks for the quick turn-around! Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] malloc: solve dead code issue in memalign()
From: Stephen Warren The recent change to memalign() caused the allocation failure detection code to be dead code; the "retry" logic is always activated under the same condition that the original failure detection code is, and also fully handles any possible failures. This patch solves the presence of dead code. Two alternatives are possible: a) Delete the now-dead test, and rely on the "retry" path to handle any allocation problems, as it does. b) Make the "retry" path fall through to the existing (currently dead) failure detection code, thus making it not-dead. (b) was chosen since it reduces the diff between U-Boot's and the upstream dlmalloc. This should make it marginally easier to import a new version of dlmalloc in the future. Reported by: Coverity Scan Fixes: 4f144a416469 ("malloc: work around some memalign fragmentation issues") Signed-off-by: Stephen Warren --- common/dlmalloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/dlmalloc.c b/common/dlmalloc.c index 2b964d16b11e..5ea37dfb6e4c 100644 --- a/common/dlmalloc.c +++ b/common/dlmalloc.c @@ -2848,7 +2848,7 @@ Void_t* mEMALIGn(alignment, bytes) size_t alignment; size_t bytes; return m; /* Otherwise, fail */ fREe(m); -return NULL; +m = NULL; } if (m == NULL) return NULL; /* propagate failure */ -- 2.7.0 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] 64-bit x86 U-Boot?
On Wed, Feb 03, 2016 at 12:42:44PM +0800, Bin Meng wrote: > Hi Simon, > > On Wed, Feb 3, 2016 at 12:31 PM, Simon Glass wrote: > > Hi Bin, > > > > On 2 February 2016 at 08:02, Bin Meng wrote: > >> Hi Albert, > >> > >> On Tue, Feb 2, 2016 at 5:53 PM, Albert ARIBAUD > >> wrote: > >>> Hello Bin and Simon, > >>> > >>> On Tue, 2 Feb 2016 15:25:48 +0800, Bin Meng wrote: > Hi Simon, > > On Tue, Feb 2, 2016 at 11:58 AM, Simon Glass wrote: > > +Bin (sorry, meant to copy you before) > >>> > >>> For non-FSP devices we don't init the RAM until much later - > >>> dram_init(). That means that a significant portion of the init > >>> sequence would be 32-bit code. I'm not sure that will work. > >>> > > I believe we can do dram_init() in 64-bit mode as well if MRC is > written in pure C. > >>> > >>> Bin: not sure what you mean by "if MRC is written in pure C" -- there > >>> is no C construct that can even approach the mrc instruction, which can > >>> only be emitted through an asm statement. > >> > >> You are exposed as an ARM guy :-) I was talking about an Intel term > >> Memory Reference Code which are a amount of magic codes to initialize > >> system RAM. > >> > >>> > > I wonder whether we might need to resort to SPL for the 32-bit > > portion, and jump to a 64-bit U-Boot from there? Tegra does something > > similar to that. > >>> > >>> Simon: seems like a sensible approach, as it does not mix 32 and 64 > >>> bits in one "build artefact", plus it seems logical in that SPL's > >>> role is to get the platform ready for U-Boot; switching from > >>> power-on32-bit mode to 64-bit mode belongs quite "naturally" in SPL. > >>> > What's the benefit of doing a 64-bit bootloader? Intel's UEFI BIOS has > a 32-bit and 64-bit version, and has caused some troubles for the next > stage loader (bootia32.efi vs. bootx64.efi). I know for PowerPC, a > 64-bit U-Boot does not exist as 32-bit U-Boot can load 32-bit and > 64-bit kernel, just like what we have for x86. 64-bit U-Boot was only > seen on ARMv8, but that's the architecture limitation I believe, and > we have to do that. > >>> > >>> Some U-Boot users who might want to get rid of x86 32-bit code in > >>> x86 64-bit platforms just like in the past some people must have wanted > >>> to get rid of real-mode 16-bit x86 code in order to run pure 32-bit; the > >> > >> Yep, but unfortunately we still cannot get rid of real-mode 16-bit x86 > >> code even today :( > >> > >>> idea is that if you can do with as well as without a feature, then that > >>> feature is potential dead code, and is candidate for removal, all the > >>> more when that feature partly collides with another feature, as here > >>> where 32-bit and 64-bit support sort of overlap partially. > >>> > >> > >> I wonder if some day these processors (arm, x86, whatever else?) will > >> come out of reset in the 64-bit mode directly. No more any legacy > >> modes. At that time, 64-bit mode bootloader is definitely a must. > > > > ARM does. Not sure if Intel will, but they should IMO! > > > > Agreed. But guess Intel won't do that due to whatever backward > compatible reasons.. > > >> > >>> Now, we can wait until x86 32-bit is really dead (as in "not used > >>> except in a few legacy projects whose engineers' children are about to > >>> retire") and then scrape dead code parts which no one really understands > >>> any more, or we can try and anticipate and replace code while we still > >>> have a grasp of what it does. I personally like the idea of anticipating > >>> better. > >>> > >>> Just in case, note that I do not mean x86 32-bit support should be > >>> removed from U-Boot now or later. I mean that if we can make x86 64-bit > >>> support in U-Boot less and less dependent on x86 32-bit support, then I > >>> think we should, so that the day we completely drop x86 32-bit support, > >>> x86 64-bit support will be (as) unaffected (as possible). > >>> > >> > >> I agree with the philosophy here. But I sense this might be too > >> anticipating as there are some other tasks to do for U-Boot 32-bit > >> like ACPI and SMM. 32-bit is enough for now, unless we want to access > >>>4GB memory in U-Boot shell? > > > > Yes, I suppose there are more important things. The 32/64-bit split > > bothers me. For example with the EFI loader series, U-Boot runs in > > 32-bit mode so can only run a 32-bit EFI application (e.g. grub). That > > seems like an annoying limitation. We don't have that limitation when > > booting a kernel. > > Isn't the limitation coming from UEFI itself? My understanding is that > we cannot boot a 64-bit EFI application from a 32-bit UEFI BIOS as > well. Well, how much are distros going to dislike having to provide 32bit EFI grub, for the x86 case here? -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/m
Re: [U-Boot] [PATCH] Revert "arm: Remove wireless_space board"
On Sun, Jan 31, 2016 at 09:37:04PM +0100, Albert ARIBAUD wrote: > Revert commit b352182a and complete generic board support. > > Signed-off-by: Albert ARIBAUD Reviewed-by: Tom Rini Go ahead and bring it in via u-boot-arm. -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] 9c11135 breaks bootz
On Tue, Feb 02, 2016 at 03:49:07PM +0100, Matthias Weißer wrote: > Hi > > 9c11135 image: fix getenv_bootm_size() function breaks the bootz > command for me on a custom hardware (very similar to mx6sxsabresd but > with only 256MB RAM). I don't have bootm_size or bootm_low defined. > > After reading zImage and dtb from serial flash I run > > => bootz 0x8080 - 0x8300 > Kernel image @ 0x8080 [ 0x00 - 0x1e5f48 ] > ## Flattened Device Tree blob at 8300 >Booting using the fdt blob at 0x8300 > ERROR: Failed to allocate 0xb28a bytes below 0x1000. > device tree - allocation error > FDT creation failed! hanging...### ERROR ### Please RESET the board ### > > I am totally unsure what the commit intents but subtracting the ram > start address from its size doesn't make much sense to me. > > + return gd->bd->bi_dram[0].size - (tmp - gd->bd->bi_dram[0].start); > > Maybe someone can shed some light on this issue for me. Masahiro? -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] ppc: xilinx-ppc405-generic
On Thu, Feb 04, 2016 at 02:45:00PM +0100, Ricardo Ribalda Delgado wrote: > Fix device tree name: > > +(xilinx-ppc405-generic) Device Tree Source is not correctly specified. > +(xilinx-ppc405-generic) Please define 'CONFIG_DEFAULT_DEVICE_TREE' > +(xilinx-ppc405-generic) or build with 'DEVICE_TREE=' > argument > +(xilinx-ppc405-generic) make[2]: *** > [arch/powerpc/dts/xilinx-ppc440-generic.dtb] Error 1 > +(xilinx-ppc405-generic) make[1]: *** [dts] Error 2 > > Signed-off-by: Ricardo Ribalda Delgado Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 5/6] dm: pxa: serial: Drop serial_sa1100 serial driver
On Sun, Jan 31, 2016 at 09:16:16AM -0700, Simon Glass wrote: > This does not appear to be used, and has not been converted to driver model > by the deadline (doc/driver-model/serial-howto.txt). > > Signed-off-by: Simon Glass Dead code: Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 4/6] dm: serial: Drop serial_max3100 serial driver
On Sun, Jan 31, 2016 at 09:16:15AM -0700, Simon Glass wrote: > This does not appear to be used, and has not been converted to driver model > by the deadline (doc/driver-model/serial-howto.txt). > > Signed-off-by: Simon Glass Dead code: Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH V2] OMAP3: omap3_logic: Remove YAFFS support.
On Mon, Feb 01, 2016 at 06:27:21AM -0600, Adam Ford wrote: > UBIFS is the preferred FS, and YAFFS isn't officially included in > Linux. Removing this feature reduces the code size. > > Signed-off-by: Adam Ford Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 2/6] dm: opencores: Drop opencores_yanu serial driver
On Sun, Jan 31, 2016 at 09:16:13AM -0700, Simon Glass wrote: > This does not appear to be used, and has not been converted to driver model > by the deadline (doc/driver-model/serial-howto.txt). > > Signed-off-by: Simon Glass Dead code: Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 3/6] dm: freescale: serial: Drop serial_imx serial driver
On Sun, Jan 31, 2016 at 09:16:14AM -0700, Simon Glass wrote: > This does not appear to be used, and has not been converted to driver model > by the deadline (doc/driver-model/serial-howto.txt). > > Signed-off-by: Simon Glass Dead code: Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] OMAP3: omap3_logic: Enable CONFIG_SMC911X_32_BIT
On Sun, Jan 31, 2016 at 05:13:33PM -0600, Adam Ford wrote: > The interface automatically converts one 32-bit word into two 16 words. > The README said it is permissible to use this flag in that scenario. > > Signed-off-by: Adam Ford Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] OMAP3: Enable SPL on omap3_logic
On Fri, Jan 29, 2016 at 08:12:34PM -0600, Adam Ford wrote: > Previously, Omap3_logic assumed X-loader was present. With this > patch, we can finally replace X-loader with an MLO generated by > U-Boot. This requires ECC to be setup to match the Linux Kernel > and the PBIAS confgured for the SD card. > > Signed-off-by: Derald D. Woods > Signed-off-by: Adam Ford Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] OMAP3_LOGIC: Setup defconfig to enable SPL and NAND booting
On Sat, Jan 30, 2016 at 06:43:59AM -0600, Adam Ford wrote: > The defconfig patch will enable the the SPL and NAND settings. > The update to Kconfig will allow the SPL to configured in and > built. > > Signed-off-by: Derald D. Woods > Signed-off-by: Adam Ford Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] OMAP3: omap3_logic: Enable Android Fastboot
On Sun, Jan 31, 2016 at 01:34:39PM -0600, Adam Ford wrote: > Android Fastboot requires USB. The TWL4030 PMIC on omap3_logic handles USB > traffic. > This patch sets up the USB gadget and Android Fastboot to match what is done > in the > omap3_beagle project. > > Signed-off-by: Adam Ford Reviewed-by: Tom Rini -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PULL] u-boot-socfpga/master
On Thu, Feb 04, 2016 at 12:44:47PM +0100, Marek Vasut wrote: > The following changes since commit 44189a032804c4a16632f4e80abf77f2820e9a48: > > Prepare v2016.03-rc1 (2016-02-02 11:29:50 -0500) > > are available in the git repository at: > > git://git.denx.de/u-boot-socfpga.git master > > for you to fetch changes up to a409a8b85ee337250043aa0c031a31b3a6639e74: > > Revert "arm: socfpga: set the fpga global bit to disable HPS to FPGA > signals" > (2016-02-04 12:43:21 +0100) > Applied to u-boot/master, thanks! -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PULL] u-boot-usb/master
On Thu, Feb 04, 2016 at 12:45:18PM +0100, Marek Vasut wrote: > The following changes since commit 44189a032804c4a16632f4e80abf77f2820e9a48: > > Prepare v2016.03-rc1 (2016-02-02 11:29:50 -0500) > > are available in the git repository at: > > git://git.denx.de/u-boot-usb.git master > > for you to fetch changes up to 8c9b4d5598e014036d2f2637c17bd6e3748ff6a3: > > usb: gadget: dwc2_udc_otg: modified the check condition for max packet size > of > ep_in in high speed (2016-02-04 12:38:26 +0100) > Applied to u-boot/master, thanks! -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PULL] Please pull u-boot-imx
On Thu, Feb 04, 2016 at 10:44:26AM +0100, Stefano Babic wrote: > Hi Tom, > > please pull from u-boot-imx, thanks ! > > > The following changes since commit 44189a032804c4a16632f4e80abf77f2820e9a48: > > Prepare v2016.03-rc1 (2016-02-02 11:29:50 -0500) > > are available in the git repository at: > > git://www.denx.de/git/u-boot-imx.git master > > for you to fetch changes up to fb0d042814e6ea3463ee335523222f91d891d084: > > imx: mx6: implement board_mmc_get_env_dev (2016-02-04 10:13:53 +0100) > So, with reservation: Applied to u-boot/master, thanks! Because this breaks ls1021aqds_*nor_lpuart. But it's likely an easy fix that should be done rather than keeping legacy code around (5160def267739518950e8e3bb78e0e6c3941cb3e is the culprit for the breakage). -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support
Rai, On 02/04/2016 06:25 AM, Rai Harninder wrote: > The fuse status register provides the values from on-chip > voltage ID efuses programmed at the factory. These values > define the voltage requirements for the chip. u-boot reads > FUSESR and translates the values into the appropriate > commands to set the voltage output value of an external > voltage regulator. No need to repeat what VID feature is. Instead, please focus on what this patch does. > > Signed-off-by: Rai Harninder > --- > .../include/asm/arch-fsl-layerscape/immap_lsch3.h |4 > board/freescale/common/vid.c | 15 ++- > board/freescale/ls2080ardb/ls2080ardb.c|5 + > include/configs/ls2080ardb.h | 16 > 4 files changed, 39 insertions(+), 1 deletions(-) > > diff --git a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > index 91f3ce8..4fd58ee 100644 > --- a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > +++ b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h > @@ -146,6 +146,10 @@ struct ccsr_gur { > u8 res_008[0x20-0x8]; > u32 gpporcr1; /* General-purpose POR configuration */ > u32 gpporcr2; /* General-purpose POR configuration 2 */ > +#define FSL_CHASSIS3_DCFG_FUSESR_VID_SHIFT 25 > +#define FSL_CHASSIS3_DCFG_FUSESR_VID_MASK0x1F > +#define FSL_CHASSIS3_DCFG_FUSESR_ALTVID_SHIFT20 > +#define FSL_CHASSIS3_DCFG_FUSESR_ALTVID_MASK 0x1F > u32 dcfg_fusesr;/* Fuse status register */ > u32 gpporcr3; > u32 gpporcr4; > diff --git a/board/freescale/common/vid.c b/board/freescale/common/vid.c > index 1bd65a8..16ae177 100644 > --- a/board/freescale/common/vid.c > +++ b/board/freescale/common/vid.c > @@ -10,6 +10,8 @@ > #include > #ifdef CONFIG_LS1043A > #include > +#elif defined(CONFIG_FSL_LAYERSCAPE) > +#include It is not appropriate to use macro CONFIG_FSL_LAYERSCAPE here. It is defined for both LS1043 and LS2080. > #else > #include > #endif > @@ -285,7 +287,7 @@ static int set_voltage(int i2caddress, int vdd) > int adjust_vdd(ulong vdd_override) > { > int re_enable = disable_interrupts(); > -#ifdef CONFIG_LS1043A > +#if defined(CONFIG_LS1043A) || defined(CONFIG_FSL_LAYERSCAPE) > struct ccsr_gur *gur = (void *)(CONFIG_SYS_FSL_GUTS_ADDR); > #else Same here. > ccsr_gur_t __iomem *gur = > @@ -362,7 +364,11 @@ int adjust_vdd(ulong vdd_override) > } > > /* get the voltage ID from fuse status register */ > +#ifdef CONFIG_FSL_LAYERSCAPE > + fusesr = in_le32(&gur->dcfg_fusesr); > +#else > fusesr = in_be32(&gur->dcfg_fusesr); > +#endif Are you sure you are not breaking LS1043 here? > /* >* VID is used according to the table below >*--- > @@ -387,6 +393,13 @@ int adjust_vdd(ulong vdd_override) > vid = (fusesr >> FSL_CHASSIS2_DCFG_FUSESR_VID_SHIFT) & > FSL_CHASSIS2_DCFG_FUSESR_VID_MASK; > } > +#elif defined(CONFIG_FSL_LAYERSCAPE) > + vid = (fusesr >> FSL_CHASSIS3_DCFG_FUSESR_ALTVID_SHIFT) & > + FSL_CHASSIS3_DCFG_FUSESR_ALTVID_MASK; > + if ((vid == 0) || (vid == FSL_CHASSIS3_DCFG_FUSESR_ALTVID_MASK)) { > + vid = (fusesr >> FSL_CHASSIS3_DCFG_FUSESR_VID_SHIFT) & > + FSL_CHASSIS3_DCFG_FUSESR_VID_MASK; > + } and here? > #else > vid = (fusesr >> FSL_CORENET_DCFG_FUSESR_ALTVID_SHIFT) & > FSL_CORENET_DCFG_FUSESR_ALTVID_MASK; > diff --git a/board/freescale/ls2080ardb/ls2080ardb.c > b/board/freescale/ls2080ardb/ls2080ardb.c > index c63b639..9515b25 100644 > --- a/board/freescale/ls2080ardb/ls2080ardb.c > +++ b/board/freescale/ls2080ardb/ls2080ardb.c > @@ -122,6 +122,11 @@ int select_i2c_ch_pca9547(u8 ch) > return 0; > } > > +int i2c_multiplexer_select_vid_channel(u8 channel) > +{ > + return select_i2c_ch_pca9547(channel); > +} > + > int config_board_mux(int ctrl_type) > { > u8 reg5; > diff --git a/include/configs/ls2080ardb.h b/include/configs/ls2080ardb.h > index 116dbcd..9a95f31 100644 > --- a/include/configs/ls2080ardb.h > +++ b/include/configs/ls2080ardb.h > @@ -14,6 +14,22 @@ > > #define CONFIG_DISPLAY_BOARDINFO > > +#define I2C_MUX_CH_VOL_MONITOR 0xa > +#define I2C_VOL_MONITOR_ADDR 0x38 > +#define CONFIG_VOL_MONITOR_IR36021_READ > +#define CONFIG_VOL_MONITOR_IR36021_SET > + > +#define CONFIG_VID_FLS_ENV "ls2080ardb_vdd_mv" > +#ifndef CONFIG_SPL_BUILD > +#define CONFIG_VID > +#endif > +/* step the IR regulator in 5mV increments */ > +#define IR_VDD_STEP_DOWN 5 > +#define IR_VDD_STEP_UP 5 > +/* The lowest and highest voltage allowed for LS2080ARDB */ > +#define VDD_MV_MIN 819 > +#define VDD_MV_MAX 1212 > + > #ifn
Re: [U-Boot] [PATCH] .travis.yml: explicitly request sudo
On 02/04/2016 02:00 AM, Heiko Schocher wrote: Hello Stephen, Am 03.02.2016 um 18:41 schrieb Stephen Warren: From: Stephen Warren Without this, builds default to using new Travis CI infra-structure which does no allow sudo. The builds need sudo in order to install the ELDK compilers. Consequently, almost all builds fail without this. I suspect that existing Travis CI users have not noticed this because their accounts or builds have been grand-fathered into backwards- compatible default settings, whereas I just set up a new build from scratch and received new default settings. Did you tried it with current ML? Or at last with the patch from Roger? http://lists.denx.de/pipermail/u-boot/2016-January/243115.html [U-Boot] [PATCH] .travis.yml: rework according to new travis-ci infra Both:-) That patch is already applied in mainline, and was included in the branch I pushed "to" Travis. If I look into: https://travis-ci.org/u-boot/u-boot There are only mips and m68k for which the build fail ... Yes. With the addition of the sudo tag, the same is now true for my branch. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] help on using patman
Hi Mugunthan, On 4 February 2016 at 08:09, Mugunthan V N wrote: > Hi Simon > > I tried to use patman with a sample commit, below is the commit > with the tag patmantest > > Commit: > ~~~ > $ git show patmantest > tag patmantest > Tagger: Mugunthan V N > Date: Thu Feb 4 11:51:48 2016 +0530 > > Series-to: me > Series-prefix: RFC > Cover-letter: > Unified command execution in one place > > At present two parsers have similar code to execute commands. Also > cmd_usage() is called all over the place. This series adds a single > function which processes commands called cmd_process(). > END > > commit 02c23a9b585d91272befb8fe43d21fe52e1fd139 > Author: Mugunthan V N > Date: Mon Jan 18 14:17:43 2016 +0530 > > defconfig: dra72_evm: enable disk driver model > > Enable disk driver model for dra72_evm as dwc_ahci supports > driver model > > Signed-off-by: Mugunthan V N > Reviewed-by: Tom Rini > > diff --git a/configs/dra72_evm_defconfig b/configs/dra72_evm_defconfig > index 32d1dc1..7ff2a4e 100644 > --- a/configs/dra72_evm_defconfig > +++ b/configs/dra72_evm_defconfig > @@ -24,3 +24,5 @@ CONFIG_DM_SPI=y > CONFIG_DM_SPI_FLASH=y > CONFIG_TIMER=y > CONFIG_OMAP_TIMER=y > +CONFIG_DISK=y > +CONFIG_DWC_AHCI=y > ~~~ > > But when I patman -n, it throws below error > > $ ./tools/patman/patman -n > Cleaned 1 patches > total: 0 errors, 0 warnings, 0 checks, 5 lines checked > > NOTE: Ignored message types: COMPLEX_MACRO CONSIDER_KSTRTO MINMAX > MULTISTATEMENT_MACRO_USE_DO_WHILE NETWORKING_BLOCK_COMMENT_STYLE > PREFER_ETHER_ADDR_COPY USLEEP_RANGE I'm not sure where this message comes from - I don't see it. I suppose it is checkpatch.pl. > > 0001-defconfig-dra72_evm-enable-disk-driver-model.patch has no obvious style > problems and is ready for submission. > Traceback (most recent call last): > File "./tools/patman/patman", line 158, in > options.add_maintainers) > File > "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/series.py", > line 222, in MakeCcFile > raise_on_error=raise_on_error) > File > "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/gitutil.py", > line 321, in BuildEmailList > raw += LookupEmail(item, alias, raise_on_error=raise_on_error) > File > "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/gitutil.py", > line 495, in LookupEmail > raise ValueError, msg > ValueError: Alias 'defconfig' not found This means it couldn't find the alias 'defconfig' :-) You have a defconfig: tag in your subject so patman will Cc that alias. Since it doesn't exist you get an error. You can use the -t option to ignore bad takes, or add an alias to .patman, like this: defconfig: Fred Bloggs Also see 'Where Patches Are Sent' in the README. > > > Then I tried with patman setting ignore_errors: True and > process_tags: False, then the out seems fine but the tag > is not processed. Do you find any thing I missed? Well only that you told it not to process the tag. I don't think it's a good idea to add those settings. Try 'patman -nt' to use tags if they can be found, and ignore tags that can't be found. > > Output with modified patman settings: > ~ > $ ./tools/patman/patman -n > Cleaned 1 patches > total: 0 errors, 0 warnings, 0 checks, 5 lines checked > > NOTE: Ignored message types: COMPLEX_MACRO CONSIDER_KSTRTO MINMAX > MULTISTATEMENT_MACRO_USE_DO_WHILE NETWORKING_BLOCK_COMMENT_STYLE > PREFER_ETHER_ADDR_COPY USLEEP_RANGE > > 0001-defconfig-dra72_evm-enable-disk-driver-model.patch has no obvious style > problems and is ready for submission. > No recipient. > Please add something like this to a commit > Series-to: Fred Bloggs > Or do something like this > git config sendemail.to u-boot@lists.denx.de > Dry run, so not doing much. But I would do this: > > Send a total of 1 patch with no cover letter. >0001-defconfig-dra72_evm-enable-disk-driver-model.patch > Cc: u-boot@lists.denx.de > Cc: Lokesh Vutla > > Version: None > Prefix: None > > Here is my patman config > $ cat ~/.patman > [alias] > me: Mugunthan V N > > [settings] > ignore_errors: True > process_tags: False > verbose: True > > Regards > Mugunthan V N Regards, Simon ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] help on using patman
Hi Simon I tried to use patman with a sample commit, below is the commit with the tag patmantest Commit: ~~~ $ git show patmantest tag patmantest Tagger: Mugunthan V N Date: Thu Feb 4 11:51:48 2016 +0530 Series-to: me Series-prefix: RFC Cover-letter: Unified command execution in one place At present two parsers have similar code to execute commands. Also cmd_usage() is called all over the place. This series adds a single function which processes commands called cmd_process(). END commit 02c23a9b585d91272befb8fe43d21fe52e1fd139 Author: Mugunthan V N Date: Mon Jan 18 14:17:43 2016 +0530 defconfig: dra72_evm: enable disk driver model Enable disk driver model for dra72_evm as dwc_ahci supports driver model Signed-off-by: Mugunthan V N Reviewed-by: Tom Rini diff --git a/configs/dra72_evm_defconfig b/configs/dra72_evm_defconfig index 32d1dc1..7ff2a4e 100644 --- a/configs/dra72_evm_defconfig +++ b/configs/dra72_evm_defconfig @@ -24,3 +24,5 @@ CONFIG_DM_SPI=y CONFIG_DM_SPI_FLASH=y CONFIG_TIMER=y CONFIG_OMAP_TIMER=y +CONFIG_DISK=y +CONFIG_DWC_AHCI=y ~~~ But when I patman -n, it throws below error $ ./tools/patman/patman -n Cleaned 1 patches total: 0 errors, 0 warnings, 0 checks, 5 lines checked NOTE: Ignored message types: COMPLEX_MACRO CONSIDER_KSTRTO MINMAX MULTISTATEMENT_MACRO_USE_DO_WHILE NETWORKING_BLOCK_COMMENT_STYLE PREFER_ETHER_ADDR_COPY USLEEP_RANGE 0001-defconfig-dra72_evm-enable-disk-driver-model.patch has no obvious style problems and is ready for submission. Traceback (most recent call last): File "./tools/patman/patman", line 158, in options.add_maintainers) File "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/series.py", line 222, in MakeCcFile raise_on_error=raise_on_error) File "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/gitutil.py", line 321, in BuildEmailList raw += LookupEmail(item, alias, raise_on_error=raise_on_error) File "/home/mugunthan/workspace/git/mainline/u-boot-ti/tools/patman/gitutil.py", line 495, in LookupEmail raise ValueError, msg ValueError: Alias 'defconfig' not found Then I tried with patman setting ignore_errors: True and process_tags: False, then the out seems fine but the tag is not processed. Do you find any thing I missed? Output with modified patman settings: ~ $ ./tools/patman/patman -n Cleaned 1 patches total: 0 errors, 0 warnings, 0 checks, 5 lines checked NOTE: Ignored message types: COMPLEX_MACRO CONSIDER_KSTRTO MINMAX MULTISTATEMENT_MACRO_USE_DO_WHILE NETWORKING_BLOCK_COMMENT_STYLE PREFER_ETHER_ADDR_COPY USLEEP_RANGE 0001-defconfig-dra72_evm-enable-disk-driver-model.patch has no obvious style problems and is ready for submission. No recipient. Please add something like this to a commit Series-to: Fred Bloggs Or do something like this git config sendemail.to u-boot@lists.denx.de Dry run, so not doing much. But I would do this: Send a total of 1 patch with no cover letter. 0001-defconfig-dra72_evm-enable-disk-driver-model.patch Cc: u-boot@lists.denx.de Cc: Lokesh Vutla Version: None Prefix: None Here is my patman config $ cat ~/.patman [alias] me: Mugunthan V N [settings] ignore_errors: True process_tags: False verbose: True Regards Mugunthan V N ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 23/26] spl: Add an option to load a FIT containing U-Boot
Hi Simon, On 28/01/2016 17:39, Simon Glass wrote: > This provides a way to load a FIT containing U-Boot and a selection of device > tree files. The board can select the correct device tree by probing the > hardware. Then U-Boot is started with the selected device tree. > > Signed-off-by: Simon Glass > --- > > Kconfig | 11 +++ > common/spl/Makefile | 1 + > common/spl/spl_fit.c | 192 > +++ > include/spl.h| 18 + > 4 files changed, 222 insertions(+) > create mode 100644 common/spl/spl_fit.c > > diff --git a/Kconfig b/Kconfig > index 3ce5ba1..f32c6c7 100644 > --- a/Kconfig > +++ b/Kconfig > @@ -215,6 +215,17 @@ config SYS_TEXT_BASE > help > TODO: Move CONFIG_SYS_TEXT_BASE for all the architecture > > +config SPL_LOAD_FIT > + bool "Enable SPL loading U-Boot as a FIT" > + depends on FIT > + help > + Normally with the SPL framework a legacy image is generated as part > + of the build. This contains U-Boot along with information as to > + where it should be loaded. This option instead enables generation > + of a FIT (Flat Image Tree) which provides more flexibility. In > + particular it can handle selecting from multiple device tree > + and passing the correct one to U-Boot. > + > config SYS_CLK_FREQ > depends on ARC || ARCH_SUNXI > int "CPU clock frequency" > diff --git a/common/spl/Makefile b/common/spl/Makefile > index 10a4589..2e0f695 100644 > --- a/common/spl/Makefile > +++ b/common/spl/Makefile > @@ -10,6 +10,7 @@ > > ifdef CONFIG_SPL_BUILD > obj-$(CONFIG_SPL_FRAMEWORK) += spl.o > +obj-$(CONFIG_SPL_LOAD_FIT) += spl_fit.o > obj-$(CONFIG_SPL_NOR_SUPPORT) += spl_nor.o > obj-$(CONFIG_SPL_YMODEM_SUPPORT) += spl_ymodem.o > obj-$(CONFIG_SPL_NAND_SUPPORT) += spl_nand.o > diff --git a/common/spl/spl_fit.c b/common/spl/spl_fit.c > new file mode 100644 > index 000..f225f64 > --- /dev/null > +++ b/common/spl/spl_fit.c > @@ -0,0 +1,192 @@ > +/* > + * Copyright (C) 2016 Google, Inc > + * Written by Simon Glass > + * > + * SPDX-License-Identifier: GPL-2.0+ > + */ > + > +#include > +#include > +#include > + I would like to test your patchset, I am trying with a i.MX6 (I want to build wandboard). It looks like that image.h is missing here. common/spl/spl_fit.c: In function 'fdt_getprop_u32': common/spl/spl_fit.c:20:2: warning: implicit declaration of function 'fdt_getprop' [-Wimplicit-function-declaration] However, in image.h it looks like that IMAGE_USE_FIT is not correctly set. I am looking why, I have just added these to wandboard_defconfig: +CONFIG_FIT=y +CONFIG_SPL_OF_LIBFDT=y +CONFIG_SPL_LOAD_FIT=y +CONFIG_OF_LIST="wandboard" Best regards, Stefano > +static ulong fdt_getprop_u32(const void *fdt, int node, const char *prop) > +{ > + const u32 *cell; > + int len; > + > + cell = fdt_getprop(fdt, node, prop, &len); > + if (len != sizeof(*cell)) > + return -1U; > + return fdt32_to_cpu(*cell); > +} > + > +static int spl_fit_select_fdt(const void *fdt, int images, int *fdt_offsetp) > +{ > + const char *name, *fdt_name; > + int conf, node, fdt_node; > + int len; > + > + *fdt_offsetp = 0; > + conf = fdt_path_offset(fdt, FIT_CONFS_PATH); > + if (conf < 0) { > + debug("%s: Cannot find /configurations node: %d\n", __func__, > + conf); > + return -EINVAL; > + } > + for (node = fdt_first_subnode(fdt, conf); > + node >= 0; > + node = fdt_next_subnode(fdt, node)) { > + name = fdt_getprop(fdt, node, "description", &len); > + if (!name) > + return -EINVAL; > + if (board_fit_config_name_match(name)) > + continue; > + > + debug("Selecting config '%s'", name); > + fdt_name = fdt_getprop(fdt, node, FIT_FDT_PROP, &len); > + if (!fdt_name) { > + debug("%s: Cannot find fdt name property: %d\n", > + __func__, len); > + return -EINVAL; > + } > + > + debug(", fdt '%s'\n", fdt_name); > + fdt_node = fdt_subnode_offset(fdt, images, fdt_name); > + if (fdt_node < 0) { > + debug("%s: Cannot find fdt node '%s': %d\n", > + __func__, fdt_name, fdt_node); > + return -EINVAL; > + } > + > + *fdt_offsetp = fdt_getprop_u32(fdt, fdt_node, "data-offset"); > + len = fdt_getprop_u32(fdt, fdt_node, "data-size"); > +#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT > + printf("FIT: Selected '%s'\n", name); > +#endif > + > + return len; > + } > + > +#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT > + printf("No matching DT out of these options:\n"); > + for (node = fdt_first_subnode(fdt, conf); > + node >= 0; > +
[U-Boot] [PATCH] api: Add FreeBSD API support for MIPS platforms
This patch adds U-Boot API support (used by FreeBSD loader) for MIPS platforms. Signed-off-by: Stanislav Galabov --- api/Makefile| 1 + api/api_platform-mips.c | 32 examples/api/Makefile | 3 +++ examples/api/crt0.S | 24 4 files changed, 60 insertions(+) create mode 100644 api/api_platform-mips.c diff --git a/api/Makefile b/api/Makefile index 3c095ee..14b7608 100644 --- a/api/Makefile +++ b/api/Makefile @@ -7,3 +7,4 @@ obj-y += api.o api_display.o api_net.o api_storage.o obj-$(CONFIG_ARM) += api_platform-arm.o obj-$(CONFIG_PPC) += api_platform-powerpc.o +obj-$(CONFIG_MIPS) += api_platform-mips.o diff --git a/api/api_platform-mips.c b/api/api_platform-mips.c new file mode 100644 index 000..a75b0f6 --- /dev/null +++ b/api/api_platform-mips.c @@ -0,0 +1,32 @@ +/* + * (C) Copyright 2007 Stanislav Galabov + * + * SPDX-License-Identifier:GPL-2.0+ + * + * This file contains routines that fetch data from bd_info sources + */ + +#include +#include +#include + +#include +#include + +#include "api_private.h" + +DECLARE_GLOBAL_DATA_PTR; + +/* + * Important notice: handling of individual fields MUST be kept in sync with + * include/asm-generic/u-boot.h, so any changes + * need to reflect their current state and layout of structures involved! + */ +int platform_sys_info(struct sys_info *si) +{ + + platform_set_mr(si, gd->bd->bi_memstart, + gd->bd->bi_memsize, MR_ATTR_DRAM); + + return 1; +} diff --git a/examples/api/Makefile b/examples/api/Makefile index 6cf23d1..4e9b8ea 100644 --- a/examples/api/Makefile +++ b/examples/api/Makefile @@ -10,6 +10,9 @@ endif ifeq ($(ARCH),arm) LOAD_ADDR = 0x100 endif +ifeq ($(ARCH),mips) +LOAD_ADDR = 0x8020 +endif # Resulting ELF and binary exectuables will be named demo and demo.bin extra-y = demo diff --git a/examples/api/crt0.S b/examples/api/crt0.S index 78d35a2..ced2c82 100644 --- a/examples/api/crt0.S +++ b/examples/api/crt0.S @@ -40,6 +40,30 @@ syscall: ldr ip, =syscall_ptr ldr pc, [ip] +#elif defined(CONFIG_MIPS) + .text + .globl __start + .ent __start +__start: + sw $sp, search_hint + b main + .end __start + + .globl syscall + .ent syscall +syscall: + sw $ra, return_addr + lw $t9, syscall_ptr + jalr$t9 + nop + lw $ra, return_addr + jr $ra + nop + .end syscall + +return_addr: + .align 4 + .long 0 #else #error No support for this arch! #endif -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] api: Add FreeBSD API support for MIPS platforms
This patch adds U-Boot API support (used by FreeBSD loader) for MIPS platforms. Signed-off-by: Stanislav Galabov --- api/Makefile| 1 + api/api_platform-mips.c | 32 examples/api/Makefile | 3 +++ examples/api/crt0.S | 24 4 files changed, 60 insertions(+) create mode 100644 api/api_platform-mips.c diff --git a/api/Makefile b/api/Makefile index 3c095ee..14b7608 100644 --- a/api/Makefile +++ b/api/Makefile @@ -7,3 +7,4 @@ obj-y += api.o api_display.o api_net.o api_storage.o obj-$(CONFIG_ARM) += api_platform-arm.o obj-$(CONFIG_PPC) += api_platform-powerpc.o +obj-$(CONFIG_MIPS) += api_platform-mips.o diff --git a/api/api_platform-mips.c b/api/api_platform-mips.c new file mode 100644 index 000..a75b0f6 --- /dev/null +++ b/api/api_platform-mips.c @@ -0,0 +1,32 @@ +/* + * (C) Copyright 2007 Stanislav Galabov + * + * SPDX-License-Identifier:GPL-2.0+ + * + * This file contains routines that fetch data from bd_info sources + */ + +#include +#include +#include + +#include +#include + +#include "api_private.h" + +DECLARE_GLOBAL_DATA_PTR; + +/* + * Important notice: handling of individual fields MUST be kept in sync with + * include/asm-generic/u-boot.h, so any changes + * need to reflect their current state and layout of structures involved! + */ +int platform_sys_info(struct sys_info *si) +{ + + platform_set_mr(si, gd->bd->bi_memstart, + gd->bd->bi_memsize, MR_ATTR_DRAM); + + return 1; +} diff --git a/examples/api/Makefile b/examples/api/Makefile index 6cf23d1..4e9b8ea 100644 --- a/examples/api/Makefile +++ b/examples/api/Makefile @@ -10,6 +10,9 @@ endif ifeq ($(ARCH),arm) LOAD_ADDR = 0x100 endif +ifeq ($(ARCH),mips) +LOAD_ADDR = 0x8020 +endif # Resulting ELF and binary exectuables will be named demo and demo.bin extra-y = demo diff --git a/examples/api/crt0.S b/examples/api/crt0.S index 78d35a2..ced2c82 100644 --- a/examples/api/crt0.S +++ b/examples/api/crt0.S @@ -40,6 +40,30 @@ syscall: ldr ip, =syscall_ptr ldr pc, [ip] +#elif defined(CONFIG_MIPS) + .text + .globl __start + .ent __start +__start: + sw $sp, search_hint + b main + .end __start + + .globl syscall + .ent syscall +syscall: + sw $ra, return_addr + lw $t9, syscall_ptr + jalr$t9 + nop + lw $ra, return_addr + jr $ra + nop + .end syscall + +return_addr: + .align 4 + .long 0 #else #error No support for this arch! #endif -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] armv8/ls2080ardb: Enable VID support
The fuse status register provides the values from on-chip voltage ID efuses programmed at the factory. These values define the voltage requirements for the chip. u-boot reads FUSESR and translates the values into the appropriate commands to set the voltage output value of an external voltage regulator. Signed-off-by: Rai Harninder --- .../include/asm/arch-fsl-layerscape/immap_lsch3.h |4 board/freescale/common/vid.c | 15 ++- board/freescale/ls2080ardb/ls2080ardb.c|5 + include/configs/ls2080ardb.h | 16 4 files changed, 39 insertions(+), 1 deletions(-) diff --git a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h index 91f3ce8..4fd58ee 100644 --- a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h +++ b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch3.h @@ -146,6 +146,10 @@ struct ccsr_gur { u8 res_008[0x20-0x8]; u32 gpporcr1; /* General-purpose POR configuration */ u32 gpporcr2; /* General-purpose POR configuration 2 */ +#define FSL_CHASSIS3_DCFG_FUSESR_VID_SHIFT 25 +#define FSL_CHASSIS3_DCFG_FUSESR_VID_MASK 0x1F +#define FSL_CHASSIS3_DCFG_FUSESR_ALTVID_SHIFT 20 +#define FSL_CHASSIS3_DCFG_FUSESR_ALTVID_MASK 0x1F u32 dcfg_fusesr;/* Fuse status register */ u32 gpporcr3; u32 gpporcr4; diff --git a/board/freescale/common/vid.c b/board/freescale/common/vid.c index 1bd65a8..16ae177 100644 --- a/board/freescale/common/vid.c +++ b/board/freescale/common/vid.c @@ -10,6 +10,8 @@ #include #ifdef CONFIG_LS1043A #include +#elif defined(CONFIG_FSL_LAYERSCAPE) +#include #else #include #endif @@ -285,7 +287,7 @@ static int set_voltage(int i2caddress, int vdd) int adjust_vdd(ulong vdd_override) { int re_enable = disable_interrupts(); -#ifdef CONFIG_LS1043A +#if defined(CONFIG_LS1043A) || defined(CONFIG_FSL_LAYERSCAPE) struct ccsr_gur *gur = (void *)(CONFIG_SYS_FSL_GUTS_ADDR); #else ccsr_gur_t __iomem *gur = @@ -362,7 +364,11 @@ int adjust_vdd(ulong vdd_override) } /* get the voltage ID from fuse status register */ +#ifdef CONFIG_FSL_LAYERSCAPE + fusesr = in_le32(&gur->dcfg_fusesr); +#else fusesr = in_be32(&gur->dcfg_fusesr); +#endif /* * VID is used according to the table below *--- @@ -387,6 +393,13 @@ int adjust_vdd(ulong vdd_override) vid = (fusesr >> FSL_CHASSIS2_DCFG_FUSESR_VID_SHIFT) & FSL_CHASSIS2_DCFG_FUSESR_VID_MASK; } +#elif defined(CONFIG_FSL_LAYERSCAPE) + vid = (fusesr >> FSL_CHASSIS3_DCFG_FUSESR_ALTVID_SHIFT) & + FSL_CHASSIS3_DCFG_FUSESR_ALTVID_MASK; + if ((vid == 0) || (vid == FSL_CHASSIS3_DCFG_FUSESR_ALTVID_MASK)) { + vid = (fusesr >> FSL_CHASSIS3_DCFG_FUSESR_VID_SHIFT) & + FSL_CHASSIS3_DCFG_FUSESR_VID_MASK; + } #else vid = (fusesr >> FSL_CORENET_DCFG_FUSESR_ALTVID_SHIFT) & FSL_CORENET_DCFG_FUSESR_ALTVID_MASK; diff --git a/board/freescale/ls2080ardb/ls2080ardb.c b/board/freescale/ls2080ardb/ls2080ardb.c index c63b639..9515b25 100644 --- a/board/freescale/ls2080ardb/ls2080ardb.c +++ b/board/freescale/ls2080ardb/ls2080ardb.c @@ -122,6 +122,11 @@ int select_i2c_ch_pca9547(u8 ch) return 0; } +int i2c_multiplexer_select_vid_channel(u8 channel) +{ + return select_i2c_ch_pca9547(channel); +} + int config_board_mux(int ctrl_type) { u8 reg5; diff --git a/include/configs/ls2080ardb.h b/include/configs/ls2080ardb.h index 116dbcd..9a95f31 100644 --- a/include/configs/ls2080ardb.h +++ b/include/configs/ls2080ardb.h @@ -14,6 +14,22 @@ #define CONFIG_DISPLAY_BOARDINFO +#define I2C_MUX_CH_VOL_MONITOR 0xa +#define I2C_VOL_MONITOR_ADDR 0x38 +#define CONFIG_VOL_MONITOR_IR36021_READ +#define CONFIG_VOL_MONITOR_IR36021_SET + +#define CONFIG_VID_FLS_ENV "ls2080ardb_vdd_mv" +#ifndef CONFIG_SPL_BUILD +#define CONFIG_VID +#endif +/* step the IR regulator in 5mV increments */ +#define IR_VDD_STEP_DOWN 5 +#define IR_VDD_STEP_UP 5 +/* The lowest and highest voltage allowed for LS2080ARDB */ +#define VDD_MV_MIN 819 +#define VDD_MV_MAX 1212 + #ifndef __ASSEMBLY__ unsigned long get_board_sys_clk(void); #endif -- 1.7.6.GIT ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] ppc: xilinx-ppc405-generic
On 04.02.2016 14:45, Ricardo Ribalda Delgado wrote: Fix device tree name: +(xilinx-ppc405-generic) Device Tree Source is not correctly specified. +(xilinx-ppc405-generic) Please define 'CONFIG_DEFAULT_DEVICE_TREE' +(xilinx-ppc405-generic) or build with 'DEVICE_TREE=' argument +(xilinx-ppc405-generic) make[2]: *** [arch/powerpc/dts/xilinx-ppc440-generic.dtb] Error 1 +(xilinx-ppc405-generic) make[1]: *** [dts] Error 2 Signed-off-by: Ricardo Ribalda Delgado --- configs/xilinx-ppc405-generic_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configs/xilinx-ppc405-generic_defconfig b/configs/xilinx-ppc405-generic_defconfig index e7132cd61152..85bc3b97ff38 100644 --- a/configs/xilinx-ppc405-generic_defconfig +++ b/configs/xilinx-ppc405-generic_defconfig @@ -14,4 +14,4 @@ CONFIG_OF_EMBED=y CONFIG_OF_CONTROL=y CONFIG_FIT=y CONFIG_FIT_VERBOSE=y -CONFIG_DEFAULT_DEVICE_TREE="xilinx-ppc440-generic" +CONFIG_DEFAULT_DEVICE_TREE="xilinx-ppc405-generic" Reviewed-by: Stefan Roese Thanks, Stefan ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 1/2] imx: mx6: Implement mmc_get_env_part
commit 216d286c7e3d3d83d4d8ccaf0415192e1b1040c0 [imx: mx6: implement mmc_get_env_dev] introduced selection of the environment device according to the boot device when booting from SD/MMC. Extend this functionality for also selecting the device partition. Signed-off-by: Soeren Moch --- Cc: Stefano Babic Cc: Peng Fan Cc: Fabio Estevam Cc: u-boot@lists.denx.de --- arch/arm/cpu/armv7/mx6/soc.c | 36 +--- 1 file changed, 33 insertions(+), 3 deletions(-) diff --git a/arch/arm/cpu/armv7/mx6/soc.c b/arch/arm/cpu/armv7/mx6/soc.c index 8aeeaec..db6eabf 100644 --- a/arch/arm/cpu/armv7/mx6/soc.c +++ b/arch/arm/cpu/armv7/mx6/soc.c @@ -21,6 +21,7 @@ #include #include #include +#include enum ldo_reg { LDO_ARM, @@ -355,7 +356,7 @@ __weak int board_mmc_get_env_dev(int devno) return CONFIG_SYS_MMC_ENV_DEV; } -int mmc_get_env_dev(void) +static int mmc_get_boot_dev(void) { struct src *src_regs = (struct src *)SRC_BASE_ADDR; u32 soc_sbmr = readl(&src_regs->sbmr1); @@ -370,15 +371,44 @@ int mmc_get_env_dev(void) */ bootsel = (soc_sbmr & 0x00FF) >> 6; - /* If not boot from sd/mmc, use default value */ + /* No boot from sd/mmc */ if (bootsel != 1) - return CONFIG_SYS_MMC_ENV_DEV; + return -1; /* BOOT_CFG2[3] and BOOT_CFG2[4] */ devno = (soc_sbmr & 0x1800) >> 11; + return devno; +} + +int mmc_get_env_dev(void) +{ + int devno = mmc_get_boot_dev(); + + /* If not boot from sd/mmc, use default value */ + if (devno < 0) + return CONFIG_SYS_MMC_ENV_DEV; + return board_mmc_get_env_dev(devno); } + +#ifdef CONFIG_SYS_MMC_ENV_PART +__weak int board_mmc_get_env_part(int devno) +{ + return CONFIG_SYS_MMC_ENV_PART; +} + +uint mmc_get_env_part(struct mmc *mmc) +{ + int devno = mmc_get_boot_dev(); + + /* If not boot from sd/mmc, use default value */ + if (devno < 0) + return CONFIG_SYS_MMC_ENV_PART; + + return board_mmc_get_env_part(devno); +} +#endif #endif int board_postclk_init(void) -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 2/2] board: tbs2910: Autoselect environment device when booting from SD
Implement board specific functions to select the environment device and partition when booting from SD/MMC. SD2: mmc 0 0 SD3: mmc 1 0 eMMC: mmc 2 1 Signed-off-by: Soeren Moch --- Cc: Stefano Babic Cc: Peng Fan Cc: Fabio Estevam Cc: u-boot@lists.denx.de --- board/tbs/tbs2910/tbs2910.c | 11 +++ include/configs/tbs2910.h | 4 ++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/board/tbs/tbs2910/tbs2910.c b/board/tbs/tbs2910/tbs2910.c index 0b509b6..d302fc2 100644 --- a/board/tbs/tbs2910/tbs2910.c +++ b/board/tbs/tbs2910/tbs2910.c @@ -257,6 +257,17 @@ int board_mmc_init(bd_t *bis) } return 0; } + +/* set environment device to boot device when booting from SD */ +int board_mmc_get_env_dev(int devno) +{ + return devno - 1; +} + +int board_mmc_get_env_part(int devno) +{ + return (devno == 3) ? 1 : 0; /* part 0 for SD2 / SD3, part 1 for eMMC */ +} #endif /* CONFIG_FSL_ESDHC */ #ifdef CONFIG_VIDEO_IPUV3 diff --git a/include/configs/tbs2910.h b/include/configs/tbs2910.h index 17b0213..0f23034 100644 --- a/include/configs/tbs2910.h +++ b/include/configs/tbs2910.h @@ -176,8 +176,8 @@ /* Environment organization */ #define CONFIG_ENV_IS_IN_MMC -#define CONFIG_SYS_MMC_ENV_DEV 2 -#define CONFIG_SYS_MMC_ENV_PART1 +#define CONFIG_SYS_MMC_ENV_DEV 2 /* overwritten on SD boot */ +#define CONFIG_SYS_MMC_ENV_PART1 /* overwritten on SD boot */ #define CONFIG_ENV_SIZE(8 * 1024) #define CONFIG_ENV_OFFSET (384 * 1024) #define CONFIG_ENV_OVERWRITE -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [GIT PULL] Xilinx changes
Hi I have just sent a patch for this. Sorry about that! On Fri, Jan 29, 2016 at 12:18 AM, Tom Rini wrote: > On Wed, Jan 27, 2016 at 04:42:09PM +0100, Michal Simek wrote: > >> Hi Tom, >> >> here is the branch with xilinx changes which are flying around. >> It is targeting PowerPC, Microblaze, ARM and ARM64. >> I can't see any build problem via buildman. >> >> Thanks, >> Michal >> >> >> The following changes since commit 9e4de7fd4acc8f99b6d383c711d21c0159849629: >> >> Merge branch 'master' of http://git.denx.de/u-boot-sunxi (2016-01-26 >> 17:45:37 -0500) >> >> are available in the git repository at: >> >> >> git://www.denx.de/git/u-boot-microblaze.git master >> >> for you to fetch changes up to f36919a8138ed7ecd3dbce4630e02936b13907da: >> >> ppc: xilinx-ppc440-generic: Wire LL_TEMAC driver (2016-01-27 15:57:20 >> +0100) >> > > Applied to u-boot/master, thanks! > > But note: > +(xilinx-ppc405-generic) Device Tree Source is not correctly specified. > +(xilinx-ppc405-generic) Please define 'CONFIG_DEFAULT_DEVICE_TREE' > +(xilinx-ppc405-generic) or build with 'DEVICE_TREE=' argument > +(xilinx-ppc405-generic) make[2]: *** > [arch/powerpc/dts/xilinx-ppc440-generic.dtb] Error 1 > +(xilinx-ppc405-generic) make[1]: *** [dts] Error 2 > > -- > Tom > > ___ > U-Boot mailing list > U-Boot@lists.denx.de > http://lists.denx.de/mailman/listinfo/u-boot > -- Ricardo Ribalda ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] ppc: xilinx-ppc405-generic
Fix device tree name: +(xilinx-ppc405-generic) Device Tree Source is not correctly specified. +(xilinx-ppc405-generic) Please define 'CONFIG_DEFAULT_DEVICE_TREE' +(xilinx-ppc405-generic) or build with 'DEVICE_TREE=' argument +(xilinx-ppc405-generic) make[2]: *** [arch/powerpc/dts/xilinx-ppc440-generic.dtb] Error 1 +(xilinx-ppc405-generic) make[1]: *** [dts] Error 2 Signed-off-by: Ricardo Ribalda Delgado --- configs/xilinx-ppc405-generic_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configs/xilinx-ppc405-generic_defconfig b/configs/xilinx-ppc405-generic_defconfig index e7132cd61152..85bc3b97ff38 100644 --- a/configs/xilinx-ppc405-generic_defconfig +++ b/configs/xilinx-ppc405-generic_defconfig @@ -14,4 +14,4 @@ CONFIG_OF_EMBED=y CONFIG_OF_CONTROL=y CONFIG_FIT=y CONFIG_FIT_VERBOSE=y -CONFIG_DEFAULT_DEVICE_TREE="xilinx-ppc440-generic" +CONFIG_DEFAULT_DEVICE_TREE="xilinx-ppc405-generic" -- 2.7.0 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] .travis.yml: rework according to new travis-ci infra
2016-02-03 17:58 GMT+01:00 Stephen Warren : > On 02/01/2016 06:57 PM, Tom Rini wrote: >> >> On Mon, Jan 25, 2016 at 08:22:41PM +0100, Roger Meier wrote: >> >>> - install using addons.apt >>> - remove MAKEALL >>> - split mpc85xx boards >>> - remove TEST_CONFIG_CMD, just info >>> - fetch mips toolchain via buildman >>> - remove --list-error-boards param >>> - conditional script >>> - use TOOLCHAIN instead of INSTALL_TOOLCHAIN >>> - add aarch64 >>> - enable notifications via email >>> >>> Signed-off-by: Roger Meier >>> Cc: Wolfgang Denk >>> Cc: Heiko Schocher >>> Cc: Tom Rini >>> Cc: Daniel Schwierzeck >>> Cc: Andreas Färber >>> Tested-by: Daniel Schwierzeck >>> Acked-by: Heiko Schocher >> >> >> Applied to u-boot/master, thanks! > > > I wanted to add something to this file, so I set up my own travis-ci.org > account and made it run against my own github U-Boot repo "fork" to test my > change. However, most of the builds failed before I even modified > .travis.yml. For example: > >> $ if [[ "${TOOLCHAIN}" == *arm* ]]; then sh >> eldk-eglibc-i686-arm-toolchain-gmae-5.4.sh -y ; fi >> Enter target directory for SDK (default: /opt/eldk-5.4/armv5te): >> /opt/eldk-5.4/armv5te >> You are about to install the SDK to "/opt/eldk-5.4/armv5te". >> Proceed[Y/n]?Y >> Sorry, you are not allowed to execute as root. > > > Do I need to perform some manual configuration of my repo/branch/profile/... > before this .travis.yml will work correctly (container vs VM I wonder?), or > perhaps obtain some kind of authorization from the Travis CI admins? If so, > if that could all be documented in a comment at the top of .travis.yml that > would be extremely helpful. Bonus points if it can be handled simply be > adding extra configuration options into .travis.yml so that it "just works" > without manual steps. Have a look at [1]. The standard Ubuntu Precise builders have "sudo: required" enabled for repositories created before 2015. Newer repositories obviously need to explicitely add "sudo: required" to the .travis.yml. [1] https://docs.travis-ci.com/user/ci-environment/ -- - Daniel ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] fastboot: sparse: remove unnecessary logging
Hi Steve, On Wed, Feb 03, 2016 at 12:46:02PM -0800, Steve Rae wrote: > remove logging of the 'skipped' blocks > > Signed-off-by: Steve Rae > --- > > common/image-sparse.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/common/image-sparse.c b/common/image-sparse.c > index f02aee4..594bf4e 100644 > --- a/common/image-sparse.c > +++ b/common/image-sparse.c > @@ -275,7 +275,6 @@ int store_sparse_image(sparse_storage_t *storage, void > *storage_priv, > sparse_buffer_t *buffer; > uint32_t start; > uint32_t total_blocks = 0; > - uint32_t skipped = 0; > int i; > > debug("=== Storage ===\n"); > @@ -334,7 +333,6 @@ int store_sparse_image(sparse_storage_t *storage, void > *storage_priv, > storage, > sparse_header); > total_blocks += blkcnt; > - skipped += blkcnt; > continue; > } > > @@ -375,8 +373,8 @@ int store_sparse_image(sparse_storage_t *storage, void > *storage_priv, > sparse_put_data_buffer(buffer); > } > > - debug("Wrote %d blocks, skipped %d, expected to write %d blocks\n", > - total_blocks, skipped, > + debug("Wrote %d blocks, expected to write %d blocks\n", > + total_blocks, What's the rationale between those two patches? Do we really want to treat the DONT_CARE chunks as if they were written? Maxime -- Maxime Ripard, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] usb: gadget: f_thor: free the allocated out request buffer
On Thursday, February 04, 2016 at 12:34:57 PM, Michal Simek wrote: > Hi guys, > > On 7.12.2015 12:59, Michal Simek wrote: > > From: Siva Durga Prasad Paladugu > > > > Fix the memory leak by freeing the allocated out request buffer > > > > Signed-off-by: Siva Durga Prasad Paladugu > > Signed-off-by: Michal Simek > > --- > > > > drivers/usb/gadget/f_thor.c | 4 > > 1 file changed, 4 insertions(+) > > > > diff --git a/drivers/usb/gadget/f_thor.c b/drivers/usb/gadget/f_thor.c > > index a60e9487e774..75b72902c9d5 100644 > > --- a/drivers/usb/gadget/f_thor.c > > +++ b/drivers/usb/gadget/f_thor.c > > @@ -51,6 +51,7 @@ DEFINE_CACHE_ALIGN_BUFFER(unsigned char, > > thor_rx_data_buf, > > > > DEFINE_CACHE_ALIGN_BUFFER(char, f_name, F_NAME_BUF_SIZE); > > static unsigned long long int thor_file_size; > > static int alt_setting_num; > > > > +static void *out_req_buf; > > > > static void send_rsp(const struct rsp_box *rsp) > > { > > > > @@ -891,6 +892,8 @@ static void thor_func_disable(struct usb_function *f) > > > > } > > > > if (dev->out_ep->driver_data) { > > > > + if (out_req_buf) > > + free(out_req_buf); Why don't you call free(dev->out_req->buf); here instead ? Then you won't need that new variable you introduce. > > dev->out_req->buf = NULL; > > usb_ep_free_request(dev->out_ep, dev->out_req); > > usb_ep_disable(dev->out_ep); > > > > @@ -947,6 +950,7 @@ static int thor_eps_setup(struct usb_function *f) > > > > } > > > > dev->out_req = req; > > > > + out_req_buf = dev->out_req->buf; > > > > /* ACM control EP */ > > ep = dev->int_ep; > > ep->driver_data = cdev; /* claim */ > > any update on this one? > > Thanks, > Michal Best regards, Marek Vasut ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] usb: dwc2: Enhance interrupt handling for CONTROL transaction
On Thursday, January 14, 2016 at 04:20:12 PM, Marek Vasut wrote: > On Thursday, January 14, 2016 at 03:50:18 PM, Chin Liang See wrote: > > On Wed, 2016-01-13 at 16:22 +0100, Marek Vasut wrote: > > > On Wednesday, January 13, 2016 at 04:18:43 PM, Chin Liang See wrote: > > > > On Wed, 2016-01-13 at 03:58 +0100, Marek Vasut wrote: > > > > > On Tuesday, January 05, 2016 at 05:16:05 PM, Marek Vasut wrote: > > > > > > On Tuesday, January 05, 2016 at 04:51:47 PM, Chin Liang See > > > > > > > > > > > > wrote: > > > > > > > On Tue, 2016-01-05 at 15:36 +0100, Marek Vasut wrote: > > > > > > > > On Tuesday, January 05, 2016 at 06:00:04 AM, Chin Liang See > > > > > > > > > > > > > > > > wrote: > > > > > > > > > Per DesignWare USB OTG databook, driver should retry up > > > > > > > > > to > > > > > > > > > 3 times when transaction error (hcint.xacterr) happen. > > > > > > > > > But > > > > > > > > > the 3 times doesn't count when the response is nack > > > > > > > > > (hcint.nak) or frame overrun (hcint.frmoverun) > > > > > > > > > > > > > > > > > > This patch solved the enumeration error as spotted at > > > > > > > > > socfpga > > > > > > > > > cyclone5_socdk when plugging in certain pendrive. > > > > > > > > > > > > > > > > > > Signed-off-by: Chin Liang See > > > > > > > > > Cc: Marek Vasut > > > > > > > > > Cc: Dinh Nguyen > > > > > > > > > Cc: Dinh Nguyen > > > > > > > > > Cc: Pavel Machek > > > > > > > > > Cc: Oleksandr Tymoshenko > > > > > > > > > Cc: Stephen Warren > > > > > > > > > Cc: Alexander Stein > > > > > > > > > Cc: Peter Griffin > > > > > > > > > > > > > > > > I applied this change on top of u-boot-socfpga/master and > > > > > > > > tested it > > > > > > > > on > > > > > > > > SoCFPGA CycloneV SoCDK with "Sandisk cruzer force" stick. > > > > > > > > The > > > > > > > > board > > > > > > > > gets > > > > > > > > completely stuck if I have dcache ENABLED and perform 'usb > > > > > > > > reset'. > > > > > > > > This > > > > > > > > > > > > > > > patch is: > > > > > > > Thanks Marek for testing. I managed to find a SanDisk Cruzer > > > > > > > Blade and > > > > > > > notice the same fail behaviours as yours. FYI, note that this > > > > > > > patch > > > > > > > works well with other 3 pendrive that I have. > > > > > > > > > > > > > > With SanDisk, the dwc2 driver was timed out as hcint.xfercomp > > > > > > > and > > > > > > > chhltd never get set even after 1s. It keep retrying > > > > > > > endlessly > > > > > > > due to > > > > > > > miss handling for the ETIMEDOUT within this patch. > > > > > > > > > > > > > > In short, the retry doesn't work for SanDisk but the dcache > > > > > > > disable > > > > > > > works. Need to figure out more what cause the failure. > > > > > > > > > > > > Excellent, I have one of those too (I bought the entire lineup > > > > > > of > > > > > > these > > > > > > sandisk sticks at one point ;-) ) > > > > > > > > > > Hi, any news on the SoCFPGA USB/QSPI problem investigation? > > > > > Thanks! > > > > > > > > I am still troubleshooting it. I played with few configuration > > > > within > > > > L3 but not helping. This including avoiding multiple outstanding > > > > transaction and security (allow both secure and non secure). > > > > > > Yeah > > > > > > > But all these issue will gone once dcache is off. I believe need to > > > > visit the MMU table. > > > > > > I was there already ;-) But given enough eyeballs, are bugs are > > > shallow. > > > > Continue some troubleshooting today. Notice some behavior change where > > the SanDisk Cruzer Blade failed after POR and dcache disable. > > > > After enabling the debug message, the hub is complaining over current > > (port change = 0x9) on the port where pen drive is plugged in. The port > > status = 0x10 indicate no device present. > > > > Appreciate any quick advise while digging more the hub spec. > > I suspect the data are corrupted somewhere. I wouldn't trust the content > of the descriptor at that point. Hi, any news on the USB mess ? :-) ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PULL] u-boot-socfpga/master
The following changes since commit 44189a032804c4a16632f4e80abf77f2820e9a48: Prepare v2016.03-rc1 (2016-02-02 11:29:50 -0500) are available in the git repository at: git://git.denx.de/u-boot-socfpga.git master for you to fetch changes up to a409a8b85ee337250043aa0c031a31b3a6639e74: Revert "arm: socfpga: set the fpga global bit to disable HPS to FPGA signals" (2016-02-04 12:43:21 +0100) Dinh Nguyen (1): Revert "arm: socfpga: set the fpga global bit to disable HPS to FPGA signals" drivers/fpga/socfpga.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PULL] u-boot-usb/master
The following changes since commit 44189a032804c4a16632f4e80abf77f2820e9a48: Prepare v2016.03-rc1 (2016-02-02 11:29:50 -0500) are available in the git repository at: git://git.denx.de/u-boot-usb.git master for you to fetch changes up to 8c9b4d5598e014036d2f2637c17bd6e3748ff6a3: usb: gadget: dwc2_udc_otg: modified the check condition for max packet size of ep_in in high speed (2016-02-04 12:38:26 +0100) Frank Wang (1): usb: gadget: dwc2_udc_otg: modified the check condition for max packet size of ep_in in high speed drivers/usb/gadget/dwc2_udc_otg.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] Issue with USB mass storage (thumb drives)
On Thursday, February 04, 2016 at 09:21:08 AM, Schrempf Frieder wrote: > On 03.02.2016 20:16, Sergei Temerkhanov wrote: > > On Wed, Feb 3, 2016 at 8:40 AM, Marek Vasut wrote: > >> On Wednesday, February 03, 2016 at 12:49:20 PM, Schrempf Frieder wrote: > >>> On 03.02.2016 12:12, Marek Vasut wrote: > On Wednesday, February 03, 2016 at 11:15:00 AM, Schrempf Frieder wrote: > > On 03.02.2016 10:55, Fabio Estevam wrote: > >> On Wed, Feb 3, 2016 at 7:40 AM, Marek Vasut wrote: > >>> In that case, debug time. > >>> > >>> Usual problems are bad routing of the tracks on the board , so try > >>> with USB 1.1 hub and if that works, that's your problem. > >> > >> Another suggestion would be to try the 100MB transfer in Linux and > >> see if this works or not. > >> > >> That would help us to narrow down whether this is a hardware or > >> software problem. > > > > Another thing to try may be limiting the value of USB_MAX_XFER_BLK in > > common/usb_storage.c > > This was a really helpful hint! Thank you Sergei! > > I just tried to limit USB_MAX_XFER_BLK to 1/8 of the original value > (65535 -> 8191) and this time the transfer works without timeouts. > > As we have a customer who needs this working as soon as possible my > question now is how to properly solve this. > Should I generally limit USB_MAX_XFER_BLK in my u-boot to avoid these > errors? Which value to choose? Nice! Can you share which sticks are those, ideally brand/type and USB IDs ? Best regards, Marek Vasut ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCHv2 1/3] arm: socfpga: add reset manager defines for Arria10
On Tuesday, January 12, 2016 at 09:56:42 PM, dingu...@opensource.altera.com wrote: > From: Dinh Nguyen > > Add the Arria10 reset manager defines that is used in Linux. Change the > license to SPDX. > > [commit 007bb689b3dbad83cdab0ad192bc6ed0162451e0 from the Linux kernel] > > Signed-off-by: Dinh Nguyen Hi! A10 branch is now u-boot-socfpga/01-arria10 . What is the current status of Arria10 please ? Best regards, Marek Vasut ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] do i have any chance of booting a vxworks 5.5.2 image with u-boot?
On 02/03/2016 12:16 PM, Robert P. J. Day wrote: Quoting Tom Rini : On Mon, Feb 01, 2016 at 05:20:16PM -0500, Robert P. J. Day wrote: i know u-boot has a "bootvx" command for booting vxworks images, but from what i read here: http://stackoverflow.com/questions/24114948/vxworks-portingdm8168 it's only vxworks 7 that supports u-boot as its bootloader. i know precious little about vxworks, i was just handed a version 5.5.2 image and asked whether it was possible for u-boot to boot it. do i have any chance whatsoever? any guidance would be useful. Well, I think there's two parts to this answer. The first is that (on PowerPC), VxWorks has been supported for practically forever. The second is that as the answers there say, you may have to deal with and fix some disagreements about what software (U-Boot or VxWorks) did or did not do what initalization. You may also, frankly, want to start out with a U-Boot of that vintage, see if that works, and if so (and it'd be great to see results and patches if needed) if things still work in mainline today. i'm certainly willing to put in the time to do this -- i have the hardware and the appropriate build environment so give me a day or two to finish something, and i can pretty much concentrate on this and submit any patches that eventually get this to work. rday Hi Robert, Tom, bootvx also boots some vxWorks 6.9.x in my case. Before i've used the bootvx command i simply fired the vxworks image with go The kernel-configuration of the vxworks Image has a define called RUNTIME_LOW_ADDRS, load your image to this address and give a go on this address. your vxWorks kernel should boot. I've stripped the vxWorks build output with "objcopyarm -O binary --binary-without-bss" You don't have a bootline initialization at this time. If you want some initalization of it, the bootvx command is the right way. Have a look to the B&R kwb board in uboot (kwb.h) Feel free to ask if something doesn't work. best regards, Hannes ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] usb: gadget: f_thor: free the allocated out request buffer
Hi guys, On 7.12.2015 12:59, Michal Simek wrote: > From: Siva Durga Prasad Paladugu > > Fix the memory leak by freeing the allocated out request buffer > > Signed-off-by: Siva Durga Prasad Paladugu > Signed-off-by: Michal Simek > --- > > drivers/usb/gadget/f_thor.c | 4 > 1 file changed, 4 insertions(+) > > diff --git a/drivers/usb/gadget/f_thor.c b/drivers/usb/gadget/f_thor.c > index a60e9487e774..75b72902c9d5 100644 > --- a/drivers/usb/gadget/f_thor.c > +++ b/drivers/usb/gadget/f_thor.c > @@ -51,6 +51,7 @@ DEFINE_CACHE_ALIGN_BUFFER(unsigned char, thor_rx_data_buf, > DEFINE_CACHE_ALIGN_BUFFER(char, f_name, F_NAME_BUF_SIZE); > static unsigned long long int thor_file_size; > static int alt_setting_num; > +static void *out_req_buf; > > static void send_rsp(const struct rsp_box *rsp) > { > @@ -891,6 +892,8 @@ static void thor_func_disable(struct usb_function *f) > } > > if (dev->out_ep->driver_data) { > + if (out_req_buf) > + free(out_req_buf); > dev->out_req->buf = NULL; > usb_ep_free_request(dev->out_ep, dev->out_req); > usb_ep_disable(dev->out_ep); > @@ -947,6 +950,7 @@ static int thor_eps_setup(struct usb_function *f) > } > > dev->out_req = req; > + out_req_buf = dev->out_req->buf; > /* ACM control EP */ > ep = dev->int_ep; > ep->driver_data = cdev; /* claim */ > any update on this one? Thanks, Michal -- Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91 w: www.monstr.eu p: +42-0-721842854 Maintainer of Linux kernel - Microblaze cpu - http://www.monstr.eu/fdt/ Maintainer of Linux kernel - Xilinx Zynq ARM architecture Microblaze U-BOOT custodian and responsible for u-boot arm zynq platform signature.asc Description: OpenPGP digital signature ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 2/4] mmc: Kconfig: Add Arasan SDHCI entry
Add Arasan SDHCI entry to Kconfig and fix all references. Signed-off-by: Michal Simek --- configs/xilinx_zynqmp_ep_defconfig | 1 + configs/zynq_microzed_defconfig| 1 + configs/zynq_picozed_defconfig | 1 + configs/zynq_zc702_defconfig | 1 + configs/zynq_zc706_defconfig | 1 + configs/zynq_zc770_xm010_defconfig | 1 + configs/zynq_zed_defconfig | 1 + configs/zynq_zybo_defconfig| 1 + drivers/mmc/Kconfig| 6 ++ include/configs/xilinx_zynqmp.h| 6 +- include/configs/xilinx_zynqmp_ep.h | 1 - include/configs/zynq-common.h | 7 +++ include/configs/zynq_microzed.h| 2 -- include/configs/zynq_picozed.h | 1 - include/configs/zynq_zc70x.h | 1 - include/configs/zynq_zc770.h | 5 + include/configs/zynq_zed.h | 1 - include/configs/zynq_zybo.h| 1 - 18 files changed, 19 insertions(+), 20 deletions(-) diff --git a/configs/xilinx_zynqmp_ep_defconfig b/configs/xilinx_zynqmp_ep_defconfig index dd2a9edffb81..3d12c96d35c6 100644 --- a/configs/xilinx_zynqmp_ep_defconfig +++ b/configs/xilinx_zynqmp_ep_defconfig @@ -24,5 +24,6 @@ CONFIG_CMD_TIME=y CONFIG_CMD_TIMER=y CONFIG_OF_EMBED=y CONFIG_NET_RANDOM_ETHADDR=y +CONFIG_ZYNQ_SDHCI=y CONFIG_ZYNQ_GEM=y # CONFIG_REGEX is not set diff --git a/configs/zynq_microzed_defconfig b/configs/zynq_microzed_defconfig index a3a66ec41a37..4c5152fa73e7 100644 --- a/configs/zynq_microzed_defconfig +++ b/configs/zynq_microzed_defconfig @@ -13,6 +13,7 @@ CONFIG_CMD_GPIO=y # CONFIG_CMD_SETEXPR is not set CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_DM_SEQ_ALIAS=y +CONFIG_ZYNQ_SDHCI=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_SPANSION=y CONFIG_SPI_FLASH_STMICRO=y diff --git a/configs/zynq_picozed_defconfig b/configs/zynq_picozed_defconfig index fbc603fd95cd..f34e2e3e265a 100644 --- a/configs/zynq_picozed_defconfig +++ b/configs/zynq_picozed_defconfig @@ -10,4 +10,5 @@ CONFIG_CMD_GPIO=y # CONFIG_CMD_SETEXPR is not set CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_DM_SEQ_ALIAS=y +CONFIG_ZYNQ_SDHCI=y CONFIG_ZYNQ_GEM=y diff --git a/configs/zynq_zc702_defconfig b/configs/zynq_zc702_defconfig index 3540653e2270..f01874f23f94 100644 --- a/configs/zynq_zc702_defconfig +++ b/configs/zynq_zc702_defconfig @@ -12,6 +12,7 @@ CONFIG_CMD_GPIO=y # CONFIG_CMD_SETEXPR is not set CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_DM_SEQ_ALIAS=y +CONFIG_ZYNQ_SDHCI=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_BAR=y CONFIG_SPI_FLASH_SPANSION=y diff --git a/configs/zynq_zc706_defconfig b/configs/zynq_zc706_defconfig index f333b7a2bfed..215f00dae9f9 100644 --- a/configs/zynq_zc706_defconfig +++ b/configs/zynq_zc706_defconfig @@ -13,6 +13,7 @@ CONFIG_CMD_GPIO=y # CONFIG_CMD_SETEXPR is not set CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_DM_SEQ_ALIAS=y +CONFIG_ZYNQ_SDHCI=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_BAR=y CONFIG_SPI_FLASH_SPANSION=y diff --git a/configs/zynq_zc770_xm010_defconfig b/configs/zynq_zc770_xm010_defconfig index ebfdeb098b5b..cec722f38b35 100644 --- a/configs/zynq_zc770_xm010_defconfig +++ b/configs/zynq_zc770_xm010_defconfig @@ -14,6 +14,7 @@ CONFIG_CMD_GPIO=y # CONFIG_CMD_SETEXPR is not set CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_DM_SEQ_ALIAS=y +CONFIG_ZYNQ_SDHCI=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_BAR=y CONFIG_SPI_FLASH_SPANSION=y diff --git a/configs/zynq_zed_defconfig b/configs/zynq_zed_defconfig index 58680127aa5d..4a2a2fc3ce45 100644 --- a/configs/zynq_zed_defconfig +++ b/configs/zynq_zed_defconfig @@ -13,6 +13,7 @@ CONFIG_CMD_GPIO=y # CONFIG_CMD_SETEXPR is not set CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_DM_SEQ_ALIAS=y +CONFIG_ZYNQ_SDHCI=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_BAR=y CONFIG_SPI_FLASH_SPANSION=y diff --git a/configs/zynq_zybo_defconfig b/configs/zynq_zybo_defconfig index ebaae49da1d4..7c23feca4239 100644 --- a/configs/zynq_zybo_defconfig +++ b/configs/zynq_zybo_defconfig @@ -13,6 +13,7 @@ CONFIG_CMD_GPIO=y # CONFIG_CMD_SETEXPR is not set CONFIG_NET_RANDOM_ETHADDR=y CONFIG_SPL_DM_SEQ_ALIAS=y +CONFIG_ZYNQ_SDHCI=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_SPANSION=y CONFIG_ZYNQ_GEM=y diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig index 9f4b766f7a47..9d3f7e908fb2 100644 --- a/drivers/mmc/Kconfig +++ b/drivers/mmc/Kconfig @@ -37,4 +37,10 @@ config PIC32_SDHCI help Support for Microchip PIC32 SDHCI controller. +config ZYNQ_SDHCI + bool "Arasan SDHCI controller support" + depends on DM_MMC && OF_CONTROL + help + Support for Arasan SDHCI host controller on Zynq/ZynqMP ARM SoCs platform + endmenu diff --git a/include/configs/xilinx_zynqmp.h b/include/configs/xilinx_zynqmp.h index 27ef74daf50f..bbc673c06887 100644 --- a/include/configs/xilinx_zynqmp.h +++ b/include/configs/xilinx_zynqmp.h @@ -89,18 +89,14 @@ # define CONFIG_CMD_SF #endif -#if defined(CONFIG_ZYNQ_SDHCI0) || defined(CONFIG_ZYNQ_SDHCI1) +#if defined(CONFIG_ZYNQ_SDHCI) # define CONFIG_MMC # define CONFIG_GENERIC_MMC # define CONFIG_SDHCI -# define CONFI
[U-Boot] [PATCH 4/4] ARM: zynq: Remove ZYNQ_BOOT_FREEBSD option
Remove CONFIG_ZYNQ_BOOT_FREEBSD configuration option and setup CONFIG_SYS_MMC_MAX_DEVICE 1 for all Zynq boards. Signed-off-by: Michal Simek --- include/configs/zynq-common.h | 4 +--- include/configs/zynq_picozed.h | 1 - include/configs/zynq_zc70x.h | 1 - include/configs/zynq_zed.h | 1 - include/configs/zynq_zybo.h| 1 - 5 files changed, 1 insertion(+), 7 deletions(-) diff --git a/include/configs/zynq-common.h b/include/configs/zynq-common.h index 1fa34163ef8b..6fcbff5c7e4e 100644 --- a/include/configs/zynq-common.h +++ b/include/configs/zynq-common.h @@ -287,9 +287,7 @@ #define CONFIG_SYS_BOOTM_LEN (60 * 1024 * 1024) /* Boot FreeBSD/vxWorks from an ELF image */ -#if defined(CONFIG_ZYNQ_BOOT_FREEBSD) -# define CONFIG_SYS_MMC_MAX_DEVICE 1 -#endif +#define CONFIG_SYS_MMC_MAX_DEVICE 1 #define CONFIG_SYS_LDSCRIPT "arch/arm/mach-zynq/u-boot.lds" diff --git a/include/configs/zynq_picozed.h b/include/configs/zynq_picozed.h index 1fc57e1e0fca..adc4d0f11e67 100644 --- a/include/configs/zynq_picozed.h +++ b/include/configs/zynq_picozed.h @@ -13,7 +13,6 @@ #define CONFIG_SYS_NO_FLASH #define CONFIG_ZYNQ_USB -#define CONFIG_ZYNQ_BOOT_FREEBSD #include diff --git a/include/configs/zynq_zc70x.h b/include/configs/zynq_zc70x.h index 2e7056ab1ff0..8a045900f62d 100644 --- a/include/configs/zynq_zc70x.h +++ b/include/configs/zynq_zc70x.h @@ -15,7 +15,6 @@ #define CONFIG_ZYNQ_USB #define CONFIG_ZYNQ_I2C0 #define CONFIG_ZYNQ_EEPROM -#define CONFIG_ZYNQ_BOOT_FREEBSD #include diff --git a/include/configs/zynq_zed.h b/include/configs/zynq_zed.h index 6f3915a0f86a..150cb4a0df97 100644 --- a/include/configs/zynq_zed.h +++ b/include/configs/zynq_zed.h @@ -13,7 +13,6 @@ #define CONFIG_SYS_NO_FLASH #define CONFIG_ZYNQ_USB -#define CONFIG_ZYNQ_BOOT_FREEBSD #include diff --git a/include/configs/zynq_zybo.h b/include/configs/zynq_zybo.h index 5287512d185c..eab05fd1a3b1 100644 --- a/include/configs/zynq_zybo.h +++ b/include/configs/zynq_zybo.h @@ -14,7 +14,6 @@ #define CONFIG_SYS_NO_FLASH #define CONFIG_ZYNQ_USB -#define CONFIG_ZYNQ_BOOT_FREEBSD /* Define ZYBO PS Clock Frequency to 50MHz */ #define CONFIG_ZYNQ_PS_CLK_FREQ5000UL -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 3/4] ARM: zynq: Read memory size setting from DT
OF_CONTROL is setup by default and memory reading is done via DT. Remove all config files with memory references. Signed-off-by: Michal Simek --- board/xilinx/zynq/board.c | 4 include/configs/zynq_microzed.h | 2 -- include/configs/zynq_picozed.h | 2 -- include/configs/zynq_zc70x.h| 2 -- include/configs/zynq_zc770.h| 2 -- include/configs/zynq_zed.h | 2 -- include/configs/zynq_zybo.h | 2 -- 7 files changed, 16 deletions(-) diff --git a/board/xilinx/zynq/board.c b/board/xilinx/zynq/board.c index 01bae5d67e3f..2f17e977a4b3 100644 --- a/board/xilinx/zynq/board.c +++ b/board/xilinx/zynq/board.c @@ -100,7 +100,6 @@ int checkboard(void) int dram_init(void) { -#if CONFIG_IS_ENABLED(OF_CONTROL) int node; fdt_addr_t addr; fdt_size_t size; @@ -118,9 +117,6 @@ int dram_init(void) return -1; } gd->ram_size = size; -#else - gd->ram_size = CONFIG_SYS_SDRAM_SIZE; -#endif zynq_ddrc_init(); return 0; diff --git a/include/configs/zynq_microzed.h b/include/configs/zynq_microzed.h index 7396ff9bd967..e66088da4f79 100644 --- a/include/configs/zynq_microzed.h +++ b/include/configs/zynq_microzed.h @@ -10,8 +10,6 @@ #ifndef __CONFIG_ZYNQ_MICROZED_H #define __CONFIG_ZYNQ_MICROZED_H -#define CONFIG_SYS_SDRAM_SIZE (1024 * 1024 * 1024) - #define CONFIG_SYS_NO_FLASH #include diff --git a/include/configs/zynq_picozed.h b/include/configs/zynq_picozed.h index 3d2bed25e5af..1fc57e1e0fca 100644 --- a/include/configs/zynq_picozed.h +++ b/include/configs/zynq_picozed.h @@ -10,8 +10,6 @@ #ifndef __CONFIG_ZYNQ_PICOZED_H #define __CONFIG_ZYNQ_PICOZED_H -#define CONFIG_SYS_SDRAM_SIZE (1024 * 1024 * 1024) - #define CONFIG_SYS_NO_FLASH #define CONFIG_ZYNQ_USB diff --git a/include/configs/zynq_zc70x.h b/include/configs/zynq_zc70x.h index a84688cff2c5..2e7056ab1ff0 100644 --- a/include/configs/zynq_zc70x.h +++ b/include/configs/zynq_zc70x.h @@ -10,8 +10,6 @@ #ifndef __CONFIG_ZYNQ_ZC70X_H #define __CONFIG_ZYNQ_ZC70X_H -#define CONFIG_SYS_SDRAM_SIZE (1024 * 1024 * 1024) - #define CONFIG_SYS_NO_FLASH #define CONFIG_ZYNQ_USB diff --git a/include/configs/zynq_zc770.h b/include/configs/zynq_zc770.h index 6121c099c297..35622ae34649 100644 --- a/include/configs/zynq_zc770.h +++ b/include/configs/zynq_zc770.h @@ -10,8 +10,6 @@ #ifndef __CONFIG_ZYNQ_ZC770_H #define __CONFIG_ZYNQ_ZC770_H -#define CONFIG_SYS_SDRAM_SIZE (1024 * 1024 * 1024) - #define CONFIG_SYS_NO_FLASH #if defined(CONFIG_ZC770_XM012) diff --git a/include/configs/zynq_zed.h b/include/configs/zynq_zed.h index 212053102b04..6f3915a0f86a 100644 --- a/include/configs/zynq_zed.h +++ b/include/configs/zynq_zed.h @@ -10,8 +10,6 @@ #ifndef __CONFIG_ZYNQ_ZED_H #define __CONFIG_ZYNQ_ZED_H -#define CONFIG_SYS_SDRAM_SIZE (512 * 1024 * 1024) - #define CONFIG_SYS_NO_FLASH #define CONFIG_ZYNQ_USB diff --git a/include/configs/zynq_zybo.h b/include/configs/zynq_zybo.h index 28d8f93f408d..5287512d185c 100644 --- a/include/configs/zynq_zybo.h +++ b/include/configs/zynq_zybo.h @@ -11,8 +11,6 @@ #ifndef __CONFIG_ZYNQ_ZYBO_H #define __CONFIG_ZYNQ_ZYBO_H -#define CONFIG_SYS_SDRAM_SIZE (512 * 1024 * 1024) - #define CONFIG_SYS_NO_FLASH #define CONFIG_ZYNQ_USB -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 1/4] zynq: zc770: Remove unused ifdefs for xm011 and xm013
Clean config file. Signed-off-by: Michal Simek --- include/configs/zynq_zc770.h | 4 1 file changed, 4 deletions(-) diff --git a/include/configs/zynq_zc770.h b/include/configs/zynq_zc770.h index 32ea1f37d6a4..f49715b6cfff 100644 --- a/include/configs/zynq_zc770.h +++ b/include/configs/zynq_zc770.h @@ -17,13 +17,9 @@ #if defined(CONFIG_ZC770_XM010) # define CONFIG_ZYNQ_SDHCI0 -#elif defined(CONFIG_ZC770_XM011) - #elif defined(CONFIG_ZC770_XM012) # undef CONFIG_SYS_NO_FLASH -#elif defined(CONFIG_ZC770_XM013) - #endif #include -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PULL] Please pull u-boot-imx
Hi Tom, please pull from u-boot-imx, thanks ! The following changes since commit 44189a032804c4a16632f4e80abf77f2820e9a48: Prepare v2016.03-rc1 (2016-02-02 11:29:50 -0500) are available in the git repository at: git://www.denx.de/git/u-boot-imx.git master for you to fetch changes up to fb0d042814e6ea3463ee335523222f91d891d084: imx: mx6: implement board_mmc_get_env_dev (2016-02-04 10:13:53 +0100) Bhuvanchandra DV (9): arm: vybrid: Enable lpuart support arm: vybrid: Update the license string arm: colibri-vf: Enable serial support arm: vf610-twr: Add device tree file's arm: pcm052: Add device tree file's arm: vybrid: Update defconfig's arm: vybrid: Drop enabling GPIO, SPI and UART in legacy mode dm: lpuart: Drop the legacy code dm: vybrid_gpio: Drop legacy code Bin Meng (1): tools: mxsboot: Use more portable cpu_to_le32() Fabio Estevam (3): mx6slevk: Fix the reset delay for the the LAN8720 PHY tqma6_wru4: Fix the reset delay for the the LAN8720 PHY mx6slevk: Remove CONFIG_ETHPRIME option Marek Vasut (2): arm: imx6: Add DDR3 calibration code for MX6 Q/D/DL arm: imx6: Enable DDR calibration on Novena Peng Fan (3): imx: mx7dsabresd: move mmc_get_env_devno to soc code imx: mx6: implement mmc_get_env_dev imx: mx6: implement board_mmc_get_env_dev Peter Robinson (1): wandboard: fix variable name so PXE boot works Ye Li (6): mx6: soc: Add ENET2 mac address support imx: mx6sxsabreauto: Add support for mx6sx SABREAUTO board imx: MX6DQ{P}/DL:SABRESD Fix bmode eMMC failure imx: mx6sx: Fix issue in LCDIF clock enablement imx: mx6ul/sx: Fix issue in LCDIF clock dividers calculation imx: mx6sxsabresd: Add MCIMX28LCD display support arch/arm/cpu/armv7/mx6/Kconfig | 6 + arch/arm/cpu/armv7/mx6/clock.c | 8 +- arch/arm/cpu/armv7/mx6/ddr.c| 559 arch/arm/cpu/armv7/mx6/soc.c| 64 ++- arch/arm/cpu/armv7/mx7/soc.c| 21 + arch/arm/dts/Makefile | 4 +- arch/arm/dts/pcm052.dts | 22 + arch/arm/dts/vf-colibri.dtsi| 15 +- arch/arm/dts/vf.dtsi| 48 +- arch/arm/dts/vf500-colibri.dts | 5 - arch/arm/dts/vf610-colibri.dts | 5 - arch/arm/dts/vf610-twr.dts | 22 + arch/arm/include/asm/arch-mx6/imx-regs.h| 23 +- arch/arm/include/asm/arch-mx6/mx6-ddr.h | 5 + board/freescale/mx6qarm2/mx6qarm2.c | 5 + board/freescale/mx6sabresd/mx6sabresd.c | 7 +- board/freescale/mx6slevk/mx6slevk.c | 7 +- board/freescale/mx6sxsabreauto/Kconfig | 12 + board/freescale/mx6sxsabreauto/MAINTAINERS | 6 + board/freescale/mx6sxsabreauto/Makefile | 6 + board/freescale/mx6sxsabreauto/imximage.cfg | 136 ++ board/freescale/mx6sxsabreauto/mx6sxsabreauto.c | 508 + board/freescale/mx6sxsabresd/mx6sxsabresd.c | 66 +++ board/freescale/mx7dsabresd/mx7dsabresd.c | 20 +- board/kosagi/novena/novena_spl.c| 23 +- board/tqc/tqma6/tqma6_wru4.c| 2 +- configs/colibri_vf_defconfig| 8 + configs/colibri_vf_dtb_defconfig| 14 - configs/mx6sxsabreauto_defconfig| 11 + configs/pcm052_defconfig| 7 + configs/vf610twr_defconfig | 7 + configs/vf610twr_nand_defconfig | 7 + doc/README.imx6 | 5 +- drivers/gpio/vybrid_gpio.c | 18 - drivers/serial/serial_lpuart.c | 101 + include/configs/colibri_vf.h| 13 - include/configs/mx6slevk.h | 1 - include/configs/mx6sxsabreauto.h| 212 + include/configs/mx6sxsabresd.h | 20 + include/configs/pcm052.h| 3 - include/configs/vf610twr.h | 3 - include/configs/wandboard.h | 2 +- tools/mxsboot.c | 18 +- 43 files changed, 1810 insertions(+), 245 deletions(-) create mode 100644 arch/arm/dts/pcm052.dts create mode 100644 arch/arm/dts/vf610-twr.dts create mode 100644 board/freescale/mx6sxsabreauto/Kconfig create mode 100644 board/freescale/mx6sxsabreauto/MAINTAINERS create mode 100644 board/freescale/mx6sxsabreauto/Makefile create mode 100644 board/freescale/mx6sxsabreauto/imximage.cfg create mode 100644 board/freescale/mx6sxsabreauto/mx6sxsabreauto.c delete mode 100644 configs/colibri_vf_dtb_defconfig create mode 100644 configs/mx6sxsabreauto_defconfig create mode 100644 inclu
Re: [U-Boot] .travis.yml: rework according to new travis-ci infra
Hi Warren > -Original Message- > From: Stephen Warren [mailto:swar...@wwwdotorg.org] > Sent: Mittwoch, 3. Februar 2016 17:58 > To: Roger Meier > Cc: Tom Rini ; Tom Rini ; u- > b...@lists.denx.de; Andreas Färber ; Meier, Roger > ; Daniel Schwierzeck > Subject: Re: [U-Boot] .travis.yml: rework according to new travis-ci infra > > On 02/01/2016 06:57 PM, Tom Rini wrote: > > On Mon, Jan 25, 2016 at 08:22:41PM +0100, Roger Meier wrote: > > > >> - install using addons.apt > >> - remove MAKEALL > >> - split mpc85xx boards > >> - remove TEST_CONFIG_CMD, just info > >> - fetch mips toolchain via buildman > >> - remove --list-error-boards param > >> - conditional script > >> - use TOOLCHAIN instead of INSTALL_TOOLCHAIN > >> - add aarch64 > >> - enable notifications via email > >> > >> Signed-off-by: Roger Meier > >> Cc: Wolfgang Denk > >> Cc: Heiko Schocher > >> Cc: Tom Rini > >> Cc: Daniel Schwierzeck > >> Cc: Andreas Färber > >> Tested-by: Daniel Schwierzeck > >> Acked-by: Heiko Schocher > > > > Applied to u-boot/master, thanks! > > I wanted to add something to this file, so I set up my own travis-ci.org > account and made it run against my own github U-Boot repo "fork" to test > my change. However, most of the builds failed before I even modified > .travis.yml. For example: > > > $ if [[ "${TOOLCHAIN}" == *arm* ]]; then sh eldk-eglibc-i686-arm-toolchain- > gmae-5.4.sh -y ; fi > > Enter target directory for SDK (default: /opt/eldk-5.4/armv5te): /opt/eldk- > 5.4/armv5te > > You are about to install the SDK to "/opt/eldk-5.4/armv5te". Proceed[Y/n]?Y > > Sorry, you are not allowed to execute as root. Things like this should work, but there are some limitations. Ok, you added sudo:true within your branch. It's unclear to me why it does not work on your build... Here it works: https://travis-ci.org/u-boot/u-boot/jobs/106517001 > > Do I need to perform some manual configuration of my > repo/branch/profile/... before this .travis.yml will work correctly > (container vs VM I wonder?), or perhaps obtain some kind of > authorization from the Travis CI admins? If so, if that could all be > documented in a comment at the top of .travis.yml that would be > extremely helpful. Bonus points if it can be handled simply be adding > extra configuration options into .travis.yml so that it "just works" > without manual steps. No, there is nothing to do beside of setting up the hook. I'm unsure about replication of documentation within .travis.yml Regards Roger ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] ARM: zynq: Remove unused SPI base addresses
On 4 February 2016 at 14:37, Michal Simek wrote: > Remove unused macros. Adresses are taken from DT. > > Signed-off-by: Michal Simek Reviewed-by: Jagan Teki -- Jagan. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] imx: Refactoring CAAM Job Ring structure and Secure Memory for imx7
On 02/02/2016 11:39, Ulises Cardenas wrote: > Refactored data structure for CAAM's job ring and Secure Memory > to support i.MX7. > > The new memory map use macros to resolve SM's offset by version. > This will solve the versioning issue caused by the new version of > secure memory of i.MX7 > > Signed-off-by: Ulises Cardenas > --- > > arch/arm/include/asm/arch-mx7/imx-regs.h | 3 ++ > drivers/crypto/fsl/jobdesc.c | 30 +-- > include/fsl_sec.h| 49 > +++- > 3 files changed, 59 insertions(+), 23 deletions(-) > > diff --git a/arch/arm/include/asm/arch-mx7/imx-regs.h > b/arch/arm/include/asm/arch-mx7/imx-regs.h > index 58a25c7..105043a 100644 > --- a/arch/arm/include/asm/arch-mx7/imx-regs.h > +++ b/arch/arm/include/asm/arch-mx7/imx-regs.h > @@ -216,6 +216,9 @@ > #define FEC_QUIRK_ENET_MAC > #define SNVS_LPGPR 0x68 > > +#define CONFIG_SYS_FSL_SEC_ADDR (CAAM_IPS_BASE_ADDR) > +#define CONFIG_SYS_FSL_JR0_ADDR (CONFIG_SYS_FSL_SEC_ADDR + 0x1000) > + > #if !(defined(__KERNEL_STRICT_NAMES) || defined(__ASSEMBLY__)) > #include > #include > diff --git a/drivers/crypto/fsl/jobdesc.c b/drivers/crypto/fsl/jobdesc.c > index 5695bef..fd0c4f7 100644 > --- a/drivers/crypto/fsl/jobdesc.c > +++ b/drivers/crypto/fsl/jobdesc.c > @@ -14,7 +14,7 @@ > #include "jobdesc.h" > #include "rsa_caam.h" > > -#ifdef CONFIG_MX6 > +#if defined(CONFIG_MX6) || defined(CONFIG_MX7) > /*! > * Secure memory run command > * > @@ -25,10 +25,14 @@ uint32_t secmem_set_cmd(uint32_t sec_mem_cmd) > { > uint32_t temp_reg; > > - sec_out32(CAAM_SMCJR0, sec_mem_cmd); > + ccsr_sec_t *sec = (void *)CONFIG_SYS_FSL_SEC_ADDR; > + uint32_t sm_vid = SM_VERSION(sec_in32(&sec->smvid)); > + uint32_t jr_id = 0; > + > + sec_out32(CAAM_SMCJR(sm_vid, jr_id), sec_mem_cmd); > > do { > - temp_reg = sec_in32(CAAM_SMCSJR0); > + temp_reg = sec_in32(CAAM_SMCSJR(sm_vid, jr_id)); > } while (temp_reg & CMD_COMPLETE); > > return temp_reg; > @@ -51,6 +55,10 @@ int caam_page_alloc(uint8_t page_num, uint8_t > partition_num) > { > uint32_t temp_reg; > > + ccsr_sec_t *sec = (void *)CONFIG_SYS_FSL_SEC_ADDR; > + uint32_t sm_vid = SM_VERSION(sec_in32(&sec->smvid)); > + uint32_t jr_id = 0; > + > /* >* De-Allocate partition_num if already allocated to ARM core >*/ > @@ -64,9 +72,9 @@ int caam_page_alloc(uint8_t page_num, uint8_t partition_num) > } > > /* set the access rights to allow full access */ > - sec_out32(CAAM_SMAG1JR0(partition_num), 0xF); > - sec_out32(CAAM_SMAG2JR0(partition_num), 0xF); > - sec_out32(CAAM_SMAPJR0(partition_num), 0xFF); > + sec_out32(CAAM_SMAG1JR(sm_vid, jr_id, partition_num), 0xF); > + sec_out32(CAAM_SMAG2JR(sm_vid, jr_id, partition_num), 0xF); > + sec_out32(CAAM_SMAPJR(sm_vid, jr_id, partition_num), 0xFF); > > /* Now need to allocate partition_num of secure RAM. */ > /* De-Allocate page_num by starting with a page inquiry command */ > @@ -105,6 +113,10 @@ int caam_page_alloc(uint8_t page_num, uint8_t > partition_num) > int inline_cnstr_jobdesc_blob_dek(uint32_t *desc, const uint8_t *plain_txt, > uint8_t *dek_blob, uint32_t in_sz) > { > + ccsr_sec_t *sec = (void *)CONFIG_SYS_FSL_SEC_ADDR; > + uint32_t sm_vid = SM_VERSION(sec_in32(&sec->smvid)); > + uint32_t jr_id = 0; > + > uint32_t ret = 0; > u32 aad_w1, aad_w2; > /* output blob will have 32 bytes key blob in beginning and > @@ -133,9 +145,9 @@ int inline_cnstr_jobdesc_blob_dek(uint32_t *desc, const > uint8_t *plain_txt, > flush_dcache_range(start, end); > > /* Now configure the access rights of the partition */ > - sec_out32(CAAM_SMAG1JR0(PARTITION_1), KS_G1); /* set group 1 */ > - sec_out32(CAAM_SMAG2JR0(PARTITION_1), 0); /* clear group 2 */ > - sec_out32(CAAM_SMAPJR0(PARTITION_1), PERM); /* set perm & locks */ > + sec_out32(CAAM_SMAG1JR(sm_vid, jr_id, PARTITION_1), KS_G1); > + sec_out32(CAAM_SMAG2JR(sm_vid, jr_id, PARTITION_1), 0); > + sec_out32(CAAM_SMAPJR(sm_vid, jr_id, PARTITION_1), PERM); > > /* construct aad for AES */ > aad_w1 = (in_sz << OP_ALG_ALGSEL_SHIFT) | KEY_AES_SRC | LD_CCM_MODE; > diff --git a/include/fsl_sec.h b/include/fsl_sec.h > index 2ddced3..a52110a 100644 > --- a/include/fsl_sec.h > +++ b/include/fsl_sec.h > @@ -97,19 +97,20 @@ typedef struct ccsr_sec { > u32 drr;/* DECO Reset Register */ > u8 res5[0x4d8]; > struct rng4tst rng; /* RNG Registers */ > - u8 res11[0x8a0]; > + u8 res6[0x8a0]; > u32 crnr_ms;/* CHA Revision Number Register, MS */ > u32 crnr_ls;/* CHA Revision Number Register, LS */ > u32 ctpr_ms;/* Compile Time Parameters Register, MS */ > u32
Re: [U-Boot] [PATCH V2 2/4] common: env_mmc: support loading env from different cards
Hi Peng, On 03/02/2016 02:01, Peng Fan wrote: > Hi Stefano, > > On Tue, Feb 02, 2016 at 08:46:09PM +0100, Stefano Babic wrote: >> Hi Peng, >> >> On 17/12/2015 05:43, Peng Fan wrote: >>> Some boards support booting from different SD card slots. >>> For example, mx6dpsabresd board supports booting from SD2, >>> SD3, EMMC4, using different boot switch. And the index >>> numbers are SD2(0), SD3(1), EMMC4(2). >>> But CONFIG_SYS_MMC_ENV_DEV is hardcoded to 1(for SD3), so when >>> booting from SD2(using 0), uboot complains "MMC: no card present", >>> since there is no card in SD3 slot. >>> >>> This patch introduces a weak function which still returns >>> CONFIG_SYS_MMC_ENV_DEV to avoid break other boards. Then >>> different boards can implement mmc_get_env_devno to read >>> env from the correct sd/emmc. >>> >>> Signed-off-by: Peng Fan >>> Cc: Stefano Babic >>> Cc: Simon Glass >>> Cc: Tim Harvey >>> Cc: Hans de Goede >>> --- >>> >> >> Tom sets this patch as deferred - then applying the rest of the series >> makes no sense. Patchset should be rechecked later after next release. > > Could you please check these three patches. I may missed to use V3, but still > used V2. > The three patches are new for the env no. > > https://patchwork.ozlabs.org/patch/574586/ > https://patchwork.ozlabs.org/patch/574587/ > https://patchwork.ozlabs.org/patch/574588/ > I have not tested, but they looks fine - I am picking them up before my PR. Best regards, Stefano Babic -- = DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sba...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] ARM: zynq: Remove unused SPI base addresses
Remove unused macros. Adresses are taken from DT. Signed-off-by: Michal Simek --- arch/arm/include/asm/arch-zynqmp/hardware.h | 3 --- arch/arm/mach-zynq/include/mach/hardware.h | 2 -- 2 files changed, 5 deletions(-) diff --git a/arch/arm/include/asm/arch-zynqmp/hardware.h b/arch/arm/include/asm/arch-zynqmp/hardware.h index 587938249e8f..1ab301f0d21f 100644 --- a/arch/arm/include/asm/arch-zynqmp/hardware.h +++ b/arch/arm/include/asm/arch-zynqmp/hardware.h @@ -13,9 +13,6 @@ #define ZYNQ_GEM_BASEADDR2 0xFF0D #define ZYNQ_GEM_BASEADDR3 0xFF0E -#define ZYNQ_SPI_BASEADDR0 0xFF04 -#define ZYNQ_SPI_BASEADDR1 0xFF05 - #define ZYNQ_I2C_BASEADDR0 0xFF02 #define ZYNQ_I2C_BASEADDR1 0xFF03 diff --git a/arch/arm/mach-zynq/include/mach/hardware.h b/arch/arm/mach-zynq/include/mach/hardware.h index 830e1fea1809..79347a83eaff 100644 --- a/arch/arm/mach-zynq/include/mach/hardware.h +++ b/arch/arm/mach-zynq/include/mach/hardware.h @@ -14,8 +14,6 @@ #define ZYNQ_GEM_BASEADDR1 0xE000C000 #define ZYNQ_I2C_BASEADDR0 0xE0004000 #define ZYNQ_I2C_BASEADDR1 0xE0005000 -#define ZYNQ_SPI_BASEADDR0 0xE0006000 -#define ZYNQ_SPI_BASEADDR1 0xE0007000 #define ZYNQ_QSPI_BASEADDR 0xE000D000 #define ZYNQ_SMC_BASEADDR 0xE000E000 #define ZYNQ_NAND_BASEADDR 0xE100 -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] .travis.yml: explicitly request sudo
Hello Stephen, Am 03.02.2016 um 18:41 schrieb Stephen Warren: From: Stephen Warren Without this, builds default to using new Travis CI infra-structure which does no allow sudo. The builds need sudo in order to install the ELDK compilers. Consequently, almost all builds fail without this. I suspect that existing Travis CI users have not noticed this because their accounts or builds have been grand-fathered into backwards- compatible default settings, whereas I just set up a new build from scratch and received new default settings. Cc: Wolfgang Denk Cc: Heiko Schocher Cc: Tom Rini Cc: Daniel Schwierzeck Cc: Andreas Färber Signed-off-by: Stephen Warren --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) Did you tried it with current ML? Or at last with the patch from Roger? http://lists.denx.de/pipermail/u-boot/2016-January/243115.html [U-Boot] [PATCH] .travis.yml: rework according to new travis-ci infra If I look into: https://travis-ci.org/u-boot/u-boot There are only mips and m68k for which the build fail ... bye, Heiko diff --git a/.travis.yml b/.travis.yml index 67674e2f5878..8caaeb34553e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,6 +3,8 @@ # build U-Boot on Travis CI - https://travis-ci.org/ +sudo: true + language: c addons: -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] Issue with USB mass storage (thumb drives)
On 03.02.2016 20:16, Sergei Temerkhanov wrote: > On Wed, Feb 3, 2016 at 8:40 AM, Marek Vasut wrote: >> On Wednesday, February 03, 2016 at 12:49:20 PM, Schrempf Frieder wrote: >>> On 03.02.2016 12:12, Marek Vasut wrote: On Wednesday, February 03, 2016 at 11:15:00 AM, Schrempf Frieder wrote: > On 03.02.2016 10:55, Fabio Estevam wrote: >> On Wed, Feb 3, 2016 at 7:40 AM, Marek Vasut wrote: >>> In that case, debug time. >>> >>> Usual problems are bad routing of the tracks on the board , so try >>> with USB 1.1 hub and if that works, that's your problem. >> Another suggestion would be to try the 100MB transfer in Linux and see >> if this works or not. >> >> That would help us to narrow down whether this is a hardware or >> software problem. > Another thing to try may be limiting the value of USB_MAX_XFER_BLK in > common/usb_storage.c This was a really helpful hint! Thank you Sergei! I just tried to limit USB_MAX_XFER_BLK to 1/8 of the original value (65535 -> 8191) and this time the transfer works without timeouts. As we have a customer who needs this working as soon as possible my question now is how to properly solve this. Should I generally limit USB_MAX_XFER_BLK in my u-boot to avoid these errors? Which value to choose? ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] Issue with USB mass storage (thumb drives)
On 03.02.2016 17:40, Marek Vasut wrote: > On Wednesday, February 03, 2016 at 12:49:20 PM, Schrempf Frieder wrote: >> On 03.02.2016 12:12, Marek Vasut wrote: >>> On Wednesday, February 03, 2016 at 11:15:00 AM, Schrempf Frieder wrote: On 03.02.2016 10:55, Fabio Estevam wrote: > On Wed, Feb 3, 2016 at 7:40 AM, Marek Vasut wrote: >> In that case, debug time. >> >> Usual problems are bad routing of the tracks on the board , so try >> with USB 1.1 hub and if that works, that's your problem. > Another suggestion would be to try the 100MB transfer in Linux and see > if this works or not. > > That would help us to narrow down whether this is a hardware or > software problem. Thank you Marek and Fabio for your input! I tried the file transfer in Linux and this seems to work fine. Also we have been using this hardware for quite some time, also with USB mass storage and large files in Linux and I can't remember any problems. For these reasons I think that the hardware is ok. I added the DEBUG defines and here are the lines around one of the timeouts. With my very limited knowledge of how usb works, I can't read much from those messages: >>> It'd help if you shared your patch and the whole output. That way we can >>> check if something goes wrong at the beginning. >>> >>> I wonder if we might be facing some misconfiguration of the USB PHY here >>> ? >>> >>> I don't have a MX6Solo . Fabio, any chance you can try ? >> Here is the debug log for "usb reset": http://paste.ubuntu.com/14865306/ >> And here the log for the file transfer (different thumb drive and >> therefore different messages than posted before): >> http://paste.ubuntu.com/14865349/ >> >> The only changes to U-Boot I made is adding my board configuration >> (derived from Freescale SabreSD config). >> The only difference from the SabreSD config related to USB is, that I >> have set CONFIG_USB_MAX_CONTROLLER_COUNT to 2 instead of 1. > The detection seems fine, it even does what it's supposed to do. > > You have a USB hub somewhere in there, right ? Is it a powered one or not ? > > What I find weird in the later log is that the failure always happens when > the buffer is at 0x19fffe00 . I suppose you're loading to 0x1800 and you > have 0x2000 or 512MiB of RAM (?). Try loading to 0x800 and see if > that helps. If it does, then you might be overwriting some malloc area of > U-Boot or somesuch . We have two self-powered USB hubs on our board, but we also have boards without any hub and I can see the same issue on those. I tried loading to 0x800 and the strange thing is, that it even fails on those USB devices, that were previously working while loading to 0x1800. So reading fails on all USB devices I tried, when loading to 0x800 with a log like this: http://paste.ubuntu.com/14875686/ But when I load to 0x1800 I have 2 devices with 100% success rate: http://paste.ubuntu.com/14875795/ And 1 device with 100% failure rate: http://paste.ubuntu.com/14865349/ I even have 1GiB of RAM on this board. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] armv8: ls2080: Update SerDes2 table for 0x45 & 0x47 protocol
LANE A of SerDes 2 Protocol 0x45 & 0x47 are SGMII9 and PCIE3 respectively. So Update SerDes2 table for 0x45 & 0x47 protocol. Signed-off-by: Prabhakar Kushwaha Signed-off-by: Pratiyush Mohan Srivastava --- arch/arm/cpu/armv8/fsl-layerscape/ls2080a_serdes.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/cpu/armv8/fsl-layerscape/ls2080a_serdes.c b/arch/arm/cpu/armv8/fsl-layerscape/ls2080a_serdes.c index ea3114c..cc4b79b 100644 --- a/arch/arm/cpu/armv8/fsl-layerscape/ls2080a_serdes.c +++ b/arch/arm/cpu/armv8/fsl-layerscape/ls2080a_serdes.c @@ -56,9 +56,9 @@ static struct serdes_config serdes2_cfg_tbl[] = { {0x42, {PCIE3, PCIE3, PCIE3, PCIE3, PCIE4, PCIE4, SATA1, SATA2 } }, {0x43, {PCIE3, PCIE3, PCIE3, PCIE3, NONE, NONE, SATA1, SATA2 } }, {0x44, {PCIE3, PCIE3, PCIE3, PCIE3, NONE, NONE, SATA1, SATA2 } }, - {0x45, {PCIE3, SGMII10, SGMII11, SGMII12, PCIE4, SGMII14, SGMII15, + {0x45, {SGMII9, SGMII10, SGMII11, SGMII12, PCIE4, SGMII14, SGMII15, SGMII16 } }, - {0x47, {SGMII9, SGMII10, SGMII11, SGMII12, PCIE4, PCIE4, PCIE4, + {0x47, {PCIE3, SGMII10, SGMII11, SGMII12, PCIE4, PCIE4, PCIE4, PCIE4 } }, {0x49, {SGMII9, SGMII10, SGMII11, SGMII12, PCIE4, PCIE4, SATA1, SATA2 } }, -- 1.9.1 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH ] board: ls2080a: Add "mcinitcmd" env for MC & DPL deployment
-Original Message- From: york sun Sent: Wednesday, January 20, 2016 9:32 PM To: Pratiyush Mohan Srivastava ; u-boot@lists.denx.de Cc: Prabhakar Kushwaha ; Pratiyush Srivastava Subject: Re: [PATCH ] board: ls2080a: Add "mcinitcmd" env for MC & DPL deployment On 01/19/2016 10:59 PM, Pratiyush Mohan Srivastava wrote: > From: Pratiyush Mohan Srivastava > > Environment variable mcinitcmd is defined to initiate MC and DPL > deployment from the location where it is stored(NOR, NAND, SD, SATA, > USB)during u-boot booting.If this variable is not defined then macro > MC_BOOT_ENV_VAR will be null and MC will not be booted and DPL will not be > applied during U-boot booting. > > Signed-off-by: Pratiyush Mohan Srivastava > > Signed-off-by: Prabhakar Kushwaha > --- > arch/arm/cpu/armv8/fsl-layerscape/README.lsch3 | 29 > ++ > board/freescale/ls2080aqds/eth.c | 5 + > board/freescale/ls2080ardb/eth_ls2080rdb.c | 5 + > 3 files changed, 39 insertions(+) > > diff --git a/board/freescale/ls2080aqds/eth.c > b/board/freescale/ls2080aqds/eth.c > index 5b9c2d1..db9de77 100644 > --- a/board/freescale/ls2080aqds/eth.c > +++ b/board/freescale/ls2080aqds/eth.c > @@ -20,6 +20,7 @@ > > #include "ls2080aqds_qixis.h" > > +#define MC_BOOT_ENV_VAR "mcinitcmd" > > #ifdef CONFIG_FSL_MC_ENET > /* - In LS2080A there are only 16 SERDES lanes, spread across 2 SERDES > banks. > @@ -714,6 +715,7 @@ void ls2080a_handle_phy_interface_xsgmii(int i) > int board_eth_init(bd_t *bis) { > int error; > + char *mc_boot_env_var; > #ifdef CONFIG_FSL_MC_ENET > struct ccsr_gur __iomem *gur = (void *)CONFIG_SYS_FSL_GUTS_ADDR; > int serdes1_prtcl = (in_le32(&gur->rcwsr[28]) & @@ -781,6 +783,9 @@ > int board_eth_init(bd_t *bis) > } > } > > + mc_boot_env_var = getenv(MC_BOOT_ENV_VAR); > + if (mc_boot_env_var) > + run_command_list(mc_boot_env_var, -1, 0); > error = cpu_eth_init(bis); Why not put the code into cpu_eth_init()? Ans: While deciding on the location of the command "run_command_list" I could not find any prior usage in arch/arm folder. Hence I decided that the run_command_list command be kept just before calling cpu_eth_init inside board folder. York ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] imx: imx7 Support for Manufacturing Protection
i.MX7 has an a protection feature for Manufacturing process. This feature uses assymetric encryption to sign and verify authenticated software handled between parties. This command is enables the use of such feature. The private key is unique and generated once per device. And it is stored in secure memory and only accessible by CAAM. Therefore, the public key generation and signature functions are the only functions available for the user. Command usage: mfgprot 0 - prints out the public key for the device. mfgprot 1 - signs and prints out a sample data. This is only a working example for the signature function, and is intended to be used as a canvas for user-specific cases. Signed-off-by: Ulises Cardenas --- arch/arm/imx-common/Makefile | 1 + arch/arm/imx-common/cmd_mfgprot.c | 91 drivers/crypto/fsl/Makefile | 4 + drivers/crypto/fsl/fsl_mfgprot.c | 286 ++ include/fsl_sec.h | 12 ++ 5 files changed, 394 insertions(+) create mode 100644 arch/arm/imx-common/cmd_mfgprot.c create mode 100644 drivers/crypto/fsl/fsl_mfgprot.c diff --git a/arch/arm/imx-common/Makefile b/arch/arm/imx-common/Makefile index e7190c3..8563150 100644 --- a/arch/arm/imx-common/Makefile +++ b/arch/arm/imx-common/Makefile @@ -22,6 +22,7 @@ ifeq ($(SOC),$(filter $(SOC),mx7)) obj-y += cpu.o obj-$(CONFIG_SYS_I2C_MXC) += i2c-mxv7.o obj-$(CONFIG_SYSCOUNTER_TIMER) += syscounter.o +obj-$(CONFIG_CMD_MFGPROT) += cmd_mfgprot.o endif ifeq ($(SOC),$(filter $(SOC),mx6 mx7)) obj-y += cache.o init.o diff --git a/arch/arm/imx-common/cmd_mfgprot.c b/arch/arm/imx-common/cmd_mfgprot.c new file mode 100644 index 000..88f2b12 --- /dev/null +++ b/arch/arm/imx-common/cmd_mfgprot.c @@ -0,0 +1,91 @@ +/* + * Copyright 2016 NXP Semiconductors. + * + * SPDX-License-Identifier: GPL-2.0+ + * + * Command for manufacturing protection + */ + +#include +#include +#include +#include +#include +#include +#include +#include + +DECLARE_GLOBAL_DATA_PTR; + +/** +* generate_mppubk() - Generates a Public for Manufacturing Protection +* +* Returns zero on success,and negative on error. +*/ +static int genenerate_mppubk(void) +{ + int ret = 0; + + ret = gen_mppubk(); + + return ret; +} + +/** +* generate_mpsign() - Example of Signature command for Manufacturing Protection +* +* Returns zero on success,and negative on error. +*/ +static int generate_mpsign(void) +{ + int ret = 0; + + ret = sign_mppubk(); + + return ret; +} + +/** + * do_mfgprot() - Handle the "mfgprogt" command-line command + * @cmdtp: Command data struct pointer + * @flag: Command flag + * @argc: Command-line argument count + * @argv: Array of command-line arguments + * + * Returns zero on success, CMD_RET_USAGE in case of misuse and negative + * on error. + */ +static int do_mfgprot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) +{ + uint32_t sel; + int ret = 0; + + u32 jr_size = 4; + u32 out_jr_size = sec_in32(CONFIG_SYS_FSL_JR0_ADDR + 0x102c); + if (out_jr_size != jr_size) { + hab_caam_clock_enable(1); + sec_init(); + } + + sel = simple_strtoul(argv[1], NULL, 10); + switch (sel) { + case 0: + ret = genenerate_mppubk(); + break; + case 1: + ret = generate_mpsign(); + break; + } + return ret; +} + +/***/ +static char mfgprot_help_text[] = + "mp 0: prints out the public key for MP\n" + "mp 1: prints out an exmple signature for MP\n"; + +U_BOOT_CMD( + mfgprot, 2, 1, do_mfgprot, + "Manufacturing Protection\n", + mfgprot_help_text +); diff --git a/drivers/crypto/fsl/Makefile b/drivers/crypto/fsl/Makefile index fd736cf..6d6903b 100644 --- a/drivers/crypto/fsl/Makefile +++ b/drivers/crypto/fsl/Makefile @@ -8,3 +8,7 @@ obj-y += sec.o obj-$(CONFIG_FSL_CAAM) += jr.o fsl_hash.o jobdesc.o error.o obj-$(CONFIG_CMD_BLOB)$(CONFIG_CMD_DEKBLOB) += fsl_blob.o obj-$(CONFIG_RSA_FREESCALE_EXP) += fsl_rsa.o + +ifdef CONFIG_MX7 +obj-$(CONFIG_CMD_MFGPROT) += fsl_mfgprot.o +endif diff --git a/drivers/crypto/fsl/fsl_mfgprot.c b/drivers/crypto/fsl/fsl_mfgprot.c new file mode 100644 index 000..967dbc4 --- /dev/null +++ b/drivers/crypto/fsl/fsl_mfgprot.c @@ -0,0 +1,286 @@ +/* + * Copyright 2014 Freescale Semiconductor, Inc. + * + * SPDX-License-Identifier:GPL-2.0+ + * + */ + +#include +#include +#include +#include +#include +#include "jobdesc.h" +#include "desc.h" +#include "jr.h" + + +/** Job Descriptor Header command - add length in words */ +#define HAB_ENG_CAAM_CMD_JOBHDR0xB080UL +#define HAB_ENG_CAAM_CMD_JOBHDR_START_SHIFT16 /**< START INDEX field */ +#define HAB_ENG_CAAM_CMD_JOBHDR_START_WIDTH6 /**< START INDEX field */ + +#define HAB_MASK(LBL) \ + uint32_t)1 << (LBL##_WID