1
0
Fork 0
Commit Graph

12640 Commits (zero-sugar)

Author SHA1 Message Date
thomasing cd10002e83
Thomas/epd init (#6)
* Working EPD init sequence.
* Read EPD temperature. Shutdown LCDIF after init.
* Working splash. Splash data is loaded from splash.dat on p1.
* Working grayscale splash screen using external proprietary binary.
* Using temperature to select waveforms. Loading compressed proprietary binary «zplash»
* Check zplash size and crc.
* Init charger before probe_serial_download.
* Renamed epd_init and epd_init.
2019-08-22 15:34:18 +02:00
Luo Ji f39aa82a3d MA-13487 Refine fsl avb functions
Too many macros are used in fsl_avbkey.c and
make it difficult to maintain.
This patch made some refine by:
  1. Move all avb/atx operations to fsl_avb.c.
  2. Refine the functions logic.
  3. Drop some unsupported conditions/functions.

Test: build and boot on
      imx8qm_mek/imx8mq_evk/imx6qp_sabresd/imx7d_pico/imx8m_aiy.

Change-Id: I5c99732acfc47d53cdf188d69223983777e577f4
Signed-off-by: Luo Ji <ji.luo@nxp.com>
2018-11-22 11:02:09 +08:00
Bai Ping 71398b89a0 MLK-20394 imx8mq: Update the ddrc QoS setting for B1 chip
Update the ddrc Qos setting for B1 to align with B0'ssetting.
Correct the initial clock for dram_pll. This setting will be
overwrite before ddr phy training. Although there is no impact
on the dram init, we still need to correct it to eliminate
confusion.

Signed-off-by: Bai Ping <ping.bai@nxp.com>
Reviewed-by: Ye Li <ye.li@nxp.com>
Tested-by: Robby Cai <robby.cai@nxp.com>
(cherry picked from commit 566b798213ab9690966f163de2765acdbfe647a7)
2018-11-20 18:28:22 +08:00
Peng Fan 75a9833506 MLK-20373-5 serial: serial_xen: support normal uboot console
Support output/input using `xl console [domid]`.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Flynn xu <flynn.xu@nxp.com>
2018-11-15 16:36:54 +08:00
Peng Fan aa08894ff4 MLK-20373-2 dm: serial: introduce puts hook
Introduce puts hook for dm serial driver.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Flynn xu <flynn.xu@nxp.com>
2018-11-15 16:36:09 +08:00
Ye Li da3f3a0816 MLK-20356-2 dwc_ahsata: Fix incorrect free
Fix coverity issue CID 43665: Free of address-of expression (BAD_FREE)
incorrect_free: free frees incorrect pointer pp.

pp points the port array field of struct ahci_uc_priv, should not free it.

Signed-off-by: Ye Li <ye.li@nxp.com>
Acked-by: Peng Fan <peng.fan@nxp.com>
2018-11-14 02:02:10 -08:00
Li Jun e66d1fb4f6 MLK-20305 usb: gadget: fastboot: fix GUID data length error
Current code uses strlen of string to get the property data
length, which is wrong for unicode string, also the whole
property length also should be corrected(descriptor length
minus head length, 142-10=132), detail data format of single
GUID see below table:

Table 4a: Microsoft Extended Properties Feature Descriptor
===================================================================
         Value          |       TYPE       |      Description
===================================================================
0x8E, 0x00, 0x00, 0x00  | DWORD (LE)       |  Descriptor length
                        |                  |  (142 bytes)
--------------------------------------------------------------------
0x00, 0x01              |  BCD WORD (LE)   |  Version ('1.0')
--------------------------------------------------------------------
0x05, 0x00              |  WORD (LE)       |  Extended Property
                        |                  |  Descriptor index (5)
--------------------------------------------------------------------
0x01, 0x00              |  WORD (LE)       |  Number of sections (1)
--------------------------------------------------------------------
0x84, 0x00, 0x00, 0x00  |  DWORD (LE)      |  Size of the property
                        |                  |  section (132 bytes)
--------------------------------------------------------------------
0x01, 0x00, 0x00, 0x00  |  DWORD (LE)      |  Property data type
                        |                  |   (1 = Unicode
                        |                  |    REG_SZ,
                        |                  |    see table below)
--------------------------------------------------------------------
0x28, 0x00              |  WORD (LE)       |  Property name
                        |                  |   length (40 bytes)
--------------------------------------------------------------------
0x44, 0x00, 0x65, 0x00, |  NUL-terminated  |  Property name
(...)                   |  Unicode String  |  "DeviceInterfaceGUID"
0x74, 0x00, 0x00, 0x00  |  (LE)            |
--------------------------------------------------------------------
0x4e, 0x00, 0x00, 0x00  |  DWORD (LE)      |  Property data
                        |                  |  length (78 bytes)
--------------------------------------------------------------------
0x7b, 0x00, 0x46, 0x00, |  NUL-terminated  |  Property name
(...)                   |  Unicode String  |  "{xxxxxxxx-xxxx-
0x7d, 0x00, 0x00, 0x00  |  (LE)            |  xxxx-xxxx-
                        |                  |  xxxxxxxxxxxx}\0"
