05 Aug, 2015
14 commits
-
The code in question polls an USB port status via USB_REQ_GET_STATUS
to determine whether there is a device on the port or not. The way to
figure that out is to check two bits. Those are wPortChange[0] and
wPortStatus[0].The wPortChange[0] indicates whether some kind of a connection status
change happened on a port (a device was plugged or unplugged). The
wPortStatus[0] bit indicates the status of the connection (plugged or
unplugged).The current code tests whether wPortChange[0] == wPortStatus[0] and
if that's the case, considers the loop polling for the presence of a
USB device on port finished.This works for most USB sticks, since they come up really quickly and
trigger the USB port change detection before the first iteration of the
detection loop happens. Thus, both wPortChange[0] and wPortStatus[0]
are set to 1 and thus equal. The loop is existed in it's first iteration
and the stick is detected correctly.The problem is with some obscure USB sticks, which take some time before
they pop up on the bus after the port was enabled. In this case, both
the wPortChange[0] and wPortStatus[0] are 0. They are equal again, so
the loop again exits in the first iteration, but this is incorrect, as
such USB stick didn't have the opportunity to get detected on the bus.Rework the code such, that it checks for wPortChange[0] first to test
if any connection change happened at all. If no change occured, keep
polling. If a change did occur, test the wPortStatus[0] to see there is
some device present on the port and only if this is the case, break out
of the polling loop.This patch also trims down the duration of the polling loop from 10s
per port to 1s per port. This is still annoyingly long, but there is
no better option in case of U-Boot unfortunatelly. This change will
most likely increase the duration of 'usb start' on some platforms,
but this is needed to fix a bug.Signed-off-by: Marek Vasut
Cc: Simon Glass
Cc: Hans de Goede -
This patch fixes operation of our on-board AX88772B chip without EEPROM
but with a ethaddr coming from the regular U-Boot environment. This is
a forward port of some remaining parts initially implemented by
Antmicro.Signed-off-by: Marcel Ziswiler
Acked-by: Marek Vasut -
USB_KEYBOARD is now defined in drivers/usb/Kconfig, drop our own duplicate
definition.Signed-off-by: Hans de Goede
-
usb_stor_reset is only defined when USB storage support is enabled, thus the
function is not declared when such support is missing.Signed-off-by: Paul Kocialkowski
-
This adds some config options to the sunxi-common config to enable the USB
download gadget and the fastboot and USB mass storage functions.Signed-off-by: Paul Kocialkowski
-
Currently, the second use of a gadget will fail, while the first one works.
Forcing the EP0 at every enable fix this issue.
Signed-off-by: Maxime Ripard
-
Now that some things were updated in Kconfig, they should be reflected on the
sunxi-common config too.Signed-off-by: Paul Kocialkowski
-
Now that the musb-new driver has a Kconfig, we can move Kconfig options to
enable controllers to it, so that it's easier in e.g. menuconfig.In addition, this allows declaring support for USB_MUSB_HOST/GADGET in
defconfigs instead of the USB_MUSB_SUNXI controller, that will get selected
automatically when needed.Signed-off-by: Paul Kocialkowski
-
Having MUSB_HOST and MUSB_GADGET in Kconfig allows more flexibility with regard
to what Kconfig options to enable, such as USB_STORAGE or USB_KEYBOARD.Signed-off-by: Paul Kocialkowski
-
USB-related options are usually prefixed with CONFIG_USB and platform-specific
adaptation for the MUSB controller already have a CONFIG_USB_MUSB prefix, so
this switches all MUSB-related options to a CONFIG_USB_MUSB prefix, for
consistency.Signed-off-by: Paul Kocialkowski
-
There is no particular reason why the USB Kconfig option should be specific to
host mode. In prevision of adding MUSB host and gadget to Kconfig, this moves
the title and help message of the USB Kconfig option to a more generic format.Adding comments to the usb Kconfig allows for a better separation and more
readability in generated configs and in menuconfig.Signed-off-by: Paul Kocialkowski
-
The USB_ARCH_HAS_HCD currently serves no purpose and adds some confusion to the
required Kconfig options that are required to have USB support.Dropping it makes things easier and doesn't break anything, since it was unused
anyways.Signed-off-by: Paul Kocialkowski
-
This patch makes the dwc2 controller like ehci / ohci / xhci controllers
by calling the board_usb_init() function from usb_lowlevel_init.This can then be implemented by specific platforms to initialise
their USB hardware (phys / clocks etc).Signed-off-by: Peter Griffin
04 Aug, 2015
24 commits
-
This patch replaces not existing addr_uboot environment variable by
loadaddr at get_uboot_net and burn_uboot_xxx commands. Otherwise these
commands are broken.Signed-off-by: Vitaly Andrianov
Acked-by: Nishanth Menon -
Add USB XHCI support for ls2085rdb platform
Signed-off-by: Nikhil Badola
Reviewed-by: York Sun -
Add USB XHCI support for ls2085qds platform
Signed-off-by: Nikhil Badola
Reviewed-by: York Sun -
Define base address of both usb xhci controllers in lsch3 config
in the format (IMMR + offset) for LS2085ASigned-off-by: Nikhil Badola
Reviewed-by: York Sun -
Define CONFIG_SYS_CACHELINE_SIZE for LS2085A which is required by
USB XHCI stack for alignmentSigned-off-by: Nikhil Badola
Reviewed-by: York Sun -
By default the bstopre value has been set to 0x100, used to be 1/4
value of refint. Modern DDR has increased the refresh time. Adjust
to 1/4 of refresh interval dynamically. Individual board can still
override this value in board ddr file, or to use auto-precharge.Signed-off-by: York Sun
-
Signed-off-by: Horia Geantă
Acked-by: Ruchika Gupta
Reviewed-by: York Sun -
HW coherency won't work properly for CAAM write transactions
if AWCACHE is left to default (POR) value - 4'b0001.
It has to be programmed to 4'b0010.For platforms that have HW coherency support:
-PPC-based: the update has no effect; CAAM coherency already works
due to the IOMMU (PAMU) driver setting the correct memory coherency
attributes
-ARM-based: the update fixes cache coherency issues,
since IOMMU (SMMU) driver is not programmed to behave similar to PAMUFixes: b9eebfade974c ("fsl_sec: Add hardware accelerated SHA256 and SHA1")
Signed-off-by: Horia Geantă
Reviewed-by: Aneesh Bansal
Reviewed-by: Mingkai Hu
Acked-by: Ruchika Gupta
Reviewed-by: York Sun -
Use fdt_setprop_u32() instead of fdt_setprop().
Fixes: 0181937fa371a ("crypto/fsl: Add fixup for crypto node")
Signed-off-by: Horia Geantă
Reviewed-by: Mingkai Hu
Acked-by: Ruchika Gupta
Reviewed-by: York Sun -
The patch will initialize PCIe controller on EP mode
1. Setup bar:
bar0 32bit 4K for specific configuration
bar1 32bit 8K for MSIX
bar2 64bit 4K for descriptor of memory
bar4 64bit 1M for DMA memory test
2. Setup iATU:
iATU inbound 0-3 to map bar transaction to memory address
started at CONFIG_SYS_PCI_EP_MEMORY_BASE
iATU outbound 0 to map 4G memory spaceSigned-off-by: Minghuan Lian
Reviewed-by: York Sun -
PCIe extends device's configuration space to 4k and provides
extended capability. The patch adds function to find them.
The code is ported from Linux PCIe driver.Signed-off-by: Minghuan Lian
Reviewed-by: Bin Meng
Reviewed-by: York Sun -
MC firware version 8.0.0 contains new command flags. This patch
contains modifications in FLIB files to support the new command flags.Signed-off-by: Itai Katz
Signed-off-by: Prabhakar Kushwaha
Reviewed-by: York Sun -
The sampling of the oscillator can be done in multiple modes for
generating the entropy value. By default, this is set to von
Neumann. This patch changes the sampling to raw data, since it
has been discovered that the generated entropy has a better
'quality'.Signed-off-by: Alex Porosanu
Acked-by: Ruchika Gupta
Reviewed-by: York Sun -
The entropy delay (the length in system clocks of each
entropy sample) for the RNG4 block of CAAM is dependent
on the frequency of the SoC. By elaborate methods, it
has been determined that a good starting value for all
platforms integrating the CAAM IP is 3200. Using a
higher value has additional benefit of speeding up
the process of instantiating the RNG, since the entropy
delay will be increased and instantiation of the RNG
state handles will be reattempted by the driver. If the
starting value is low, for certain platforms, this can
lead to a quite lengthy process.
This patch changes the starting value of the length of
the entropy sample to 3200 system clocks.
In addition to this change, the attempted entropy delay
values are now printed on the console upon initialization
of the RNG block.Signed-off-by: Alex Porosanu
Acked-by: Ruchika Gupta
Reviewed-by: York Sun -
The rtfrqmax & rtfrqmin set the bounds of the expected frequency of the
oscillator, when SEC runs at its maximum frequency. For certain platforms
(f.i. T2080), the oscillator is very fast and thus if the SEC runs at
a lower than normal frequency, the ring oscillator is incorrectly detected
as being out of bounds.This patch effectively disables the maximum frequency check, by setting a
high enough maximum allowable frequency for the oscillator. The reasoning
behind this is that usually a broken oscillator will run too slow
(i.e. not run at all) rather than run too fast.Signed-off-by: Alex Porosanu
Acked-by: Ruchika Gupta
Reviewed-by: York Sun -
To improve eTSEC performance on LS1021A Rev2.0,
snooping of all transmit frames from memory and
all transmit BD memory accesses in enabled.Signed-off-by: Alison Wang
Reviewed-by: York Sun -
On LS1021A Rev2.0, OCRAM's security level needs to be changed to
non-secure access for SD boot. This patch will allow OCRAM
access permission as R/W in SPL.Signed-off-by: Alison Wang
Reviewed-by: York Sun -
Bootrom will put cpus into WFE state when boot cpu release cpus, so
target cpu cannot correctly go to spin state.Add 'sev' to wakeup non-boot cpu that hold on bootrom space, let target
cpu can fall into u-boot spin table.Signed-off-by: Wang Dongsheng
Reviewed-by: York Sun -
Program the external regulator to switch off voltage in deep sleep.
Signed-off-by: Chenhui Zhao
Acked-by: Alison Wang
Reviewed-by: York Sun -
Signed-off-by: Tang Yuantian
Acked-by: Alison Wang
Reviewed-by: York Sun -
Enable bootscript support in secure boot for establishing
chain of trust on LS1021atwr.Signed-off-by: Gaurav Rana
Reviewed-by: York Sun -
strncpy is safer than strcpy, use it to instead of strcpy.
Signed-off-by: Zhao Qiang
Reviewed-by: York Sun -
when using printf, the parameter type need to be compatible
type, so transform them to compatible typeSigned-off-by: Zhao Qiang
Reviewed-by: York Sun -
For ls1021a, Reserve secure code in to memory in case OCRAM
is needed by other usage.Signed-off-by: Zhuoyu Zhang
Acked-by: Alison Wang
Reviewed-by: York Sun
03 Aug, 2015
1 commit
-
Signed-off-by: Tom Rini
02 Aug, 2015
1 commit
-
This function is called from esdhc_send_cmd so we need it available to
everyone.Signed-off-by: Tom Rini