Commit graph

35574 commits

Author SHA1 Message Date
Gokul Sriram Palanisamy
0564bbf6f9 tzt: Enabled exectzt for ipq40xx with dcache off
Change-Id: I9eec6dc9dc659808757aa1197ae09d708ffbf1c2
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-07-10 02:34:16 -07:00
Linux Build Service Account
84705ce4b0 Merge "ipq: mmc: call board_flash_protect based on board's flashtype" 2018-07-09 22:34:10 -07:00
Linux Build Service Account
75776384b9 Merge "ipq40xx: mmc: Added check for status of sdhci node" 2018-07-09 22:34:10 -07:00
Balaji Jagadeesan
9e96ab7e28 ipq40xx: mmc: Added check for status of sdhci node
Currently, we search for "sdhci" node and continue with
mmc_init if it is present. We never check for status of
the sdhci node. As sdhci node is present in all the
board variants, mmc_init happens in all boards.

So, added a check to see if the status of sdhci node is
"okay" and continue with initialization, else return.

fdtdec_get_is_enabled library function checks only for
string "okay" which is the correct usage for status
variable. So, changed the status string in the
dts files accordingly.

Change-Id: I26ac5d9930b9e91e3d9d2436eff0cf02b8977b2e
Signed-off-by: Balaji Jagadeesan <bjagadee@codeaurora.org>
2018-07-09 14:51:44 +05:30
Balaji Jagadeesan
0f86dd5445 ipq: mmc: call board_flash_protect based on board's flashtype
Call board_flash_protect only if the primary/secondary boot
type of the board is mmc.

Change-Id: Ib6f1251a7435a08d647909202c6570c383a64311
Signed-off-by: Balaji Jagadeesan <bjagadee@codeaurora.org>
2018-07-06 18:19:42 +05:30
Balaji Jagadeesan
70dae9d948 ipq40xx: dts: Remove sdhci gpio entries in DK06 and DK07
In DK06, there is no h/w support for mmc and sd.
In DK07, there is no h/w support for mmc and no support
for sd in uboot.
So, removing the sdhci entries from dts.

Change-Id: I39ac2fa56745d1ee3c23be5d8acd3ce5c355a135
Signed-off-by: Balaji Jagadeesan <bjagadee@codeaurora.org>
2018-07-06 00:38:03 -07:00
Antony Arun T
74e17d6a35 arm: qca: enable dcache command
Change-Id: I1847b41ef9e55f0e18589cf3637d3f8dcc282562
Signed-off-by: Antony Arun T <antothom@codeaurora.org>
2018-07-05 18:08:11 +05:30
Linux Build Service Account
d21e486821 Merge "ipq40xx: Device tree support for AP.DK07.1-C4" 2018-06-28 15:35:24 -07:00
Linux Build Service Account
12318cc099 Merge "fdt_fixup: Added debug prints" 2018-06-28 07:34:58 -07:00
Linux Build Service Account
df56f1eb9d Merge "fdt_fixup: Fixed TCSR_USB_HSPHY_DEVICE_MODE" 2018-06-28 07:34:43 -07:00
Gokul Sriram Palanisamy
2c0d86570c fdt_fixup: Added debug prints
Change-Id: Ie76240fc029616e0bb9d2ebbcfe9200a77ac3a63
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-06-28 10:27:15 +05:30
Gokul Sriram Palanisamy
6ad0cd2205 fdt_fixup: Added SoC info fixup
Extended SoC major and minor version fixup
to kernel device-tree on IPQ8064 and IPQ4019.
Also includes cpu_type fixup for IPQ4019.

Find two new entries in the root-node:
soc_version_major, soc_version_minor

Change-Id: I99210aefdc578890b62779d253764b82fe47c543
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-06-27 19:38:11 +05:30
Gokul Sriram Palanisamy
0517d2687f fdt_fixup: Fixed TCSR_USB_HSPHY_DEVICE_MODE
Change-Id: Ifd58bf211c30c7e39bfb3b96abbba8a1a51f79fa
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-06-27 11:12:44 +05:30
Linux Build Service Account
d2267ec5cd Merge "ipq40x: Added multicore support" 2018-06-26 03:01:33 -07:00
Santan Kumar
b7af9b06d2 ipq40x: Added multicore support
-Device IO commands are not supported
-CPU down is supported by waiting in loop
-Need reboot to execute bootipq command

Change-Id: Id10eef0c8e5feb636716461c58ba1640dfe46658
Signed-off-by: Santan Kumar <santank@codeaurora.org>
2018-06-25 05:55:03 -07:00
Sham Muthayyan
f0321e1c5f ipq807x: Enable ethernet support for HK08
-Add 8031 phy and Aquantia phy