--------------------------------------------------------------------

Details of WCID see below link:
https://github.com/pbatard/libwdi/wiki/WCID-Devices

Reviewed-by: Ye Li <ye.li@nxp.com>
Signed-off-by: Li Jun <jun.li@nxp.com>
2018-11-13 14:11:21 +08:00
Ye Li f85da6b1fc MLK-20240-8 fastboot: Add NULL check for mmc variable
Fix coverity issue CID 5015449: Dereference before null check (REVERSE_INULL)
check_after_deref: Null-checking mmc suggests that it may be null, but it has
already been dereferenced on all paths leading to the check

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-12 20:09:51 -08:00
Ye Li 661bc6ec62 MLK-20240-7 fastboot: Add NULL return check
Fix coverity issue CID 1898965: Dereference null return value (NULL_RETURNS)
dereference: Dereferencing a pointer that might be NULL dev_desc when calling
write_backup_gpt_partitions

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-12 20:09:51 -08:00
Ye Li 7bc5136e52 MLK-20240-6 fastboot: Fix potential buffer overflow
Fix coverity issue CID 3826473: Destination buffer too small (STRING_OVERFLOW)
string_overflow: You might overrun the 16-character destination string buffer by
writing 20 characters from

The size of g_ptable->name is 20, but we use 16 bytes buffer for strcpy. It may
cause buffer overflow.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-12 20:09:51 -08:00
Ye Li cedf379e3d MLK-20240-5 fsl_usdhc: Fix fsl_esdhc_get_cd issue
Fix coverity issue CID 3606685: Structurally dead code (UNREACHABLE)
unreachable: This code cannot be reached: return esdhc_getcd_common

Should not return true directly, otherwise the esdhc_getcd_common is
bypassed.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-12 20:09:51 -08:00
Ye Li 3553a99cc4 MLK-20240-4 pxp: Fix missing break in switch
Fix coverity issue CID 3411367: Missing break in switch (MISSING_BREAK)
unterminated_case: The case for value 1U is not terminated by a 'break' statement.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-12 20:09:51 -08:00
Ye Li fe324483b4 MLK-20240-3 gis: Add NULL pointer check
Fix coverity issue CID 3768406: Dereference null return value (NULL_RETURNS)
dereference: Dereferencing a pointer that might be NULL gis_input when calling strcmp.

The gis_input may returns NULL from env_get, need check it before strcmp.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-12 20:09:51 -08:00
Ye Li 876f435b63 MLK-20240-2 sata: ahsata: Fix wrong operand for checking SERR DIAG_X
Fix coverity issue CID 3261683: Wrong operator used (CONSTANT_EXPRESSION_RESULT)
operator_confusion: ({...; __v;}) | 67108864 is always 1/true regardless of the values
of its operand. This occurs as the logical operand of !

