summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* siemens-am33x-common: Hardcoded value instead of non-included definePaul Kocialkowski2015-07-271-1/+1
| | | | | | | | | | | | The config file for the siemens-am33x-common was using OMAP_I2C_STANDARD, which is defined in a header that is not included in the config header. In most cases, it was being included by the code using CONFIG_SYS_OMAP24_I2C_SPEED, but it might not always be the case. In particular, when introducing I2C SPL support in omap-common's boot-common.c, the header is missing and including it breaks other devices. Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
* omap-common: Boot device define instead of hardcoded valuePaul Kocialkowski2015-07-271-2/+2
| | | | | | | Now that SPL boot devices are clearly defined, we can use BOOT_DEVICE_QSPI_4 instead of a hardcoded value. Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
* omap: SPL boot devices cleanup and completionPaul Kocialkowski2015-07-274-67/+88
| | | | | | | This cleans up the SPL boot devices for omap platforms and introduces support for missing boot devices. Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
* omap-common: Common boot code OMAP3 support and cleanupPaul Kocialkowski2015-07-2718-167/+143
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces OMAP3 support for the common omap boot code, as well as a major cleanup of the common omap boot code. First, the omap_boot_parameters structure becomes platform-specific, since its definition differs a bit across omap platforms. The offsets are removed as well since it is U-Boot's coding style to use structures for mapping such kind of data (in the sense that it is similar to registers). It is correct to assume that romcode structure encoding is the same as U-Boot, given the description of these structures in the TRMs. The original address provided by the bootrom is passed to the U-Boot binary instead of a duplicate of the structure stored in global data. This allows to have only the relevant (boot device and mode) information stored in global data. It is also expected that the address where the bootrom stores that information is not overridden by the U-Boot SPL or U-Boot. The save_omap_boot_params is expected to handle all special cases where the data provided by the bootrom cannot be used as-is, so that spl_boot_device and spl_boot_mode only return the data from global data. All of this is only relevant when the U-Boot SPL is used. In cases it is not, save_boot_params should fallback to its weak (or board-specific) definition. save_omap_boot_params should not be called in that context either. Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
* kbuild: create symbolic link only for ARM, AVR32, SPARC, PowerPC, x86Masahiro Yamada2015-07-273-0/+12
| | | | | | | | | | | | | The symbolic link to SoC/CPU specific header directory is created during the build, while it is only necessary for ARM, AVR32, SPARC, x86, and some CPUs of PowerPC. For the other architectures, it just results in a broken symbolic link. Introduce CONFIG_CREATE_ARCH_SYMLINK to not create unneeded symbolic links. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* nds32: include <asm/arch-*/*.h> instead of <asm/arch/*.h>Masahiro Yamada2015-07-273-3/+3
| | | | | | | | | | | There are only two SoC-specific headers for this architecture: - arch/nds32/include/asm/arch-ag101/ag101.h - arch/nds32/include/asm/arch-ag102/ag102.h Those two have different file names, so there is no advantage to include them via symbolic linked directory. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* generic_board: Call "checkboard" even though the root node has a "model" ↵Haikun.Wang@freescale.com2015-07-271-5/+2
| | | | | | | | | | | | | | | | | | | | | | | | property In case of enable CONFIG_OF_CONTROL and has a "model" property in the root node, the board special "checkboard" will not be called. Usually we show some useful version information in the function. This patch enable call "checkboard" in any case. It is not conflicting with showing "model" at the same time. For example on LS2085AQDS: Showing "model" only: Model: Freescale Layerscape 2085a QDS Board Showing "checkboard" only: Board: LS2085E-QDS, Board Arch: V1, Board version: B, boot from vBank: 4 Showing both: Model: Freescale Layerscape 2085a QDS Board Board: LS2085E-QDS, Board Arch: V1, Board version: B, boot from vBank: 4 Signed-off-by: Haikun Wang <haikun.wang@freescale.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* keystone2: net: add mcast function to keyston2 Ethernet driverVitaly Andrianov2015-07-271-0/+10
| | | | | | | | | | | The MCAST_TFTP support requires that network drivers has mcast functon implemented. This commit adds dummy keystone2_eth_bcast_addr() to meet the requirement. As far as the driver doesn't use ALE and doesn't filter any incoming packets, the function is empty. Signed-off-by: Vitaly Andrianov <vitalya@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
* keystone2: add wfi in to the core_spin loopVitaly Andrianov2015-07-271-2/+7
| | | | | | | | | When core A turning of core B, via tetris DPSC it places the core B DPSC into transitional state. The core B has to execute wfi instruction to move its DPSC to the OFF state. This patch add such instruction. Signed-off-by: Vitaly Andrianov <vitalya@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com>
* misc: led: pca9551_led: Fix problem with multiple blink frequenciesStefan Roese2015-07-271-10/+22
| | | | | | | | | | | Only 2 frequencies are supported. The current driver implementation does not always use the 2 last configured blink frequencies. This patch fixes this problem. So that the last two entered frequencies are active. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Tom Rini <trini@konsulko.com>
* stm32f429-discovery: Use ttyS0 as the console devicerev13@wp.pl2015-07-271-1/+1
| | | | | | Mainline kernel will be using this device name as well. Signed-off-by: Kamil Lulko <rev13@wp.pl>
* kbuild: use relative path more to include MakefileMasahiro Yamada2015-07-271-11/+9
| | | | | | | | | | | | | | | | Prior to this commit, it was impossible to use relative path to include Makefiles from the top level Makefile because the option "--include-dir=$(srctree)" becomes effective when Make enters into sub Makefiles. To use relative path in any places, this commit moves the option above the "sub-make" target. This was imported from Linux (commit a436bb7b8063) and adjusted for U-Boot. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Michal Marek <mmarek@suse.cz>
* kbuild: do not add $((generic-)offsets-file) to targetsMasahiro Yamada2015-07-271-2/+1
| | | | | | | | | $(always) is added to targets by scripts/Makefile.build. Moreover, filechk does not need .*.cmd files. Adding these two files to targets is redundant. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* kbuild: sync with Linux 4.1Masahiro Yamada2015-07-275-52/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update some build scripts to match Linux 4.1. Commit-based syncing was done so as not to break U-Boot specific changes. The previous big sync was from Linux 3.18-rc1 by commit 176d09827725 (kbuild: sync misc scripts with Linux 3.18-rc1). The commits imported from Linux (some with adjustments) are: [1] commit 9fb5e5372208973984a23ee6f5f025c05d364633 Author: Robert Richter <rrichter@cavium.com> dts, kbuild: Factor out dtbs install rules to Makefile.dtbinst [2] commit 371fdc77af44f4cb32475fd499e1d912ccc30890 Author: Masahiro Yamada <yamada.m@jp.panasonic.com> kbuild: collect shorthands into scripts/Kbuild.include [3] commit a29b82326ed4eb5567b03c85b52c6891578d5a03 Author: Michal Marek <mmarek@suse.cz> kbuild: Remove duplicate $(cmd) definition in Makefile.clean [4] commit 1846dfbde3e8a53f3673dcb1c1b79fd9b3f8d40d Author: Masahiro Yamada <yamada.m@jp.panasonic.com> kbuild: remove redundant -rR flag of hdr-inst [5] commit 34948e0bbf98640fc1821751b01d2f0cd17d84d5 Author: Michal Marek <mmarek@suse.cz> kbuild: Drop support for clean-rule [6] commit a16c5f99a28c9945165c46da27fff8e6f26f8736 Author: Michal Marek <mmarek@suse.cz> kbuild: Fix removal of the debian/ directory [7] commit d0d38cd9e853db11e0242b3df4c9c3c4a663fbb4 Author: Masahiro Yamada <yamada.m@jp.panasonic.com> kbuild: use mixed-targets when two or more config targets are given [8] commit dd33c03b18b3f2db791eb6a17c37d2de66e4de18 Author: Masahiro Yamada <yamada.m@jp.panasonic.com> kbuild: fix cc-ifversion macro [9] commit 665d92e38f65d70796aad2b8e49e42e80815d4a4 Author: Masahiro Yamada <yamada.m@jp.panasonic.com> kbuild: do not add $(call ...) to invoke cc-version or cc-fullversion [10] commit 6dcb4e5edf39e3b65a75ca76f087b2fdbee8a808 Author: Masahiro Yamada <yamada.m@jp.panasonic.com> kbuild: allow cc-ifversion to have the argument for false condition [11] commit c0a80c0c27e5e65b180a25e6c4c2f7ef9e386cd3 Author: Heiko Carstens <heiko.carstens@de.ibm.com> ftrace: allow architectures to specify ftrace compile options [12] commit 0b24becc810dc3be6e3f94103a866f214c282394 Author: Andrey Ryabinin <a.ryabinin@samsung.com> kasan: add kernel address sanitizer infrastructure [13] commit 4218affdf57f938c04e3a916a9685ee27079f377 Author: Masahiro Yamada <yamada.m@jp.panasonic.com> kbuild: remove warning about "make depend" [14] commit 77479b38e2f58890eb221a0418357502a5b41cd6 Author: Nathan Rossi <nathan.rossi@xilinx.com> kbuild: Create directory for target DTB Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Signed-off-by: Robert Richter <rrichter@cavium.com> Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> Signed-off-by: Andrey Ryabinin <a.ryabinin@samsung.com> Signed-off-by: Nathan Rossi <nathan.rossi@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Signed-off-by: Olof Johansson <olof@lixom.net> Signed-off-by: Michal Marek <mmarek@suse.cz> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* kconfig: sync with Linux 4.1Masahiro Yamada2015-07-2717-203/+189
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update the files under scripts/kconfig/ to match Linux 4.1. Some Kconfig sources have diverged from those in the kernel, so commit-base syncing was done not to lose U-Boot specific updates. The commits cherry-picked from Linux are: [1] commit be8af2d54a66911693eddc556e4f7a866670082b Author: Bjørn Forsman <bjorn.forsman@gmail.com> kconfig/lxdialog: get ncurses CFLAGS with pkg-config [2] commit 3943f42c11896ce82ad3da132c8a5630313bdd0e Author: Andrey Utkin <andrey.krieger.utkin@gmail.com> Replace mentions of "list_struct" to "list_head" [3] commit e4e458b45c5861808674eebfea94cee2258bb2ea Author: Arjun Sreedharan <arjun024@gmail.com> calloc/xcalloc: Fix argument order [4] commit 09950bc256e3628d275f90e016e6f5a039fbdcab Author: Olof Johansson <olof@lixom.net> merge_config.sh: Display usage if given too few arguments [5] commit b6a2ab2cd4739a9573ed41677e53171987b8da34 Author: Colin Ian King <colin.king@canonical.com> kconfig: use va_end to match corresponding va_start [6] commit 70529b1a1784503169416df19ce3d68746401340 Author: Michal Marek <mmarek@suse.cz> kconfig: Get rid of the P() macro in headers [7] commit 463157444e377bf9b279101b1f16a94c4648c03a Author: Michal Marek <mmarek@suse.cz> kconfig: Remove dead code [8] commit ad8d40cda3ad22ad9e8863d55a5c88f85c0173f0 Author: Michal Marek <mmarek@suse.cz> kconfig: Remove unnecessary prototypes from headers [9] commit de4619937229378e81f95e99c9866acc8e207d34 Author: Masahiro Yamada <yamada.masahiro@socionext.com> kbuild: mergeconfig: fix "jobserver unavailable" warning [10] commit b9fe99c5b994c6ddc57780993966b18899526c0b Author: Masahiro Yamada <yamada.masahiro@socionext.com> kbuild: mergeconfig: move an error check to merge_config.sh [11] commit 371cfd4ff0611d8bc5d18bbb9cc6a2bc3d56cd3d Author: Masahiro Yamada <yamada.masahiro@socionext.com> kbuild: mergeconfig: remove redundant $(objtree) [12] commit 3a975b8cfcbe026b535f83bde9a3c009bae214f9 Author: Masahiro Yamada <yamada.masahiro@socionext.com> merge_config.sh: improve indentation [13] commit bc8f8f5fc47cd02c2c5f3580dac2fe6695af1edd Author: Masahiro Yamada <yamada.masahiro@socionext.com> merge_config.sh: rename MAKE to RUNMAKE [14] commit 63a91033d52e64a22e571fe84924c0b7f21c280d Author: Masahiro Yamada <yamada.masahiro@socionext.com> kbuild: add generic mergeconfig target, %.config [15] commit 1cba0c305758c3c1786ecaceb03e142c95a4edc9 Author: Michal Marek <mmarek@suse.cz> kconfig: Simplify Makefile [16] commit 0a1f00a1c86421cc07cec87011c7cf4df68ee54b Author: Michal Marek <mmarek@suse.cz> kconfig: Do not print status messages in make -s mode Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Bjørn Forsman <bjorn.forsman@gmail.com> Signed-off-by: Andrey Utkin <andrey.krieger.utkin@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Arjun Sreedharan <arjun024@gmail.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Olof Johansson <olof@lixom.net> Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Michal Marek <mmarek@suse.cz>
* config: ti_omap5_common: Palmas power support in SPLPaul Kocialkowski2015-07-272-2/+1
| | | | | | | | | | | | Palmas power support is required for OMAP5 devices such as the OMAP5 uEVM, that need to e.g. enable MMC power at SPL stage. This is especially important when booting from a peripheral (such as USB, UART), where the bootrom will not enable power for the MMC device that will hold the main U-Boot. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Reviewed-by: Tom Rini <trini@konsulko.com>
* Merge branch 'master' of http://git.denx.de/u-boot-sunxiTom Rini2015-07-2575-342/+347
|\
| * sunxi: Enable both ehci and otg in host mode on various boardsHans de Goede2015-07-254-0/+6
| | | | | | | | | | | | | | | | | | | | | | Now that the device-model port of the musb mode makes it possible, enable both the ehci and otg in host mode on boards where the musb is wired up in host only mode, either via an usb-a receptacle or via an usb <-> sata converter. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Marek Vasut <marex@denx.de> Acked-by: Ian Campbell <ijc@hellion.org.uk>
| * sunxi: ga10h: Enable both otg and regular usb host controllersHans de Goede2015-07-253-0/+28
| | | | | | | | | | | | | | This allows using devices plugged into both ports of the tablet. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
| * sunxi: musb: Stop treating not having a vbus-det gpio as an errorHans de Goede2015-07-252-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | On some boards the otg is wired up in host-only mode in this case we have no vbus-det gpio. Stop logging an error from sunxi_usb_phy_vbus_detect() in this case, and stop treating sunxi_usb_phy_vbus_detect() returning a negative errno, as if a charger is plugged into the otg port. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Marek Vasut <marex@denx.de> Acked-by: Ian Campbell <ijc@hellion.org.uk>
| * sunxi: musb: Improve output during probingHans de Goede2015-07-251-5/+6
| | | | | | | | | | | | | | | | | | When we return an error the usb core will print an error-message, so in this case do not print anything. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Marek Vasut <marex@denx.de> Acked-by: Ian Campbell <ian.campbell@citrix.com>
| * sunxi: musb: Use device-model for musb host modeHans de Goede2015-07-252-1/+58
| | | | | | | | | | | | | | | | | | | | | | | | Modify the sunxi musb glue to use the device-model for musb host mode. This allows using musb in host mode together with other host drivers such as ehci / ohci, which is esp. useful on boards which use the musb controller in host-only mode, these boards have e.g. an usb-a receptacle or an usb to sata converter attached to the musb controller. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
| * sunxi: musb: Move musb config and platdata to the sunxi-musb glueHans de Goede2015-07-253-36/+34
| | | | | | | | | | | | | | | | | | Move the musb config and platdata to the sunxi-musb glue, which is where it really belongs. This is preparation patch for adding device-model support for the sunxi-musb-host code. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
| * sunxi: musb: Add id pin supportHans de Goede2015-07-254-0/+8
| | | | | | | | | | | | | | | | | | | | When in host mode check if there is a host cable inserted into the otg port by checking the id pin. If there is no host cable return an error to make usb_lowlevel_init() exit early, rather then waiting for 1 second for a device which will never show up. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
| * sunxi: musb: Move vbus check to sunxi_musb_enableHans de Goede2015-07-251-10/+9
| | | | | | | | | | | | | | This way it can be re-checked on "usb reset". Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
| * sunxi: usb-phy: Add support for reading otg id pin valueHans de Goede2015-07-253-0/+42
| | | | | | | | | | | | | | | | Add support for reading the id pin value of the otg connector to the usb phy code. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk>
| * sunxi: Enable CMD_USB and USB_STORAGE by default on sunxiHans de Goede2015-07-252-5/+2
| | | | | | | | | | | | | | | | | | | | Start using the new Kconfig options which are available for these now, and simply always enable them by selecting them as sunxi builds always include USB support. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk> Reviewed-by: Simon Glass <sjg@chromium.org>
| * sunxi: Update selects in arch/arm/Kconfig for DM conversionsTom Rini2015-07-2562-250/+86
| | | | | | | | | | | | | | | | | | | | | | | | | | With certain features being convert to DM now we want sunxi to default to having DM enabled for ETH/SERIAL and USB in some cases. Cc: Hans de Goede <hdegoede@redhat.com> Cc: Ian Campbell <ijc@hellion.org.uk> Signed-off-by: Tom Rini <trini@konsulko.com> [hdegoede@redhat.com: Also select CONFIG_USB for all sunxi builds] Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ian Campbell <ijc@hellion.org.uk> Reviewed-by: Simon Glass <sjg@chromium.org>
| * sunxi: Remove bogus uart entry from utoo-p66 dts fileHans de Goede2015-07-251-14/+0
| | | | | | | | | | | | | | | | | | | | | | At one point in time the utoo-p66 dts file in the kernel had a bogus uart entry, and it seems like we synced with the kernel at just the wrong moment. This commit removes the bogus uart entry, which breaks booting the utoo-p66 when DM_SERIAL=y. Signed-off-by: Hans de Goede <hdegoede@redhat.com>
| * sunxi: spl: Remove redundant check from `board_mmc_init` for signatureDaniel Kochmański2015-07-241-9/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | Remove the boot signature check from board_mmc_init() in spl mode, as it is already done in spl_boot_device() in this case, and update the comments to reflect this. Signed-off-by: Daniel Kochmański <dkochmanski@turtle-solutions.eu> CC: Roy Spliet <r.spliet@ultimaker.com> Cc: Ian Campbell <ijc@hellion.org.uk> [hdegoede@redhat.com: Disable the check only for SPL instead of always] Acked-by: Hans De Goede <hdegoede@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
| * sunxi: spl: Detect at runtime where SPL was read fromDaniel Kochmański2015-07-241-12/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | Make possible using a single `u-boot-sunxi-with-spl.bin` binary for both NAND memory and SD card. Detection where SPL was read from is implemented in `spl_boot_device`. Signed-off-by: Daniel Kochmański <dkochmanski@turtle-solutions.eu> CC: Roy Spliet <r.spliet@ultimaker.com> Cc: Ian Campbell <ijc@hellion.org.uk> [hdegoede@redhat.com: Some small coding style fixes] Acked-by: Hans De Goede <hdegoede@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
| * sunxi: Create helper function veryfing valid boot signature on MMCDaniel Kochmański2015-07-243-6/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch extracts checking for valid SD card "eGON.BT0" signature from `board_mmc_init` into function `sunxi_mmc_has_egon_boot_signature`. Buffer for mmc sector is allocated and freed at runtime. `panic` is triggered on malloc failure. Signed-off-by: Daniel Kochmański <dkochmanski@turtle-solutions.eu> CC: Roy Spliet <r.spliet@ultimaker.com> Cc: Ian Campbell <ijc@hellion.org.uk> [hdegoede@redhat.com: Small bugfix to make it work for devs other then mmc0] Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
| * mmc: Protect `mmc_initialize` from initialising mmc multiple timesDaniel Kochmański2015-07-241-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | `mmc_initialize` might be called multiple times leading to the mmc-controllers being initialised twice, and initialising the `mmc_devices` list head twice which may lead to memory leaks. Signed-off-by: Daniel Kochmański <dkochmanski@turtle-solutions.eu> CC: Roy Spliet <r.spliet@ultimaker.com> Cc: Ian Campbell <ijc@hellion.org.uk> CC: Pantelis Antoniou <panto@antoniou-consulting.com> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
* | Merge git://git.denx.de/u-boot-usbTom Rini2015-07-2453-374/+666
|\ \
| * | usb: ci_udc: fix request allocation when endpoints are disabledRob Herring2015-07-241-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The ci_udc driver request allocation assumes that the endpoint descriptor pointer is set to retrieve the endpoint number, but that is only true when the endpoint is enabled. This results in a NULL ptr dereference which for me happens to return 0 value. This causes the EP0 request struct to be returned for other endpoints. Some gadget drivers like fastboot and USB MS work fine, but ethernet does not. Really, the ci_udc driver is the oddball here doing this EP0 special case handling Stephen added. All the other drivers alloc/free functions are pretty much the same with the only variation being the size of the private struct. This could all be consolidated to a common function. Signed-off-by: Rob Herring <robh@kernel.org> Cc: Marek Vasut <marex@denx.de> Acked-by: Stephen Warren <swarren@nvidia.com>
| * | ci_udc: fix 64-bit compile warningsStephen Warren2015-07-231-9/+10
| | | | | | | | | | | | | | | | | | | | | This is the same as f72d8320b605 "usb: ci_udc: fix warnings on 64-bit builds", but more. Signed-off-by: Stephen Warren <swarren@nvidia.com>
| * | usb: ehci-marvell: Drop wrl accessor functionStefan Roese2015-07-221-14/+12
| | | | | | | | | | | | | | | | | | | | | | | | This patch removes the wrl accessor function from the Marvell EHCI driver by replacing it with the writel function. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Marek Vasut <marex@denx.de>
| * | usb: CONFIG_USB_FASTBOOT prefix replacement for consistencyPaul Kocialkowski2015-07-229-20/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FASTBOOT is defined both by CONFIG_USB_FUNCTION_FASTBOOT AND CONFIG_CMD_FASTBOOT, so it doesn't make much sense to have a CONFIG_USB_FASTBOOT prefix for fastboot-specific options, especially given that other config options for fastboot use the CONFIG_FASTBOOT prefix. This replaces the CONFIG_USB_FASTBOOT prefix with CONFIG_FASTBOOT, for consistency. Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
| * | implement Fastboot via USB OTG on bcm28155_ap boardsJiandong Zheng2015-07-223-0/+61
| | | | | | | | | | | | | | | Signed-off-by: Jiandong Zheng <jdzheng@broadcom.com> Signed-off-by: Steve Rae <srae@broadcom.com>
| * | usb: gadget: bcm_udc_otg filesJiandong Zheng2015-07-223-0/+80
| | | | | | | | | | | | | | | | | | | | | Add the required files for the Broadcom UDC OTG interface. Signed-off-by: Jiandong Zheng <jdzheng@broadcom.com> Signed-off-by: Steve Rae <srae@broadcom.com>
| * | g_dnl: add missing declarationSteve Rae2015-07-221-0/+1
| | | | | | | | | | | | | | | | | | Signed-off-by: Steve Rae <srae@broadcom.com> Tested-by: Lukasz Majewski <l.majewski@samsung.com> Test HW: Exynos 4210 (trats), Exynos 5422 (Odroid XU3)
| * | usb: gadget: fastboot: Dequeue the previous IN request for the current requestPaul Kocialkowski2015-07-221-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recent versions of the fastboot tool will query the partition type before doing an operation on a partition (such as erase, flash, etc). It will then submit the operation as soon as the response for the partition type is received. Usually, the MUSB controller will see that the partition type request return status was read by the host at the very same time as the actual operation request is submitted by the host. However, the operation will be read first (int_rx is handled first in musb_interrupt) and after it is completed, the fastboot USB gadget driver will send another return status. Hence, this happens before the musb gadget framework has had a chance to handle the previous acknowledgement that the host read the return status and dequeue the request. The host will then usually empty the FIFO by the time musb_interrupt gets around handling the return status acknowledgement (for the previous request, this is still on the same musb_interrupt call), so no other interrupt is generated and the most recent return status acknowledgement remains unaccounted for. It will then be used as a response for the next command, and the proper response for it will be delayed to the next command, and so on. Dequeuing the previous IN request in the fastboot code ensures that no previous return status remains. It is acceptable to do it since there is no callback to it anyways. Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
| * | usb: gadget: fastboot: Request status and length check in rx handlerPaul Kocialkowski2015-07-221-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | This avoids handling requests that have an error status or no data. In particular, this avoids showing unnecessary error messages when the USB gadget gets disconnected (e.g. with fastboot continue) and the fastboot USB gadget driver sends an error back to the host (that has disconnected already). Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
| * | fastboot: Dynamic controller index for usb_gadget_handle_interruptsPaul Kocialkowski2015-07-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Since we're now using a dynamic controller index for fastboot too, usb_gadget_handle_interrupts should be using it instead of 0 (despite the fact that it's currently not being used at all in the musb-new implementation). Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
| * | usb: gadget: Weak board_usb_init/cleanup definitions in USB download gadget codePaul Kocialkowski2015-07-221-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Weak versions of board_usb_init and board_usb_cleanup are defined in common USB host code, but it is also used for USB device gadgets, so we also need a weak definition of it when there is no USB host enabled. Both weak definitions do not conflict. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Tested-by: Lukasz Majewski <l.majewski@samsung.com> Test HW: Odroid_XU3 (Exynos5422), trats (Exynos4210)
| * | usb: board_usb_init and board_usb_cleanup calls in the fastboot commandPaul Kocialkowski2015-07-222-7/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Each USB download function command calls board_usb_init before registering the USB gadget and board_usb_cleanup after de-registering it. On devices currently using fasboot, musb-new is usually initialized earlier, but some other boards might need the board_usb_init call to properly initialize musb-new. This requires adding an argument (the USB controller index) to the fastboot command, as it is currently done with other USB download gadget functions. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Tested-by: Lukasz Majewski <l.majewski@samsung.com> Test HW: Odroid_XU3 (Exynos5422), trats (Exynos4210)
| * | usb: Fastboot function config for better consistency with other functionsPaul Kocialkowski2015-07-229-4/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | USB download gadget functions such as thor and dfu have a separate config option for the USB gadget part of the code, independent from the command part. This switches the fastboot USB gadget to the same scheme, for better consistency. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Tested-by: Lukasz Majewski <l.majewski@samsung.com> Test HW: Odroid_XU3 (Exynos5422), trats (Exynos4210)
| * | usb: USB download gadget and functions config options coherent namingPaul Kocialkowski2015-07-2224-57/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces a coherent scheme for naming USB download gadget and functions config options. The download USB gadget config option is moved to CONFIG_USB_GADGET_DOWNLOAD for better consistency with other gadgets and each function's config option is moved to a CONFIG_USB_FUNCTION_ prefix. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Tested-by: Lukasz Majewski <l.majewski@samsung.com> Test HW: Odroid_XU3 (Exynos5422), trats (Exynos4210)
| * | drivers: usb: fsl: Remove LS102XA immap inclusionNikhil Badola2015-07-221-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | Remove LS102XA immap header inclusion from xhci fsl driver. It removes redefinition warnings when built for platforms other than LS102XA Signed-off-by: Nikhil Badola <nikhil.badola@freescale.com>
| * | include: usb: Map USB controller base addresses for LS2085ANikhil Badola2015-07-221-0/+3
| | | | | | | | | | | | | | | | | | Map USB XHCI controller base addresses for LS2085A SOC Signed-off-by: Nikhil Badola <nikhil.badola@freescale.com>
OpenPOWER on IntegriCloud