18 Jan, 2021
35 commits
-
Broadcast device is switched to oneshot mode in
hrtimer_switch_to_hres() -> tick_broadcast_switch_to_oneshot().
After high resolution timers are enabled, new installed
broadcast device has no chance to switch mode.This issue happens in below situation:
To make broadcast clock source driver build as module,
use module_platform_driver() to replace TIMER_OF_DECLARE().
This will make clock source driver probed later than
high resolution timers enabled.Change-Id: I5cada6507bf44162b0642bc10efd1548b1b3f68a
Signed-off-by: Jindong Yue -
Allow imx system counter timer driver to be loaded as a module.
Signed-off-by: Jindong
Change-Id: Iad43c71a955fe806649ad317b3642470803fb9ea -
This allows timer drivers to be compiled as modules.
Bug: 146868249
Change-Id: I490a0e82ff59022da72b5e2f7e631cfb21533589
Link: https://lore.kernel.org/patchwork/patch/1214447/
Signed-off-by: Saravana Kannan
Signed-off-by: Baolin Wang
Signed-off-by: Baolin Wang
Signed-off-by: Orson Zhai -
irq_chip_pm_get/irq_chip_pm_put are used in imx gpio driver.
If build imx gpio as module, need export these two symbols.Change-Id: Ifbdffe3bbf33f7db1585202b205e643b5ca2ceef
Signed-off-by: zhang sanshan -
Export symbols used by other modules, like pci-imx6.
Signed-off-by: Jindong Yue
Change-Id: I2c77bfbfbec750ecdf21f0cd1bbb20fe339a2f0c -
Below Android AOSP patch fix the same issue, after merge this AOSP patch
previous "Flush cache after zero CMA allocated memory" patch is not needed.Revert "MGS-5565-1 staging: android: ion: Flush outer cache after zero CMA allocated memory"
This reverts commit d39a68543c7002b7abd7f9df6d8f26fedda72ea5.
Revert "MGS-5565 staging: android: ion: Flush cache after zero CMA allocated memory"
This reverts commit 3d549870d99b2522d863a4940cd320d2a87eaad7.AOSP fix:
commit 20a9f3da0e6fd33e9df8f280756c94ce35660391
Author: Vincent Donnefort
Date: Thu Oct 4 18:21:47 2018 +0100ANDROID: ion: flush cache before exporting non-cached buffer
Change-Id: Ie57f6905f60a3f213b88b0e2bb0b5755ca36b598
Signed-off-by: Richard Liu -
Export several APIs used by fsl_dsp driver.
Signed-off-by: Jindong
Change-Id: Ia8ad3dea24cf37a5366d75434984be605d969c61 -
add "MODULE_LICENSE("GPL v2")" for the driver device_cooling.c, otherwise
EXPORT_SYMBOL_GPL can't work when built as module.Change-Id: Idcebb991e6d880f403b1931878e3625920b52f5f
Signed-off-by: Dandan Sun -
change "ifdef CONFIG_DEVICE_THERMAL" to "if IS_ENABLED(CONFIG_DEVICE_THERMAL)"
to enable the module with IS_BUILTIN(option) or IS_MODULE(option)).Change-Id: I116ed60acae56629713163888cb4a7d5a2d6acb3
Signed-off-by: Dandan Sun -
Make fsl_dsp_cpu as a separate driver, otherwise below
build error will occur when set CONFIG_SND_SOC_FSL_DSP=mld.lld: error: duplicate symbol: init_module
>>> defined at fsl_dsp.c
>>> sound/soc/fsl/fsl_dsp.o:(init_module)
>>> defined at fsl_dsp_cpu.c
>>> sound/soc/fsl/fsl_dsp_cpu.o:(.init.text+0x0)Change-Id: I1b1231b59233c9dfa209aaffc9e79f7de78f8283
Signed-off-by: Jindong
Reviewed-by: Shengjiu Wang -
After enable remote proc drvier, audio rpmsg
driver should not depend on HAVE_IMX_RPMSG.Change-Id: I97007c07004e7d3b5de0fb46a4546d98f25f4824
Signed-off-by: Jindong
Reviewed-by: Shengjiu Wang -
Move rpmsg wm8960 i2c driver to a new driver file,
otherwise it can not be built as module.Change-Id: Ia1e7a9b4fddb21ca64378a003c0237adb1798d23
Signed-off-by: Jindong
Reviewed-by: Shengjiu Wang -
Move i2s rpmsg driver to a new file: imx-i2s-rpmsg.c
This new driver should be probed after fsl_rpmsg_i2s, which
calls imx_rpmsg_platform_register (in imx-pcm-rpmsg) to fill
global variable: i2s_info_g.Change-Id: I3c716765141a3034b7c863bd99523c3aa975345b
Signed-off-by: Jindong
Reviewed-by: Shengjiu Wang -
Enabling BTI(Branch Target Identification) will insert two
additional processor specific entries in the dynamic section
of vdso.so, but the linker in bionic can't handle these two
entries (not yet) and will output warnings like below:
linker : Warning: "[vdso]" unused DT entry: unknown processor-specific (type 0x70000001 arg 0x0) (ignoring)
linker : Warning: "[vdso]" unused DT entry: unknown processor-specific (type 0x70000003 arg 0x0) (ignoring)As the BTI will only be available for ARMv8.5 and we can't
get benefits for i.MX 8 SoCs, so this commit will disable
the BTI config to silent the warnings.Test: Boots on imx8qm.
Signed-off-by: Ji Luo
Change-Id: Iee36edd3dd8131900ec315aadd439cbdeb76e63a -
correct the mmc block path
Change-Id: Iec631bb1616477686aa7f7041bed2c82e4777716
Signed-off-by: zhang sanshan -
uboot will check the dtb pass to kernel that whether
the resource is from the AP. If no, it will print error log.
android use the M4 image by default, so the dtb will change to
the rpmsg oneUBOOT boot up error log:
Disable mu@31580000 rsrc 505 not owned
Disable i2c@3b230000 rsrc 308 not owned
Disable clock-controller@3b630000 rsrc 308 not owned
Disable intmux@3b400000 rsrc 309 not owned
Disable clock-controller@5a480000 rsrc 59 not owned
Disable can@5a8d0000 rsrc 105 not owned
Disable can@5a8e0000 rsrc 106 not owned
Disable can@5a8f0000 rsrc 107 not owned
Disable clock-controller@5acd0000 rsrc 105 not owned
Disable clock-controller@5ace0000 rsrc 106 not owned
Disable clock-controller@5acf0000 rsrc 107 not owned
Disable spi@5d120000 rsrc 237 not owned
Disable imx8qm_cm4@0 rsrc 278 not owned
Disable imx8qm_cm4@0 rsrc 297 not owned
Disable imx8x_cm4@1 rsrc 298 not owned
Disable imx8x_cm4@1 rsrc 317 not ownedChange-Id: Iceaca0fca037d2f0953456babb49ff247ce39a7c
Signed-off-by: zhang sanshan -
enable zram to support swapon_all.
Change-Id: I17a6a34eaa4ef7e7dbd47b0b6cd3c6c91e7e44d9
Signed-off-by: zhang sanshan -
Legacy lz4 format (generated by 'lz4 -l') is unsupported by u-boot
Use default 'lz4' command to generate lz4 compressed kernel image.Change-Id: I4390216c8fed77881d4542ce22b7a9441a09bf5e
Signed-off-by: zhang sanshan -
CONFIG_VT is not set in android config. But we need fb_con which depend on CONFIG_VT.
FRAMEBUFFER_CONSOLE is selected automaticly when enable DRM_KMS_FB_HELPER if we are not EXPERT user.
Android enable CONFIG_EXPERT. So we need add FRAMEBUFFER_CONSOLE in defconfig.Change-Id: Ibf96c16e8a3b1aa2d7ccfe347217e23e5dfe3b67
Signed-off-by: zhang sanshan -
enable dummy battery, otherwise system will enter suspend in 5 seconds after
boot up system.Change-Id: Ie04dfc5630f962d8018a52219b97a4c6cfa7b53e
Signed-off-by: zhang sanshan -
When "echo 0 /sys/class/power_supply/battery/online",
Error log: CFI failure (target: dummy_battery_set_property+0x0/0x4)
so amend dummy_usb_set_property denifition,
to align with the power_supply_desc.set_property,
change "union power_supply_propval *val" to "const union power_supply_propval *val"Change-Id: I6b0e5f639ffba9938a99bc53a7a0a6782a8e3994
Signed-off-by: Dandan Sun -
Fix below slab-out-of-bounds fault:
BUG: KASAN: slab-out-of-bounds in dummy_power_init+0xc4/0x184
Write of size 4 at addr ffff000823f73634 by task swapper/0/1CPU: 0 PID: 1 Comm: swapper/0 Not tainted 5.4.47-00001-g33634cfec204-dirty #8
Hardware name: Freescale i.MX8QXP MEK (DT)
Call trace:
dump_backtrace+0x0/0x1a0
show_stack+0x18/0x24
dump_stack+0xe0/0x150
print_address_description+0x88/0x558
__kasan_report+0x1b0/0x210
kasan_report+0x14/0x20
__asan_store4+0x98/0x9c
dummy_power_init+0xc4/0x184Change-Id: I97aac00cfd0115f0ab203360c3d4d062dfd6d123
Signed-off-by: Jindong Yue -
override dummy_power_desc[] to implement dummy_usb_set_property,
dummy_usb_property_is_writeable, dummy_battery_set_property,
dummy_battery_property_is_writeable to overlay POWER_SUPPLY_PROP_ONLINE,can echo 0 or 1 to /sys/class/power_supply/battery/online and
/sys/class/power_supply/usb/online, when both set to 0, equals to
unplug power_supply device, charger_online will be set to false,
system will shut down by HandlePowerSupplyState when in charger mode.Change-Id: I22f8be46dc5cd5c550f568cc28238a2f83d6d723
Signed-off-by: Dandan Sun -
add below node /sys/devices/virtual/power_supply/battery/ which is used
in BatteryMonitor. /sys/class/power_supply linked to the former link.
Many cts can't pass if do not add this sys node.Change-Id: I3fed4166ab6a1860c0bb35a3bf62ad5bb49a7741
Signed-off-by: zhang sanshan -
remove battery related setting in dummy battery driver,
so userspace can only find usb power supply online.Change-Id: I265d1940324b6a1edac42898cbc06592db6b9e4c
Signed-off-by: Zhang Bo -
cherry-pick following two patches from android-things git.
commit 8477e9491f8654a31e233aae11ba9c1684c28541
Author: Dave Rim
Date: Thu Oct 12 14:48:39 2017 +0900Create dummy battery for devices with no battery
Creates a dummy battery module for android devices with no battery
Bug: 63166743, Bug: 64996847
Test: com.android.server.cts.BatteryStatsValidationTest#testBleScans
Change-Id: I21e0968e8b43ee35c21b77ada204069f2df58773commit b067cacece5ebcc4f3f0b7efda4b7940c723706a
Author: Dave Rim
Date: Thu Oct 19 11:41:25 2017 +0900Set dummy battery status to charging
CtsJobSchedulerTestCases requires status charging
Bug: 67625790
Test: cts-tradefed run commandAndExit cts -m CtsJobSchedulerTestCases -t
android.jobscheduler.cts.TimingConstraintsTest#testJobParameters_unexpiredDeadline
Change-Id: I26463cf8adafbd8baec960ee06e1c7f836f92ed9Change-Id: If41f51806c7c1a8ac7c5980f00be7a11a54dec7d
Signed-off-by: Zhang Bo -
Add defconfig items to build mxmdriver as module
for nxp wifi.Change-Id: I8c1bc557d1f8920aa46a56986bbd6afa0dd7ec5a
Signed-off-by: yang.tian -
Add initial MxM (multi-chip-multi-interface) wifi driver
for IMX Linux Kernel version 5.10.
The driver is initial to target support 88w8987/88w8997.The MxM wifi driver is merged from below repo:
ssh://git@bitbucket.sw.nxp.com/wcswrel/
rel-l5-10-nxp-wifi-fp92-bt-fp92-linux-android-mxm5x16214-mgpl.gitChange-Id: I431cc871963cb571d6561293ec4e5a8507bbf098
Signed-off-by: yang.tian -
enable below which is compatible with kernel/configs/r/android-5.10/
otherwise it will have build error
CONFIG_TRACE_GPU_MEM=y
CONFIG_ARMV8_DEPRECATED=y
CONFIG_CP15_BARRIER_EMULATION=y
CONFIG_SETEND_EMULATION=y
CONFIG_SHADOW_CALL_STACK=y
CONFIG_SWP_EMULATION=y
CONFIG_BPF_JIT_ALWAYS_ON=yChange-Id: I7d7c5a012275c72d4e1bcc9a6f0927eb6a02cb4d
Signed-off-by: zhang sanshan -
kernel5.10 define TRACE_GPU_MEM in android-base-conditional.xml
So need enable TRACE_GPU_MEM in defconfig explicitlyChange-Id: I50b40c8e2d8b96131918779762014a726c60a876
Signed-off-by: zhang sanshan -
system will reboot if userdata partition encrytion failed.
Change-Id: I0489f1d45d583b11faab59de59337fffc548e95a
Signed-off-by: zhang sanshan -
enable storage mount in early stage
Change-Id: Ib2010b3291bceaacecc8f9fbd48c33f13ac3f67b
Signed-off-by: zhang sanshan -
detail steps:
ARCH=arm64 scripts/kconfig/merge_config.sh arch/arm64/configs/imx_v8_android_defconfig /home/sanshan/aosp_kernel/kernel/configs/android-5.10/android-base.config /home/sanshan/aosp_kernel/kernel/configs/android-5.10/android-recommended.config /home/sanshan/aosp_kernel/kernel/configs/android-5.10/android-recommended-arm64.config
make savedefconfig ARCH=arm64
cp defconfig arch/arm64/configs/imx_v8_android_defconfig
rm .config
ARCH=arm scripts/kconfig/merge_config.sh arch/arm/configs/imx_v7_defconfig /home/sanshan/aosp_kernel/kernel/configs/android-5.10/android-base.config /home/sanshan/aosp_kernel/kernel/configs/android-5.10/android-recommended.config /home/sanshan/aosp_kernel/kernel/configs/android-5.10/android-recommended-arm.config
rm defconfig
make savedefconfig ARCH=arm
cp defconfig arch/arm/configs/imx_v7_android_defconfig
rm defconfig
rm .configconfigure git info:
https://android.googlesource.com/kernel/configs/
master branch for configs.git
commit id: 0684b082acceddee9b22dccfe441e8d4d716e415
configs/android-5.10Change-Id: I61f87064fead1d27b256ed4467fee77a726b397e
Signed-off-by: zhang sanshan -
imx_v7_android_defconfig is from imx_v7_defconfig.
imx_v8_android_defconfig is from imx_v8_defconfig.Change-Id: Ib681ba8b4a675f3aaee6de915ed5828c4a46b563
Signed-off-by: zhang sanshan -
Change-Id: I42aa8c4cdf7dcf55b4392a5588f6d37d43a1eef7
16 Jan, 2021
1 commit
-
There are cases when default / POR value for RTSDCTL[ENT_DLY] is
equal or greater than minimum value that kernel tries to program (3200).In this case, (re-)programming of RTSDCTL[ENT_DLY] and related RTFRQMIN,
RTFRQMAX is skipped - this logic is fine.
However, RNG sample size (RTSDCTL[SAMP_SIZE]) and associated self-test
parameters must be (re-)programmed irrespective of this condition.This solves the issue of RNG performance dropping after a suspend/resume
cycle on parts where caam loses power AND default value for
RTSDCTL[ENT_DLY] is >= 3200 AND RNG handles are successfully instantiated.Fixes: 29d925df53cf ("LF-2943 crypto: caam - optimize RNG sample size")
Signed-off-by: Horia Geantă
Reviewed-by: Varun Sethi
15 Jan, 2021
2 commits
-
There are cases when the interrupt status register (JRINTR) is non-zero,
even though:
1. An interrupt was generated, but it was masked OR
2. There was no interrupt generated at all
for the corresponding job ring.1. The case when interrupt is masked (JRCFGR_LS[IMSK]=1b'1)
while other events have happened and are being accounted for, e.g.
-JRINTR[HALT]=2b'10 - input job ring underwent a flush of all on-going
jobs and processing of still-existing jobs (sitting in the ring) has been
halted
-JRINTR[HALT]=2b'01 - input job ring is currently undergoing a flush
-JRINTR[ENTER_FAIL]=1b'1 - SecMon / SNVS transitioned to FAIL MODE
It doesn't matter whether these events would assert the interrupt signal
or not, interrupt is anyhow masked.2. The case when interrupt is not masked (JRCFGR_LS[IMSK]=1b'0), however
the events accounted for in JRINTR do not generate interrupts, e.g.:
-JRINTR[HALT]=2b'01
-JRINTR[ENTER_FAIL]=1b'1 and JRCFGR_MS[FAIL_MODE]=1b'0Currently in these cases, when the JR interrupt handler is invoked (as a
consequence of JR sharing the interrupt line with other devices - e.g.
the two JRs on i.MX7ULP) it continues execution instead of returning
IRQ_NONE.
This could lead to situations like interrupt handler clearing JRINTR (and
thus also the JRINTR[HALT] field) while corresponding job ring is
suspended and then that job ring failing on resume path, due to expecting
JRINTR[HALT]=b'10 and reading instead JRINTR[HALT]=b'00.Fix this by checking status of JRINTR[JRI] in the JR interrupt handler.
If JRINTR[JRI]=1b'0, there was no interrupt generated for this JR and
handler must return IRQ_NONE.Signed-off-by: Horia Geantă
Reviewed-by: Varun Sethi -
The data of property 'fsl,rcpm-wakeup' is not corrcet, which causing
RCPM driver incorrectly program register IPPDEXPCR1, then flextimer is
wrongly clock gated during system suspend, can't send interrupt to
wake.Signed-off-by: Ran Wang
Acked-by: Li Yang
14 Jan, 2021
2 commits
-
Fine tune hdmi phy to pass HDMI electrical CTS.
Signed-off-by: Sandor Yu
Reviewed-by: Robby Cai -
reset hdmi phy power.
Signed-off-by: Sandor Yu
Reviewed-by: Robby Cai