Commit graph

3860 commits

Author SHA1 Message Date
Venkat Raju Sana
d0efe15871 MINIDUMP: Add check for dump_minimal env variable
dump_minimal env variable  is not currently
validated against junk characters. This check enables
minimal dump only when it  is set to 1.

Change-Id: I62a32ae1fc5c9355321c7b5ba2f6a96d8e890c50
Signed-off-by: Venkat Raju Sana <vrsana@codeaurora.org>
Signed-off-by: Venkat Raju Sana <vrsana@codeaurora.org>
2019-07-30 22:45:09 -07:00
Antony Arun T
6cc115dc59 ipq6018: reset: fixing reset flow after dump collection into flash
in ipq6018, instead of going for warm reset after collecting dump into flash,
checking wonce register and deciding whether to go for warm/cold reboot.

Change-Id: I6537d7455e6922467b4727f95e62ad0f2fc54295
Signed-off-by: Antony Arun T <antothom@codeaurora.org>
2019-07-19 16:13:50 +05:30
Sandhya
0b984e927c Fix compiler warnings: Indentation
Change-Id: I9786e6350b77b810ec676bfb770f14a559b67514
Signed-off-by: Sandhya <sandhyks@codeaurora.org>
2019-06-26 10:24:59 +05:30
sameeruddin shaik
f0822eadeb uboot: Fix compiler warnings in u-boot-2016
This change will fix the following warnings.
1.-Wmaybe-uninitialized

Change-Id: I353962197b9160e7d15d6cb48b67982e42120df2
Signed-off-by: sameeruddin shaik <samesh@codeaurora.org>
2019-06-19 13:03:29 +05:30
Linux Build Service Account
88fdb5c2bb Merge "u-boot-2016: Fix compiler warnings" 2019-06-18 17:05:09 -07:00
Md Sadre Alam
f2ed166473 driver: mtd: Add support to read entire ONFI parameter page structure.
This change will read entire ONFI parameter page. This will helpful
while validating new ONFI AVL part.

To read entire ONFI parameter page data structure use command:

"#nand onfipara".

Change-Id: Icea80fce6900716871d8c82a2d1ac0c00531af98
Signed-off-by: Md Sadre Alam <mdalam@codeaurora.org>
2019-06-11 22:51:13 +05:30
Gitanjali Krishna
9af31feb8b u-boot-2016: Fix compiler warnings
Change-Id: I1bf55699f4767de381c3875a0a3d84177a87282e
Signed-off-by: Gitanjali Krishna <gitanjal@codeaurora.org>
2019-06-10 14:50:33 -07:00
Md Sadre Alam
f80127f8a7 common: cmd_boot: Add stack canary test command.
This change will add stack canary test command in
u-boot command list.

The stack canary test command format like as :
canary <string>. The string must be 10 bytes long.

e.g
" #canary Helloworldhelloworld".

After this command we can see the below print.
Stack Canary test start.
stack-protector: U-boot stack is corrupted.
Resetting CPU ...

If stack-protection not enabled and stack overflow
occure then we will get the following print.

prefetch abort
pc : [<4a006f72>]          lr : [<4a90faf0>]
reloc pc : [<4a006f72>]    lr : [<4a90faf0>]
sp : 4a77f948  ip : 20f14495     fp : 4a90fab4
r10: 00000002  r9 : 4a77fea0     r8 : 00000000
r7 : 4a983d20  r6 : 6f6f6f6f     r5 : 6f6f6f6f  r4 : 6f6f6f6f
r3 : 00000000  r2 : 4a77f946     r1 : 4a78233b  r0 : 00000000
Flags: nZCv  IRQs off  FIQs off  Mode SVC_32
Resetting CPU ...

Change-Id: If36d1da3ecc1d0038cd1a6bad6ab3d265b47dac8
Signed-off-by: Md Sadre Alam <mdalam@codeaurora.org>
2019-06-10 11:48:03 +05:30
Pavithra Palanisamy
b7239058e9 ipq: Enable crashdump collection in usb device
This change enables support to collect crashdump files
in connected usb storage device on requirement.

Change-Id: If191bcae5329dd2c9e84035069e4d9b0e73b546b
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2019-05-30 20:17:55 +05:30
Pavithra Palanisamy
42a29e7793 ipq: Flash command code cleanup
Change-Id: I54b8677cba4b8a63b245bde8f1840d146d6694ee
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2019-05-28 16:19:55 +05:30
Pavithra Palanisamy
4bb8ae0f50 ipq: Add check to avoid overwriting successive partitions
This change adds a check to detect if the size of image to be flashed
fits within the respective partition region.

