summaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2013-03-12Merge branch 'am335x-connectivity-2013.01.01' into ti-u-boot-2013.01.01Tom Rini
2013-03-12dfu: NAND specific routines for DFU operationPantelis Antoniou
Support for NAND storage devices to work with the DFU framework. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com> Signed-off-by: Tom Rini <trini@ti.com>
2013-03-12nand: Extend nand_(read|write)_skip_bad with *actual and limit parametersTom Rini
We make these two functions take a size_t pointer to how much space was used on NAND to read or write the buffer (when reads/writes happen) so that bad blocks can be accounted for. We also make them take an loff_t limit on how much data can be read or written. This means that we can now catch the case of when writing to a partition would exceed the partition size due to bad blocks. To do this we also need to make check_skip_len count not just complete blocks used but partial ones as well. All callers of nand_(read|write)_skip_bad are adjusted to call these with the most sensible limits available. The changes were started by Pantelis and finished by Tom. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com> Signed-off-by: Tom Rini <trini@ti.com>
2013-03-12dfu: Support larger than memory transfers.Pantelis Antoniou
Previously we didn't support upload/download larger than available memory. This is pretty bad when you have to update your root filesystem for example. This patch removes that limitation (and the crashes when you transfered any file larger than 4MB) by making raw image writes be done in chunks and making file maximum size be configurable. The sequence number is a 16 bit counter; make sure we handle rollover correctly. This fixes the wrong transfers for large (> 256MB) images. Also utilize a variable to handle initialization, so that we don't rely on just the counter sent by the host. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com> Signed-off-by: Tom Rini <trini@ti.com>
2013-03-12usb: Fix bug when both DFU & ETHER are definedPantelis Antoniou
When both CONFIG_USB_GADGET & CONFIG_USB_ETHER are defined the makefile links objects twice. This patch uses a Makefile specific idiom of 'if defined(CONFIG_USB_GADGET) || defined(CONFIG_USB_ETHER)' to handle the case. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
2013-02-15ARM: OMAP4+: Make control module register structure genericLokesh Vutla
A seperate omap_sys_ctrl_regs structure is defined for omap4 & 5. If there is any change in control module for any of the ES versions, a new structure needs to be created. In order to remove this dependency, making the register structure generic for all the omap4+ boards. Signed-off-by: R Sricharan <r.sricharan@ti.com> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com> Reviewed-by: Tom Rini <trini@ti.com>
2013-02-15dfu: Add a partition type targetPantelis Antoniou
Dealing with raw block numbers with the dfu is very annoying. Introduce a partition method. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
2013-02-15dfu: Properly zero out timeout valuePantelis Antoniou
Zero out timeout value; letting it filled with undefined values ends up with the dfu host hanging. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
2013-02-15dfu: Send correct DFU response from composite_setupPantelis Antoniou
DFU is a bit peculiar. It needs to hook to composite setup and return it's function descriptor. So when get-descriptor request comes with a type of DFU_DT_FUNC we iterate over the configs, and functions, and when we find the DFU function we call the setup method which is prepared to return the appropriate function descriptor. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
2013-01-14Merge branch 'agust@denx.de' of git://git.denx.de/u-boot-stagingTom Rini
2013-01-14twl4030: fix 'could could' in error messagesPeter Meerwald
Signed-off-by: Peter Meerwald <p.meerwald@bct-electronic.com>
2013-01-14Merge branch 'u-boot-imx/master' into 'u-boot-arm/master'Albert ARIBAUD
2013-01-14Merge branch 'u-boot-samsung/master' into 'u-boot-arm/master'Albert ARIBAUD
2013-01-14video: exynos_fb: Make a call to draw_logo only when CONFIG_CMD_BMP is selectedAjay Kumar
Previously, the call to draw_logo() was happening irrespective of whether we have selected logo or LCD console. With this patch we call draw_logo() only when CONFIG_CMD_BMP is selected. This would even fix the following compilation warning: exynos_fb.c: In function 'draw_logo': exynos_fb.c:74:8: warning: variable 'addr' set but not used [-Wunused-but-set-variable] exynos_fb.c:73:9: warning: variable 'y' set but not used [-Wunused-but-set-variable] exynos_fb.c:73:6: warning: variable 'x' set but not used [-Wunused-but-set-variable] Signed-off-by: Ajay Kumar <ajaykumar.rs@samsung.com> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-14video: exynos_dp: Remove unused variable disp_infoAjay Kumar
Remove unused variable disp_info to fix the following compilation warning: exynos_dp.c: In function 'exynos_init_dp': exynos_dp.c:860:23: warning: variable 'disp_info' set but not used [-Wunused-but-set-variable] Signed-off-by: Ajay Kumar <ajaykumar.rs@samsung.com> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-14I2C: S3C24X0: Resolve build error for VCMA9Rajeshwari Shinde
This patch resolves the following build errors for I2C driver in VCMA9: In file included from s3c24x0_i2c.c:40:0: s3c24x0_i2c.h:38:17: error: field 'id' has incomplete type s3c24x0_i2c.c:70:39: error: 'CONFIG_MAX_I2C_NUM' undeclared here (not in a function) s3c24x0_i2c.c:70:31: warning: 'i2c_bus' defined but not used [-Wunused-variable] s3c24x0_i2c.c:72:12: warning: 'i2c_busses' defined but not used [-Wunused-variable] Signed-off-by: Rajeshwari Shinde <rajeshwari.s@samsung.com> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-13mx31/mx35/mx51/mx53/mx6: add watchdogTroy Kisky
Use a common watchdog driver for all these cpus. Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com> Acked-by: Stefano Babic <sbabic@denx.de>
2013-01-11Merge branch 'master' of git://git.denx.de/u-boot-armTom Rini
2013-01-10serial/ns16550: add an option to avoid hanging on broken platformsJavier Martinez Canillas
Some platforms (e.g. IGEPv2 board) has a broken ns16550 UART that does not set the TEMT bit when the transmitter is empty in SPL. This makes U-Boot to hang while waiting for TEMT to be set. Add a new option to avoid this: CONFIG_SYS_NS16550_BROKEN_TEMT 16550 UART set the Transmitter Empty (TEMT) Bit when all output has finished and the transmitter is totally empty. U-Boot waits for this bit to be set to initialize the serial console. On some broken platforms this bit is not set in SPL making U-Boot to hang while waiting for TEMT. Define this option to avoid it. Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
2013-01-10cfi_flash: Report Advanced Sector Protection (PPB) with flinfo cmdStefan Roese
Report the usage of the Advanced Sector Protection (PPB) to the user upon 'flinfo' command. E.g: Bank # 1: CFI conformant flash (16 x 16) Size: 64 MB in 512 Sectors AMD Standard command set, Manufacturer ID: 0x01, Device ID: 0x227E2301 Advanced Sector Protection (PPB) enabled Erase timeout: 16384 ms, write timeout: 2 ms Buffer write timeout: 5 ms, buffer size: 32 bytes Sector Start Addresses: FC000000 E FC020000 E RO FC040000 E FC060000 E FC080000 E ... Signed-off-by: Stefan Roese <sr@denx.de> Cc: Anatolij Gustschin <agust@denx.de> Cc: Holger Brunck <holger.brunck@keymile.com> Tested-by: Holger Brunck <holger.brunck@keymile.com>
2013-01-10cfi_flash: Enable PPB protection for all AMD cmdset flash chipsStefan Roese
Not only Spansion supports the Persistent Protection Bits (PPB) locking. Other devices like the Micron JS28F512M29EWx also support this type of locking/unlocking. Detection of support is done in the same way as done for the Spansion chips - via the 0x49 CFI word. This patch enables this PPB protection mechanism for all AMD type (AMD commandset) chips. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Anatolij Gustschin <agust@denx.de> Cc: Holger Brunck <holger.brunck@keymile.com> Tested-by: Holger Brunck <holger.brunck@keymile.com>
2013-01-10cfi_flash: Read PPB sector protection from device for AMD/Spansion chipsStefan Roese
Patch 66863b05 [cfi_flash: add support for Spansion flash PPB sector protection] introduced the PPB (Persistent Protection Bit) locking for Spansion chips. But right now the sector protection status (locked vs unlocked) is set to unlocked for all sectors upon bootup. The real sector protection status is ignored. This patch now reads the current sector protection status and uses it for these AMD/Spansion flash chips. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Anatolij Gustschin <agust@denx.de> Cc: Holger Brunck <holger.brunck@keymile.com> Tested-by: Holger Brunck <holger.brunck@keymile.com>
2013-01-10cfi_flash: Add manufact_match helper functionStefan Roese
Consolidate manufacturer matching into the function manufact_match() and use it. Signed-off-by: Stefan Roese <sr@denx.de> Tested-by: Holger Brunck <holger.brunck@keymile.com>
2013-01-10mtd/cfi: add support for SST 4KB sector granularityAngelo Dureghello
Add support for SST 4KB sector granularity. Many recent SST flashes, i.e. SST39VF3201B and similar of this family are declared CFI-conformant from SST. They support CFI query, but implement 2 different sector sizes in the same memory: a 64KB sector (they call it "block", std AMD erase cmd=0x30), and a 4KB sector (they call it "sector", erase cmd=0x50). Also, CFI query on these chips, reading from address 0x2dh of cfi query struct, detects a number of secotrs for the 4KB granularity (flinfo shows it). For all other aspects, they are CFI compliant, so, as Linux do, i think it's a good idea to handle these chips in the CFI driver, with a fixup to allow 4KB granularity, as should be expected, instead of 64KB. Signed-off-by: Angelo Dureghello <sysamfw@gmail.com> Signed-off-by: Stefan Rose <sr@denx.de>
2013-01-10video: Modify exynos_fimd driver to support LCD consoleAjay Kumar
Currently, exynos FIMD driver is being used to support only TIZEN LOGOs. In order to get LCD console, we need to enable half word swap feature of FIMD and use 16 BPP. LCD console and proprietary Logo cannot be used simultaneously. We use "logo_on" field inside vidinfo_t structure to decide whether user wants Logo or Console. Define CONFIG_CMD_BMP and make logo_on = 1 to get Logo on screen. Use logo_on = 0 to get output console on LCD. Signed-off-by: Ajay Kumar <ajaykumar.rs@samsung.com> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-10PMIC: MAX77686: Add FDT SupportRajeshwari Shinde
This patch adds fdt support to MAX77686. Signed-off-by: Rajeshwari Shinde <rajeshwari.s@samsung.com> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-09Merge 'u-boot-atmel/master' into 'u-boot-arm/master'Albert ARIBAUD
2013-01-09Fix SPL build for non-ARM targetsAlbert ARIBAUD
Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
2013-01-09video:cache:fix: Enable dcache flush at LCD subsystem for Exynos based boardsƁukasz Majewski
lcd_set_flush_dcache(1) function is called from exynos_fb.c configuration file to enable lcd_sync function. Signed-off-by: Lukasz Majewski <l.majewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Tested-by: Lukasz Majewski <l.majewski@samsung.com> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-09kirkwood: make MPP arrays static constAlbert ARIBAUD
This saves stack and code memory for local copy, and consumes initialized data memory. For 22 of the 29 kirkwood-based boards, this results in a global saving of about 30 bytes. For 7 of them, it results in an increase of 6 to 14 bytes. Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
2013-01-09mv88e61xx: refactor PHY and SWITCH level-codeAlbert ARIBAUD
Signed-off-by: Albert ARIBAUD <albert.u.boot@aribaud.net>
2013-01-08Merge branch 'master' of git://git.denx.de/u-boot-armTom Rini
2013-01-08Merge branch 'u-boot-imx/master' into 'u-boot-arm/master'Albert ARIBAUD
2013-01-08Merge branch 'u-boot-ti/master' into 'u-boot-arm/master'Albert ARIBAUD
This required manual merging drivers/mtd/nand/Makefile and adding am335x_evm support for CONFIG_SPL_NAND_DRIVERS
2013-01-08EHCI: Exynos: Add fdt supportRajeshwari Shinde
Adding fdt support to ehci-exynos in order to parse register base addresses from the device node. Signed-off-by: Vivek Gautam <gautam.vivek@samsung.com> Signed-off-by: Rajeshwari Shinde <rajeshwari.s@samsung.com> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-08SPI: EXYNOS: Add FDT support to driver.Rajeshwari Shinde
This patch adds FDT support to the SPI driver. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Rajeshwari Shinde <rajeshwari.s@samsung.com> Acked-by: Simon Glass <sjg@chromium.org> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-08Sound: WM8994: Add FDT support to codecRajeshwari Shinde
This patch adds FDT support to the codec. Signed-off-by: Rajeshwari Shinde <rajeshwari.s@samsung.com> Acked-by: Simon Glass <sjg@chromium.org> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-08Sound: Add FDT support to driverRajeshwari Shinde
This patch adds FDT support to the sound driver. Signed-off-by: Rajeshwari Shinde <rajeshwari.s@samsung.com> Acked-by: Simon Glass <sjg@chromium.org> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-08I2C: Driver changes for FDT supportRajeshwari Shinde
Functions added to get the I2C bus number and reset I2C bus using FDT node. Signed-off-by: Rajeshwari Shinde <rajeshwari.s@samsung.com> Acked-by: Simon Glass <sjg@chromium.org> Acked-by: Heiko Schocher <hs@denx.de> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2013-01-05fsl_esdhc: add MMC_MODE_HC host_capsShawn Guo
All esdhc variants we know should support high capacity MMC cards, so let's add MMC_MODE_HC host_caps unconditionally to support those MMC cards (capacity > 2 GB). Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
2012-12-22Merge branch 'master' of git://git.denx.de/u-boot-armTom Rini
2012-12-22Merge samsung, imx, tegra into u-boot-arm/masterAlbert ARIBAUD
This commit merges branches from samsung, imx and tegra meant to fix merge issues between u-boot/master and u-boot-arm/master, as well as a few manual merge fixes.
2012-12-21Merge branch 'master' of git://git.denx.de/u-boot-usbTom Rini
2012-12-21driver/mtd/IFC:Wait tWB time, poll R/B before command executionPrabhakar Kushwaha
IFC_FIR_OP_CMD0 issues command for execution without checking flash readiness. It may cause problem if flash is not ready. Instead use IFC_FIR_OP_CW0 which Wait for tWB time and poll R/B to return high or time-out, before issuing command. NAND_CMD_READID command implemention does not fulfill above requirement. So update its programming. Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com> Signed-off-by: Hemant Nautiyal <hemant.nautiyal@freescale.com>
2012-12-20serial_sh: Add support Renesas SH7752Yoshihiro Shimoda
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
2012-12-19Merge remote-tracking branch 'u-boot/master' into u-boot-arm-mergedAllen Martin
Conflicts: README arch/arm/cpu/armv7/exynos/clock.c board/samsung/universal_c210/universal.c drivers/misc/Makefile drivers/power/power_fsl.c include/configs/mx35pdk.h include/configs/mx53loco.h include/configs/seaboard.h
2012-12-17Merge branch 'master' of git://git.denx.de/u-boot-netTom Rini
2012-12-17g_dnl: Properly terminate string list.Pantelis Antoniou
Well, not terminating the list causes very interesting crashes. As in changing the vendor & product ID crashes. Fun. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
2012-12-17g_dnl: Issue connect/disconnect as appropriatePantelis Antoniou
Call usb_gadget_connect/usb_gadget_disconnect in g_dnl_bind/g_dnl_unbind. Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
2012-12-17pxa25x_udc: Remove usbdescriptors.hLukasz Dalek
usbdescriptors.h conflicts with linux/usb/ch9.h. Remove it. Signed-off-by: Lukasz Dalek <luk0104@gmail.com>