When DIAG_X is set, the PHY COMINIT signal is detected, so should use '&' to check
whether it is set.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-12 20:09:51 -08:00
Ye Li 8f52ef83db MLK-20240-1 sata: ahsata: Fix resource leak
Fix coverity issue CID 3606684: Resource leak (RESOURCE_LEAK)
leaked_storage: Variable uc_priv going out of scope leaks the storage it points to

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-12 20:09:51 -08:00
Ji Luo e48ceaae24 [iot] Update rollback index when slot has been marked as successful
The rollback index should be updated when avb verify pass
and the slot has been marked as successful, update the
rollback index also for those enabled dual bootloader
feature.
This commit also fix some configs condition issue so
read/write rollback index with trusty will work.

Test: rollback index updated successfully on
      imx7d_pico and AIY.

Change-Id: I2344d6462249d8d88f0622d331cdeffc7e12f885
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-11-12 09:18:38 +08:00
Ji Luo 26131b6347 [iot] Calculate VBH in bootloader
SHA256 hash of the entire verified software stack should be calculated
and passed to 'trusty_set_boot_params'. This commit will calculate the
SHA256 hash which represents spl.bin and bootloader.img, and then extend
that hash with the hash of vbmeta image into the final VBH.

Bug: 110905171

Test: VBH is calculated and passed ok on AIY.

Change-Id: Id83ad36f3de79bedd435ca8f26035a35cca66b07
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-11-12 09:18:38 +08:00
Ji Luo b57739cac7 [iot] Support fastboot variable 'at-vboot-state'
Add support for fastboot variable 'at-vboot-state', it's composed
by 6 sub-variable: 'bootloader-locked', 'bootloader-min-versions',
'avb-perm-attr-set', 'avb-locked', 'avb-unlock-disabled' and
'avb-min-versions'.

Test: All 'at-vboot-state' variables are returned
      correctly on imx7d_pico and AIY.

Change-Id: Ibb855cbcc7c41657af62dafb98a96c4dfb96ef22
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-11-12 09:18:37 +08:00
Ji Luo aebefa8046 [iot] Support command 'oem at-disable-unlock-vboot'
Device will be locked permanently after disabling the unlcok vboot, store
the disable unlock vboot status into fuse. Since the fuse write operation
is irreversible so config 'CONFIG_AVB_FUSE' is disabled by default, user
need to add this config manually and run this command again.

Test: Disable unlock vboot bit is set after enabling "CONFIG_AVB_FUSE",
      device was locked permanently after running this command. This is
      verified on both imx7d_pico and AIY.

Change-Id: Iad8991a238763b1d662e33cba65f0b9eb44e97ef
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-11-12 09:18:37 +08:00
Ji Luo c14e9d4e27 [iot] Support lock vboot for Android Things
Supoort "fastboot oem at-lock-vboot" command for Android
Things, this command can only be called after perm-attr
have been fused.

Test: build and boot ok on imx7d_pico and AIY.

Change-Id: Ifcfeb2a38d88c5d12b46a1d9ea61b182ae2e7bcb
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-11-12 09:18:37 +08:00
Ji Luo d4a0dbd9a4 [iot] Support authenticated unlock
Add fastboot commands "fastboot oem at-get-vboot-unlock-challenge"
and "fastboot oem at-unlock-vboot" to support the authenticated
unlock feature for Android Things devices. Use software random
numbers generator to generate the 16 bytes random challenge, it
should be replaced with hardware encrypted random generator when
the TEE part is ready.

Test: Generate unlock challenge by:
        ./avbtool make_atx_unlock_credential
        --output=atx_unlock_credential.bin
        --intermediate_key_certificate=atx_pik_certificate.bin
        --unlock_key_certificate=atx_puk_certificate.bin
        --challenge=my_generated_challenge.bin
        --unlock_key=testkey_atx_puk.pem
      validated the unlock credential successfully on imx7d_pico
      and AIY.