Change-Id: I794262fa759eef4ecc726252fb3d234c087f2b4d
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2019-04-30 15:51:39 +05:30
Venkat Raju Sana
2e7684f3f9 ip1807x:Initial commit for Minidump
Change-Id: If08d31ebb009d6b37ee55861644ab1f11a46ac98
Signed-off-by: Venkat Raju Sana <vrsana@codeaurora.org>
2019-03-29 12:47:06 -07:00
sameeruddin shaik
8338952d77 ipq807x: Fix compiler warnings in u-boot
Change-Id: Icd0c082fcc5d191745e4e4242dda5a7f3b22c4f0
Signed-off-by: sameeruddin shaik <samesh@codeaurora.org>
2019-01-22 12:57:57 +05:30
sameeruddin shaik
f2741fbe5a ipq806x: Disable relocation in uboot-2016
This change will resolve the "L2 Master port decode error"
 print in the Kernel log.

Change-Id: I12fd39a85093cc1d7fab336898e039a61eeb5565
Signed-off-by: sameeruddin shaik <samesh@codeaurora.org>
2018-11-29 10:54:48 +05:30
Antony Arun T
1c7d57b963 ipq6018: Skip uboot relocation and setup CP15 barrier
Change-Id: I29ced10a3ab0f36a06bdbb642f6b73ab287e8d6d
Signed-off-by: Antony Arun T <antothom@codeaurora.org>
2018-11-20 14:53:15 +05:30
Pavithra Palanisamy
15456d8ba6 qca : Add u-boot CLI command "flasherase"
The "flasherase" command can be used to erase partitions in flash.

Change-Id: I1111f3a626c3a36bcef57079a10c5d6be4e1e8df
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2018-11-16 11:39:22 +05:30
Gokul Sriram Palanisamy
dd315b2f72 ipq807x: Removed unused commands to reduce footprint
Change-Id: Idc83e732de310c63e8f8acba281b1bd2bf78828e
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-11-12 19:46:39 +05:30
Nikhil Prakash V
8438ea4b9b ipq807x: Adding SOC version to default env.
Adding soc_version_major and soc_version_minor to the default
environment.

Change-Id: I38ee6dd228382111beaa2bdacfade1e3d2c989de
Signed-off-by: Nikhil Prakash V <nprakash@codeaurora.org>
2018-11-09 16:29:18 +05:30
Pavithra Palanisamy
7fb1dc8e4c qca: KW fix for flash command
Change-Id: I330bee105bfd9f27d63f907d179e3561c25ca614
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2018-09-06 17:51:43 +05:30
Pavithra Palanisamy
8093a5448b ipq: Modified flash command with simplified parameters.
This change removes the "default" option in existing flash command
and makes use of environment variables in default case.

Change-Id: Ibc6ed68043acc708323b90132686cecf7f2f0d82
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2018-09-03 19:58:29 +05:30
Pavithra Palanisamy
89895d3766 qca: Change for fixing KW issue
Change-Id: I517bbec630f7a57830f51500535615461d37d3e1
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2018-08-13 12:30:38 +05:30
Pavithra Palanisamy
8160116212 qca: Fix KW issues with flashwrite command
Change-Id: Ia5b6ef5cbdf27a0a46f56445ee9335bb72353c63
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2018-07-27 18:56:24 +05:30
Pavithra Palanisamy
316e48fb0d qca: Add uboot-CLI command "flash"
The "flash" command erases given partition and
writes the image to flash.

Change-Id: I059414fd3d7eefeac0c626e1980a70985f2de986
Signed-off-by: Pavithra Palanisamy <pavip@codeaurora.org>
2018-07-13 19:48:38 +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
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
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
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
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
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
Santan Kumar
c90a856ac3 ipq806x: Added multicore support
-Device IO commands are not supported
-CPU down is temporary supported by WFE instruction
-Need reboot to execute bootipq command

Change-Id: Ic7f1dece29e29f75b984018bcf1fc5f724282567
Signed-off-by: Santan Kumar <santank@codeaurora.org>
2018-04-27 11:47:47 +05:30
Gokul Sriram Palanisamy
201def52b9 ARM: mmc: Added power-on write protection support
Change-Id: Iba7e4bfcbee3f5106ef7d0ecc64e8af175732f7c
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-03-12 05:25:56 -07:00
Gokul Sriram Palanisamy
ee2ddf9dc2 env_nand: Updated erase size to partition size
erase complete partiton size, board_env_size.

Change-Id: Ib0f7e65f49fbd29cd265f5ff12cd03424db61227
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-03-08 18:46:30 +05:30
Nikhil Prakash V
e47694ebe8 ipq807x: Changes for fixing kw issues
Adding nullpointer condition checks before the pointer
is accessed or passed to a function as argument.