Change-Id: I69118be6a358ac9ea7b1cf6e793ed3343e174e39
Signed-off-by: Sham Muthayyan <smuthayy@codeaurora.org>
2018-06-25 15:42:00 +05:30
Sham Muthayyan
8d9a453c47 ipq807x: Add uncahed alloc support for edma driver
TX and RX descriptors are 16 bytes. This causes problems with the cache
maintenance on CPUs where the cache-line size exceeds the size of these
descriptors. What will happen is that when the driver receives a packet
it will be immediately requeued for the hardware to reuse. The CPU will
therefore need to flush the cache-line containing the descriptor, which
will cause all other descriptors in the same cache-line to be flushed
along with it. If one of those descriptors had been written to by the
device those changes (and the associated packet) will be lost.

To work around this, we make use of non-cached memory if available. If
descriptors are mapped uncached there's no need to manually flush them
or invalidate them.

Change-Id: I7b8a9a55226dfdcbab49a93bcdf43af4d70c108a
Signed-off-by: Sham Muthayyan <smuthayy@codeaurora.org>
2018-06-22 02:39:51 -07:00
Abhishek Sahu
2f4701e58b ipq: board: fix build error if ubifs is enabled
UBIFS has add_node function and FDT dynamic patch has
add_node global variable which generates link error.

Change-Id: I5e1350c6280a0ecb0906743fc93563cf5b106d42
Signed-off-by: Abhishek Sahu <absahu@codeaurora.org>
2018-06-21 00:17:36 -07:00
Linux Build Service Account
294f6eb36d Merge "runmulticore: Added secondary core status prints" 2018-06-20 07:09:28 -07:00
Gitanjali Krishna
3cc4f89b3d ipq40xx: Device tree support for AP.DK07.1-C4
This change enables u-boot support for AP.DK07.1-C4 configuration.
AP.DK07.1-C4 enables QCA402x IOT support

Change-Id: I5982b8f8783755b03d11c878f8108d71e6ace6d1
Signed-off-by: Gitanjali Krishna <gitanjal@codeaurora.org>
2018-06-19 20:20:56 -07:00
Gokul Sriram Palanisamy
e7dbf7657c runmulticore: Added secondary core status prints
Change-Id: I16b88abfbd2e518ce6259e3a5f0329303462389f
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-06-19 14:28:39 +05:30
Vinoth Gnanasekaran
bb7513767e ipq806x: Secondary core boot address gets decided dynamically
'forever' (Infinite while loop) function gets called in dump
collection path. 'ak_secondary_cpu_init' function gets called
in runmulticore path.

Change-Id: Ie7bcf618fd6da5ce968954db538ae345c4f43d92
Signed-off-by: Vinoth Gnanasekaran <vgnana@codeaurora.org>
2018-06-14 12:25:38 +05:30
Linux Build Service Account
4459f567fa Merge "ipq807x: Enabled napa phy for HK07" 2018-06-13 13:06:51 -07:00
Linux Build Service Account
ec287410de Merge "ipq807x: DTS support for HK09, AC01.1, AC01.2" 2018-06-13 06:37:34 -07:00
Kathiravan T
787612bfba ipq: enable the support to authenticate the signed images
This patch enables the support to authenticate the signed images
before flashing through the 'secure_authenticate' command.

Also, changes have been done for compatibility with the 64Bit TZ variants.

Change-Id: I0972b481b826c9594367eda31a2e9c87566db705
Signed-off-by: Kathiravan T <kathirav@codeaurora.org>
2018-06-12 04:54:26 -07:00
Sham Muthayyan
8550018c8e ipq807x: Enabled napa phy for HK07
Change-Id: I1865a8336fc9763e1c541f5b6346ddbce7cb6eb9
Signed-off-by: Sham Muthayyan <smuthayy@codeaurora.org>
2018-06-11 07:20:22 -07:00
Sham Muthayyan
b8f8d40827 ipq807x: Add qca8081 phy support
Change-Id: I09093ee3351066aa55f70012459512ae4cbcb23f
Signed-off-by: Sham Muthayyan <smuthayy@codeaurora.org>
2018-06-11 07:19:54 -07:00
Nikhil Prakash V
9bddf3451b ipq807x: DTS support for HK09, AC01.1, AC01.2
Change-Id: Id74932004e2844a503237dee30b6655264d06748
Signed-off-by: Nikhil Prakash V <nprakash@codeaurora.org>
2018-06-11 13:09:28 +05:30
Linux Build Service Account
5080bfea38 Merge "dcache: Skipping dcache flush when no destination pointer" 2018-06-08 12:37:39 -07:00
Linux Build Service Account
502cc89ea4 Merge "ipq40xx: Removed dk04-c5.dtb entry" 2018-06-08 07:56:48 -07:00
Linux Build Service Account
315f1e32fa Merge "usb: hub: Translate USB 3.0 hub port status into old version" 2018-06-08 07:56:44 -07:00
Gokul Sriram Palanisamy
563590e559 dcache: Skipping dcache flush when no destination pointer
In imxtract, if destination pointer is not given,
skipping dcache flush at the destination pointer
to avoid null-pointer issue.

