23 Feb, 2017
40 commits
-
This patch fixes the following issue reported by Coverity:
if (IS_ERR(clk))
freed_arg: kfree frees clk. [Note: The source code implementation of the
function has been overridden by a builtin model.]
kfree(clk);Use after free (USE_AFTER_FREE)
use_after_free: Using freed pointer clk.
return clk;Signed-off-by: Liu Ying
-
This patch fixes the following issue reported by Coverity:
Constant expression result (CONSTANT_EXPRESSION_RESULT)
always_true_or: The "or" condition disp != 0 || disp != 1 will always be true
because disp cannot be equal to two different values at the same time, so it
must be not equal to at least one of them.
if ((disp != 0) || (disp != 1))
return;Signed-off-by: Liu Ying
-
We should do the bailout dance correctly for the ioctrl IPU_ALLOC:
- Free the mem pointer.
- Free the DMA.
- Delete the mem->list from the ipu_alloc_list.The potential memory leakage issue on the mem pointer is reported by Coverity:
if (get_user(size, argp))
Resource leak (RESOURCE_LEAK)
leaked_storage: Variable mem going out of scope leaks the storage it points to.
return -EFAULT;Signed-off-by: Liu Ying
-
Comparing unsigned integer with 0 is meaningless. So
remove this kind of integer comparing.Signed-off-by: Fancy Fang
-
The code slice in the 'v4l2_fmt_to_pxp_fmt()' function:
"
else if (v4l2_pix_fmt == V4L2_PIX_FMT_RGB555)
pxp_fmt = PXP_PIX_FMT_RGB555;
"
appears twice continuously. And the second code slice
will become dead code which is never executed. So
remove the second one.Signed-off-by: Fancy Fang
-
After coverity code check, it reports dereference NULL return value
complain, so fix it.Signed-off-by: Bai Ping
-
Check if data->usbmisc_data is NULL before dereference it in probe.
Acked-by: Peter Chen
Signed-off-by: Li Jun -
Add the missing error code check just as the others which
have the check.Signed-off-by: Fancy Fang
-
The 'buf' index loop is obviously wrong. So correct
it.Signed-off-by: Fancy Fang
-
The code slice in the pxp_probe() function:
"
if (!res || irq < 0) {
err = -ENODEV;
goto exit;
}
"
appears twice closely. And the second code slice will become
dead code which is never executed. So remove the second one.Signed-off-by: Fancy Fang
-
The 'sg' buffer should be allocated dynamically, since its
size is dependent on the 'sg_len' which is calculated
according to the functions required.Signed-off-by: Fancy Fang
(cherry picked from commit 57f08c108fc4f4721449b4b94be9820c7443978a) -
Dereference data pointer after its NULL check.
Signed-off-by: Li Jun
-
Fix the coverity check complains although there is no function issue
with current code.Signed-off-by: Li Jun
-
For SAI master mode, when Tx(Rx) sync with Rx(Tx) clock, Rx(Tx) will
generate bclk and frame clock for Tx(Rx), we should set RCR4(TCR4),
RCR5(TCR5) and RMR(TMR) for playback(capture), or there will be sync
error sometimes.Signed-off-by: Zidan Wang
Acked-by: Nicolin Chen
Signed-off-by: Mark Brown
(cherry picked from commit 51659ca069ce5bdf20675a7967a39ef8419e87f2) -
(cherry-pick from f9759787e60ad3422d2119f9f25ac320ca58f5df)
confilict: arch/arm/boot/dts/imx6sx.dtsi
The dts file arch has changed in 3.14. Add QoS description in
imx6sx dts manually and solve the conflict.Date Feb 2, 2015
Signed-off-by: Shawn Xiao
-
When a framebuffer is blanked, the user may call the MXCFB_SET_PREFETCH ioctrl
to enable or disable the prefetch engine. After sanity check, the cached
->prefetch should reflect the user's intention for next unblank operation
any way instead of checking ->cur_prefetch first.Signed-off-by: Liu Ying
-
In MLK-11272, we introduce a workaround to resolve data pulse detection
IC issue in i.MX7D, but did not disable the term select override after
the A device becomes B device in some cases: a_idle --> enable term
select override --> b_idle, which cause the B device cannot be enumerated
in b_peripheral mode. This patch is to fix it by disable the term select
and data pulse when A device becomes B device.Signed-off-by: Li Jun
(cherry picked from commit 2df52fcaded838a572c2ee8f93d6cc827a2ebc60) -
The pre_list can be accessed in an irq context. To avoid potential hang up
issue, use spinlock to protect pre_list instead of mutex.Signed-off-by: Liu Ying
-
The capture channel should be correctly disabled in ->suspend() and
enabled in ->resume() with ->enc_disable()/->enc_disable_csi() and
->enc_enable()/->enc_enable_csi() respectively.Signed-off-by: Liu Ying
-
The commit '39c6663 MLK-11848-2 dma: imx-sdma: add __init for probe()' is
not correct, fix it totally.Signed-off-by: Robin Gong
-
Add s_stream interface for MIPI CSI and ov5647/ov5640 drivers.
Enable MIPI CSI sensor after MIPI CSI DPHY CLK enable
in case MIPI DPHY miss MIPI CSI sensor signal.Signed-off-by: Sandor Yu
(cherry picked from commit 26d81b416be6e3af203d1254a3116dbcf39a5605) -
There is a error in i.MX7D RM RevB.
Actually the register of SRC_MIPIPHY_RCR(src offset 0x28)
bit 1 for MIPI PHY Master Reset
bit 2 for MIPI PHY Slave Reset.Signed-off-by: Sandor Yu
(cherry picked from commit 4f3128a79c023319c9e21690be866dc46a9d6816) -
The 'pre_periph2_sel' and 'pre_periph_clk' and other two clks
should have the ability to change its parent clk without disabling
itself first, so change the clk type of these clocks to make the
parent can be swithed without disabling the clock.Signed-off-by: Bai Ping
-
imx pcie used the wrab mode to do the cached access
methods on axi bus. There is 64bytes address mis-aligned
problem.
Disable the cached operations.Signed-off-by: Richard Zhu
(cherry picked from commit 85db70336ab66136481926bcd7f5abe599e2aa4f) -
The previous fb buffer management has two problems:
1. After reallocate a bigger buffer and free the old buffer,
user space app doesn't know this and may continue accessing
the old buffer.
2. The freed buffer contents will be lost.So, this patch allocates a big enough fb buffer(32MB) from the
beginning and never reallocates it.Signed-off-by: Fancy Fang
(cherry picked from commit c76a37e342369675aa9ef2efde6373d288c2f013)Conflicts:
drivers/video/mxsfb.c -
some issue was involved when merging the commit to kernel 4.1
Signed-off-by: Han Xu
-
Fix buiding error with GCC 4.6.2:
WARNING: drivers/dma/built-in.o(.text+0xefac): Section mismatch in reference from the function sdma_probe() to the function .init.text:sdma_event_remap.isra.21()
The function sdma_probe() references
the function __init sdma_event_remap.isra.21().
This is often because sdma_probe lacks a __init
annotation or the annotation of sdma_event_remap.isra.21 is wrong.Signed-off-by: Robin Gong
-
This commit 06634f8a25f4c5e4ff0c0ef5368a48eb394db63b cherry-picked wrong,
and that cause SPI DMA mode never works. Actually, no need this patch since
this patch has already been upsteaminged as below:commit f8bb820da4ae863c676156627973a950129559fb
Author: Robin Gong
Date: Thu Apr 16 10:54:18 2015 +0800spi: check tx_buf and rx_buf in spi_unmap_msg
Signed-off-by: Robin Gong
-
FreeRTOS/M4 has DDR use case, M4 can only execute on DDR
space lower than 0xa0000000, Linux kernel will reserve 1M
(0x9ff00000 - 0x9fffffff) for it, below are the DDR usage:0x80000000 - 0x9fefffff: Linux kernel;
0x9ff00000 - 0x9fffffff: FreeRTOS;
0xa0000000 - 0xbfefffff: Linux kernel;
0xbff00000 - 0xbfffffff: RPMSG shared memory;
0xc0000000 - 0xffffffff: Linux kernel if boards has 2GB DDR.Also, remove 'reg' property which is unused.
Signed-off-by: Anson Huang
-
FreeRTOS/M4 has DDR use case, M4 can only execute on DDR
space lower than 0xa0000000, Linux kernel will reserve 1M
(0x9ff00000 - 0x9fffffff) for it, below are the DDR usage:0x80000000 - 0x9fefffff: Linux kernel;
0x9ff00000 - 0x9fffffff: FreeRTOS;
0xa0000000 - 0xbfefffff: Linux kernel;
0xbff00000 - 0xbfffffff: RPMSG shared memory;
0xc0000000 - 0xffffffff: Linux kernel if boards has 2GB DDR.Also, remove 'reg' property which is unused.
Signed-off-by: Anson Huang
-
FreeRTOS has use case of running on OCRAM, reserve the
bottom half of OCRAM spase(0x910000 - 0x91efff) for M4,
the last 4K is for shared memory power management.Signed-off-by: Anson Huang
-
FreeRTOS has use case of running on OCRAM, reserve the
bottom half of OCRAM spase(0x910000 - 0x91ffff) for M4.Signed-off-by: Anson Huang
-
ARM/MP: 814220—B-Cache maintenance by set/way operations can execute out of order.
Description:
The v7 ARM states that all cache and branch predictor maintenance operations
that do not specify an address execute, relative to each other, in program
order. However, because of this erratum, an L2 set/way cache maintenance
operation can overtake an L1 set/way cache maintenance operation, this would
cause the data corruption.This ERRATA affected the Cortex-A7 and present in r0p2, r0p3, r0p4, r0p5.
This patch is the SW workaround by adding a DSB before changing cache levels as
the ARM ERRATA: ARM/MP: 814220 told in the ARM ERRATA documentation.Signed-off-by: Jason Liu
(cherry picked from commit 0e9a87bbd4f7d1c48e42c65aa94939a7283599dd)Conflicts:
arch/arm/mach-imx/Kconfig -
The 'CONFIG_PM_RUNTIME' has been eliminated and all the users
should use 'CONFIG_PM' directly. So do this change for epdc and
epdc-v2.Signed-off-by: Fancy Fang
-
The 'CONFIG_PM_RUNTIME' has been eliminated and all the users
should use 'CONFIG_PM' directly. So do this change for pxp-v2
and pxp-v3.Signed-off-by: Fancy Fang
-
The 'CONFIG_PM_RUNTIME' has been eliminated and all the users
should use 'CONFIG_PM' directly. So do this change for mxsfb.Signed-off-by: Fancy Fang
-
There is one ROM bug on i.mx6sx TO1.1 that default ROM code use the old
ocram space 0x900000, but it should be 0x8f8000. So SW workaround need to
be added, unfortunately, the 'romcp' device node not added in i.mx6sx dtsi
on v4.1, thus i.mx6sx-sdb-reva board will be failed to resume back, add them
back.Signed-off-by: Robin Gong
-
When the usb in idle, it calls release_bus_req.
When the usb is going to use, it calls request_bus_req.
This is a rework patch of ENGR00286459 and ENGR00286926.Signed-off-by: Peter Chen
Signed-off-by: Li Jun -
LDO2p5 cannot be disabled in low power idle mode when the USB driver
enables VBUS wakeup. To identify when LDO2p5 can be disabled add a dummy
regulator that the USB driver will enable when VBUS wakeup is required.Signed-off-by: Ranjani Vaidyanathan
Signed-off-by: Li Jun -
Add egalax touch screen support for imx6qdl-sabresd board.
Signed-off-by: Haibo Chen