Change-Id: I6848c132076708f69fad00a75e42a1c2f33b6215
Signed-off-by: Nikhil Prakash V <nprakash@codeaurora.org>
2018-03-06 14:06:48 +05:30
Linux Build Service Account
9dbc4f95f1 Merge "ipq40xx: nand: Initialize nand flash device before flashing" 2018-02-27 02:16:52 -08:00
Antony Arun T
4ca40fa90d SF: Bulk Erase command support for spansion
Change-Id: Ida70d167cafc6af823f31c660d108cc25be6edff
Signed-off-by: Antony Arun T <antothom@codeaurora.org>
2018-02-23 13:10:34 +05:30
Balaji Jagadeesan
23dfc73b5b ipq40xx: nand: Initialize nand flash device before flashing
The DK01 board will be bricked if a nand image is flashed onto it.
Because it supports only nor and nor_plus_nand flash types.
So, this patch detects the nand flash before flashing.

Change-Id: I0e0ce2f4d72bcd6724847729170562068a00394d
Signed-off-by: Balaji Jagadeesan <bjagadee@codeaurora.org>
2018-02-22 15:47:51 +05:30
Antony Arun T
1279dad923 ipq806x: Customized environment size handling
To save space in NOR flash, environment loading from flash is
handled differently for NOR and NAND. The size for NOR flash
environment is taken from partition size itself.

Change-Id: I588471b679fad0e96b836d43dc1a0136c5400fc1
Signed-off-by: Antony Arun T <antothom@codeaurora.org>
2018-02-19 16:11:21 +05:30
Linux Build Service Account
58f99d4204 Merge "qca: Add logic to restrict runmulticore command on secondary cores" 2018-02-08 18:36:15 -08:00
Linux Build Service Account
3221496969 Merge "qca: spi-nor: Store the probe information to avoid unnecessary probes" 2018-02-08 15:43:34 -08:00
Santan Kumar
a0dd6f4332 qca: spi-nor: Store the probe information to avoid unnecessary probes
Change-Id: If7260e4a4065d6406d9a8554f43853663f0e8f3b
Signed-off-by: Santan Kumar <santank@codeaurora.org>
2018-02-08 15:58:22 +05:30
Santan Kumar
bf90754ab4 qca: Add logic to restrict runmulticore command on secondary cores
Change-Id: Ibe1bf89614ddadb770cda2216b696152534daaf7
Signed-off-by: Santan Kumar <santank@codeaurora.org>
2018-02-08 01:37:20 -08:00
Nirmala Devi Mal Nadar
0f24b749d6 ipq806x: Skip adding mtdid for invalid mtd device
Modified function to skip adding mtdid list if mtd device is
not found rather than completely returning error.

Change-Id: I515db87802721c1fa1d87b3422eb17eff049e345
Signed-off-by: Nirmala Devi Mal Nadar <nmalna@codeaurora.org>
Signed-off-by: Kirthik Srinivasan <kirthik@codeaurora.org>
Signed-off-by: Nisar Ahamed Khan <nkhan@codeaurora.org>
(cherry picked from commit 4b0ccfab10)
Signed-off-by: Kathiravan T <kathirav@codeaurora.org>
2018-02-06 23:55:50 -08:00
Gokul Sriram Palanisamy
3ad3c2e50c QCA: Enable board reset after crashdump to flash
Added board reset command after crashdump to flash. Also,
updated with valid return values in do_dumpqca_flash_data function.

Change-Id: Ib89ee06cd6e34c0a56090284983534f107c97ea7
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-01-31 19:49:35 -08:00
Gokul Sriram Palanisamy
ebfe553da8 QCA: Crashdump data to flash
If the dump_to_flash environment variable is set with the proper
offset in u-boot, crashdump data will be stored to flash memory.
Otherwise it will be stored in tftp server.

Change-Id: I10ac1016e3dfe6a2fa11a0a67c5774b29c3df67a
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-01-29 13:18:16 +05:30
Gokul Sriram Palanisamy
e1b9106107 ARM: qca: Skipping u-boot prompt during crashdump
If crashdump magic is found, should not allow user
to access u-boot prompt as tz will be in unsecure state.

Change-Id: Icdc94c33fb87664857bafa981950f9768794cf11
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2018-01-10 04:27:44 -08:00
Gokul Sriram Palanisamy
a23d322ca1 eth: Moved eth_initialize to end of autoboot
If autoboot command fails, it returns to prompt
without ethernet initialized. Hence, moved it to
the end of autoboot to make sure ethrernet is
initialized before entering the prompt.

Change-Id: I79ea6f51842c544e9eb3b97bf7658c45feb34f0b
Signed-off-by: Gokul Sriram Palanisamy <gokulsri@codeaurora.org>
2017-12-28 10:51:35 +05:30