Change-Id: I4dc08bd35c4ffb083ab0c646961644560fbf4c1a
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-06-08 17:50:42 +05:30
Linux Build Service Account
71e72eff91 Merge "ipq807x: Device tree support in u-boot for HK08" 2018-06-07 09:36:04 -07:00
Linux Build Service Account
365124f20d Merge "ipq40xx: mmc: Added erase quirk for eMMC part" 2018-06-07 03:08:43 -07:00
Linux Build Service Account
e4fb3ba942 Merge "usb: hub: Add a new API to test if a hub device is root hub" 2018-06-07 03:08:42 -07:00
Nikhil Prakash V
a05866dad9 ipq807x: Device tree support in u-boot for HK08
Adding device tree support for HK08 in u-boot-2016.

Change-Id: I30d653e0dcb5a0f2da453360f7255edd153c6606
Signed-off-by: Nikhil Prakash V <nprakash@codeaurora.org>
2018-06-07 13:00:51 +05:30
Rajkumar Ayyasamy
e269b5a3ac ipq40xx: Removed dk04-c5.dtb entry
To use u-boot-2016 in DK04-C5 (Spi nor + Spi nand),
dk04-c5.dtb can be added

Change-Id: Id61a0d4d03b5e1482eca5572e73ed42fca175bc9
Signed-off-by: Rajkumar Ayyasamy <arajkuma@codeaurora.org>
2018-06-07 12:28:55 +05:30
Abhishek Sahu
961d3301a2 mtd: nand: qcom: support for non-page aligned read start address
Currently, the nand driver expects the start address to be page
aligned. This patch adds the support for reading data from
non-page aligned start address by using intermediate buffer.

1. Determine the number of pages with start address and
   length.
2. Do the full page read for all the pages. For first page,
   check the start address and determine the column. If column is
   non-zero then use the intermediate buffer for page data and copy
   the required number of bytes from this intermediate buffer to
   actual buffer.

Change-Id: I05a4b98547c83f785096027596cedd83a283edd8
Signed-off-by: Abhishek Sahu <absahu@codeaurora.org>
2018-06-06 23:02:13 -07:00
Vinoth Gnanasekaran
4dc439fee1 ipq40xx: mmc: Added erase quirk for eMMC part
eMMC part THGBMBG5D1KBAIT is taking long time for the secure trim.
This leads to erase timeout. Manufacturer ID based quirk is added
for the specific part to use trim instead of secure trim for block erase.

Change-Id: Id4ecfde9585e112521863439f684feb5e0caaa51
Signed-off-by: Vinoth Gnanasekaran <vgnana@codeaurora.org>
2018-06-06 22:03:38 -07:00
Linux Build Service Account
9f318b6fca Merge "bootqca: Avoiding SPI NOR being read as psudo-NAND" 2018-06-06 10:07:48 -07:00
Gokul Sriram Palanisamy
65a407ecf8 bootqca: Avoiding SPI NOR being read as psudo-NAND
When SPI NOR is treated as psudo-nand,
SPI-NOR gets stuck in 3-byte mode
causing reads at incorrect offssets.

Change-Id: I062bce4755ee1b7be0d8dcc88ae9d5412143b6e1
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-06-06 18:14:21 +05:30
Bin Meng
0854db78bc usb: hub: Translate USB 3.0 hub port status into old version
USB 3.0 hub port status field has different bit positions from 2.0
hubs. Since U-Boot only understands the old version, translate the
new one into the old one.

Since we are going to add USB 3.0 hub support, this feature is only
available with driver model USB.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
(cherry picked from commit 74ffc7cbb1)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Conflicts:
	common/usb_hub.c