Change-Id: I4b8cee87c9e96924169479b65020a081136681f6
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-11-12 09:18:37 +08:00
Haoran.Wang 41ee143a2d [iot] Support at-attest-dh variable
Per security requirement, attestation of keymaster
supported by Trusty OS should support both P256
and curve25519 algorithm for Diffie-Hellman.

TEST: Works on AIY boards by below commands:
      $fastboot getvar at-attest-dh

Change-Id: I3244f8d8b677222463b4e8fc75412e54dadeb23e
Signed-off-by: Haoran.Wang <elven.wang@nxp.com>
2018-11-12 09:18:36 +08:00
Braden Kell 2081a25561 Fix buffer overflow in kernel cmdline handling
Flashing a signed vbmeta image adds extra
parameters to the kernel command line, overflowing
the buffer and corrupting the global data struct.
Increase the command line buffer size from 512
to 1024 to accomodate the extra data, and change
the sprintf's to snprintf's to prevent this from
happening if more parameters are added later.

This bug was exposed by
Idd55dde79eed793dccdd7319600fbd04e11ca12d.

Bug: 112397808
Test: Device boots with images from console and
      from local build.

Change-Id: If73d04007d54193527e11e11c6ef326110e899b6
2018-11-12 09:18:34 +08:00
Leonid Lobachev 8be00c435e Fix P0/EVT boards boot without serial cable connection.
Change-Id: I5969217e400ab494f9a74662d1d228fcf2e2d465
2018-11-12 09:18:34 +08:00
Ye Li d86096accb MLK-19852 imx: fastboot: eliminate confused print
When booting from NAND/SPINOR/WEIMNOR boot devices, the fastboot will
print "unsupported boot device". This warning is used by android fastboot
when setting its "bootcmd". Since android does not support these devices.
so it gives the warning correctly.
But for BSP normal boot, this warning will bring confuse to users. So
change to check the "bootcmd" before giving such warning.

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
2018-11-06 19:25:58 -08:00
Bai Ping cb43368096 MLK-20163-02 imx8m: ddr: update the dram driver for i.MX8M
Sometimes, SPL need to pass the trained FSP drate to ATF
if DDR PHY bypass mode is not enabled. So add a fsp_table
to pass these info to ATF. additionally, add more clock
frequency point config to support for code reuse for i.MX8MQ.

Signed-off-by: Bai Ping <ping.bai@nxp.com>
2018-11-02 20:50:11 -05:00
Ye Li 477dd3a2cb MLK-20160-1 usb: ehci-mx6: Fix PHY power up issue on iMX8 platforms
On iMX8 platforms like 8QM/QXP, we must power up the USB PHY resource
before accessing the PHY. However, current init flow access the USB PHY
in ehci_mx6_common_init prior than ehci_usb_phy_mode where the PHY is power
up.

Fix the issue by adding ehci_get_usb_phy function to parse the PHY address
from DTB and power up the PHY before ehci_mx6_common_init.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-02 20:50:10 -05:00
Ji Luo 21a49ca83b MA-13295 Fix userdata partition size overflow on imx6/7 platforms
Type "ulong" will be 32 bits long on imx6/7 but we may have
userdate partition more than 4G on 32 bits platforms. Use
"uint64_t" instead of "ulong" here to fix this issue.

Test: Get correct userdata partition size on both imx6dl
      and imx8qxp.

Change-Id: Ia6b242f3998a65b157737e83da0ad3126b689713
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-11-02 20:50:10 -05:00
Ye Li 34cf0e9cb5 MLK-20157 spi: mxc_spi: Fix build warning on ARM64 platforms
When building mxc_spi driver on ARM64 platforms like iMX8MM, get
such build warnings below. Fix it in this patch.

In file included from include/common.h:48:0,
 from drivers/spi/mxc_spi.c:9:
 drivers/spi/mxc_spi.c: In function ‘spi_xchg_single’:
