summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-11-27sandbox: Fix warnings in cpu.c and os.cSimon Glass
This fixes the following two problems: cppcheck reports: [arch/sandbox/cpu/start.c:132]: (error) Uninitialized variable: err [arch/sandbox/cpu/os.c:371]: (error) Memory leak: fname Signed-off-by: Simon Glass <sjg@chromium.org> Reported-by: Wolfgang Denk <wd@denx.de>
2014-11-27sandbox: Fix warnings due to 64-bit printf() stringsSimon Glass
Now that we have inttypes.h, use it in a few more places to avoid compiler warnings on sandbox when building on 64-bit machines. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-27mtd/nand/vf610_nfc: Disable subpage writesSanchayan Maity
This patch disables subpage writes for vf610_nfc nand driver. This is required, as without this fix, writing unaligned u-boot images with DFU results in a hang. Trying to write unalgined binary images also results in a hang, without disabling subpage writes. Patch has been tested on a Colibri VF61 module. Signed-off-by: Sanchayan Maity <maitysanchayan@gmail.com>
2014-11-27mtd: denali: set some registers after nand_scan_ident()Masahiro Yamada
Some but not all of implementations of the Denali NAND controller have hardware circuits to detect the device parameters such as page_size, erase_size, etc. Even on those SoCs with such hardware supported, the hardware is known to detect wrong parameters for some nasty (almost buggy) NAND devices. The device parameters detected during nand_scan_ident() are more trustworthy. This commit sets some hardware registers to mtd->pagesize, mtd->oobsize, etc. in the code between nand_scan_ident() and nand_scan_tail(). Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Scott Wood <scottwood@freescale.com> Cc: Chin Liang See <clsee@altera.com>
2014-11-27mtd: denali: use CONFIG_SYS_NAND_SELF_INITMasahiro Yamada
Some variants of the Denali NAND controller need some registers set up based on the device information that has been detected during nand_scan_ident(). CONFIG_SYS_NAND_SELF_INIT has to be defined to insert code between nand_scan_ident() and nand_scan_tail(). It is also helpful to reduce the difference between this driver and its Linux counterpart because this driver was ported from Linux. Moreover, doc/README.nand recommends to use CONFIG_SYS_NAND_SELF_INIT. Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: Scott Wood <scottwood@freescale.com> Cc: Chin Liang See <clsee@altera.com>
2014-11-27nand: reinstate lazy bad block scanningRostislav Lisovy
Commit ff94bc40af3481d47546595ba73c136de6af6929 ("mtd, ubi, ubifs: resync with Linux-3.14") accidentally reverted part of the commit 13f0fd94e3cae6f8a0d9fba5d367e311edc8ebde ("NAND: Scan bad blocks lazily."). Reinstate the change as by commit fb49454b1b6c7c6e238ac3c0b1e302e73eb1a1ea ("nand: reinstate lazy bad block scanning") Signed-off-by: Rostislav Lisovy <lisovy@merica.cz> Acked-by: Heiko Schocher <hs@denx.de>
2014-11-26Merge branch 'master' of git://git.denx.de/u-boot-fsl-qoriqTom Rini
2014-11-26Merge branch 'master' of git://git.denx.de/u-boot-mpc85xxTom Rini
Conflicts: drivers/mmc/fsl_esdhc.c Signed-off-by: Tom Rini <trini@ti.com>
2014-11-26spl: Fix SPL EXT supportGuillaume GARDET
Commit 9f12cd0e062614e19734b2ab37842d387457c5e5 has broken SPL EXT support. This patch update error code check to get SPL EXT support working again. Tested on a Pandaboard (rev. A3). Reviewed-by: Suriyan Ramasami <suriyan.r@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Guillaume GARDET <guillaume.gardet@free.fr> Cc: Tom Rini <trini@ti.com>
2014-11-26Merge branch 'master' of http://git.denx.de/u-boot-samsungTom Rini
2014-11-26Merge branch 'master' of http://git.denx.de/u-boot-sunxiTom Rini
2014-11-26Merge git://git.denx.de/u-boot-fdtTom Rini
2014-11-25tools: Add ifdtool to .gitignoreBin Meng
Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: chromebook_link: Enable the Chrome OS ECSimon Glass
Enable the Chrome OS EC so that it can be used from U-Boot. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: chromebook_link: Enable the x86 emulatorSimon Glass
Enable this so that it can be used instead of native execution if desired. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25bios_emulator: Always print errors when opcode decode failsSimon Glass
This is a rare event and should not happen. When it does it is confusing to work out why. At least we should print a message. Adjust the emulator to always print decode errors to the console. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25bios_emulator: Add an option to enable debuggingSimon Glass
At present there are DEBUG options spread around the place. If you enable one and not another you can end up with an emulator that does not work, since each file can have a different view of what the registers look like. To fix this, create a global CONFIG_X86EMU_DEBUG option that keeps everything consistent. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25bios_emulator: Allow a custom interrupt handler to be installedSimon Glass
Sometime we want to provide an interrupt handler for the ROM, Add a function to allow this. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25bios_emulator: Add vesa support and allow ROMs to be passed in as dataSimon Glass
As well as locating the ROM on the PCI bus, allow the ROM to be supplied to the emulator. Split the init up a little so that callers can supply their own interrupt routines. Also allow a vesa mode to be provided, to be selected once the BIOS run is complete. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25bios_emulator: Allow x86 to use the emulatorSimon Glass
There is an implicit assumption that x86 machines want to use raw I/O in the BIOS emulator, but this should be selectable. Add an CONFIG_X86EMU_RAW_IO option to control it instead. Also fix a few bugs which cause warnings on x86 and adjust the Makefile to remove the assumption that only PowerPC uses the emulator. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: config: Enable video support for chromebook_linkSimon Glass
Now that we have the required drivers, enable video support with a suitable option ROM. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: dts: Add video information to the device treeSimon Glass
This provides panel timing information needed by the video driver. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Add initial video device init for Intel GMASimon Glass
Intel's Graphics Media Accelerator (GMA) is a generic name for a wide range of video devices. Add code to set up the hardware on ivybridge. Part of the init happens in native code, part of it happens in a 16-bit option ROM for those nostalgic for the 1970s. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Allow an option ROM to be built into U-BootSimon Glass
Some x86 machines require a binary blob containing 16-bit initialisation code for their video hardware. Allow this to be built into the x86 ROM so that it is accessible during boot. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: video: Add video driver for bare x86 boardsSimon Glass
Add a very simple driver which uses vesa to discover the video mode and then provides a frame buffer for use by U-Boot. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Anatolij Gustschin <agust@denx.de>
2014-11-25pci: Add general support for execution of video ROMsSimon Glass
Some platforms don't have native code for dealing with their video hardware. In some cases they use a binary blob to set it up and perform required actions like setting the video mode. This approach is a hangover from the old PC days where a ROM was provided and executed during startup. Even now, these ROMs are supplied as a way to set up video. It avoids the code for every video chip needing to be provided in the boot loader. But it makes the video much less flexible - e.g. it is not possible to do anything else while the video init is happening (including waiting hundreds of milliseconds for display panels to start up). In any case, to deal with this sad state of affairs, provide an API for execution of x86 video ROMs, either natively or through emulation. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Add support for running option ROMs nativelySimon Glass
On x86 machines we can use an emulator to run option ROMS as with other architectures. But with some additional effort (mostly due to the 16-bit nature of option ROMs) we can run them natively. Add support for this. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25Add support for Vesa BIOS extensionsSimon Glass
For option ROMs we can use these extensions to request a particular video mode. Add a header file which defines the binary interface. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Add vesa mode configuration optionsSimon Glass
Add Kconfig options to allow selection of a vesa mode on x86 machines. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Add GDT descriptors for option ROMsSimon Glass
Option ROMs require a few additional descriptors. Add these, and remove the enum since we now have to access several descriptors from assembler. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25Introduce a header file for the BIOS emulatorSimon Glass
We should have a public header so that users can avoid defining functions themselves. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Add a definition of asmlinkageSimon Glass
This is needed to permit calling C from assembler without too much pain. Add a definition for x86. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: config: Enable SPI for chromebook_linkSimon Glass
Enable SPI so that the SPI flash can be used. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: ivybridge: Add northbridge init functionsSimon Glass
Add init for the northbridge, another part of the platform controller hub. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Drop some msr functions that we don't supportSimon Glass
These are not available in U-Boot as yet, so drop them. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Add init for model 206AX CPUSimon Glass
Add the setup code for the CPU so that it can be used at full speed. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Add LAPIC setup codeSimon Glass
Add code to set up the Local Advanced Peripheral Interrupt Controller. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
2014-11-25x86: Drop old CONFIG_INTEL_CORE_ARCH codeSimon Glass
This is no-longer used, so drop it. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
2014-11-25x86: Remove unnecessary call to initr_enable_interrupts()Bin Meng
Actually initr_enable_interrupts() was never called in an x86 build due to it was wrapped by CONFIG_x86 (typo of X86). Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Refactor interrupt_init()Bin Meng
Rename interrupt_init() in arch/x86/lib/pcat_interrupts.c to i8259_init() and create a new interrupt_init() in arch/x86/cpu/interrupt.c to call i8259_init() followed by a call to cpu_init_interrupts(). Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Remove cpu_init_r() for x86Bin Meng
Since cpu_init_interrupts() was moved out of cpu_init_r(), it is useless to keep cpu_init_r() for x86, thus remove it. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Call cpu_init_interrupts() from interrupt_init()Bin Meng
Currently cpu_init_interrupts() is called from cpu_init_r() to setup the interrupt and exception of the cpu core, but at that time the i8259 has not been initialized to mask all the irqs and remap the master i8259 interrupt vector base, so the whole system is at risk of being interrupted, and if interrupted, wrong interrupt/exception message is shown. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: Add Intel speedstep and turbo mode codeSimon Glass
Intel chips have a turbo mode where they can run faster for a short period until they reach thermal limits. Add code to adjust and query this feature. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: ivybridge: Set up XHCI USBSimon Glass
Add init for XHCI so that high-speed USB can be used. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: config: Enable USB on linkSimon Glass
Enable USB support on link - there are two EHCI ports available. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: ivybridge: Set up EHCI USBSimon Glass
Add init for EHCI so that USB can be used. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: dts: Add SATA settings for linkSimon Glass
Add the requires settings to enable SATA on link. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: ivybridge: Add SATA initSimon Glass
Add code to set up the SATA interfaces on boot. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: dts: Add LPC settings for linkSimon Glass
Add some settings required to set up the LPC correctly. Signed-off-by: Simon Glass <sjg@chromium.org>
2014-11-25x86: dts: Move PCI peripherals into a pci nodeSimon Glass
These peripherals should not be at the top level, since they exist inside the PCI bus. We don't have a full device tree node for pci yet, but we should at least put it at the right level. Signed-off-by: Simon Glass <sjg@chromium.org>