Change-Id: I0456a1753f879592572ea40bc352d943065f8666
2018-06-05 15:55:12 +05:30
Bin Meng
d7842cf5dd usb: hub: Add 3.0 hub port status mask of 2.0 hub
USB 3.0 hub port status has different bit position regarding to
port power, port speed, etc. But others are the same as 2.0 hubs.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Stefan Roese <sr@denx.de>
Tested-by: Stefan Roese <sr@denx.de>
(cherry picked from commit 98ba3d6c23)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Change-Id: I77b72af7669aa05070ebacd1d95123413761c11c
2018-06-05 15:40:29 +05:30
Bin Meng
1bc23dd4ce usb: xhci: Program 'route string' in the input slot context
xHCI spec says: the values of the 'route string' field shall be
initialized by the first 'Address Device' command issued to a
device slot, and shall not be modified by any other command.

So far U-Boot does not program this field, and it does not prevent
SS device directly attached to root port, or HS device behind an HS
hub, from working, due to the fact that 'route string' is used by
the xHC to target SS packets. But in order to enumerate devices
behind an SS hub, this field must be programmed.

With this commit and along with previous commits, now SS & HS devices
attached to a USB 3.0 hub can be enumerated by U-Boot.

As usual, this new feature is only available when DM is on.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
(cherry picked from commit 493b8dd070)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Change-Id: I367a0f1fa5e310c1c6af2d4675a86a3293337d64
2018-06-05 15:40:00 +05:30
Bin Meng
3db02616a7 usb: hub: Support 'set hub depth' request for USB 3.0 hubs
USB 3.0 hub uses a hub depth value multiplied by four as an offset
into the 'route string' to locate the bits it uses to determine the
downstream port number. We shall set the hub depth value of a USB
3.0 hub after it is configured.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
(cherry picked from commit bbc6f06c00)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Conflicts:
	include/usb.h

Change-Id: I7fa67c83c854c136fa9401201189e0597912e2a8
2018-06-05 15:37:56 +05:30
Bin Meng
f345bf9517 usb: xhci: Change xhci_setup_addressable_virt_dev() signature
For future extension, change xhci_setup_addressable_virt_dev()
signature to accept a pointer to 'struct usb_device', instead
of its members slot_id & speed, as the struct already contains
these two plus some other useful information of the device.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
(cherry picked from commit daec469144)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Change-Id: Ibd7991073f0de4a97babbd9a96270f53f77cb185
2018-06-05 15:30:23 +05:30
Bin Meng
a4aff629f3 usb: hub: Use 'struct usb_hub_device' as hub device's uclass_priv
Use USB hub device's dev->uclass_priv to point to 'usb_hub_device'
so that with driver model usb_hub_reset() and usb_hub_allocate()
are no longer needed.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
(cherry picked from commit dfa96e0676)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Conflicts:
	common/usb_hub.c

Change-Id: I7a46a12c62aa7429ef2241c9543dd877abe6ac0b
2018-06-05 15:27:08 +05:30
Bin Meng
b09471d0e0 usb: hub: Add a new API to test if a hub device is root hub
Sometimes we need know if a given hub device is root hub or not.
Add a new API to test this. This removes the xHCI driver's own
version is_root_hub() and change to use the new API.

While we are here, remove the unused/commented out get_usb_device()
in the xHCI driver too.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
(cherry picked from commit 46c1d49330)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Change-Id: Ia27ee3b541f936e3eebf6ecb57c3499c08da3781
2018-06-05 15:21:48 +05:30
Bin Meng
28468cd710 usb: hub: Change USB hub descriptor to match USB 3.0 hubs
USB 3.0 hubs have a slightly different hub descriptor than USB 2.0
hubs, with a fixed (rather than variable length) size. Change the
host controller drivers that access those last two fields
(DeviceRemovable and PortPowerCtrlMask) to use the union.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Stefan Roese <sr@denx.de>
Tested-by: Stefan Roese <sr@denx.de>
(cherry picked from commit 337fc7e665)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Change-Id: I4ee4c866f4d35fea3ecf6431b90cec1af121fe29
2018-06-05 15:21:39 +05:30
Bin Meng
0fb9d498ff usb: hub: Send correct wValue to get hub descriptor of a USB 3.0 hub
Testing a USB 3.0 hub by connecting it to the xHCI port on Intel
MinnowMax, when issuing 'get hub descriptor' to the hub, xHCI
reports a transfer event TRB with a completion code 6 which means
'Stall Error'.

In fact super speed USB hub descriptor type is 0x2a, not 0x29.
Sending correct SETUP packet to the hub makes it not stall anymore.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Stefan Roese <sr@denx.de>
Tested-by: Stefan Roese <sr@denx.de>
(cherry picked from commit f342119602)
Signed-off-by: Santan Kumar <santank@codeaurora.org>

Change-Id: I105e81557ec4097e6fafafdd2e2b5ecffb75b56b
2018-06-05 15:21:17 +05:30