drivers/spi/mxc_spi.c:232:21: warning: cast from pointer to integer of
different size [-Wpointer-to-int-cast]
 _func_, bitlen, (u32)dout, (u32)din);
 ^
 include/log.h:135:26: note: in definition of macro ‘debug_cond’
printf(pr_fmt(fmt), ##args); \
 ^~~~
 drivers/spi/mxc_spi.c:231:2: note: in expansion of macro ‘debug’
debug("%s: bitlen %d dout 0x%x din 0x%x\n",
 ^~~~~
 drivers/spi/mxc_spi.c:232:32: warning: cast from pointer to integer of
different size [-Wpointer-to-int-cast]
 _func_, bitlen, (u32)dout, (u32)din);
 ^
 include/log.h:135:26: note: in definition of macro ‘debug_cond’
printf(pr_fmt(fmt), ##args); \
 ^~~~
 drivers/spi/mxc_spi.c:231:2: note: in expansion of macro ‘debug’
debug("%s: bitlen %d dout 0x%x din 0x%x\n",
 ^~~~~

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
2018-11-02 20:50:09 -05:00
Ye Li 04b813d468 MLK-20154-1 mtd: spi: Add flash id for GD25LQ16
iMX8MM DDR3L validation board uses GD25LQ16, but its id is not in
u-boot flash ids table. Add the new id and parameters into the table.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-11-02 20:50:09 -05:00
Ye Li e92d831e5b MLK-20107 fspi: Keep the module enabled after probe
In flexspi driver, each sf command will disable the module in release bus
function. So reading from flexspi memory-map address using "md" command
can't work. When iMX8MM kicks M4 image to run flexspi NOR XIP,
this causes problem.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-10-29 00:19:06 -07:00
Ye Li d62ffbb7fa MLK-20057 usb: ehci-mx6: Fix usb type issue in DM driver
Currently the clocks and power of USB controller and USB PHY are both
controlled by ehci-mx6 driver in device probe. However, the function
"ehci_usb_ofdata_to_platdata" calls "ehci_usb_phy_mode"
to access PHY registers when "dr_mode" is set to OTG, both "dr_mode" and
"extcon" properties are not set in DTB. This may cause hang at accessing
USB PHY registers if the power and clocks are not enabled.

Change the usb type logic to more clear way:
1. plat->init_type: The requested USB mode type from uplayers
2. priv->init_type: The USB mode type specified by DTB or by the USB ID pin or
   by external controller like tcpc or GPIO.
3. If two init_type are not same, return failure. Align with non-DM driver.
4. USB PHY access is moved after power and clock enabled.

Signed-off-by: Ye Li <ye.li@nxp.com>
2018-10-25 18:34:13 -07:00
Ye Li b12e170792 MLK-20026 caam: Fix CAAM RNG init hang on imx8mq RevA
Found the imx8mq Rev A chip (B0 and B1 chips are ok) boot hang at CAAM RNG init.
The jobring 0 can't complete instantiation descriptor and spins on checking ORSFR_JR0.

In current implementation, the descriptor and jobring input and output base address locate
on TCM, because the driver uses raw_data array in jr_data_st structure as the buffer.
This seems cause the issue. If switched from TCM to OCRAM, the issue will go.

Since accessing TCM by CAAM is not very reliable. Add this patch to use OCRAM for SPL case.
The early malloc is ready on SPL before calling board_init_f. So we can use malloc to allocate
memory instead of the raw_data array.

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
2018-10-23 20:32:59 -07:00
Bai Ping dac64635e9 MLK-19907 imx8m: ddr4: Update the refresh_mode setting
Update the refresh_mode setting. Clear the RFSHCTL3.refresh_mode bit
to set it to normal_mode.

Signed-off-by: Bai Ping <ping.bai@nxp.com>
Reviewed-by: Ye Li <ye.li@nxp.com>
2018-10-12 16:28:56 +08:00
Ji Luo 557981f3ac MA-13048 [AUTO] Support program rpmb key with fastboot command
Add fastboot command "fastboot oem set-rpmb-key" to program the rpmb
key which should be staged first.
Usage:
      1. fastboot stage my-rpmb-key.bin
      2. fastboot oem set-rpmb-key

Test: rpmb key programed successfully on imx8qxp.

Change-Id: I95474a6367eb8ef0db16bb38680975b8c45b84f1
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-10-12 09:02:28 +08:00
Laurentiu Palcu a809d62f20 MLK-19623: change hdmi keep-alive check mechanism
The current keep-alive check mechanism uses a static variable that is
initialized to 0. When the function is first called, it may happen to
catch the 8-bit keep-alive counter right when it overflows, hence
returning BUSY.

This patch will keep checking the counter for 10us, every 1us, but it
will immediately return if the keep-alive counter changed.

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
2018-10-09 15:26:46 +03:00
Bai Ping 65fed31a52 MLK-19777-03: imx8mm_evk: Optimize the ddr4 init flow
Optimize the DDR4 init flow. Split the common flow
with the DDR specific timing config. So the common
flow can be reused.

Signed-off-by: Bai Ping <ping.bai@nxp.com>
2018-10-01 17:25:25 +08:00
Bai Ping 258db72309 MLK-19777-01: imx8mm: rename the lpddr4_ddrphy_train file
For LPDDR4 or DDR4, the ddr phy train flow is the same.
So rename the 'lpddr4_ddrphy_train.c' to 'ddrphy_train.c'.
make it more common for reuse and move it to driver/ddr/imx8m/.

Signed-off-by: Bai Ping <ping.bai@nxp.com>
2018-10-01 17:25:24 +08:00
faqiang.zhu bea54d4fbe MA-12283-4 remove the limitation of lock when use uuu
For imx8 chips, if boot from usb, lock status will be ignored for the
convenience of using uuu. For imx6 and imx7, the presistdata partition
is ignored, so unlock operation can alway succeed.

Change-Id: I842bab9fd2c04f8a864f4a134b63efc4436f71a4
Signed-off-by: faqiang.zhu <faqiang.zhu@nxp.com>
2018-09-29 14:14:24 +08:00
Abel Vesa f7587cc948 MLK-19183-12 iMX8QXP SPL: Add QSPI support for imx8qxp_mek
Allow iMX8QXP SPL to boot from QSPI.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Ye Li <ye.li@nxp.com>
2018-09-18 09:47:48 +03:00
Aymen Sghaier 2aff5ffb2c MLK-19053: crypto: caam: RNG4 TRNG errata
The TRNG as used in RNG4, used in CAAM has a documentation issue. The
 effect is that it is possible that the entropy used to instantiate the
 DRBG may be old entropy, rather than newly generated entropy. There is
 proper programming guidance, but it is not in the documentation.

Signed-off-by: Aymen Sghaier <aymen.sghaier@nxp.com>
2018-09-14 08:58:50 +02:00
Haoran.Wang cf2a6c19c8 MA-12699 Refine libavb for security features
Assign security features to specific config.
Now, use AVB_RPMB to enable RPMB stored rollback
index.

After this refine,
for imx6/7/8 Android release, use no AVB_RPMB,
for imx6/7 AndroidThings, use AVB_RPMB.

This patch also fix below build error for imx6/7:
vendor/nxp-opensource/uboot-imx/lib/avb/fsl/fsl_avbkey.c:711:2: error:
implicit declaration of function 'fsl_fuse_read'
[-Werror=implicit-function-declaration]
  if (fsl_fuse_read((uint32_t *)blob, RPMBKEY_FUSE_LENW,
RPMBKEY_FUSE_OFFSET)){

Change-Id: I734479f0627901f372f4b211b2e710bd103eb244
Signed-off-by: Haoran.Wang <elven.wang@nxp.com>
2018-09-13 14:51:00 +08:00
Haoran.Wang 502522c089 [iot] Support ARM64 for Trusty OS
Align the callback to ARM64 environment for
Trusty OS.

TEST: AIY-3G & AIY-1G board's TIPC and AVB handler
      works.

Change-Id: I65806f56267a4a9278db04a462e351da181618cb
Signed-off-by: Haoran.Wang <elven.wang@nxp.com>
2018-09-12 18:12:13 +08:00
Richard Zhu a612cab389 MLK-19479-2 fastboot: enable sata fastboot
- fix the blksize is 0 bug when boot device is sata
- add the sparse image support in the process flash sata

Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>
Signed-off-by: Ye Li <ye.li@nxp.com>
2018-09-10 17:46:35 +08:00
faqiang.zhu 9a36704925 MA-12283-3 chage eMMC bootloader offset for 8qm B0
for 8qm B0, bootloader in eMMC boot partition should be 0, it is
different from 8qm A0, which need to be 33K.

Change-Id: I3606aaee733b3a159bc818ac4938c34ec65f5896
Signed-off-by: faqiang.zhu <faqiang.zhu@nxp.com>
2018-09-10 10:57:00 +08:00
Ranjani Vaidyanathan 93450bafc8 MLK-19477 iMX8QM: Power down HDMI_PLL_0 after firmware loading is done.
Need to power down HDMI_PLL_0 after HDMI firmware is loaded, else
resource is left ON when entering low power states thus impacting low
power number.

Signed-off-by: Ranjani Vaidyanathan <Ranjani.Vaidyanathan@nxp.com>
2018-09-07 17:10:31 -05:00
Ji Luo 77542218ab MA-12337-1 Including DTBO in Recovery for Non-A/B Devices in Pie 9.0
Non-A/B devices should include dtbo in recovery.img to prevent mismatch
with recovery if OTA failure. Load dtbo from recovery.img for Non-A/B
devices in recovery mode.

Change-Id: Ie8b12aeb562b80a172769af0b163df3c672c9af0
Signed-off-by: Ji Luo <ji.luo@nxp.com>
2018-09-07 10:44:16 +08:00
Ye Li 4a8a24ae8b MLK-19433-3 mxc_ocotp: Disable fuse sense for imx8mq B1
On iMX8MQ Rev B1, reading from fuse box is not allowed. The
OCOTP_READ_FUSE_DATA register is tied to magic number 0xff0055aa
for chip rev. So u-boot has to disable the fuse sense function for it.

Signed-off-by: Ye Li <ye.li@nxp.com>
Tested-by: Anson Huang <Anson.Huang@nxp.com>
(cherry picked from commit da95f60611e8859eba3e7ccb715fdce4d6376774)
2018-09-04 01:58:10 -07:00
Ye Li a251b17f4c MLK-19356 fastboot: Fix ucmd issue in fastboot
After executing each ucmd, the ucmd callback function always call fastboot_setup
to setup some enviroments.

Because the mmc will be switched to user area by calling blk_get_dev in _fastboot_load_partitions.
When running "mmc partconf" by ucmd, the PART_CONFIG EXTCSD is updated, but the part_config and
hwpart variables in mmc and blk structure are not synced. So the old value will write to
PART_CONFIG EXTCSD again when switch to user area.

This patch changes the fastboot_setup, only load the partitions when the storage device is changed.
Also force to re-init mmc before loading the partitions to sync mmc variables.

Signed-off-by: Ye Li <ye.li@nxp.com>
(cherry picked from commit c9cd93b25586ecd4ce9178da7b8141f60cdd9deb)
2018-08-28 03:08:27 -07:00
faqiang.zhu e4a824f6c5 MA-12283: eliminate "unsupported boot devices" output when using uuu
make the case of USB_BOOT won't execute to the case of default.

Change-Id: I6393d1532df6fe75e81b0ee0a88ca83427378e5c
Signed-off-by: faqiang.zhu <faqiang.zhu@nxp.com>
2018-08-27 11:01:53 +08:00