04 Aug, 2015

1 commit


16 Mar, 2015

1 commit


05 Mar, 2015

1 commit


06 Feb, 2015

2 commits

  • We've got a race condition bewteen the interrupt handler mxsfb_irq_handler()
    and the function mxsfb_wait_for_vsync() on the flag host->wait4vsync.
    If a CUR_FRAME_DONE interrupt comes and we just finish setting host->wait4vsync
    to be 1 in mxsfb_wait_for_vsync() before we go to the interrupt handler, we are
    likely to see the VSYNC_EDGE interrupt status bit asserted in the interrupt
    handler for the CUR_FRAME_DONE interrupt, disable the not yet enabled VSYNC_EDGE
    interrupt and finally clear host->wait4vsync.
    Then, we go back to mxsfb_wait_for_vsync() and enable the VSYNC_EDGE interrupt
    with host->wait4vsync=0. This may leave the VSYNC_EDGE interrupt enabled all
    the time and never get a chance to be disabled in the interrupt handler.
    So, we are deemed to hang up because the uncleared VSYNC_EDGE interrupt status
    bit will cause the CPU to be trapped forever, according to SoC designer's words.
    This patch corrects the interrupt handling to handle only the interrupts which
    are acknowledged by checking both the interrupt enablement bits and the status
    bits but not the status bits only. This may avoid any bogus interrupt from
    being handled.

    Signed-off-by: Liu Ying
    (cherry picked from commit 24e1e55076b624f9dc93c1f23e14dd024bdff1c7)

    Liu Ying
     
  • With IC engineer confirmation, 500ms is enough to detect whether
    it is a standard USB connection or not. Decrease the timeout value
    can reduce the system suspending time if it is not a standard
    USB connection.

    Signed-off-by: Peter Chen

    Peter Chen
     

04 Feb, 2015

7 commits


02 Feb, 2015

22 commits

  • Remove csi1_v4l2_cap item from imx6sx-sdb-lcdif.dts file.
    The item is not used in dts now.

    Signed-off-by: Sandor Yu
    (cherry picked from commit a1d3b98ad9dbd53aea088855ae6da1251ce18980)

    Sandor Yu
     
  • -Sii902x hdmi daughter connect to lcdif1 interface,
    move this function to lcdif1 dts.
    -Sii902x hdmi driver share the reset pin with ov5640 driver,
    one driver will been reset by the other driver,
    so move sii902x reset pin configure to licdif1 dts.

    Signed-off-by: Sandor Yu
    (cherry picked from commit 59c54859ec5b4bd319be2aec8ce034be1ecc7bf5)

    Sandor Yu
     
  • Enable sii902x hdmi driver in imx6sx sdb board.
    Driver suppoer HPD and read edid data from dispaly monitor.

    Signed-off-by: Sandor Yu
    (cherry picked from commit 8abc5d8909e13f603588b471ea9a898bbc103fc0)

    Sandor Yu
     
  • Write initial words to SAI FIFO to reduce underrun error

    Signed-off-by: Shengjiu Wang
    (cherry picked from commit 7ba8ae883d84540fac5ed4147d124399537bc0b3)

    Shengjiu Wang
     
  • esai_ipg clock's parent is ahb, not ipg.

    Signed-off-by: Shengjiu Wang
    (cherry picked from commit adfc94281c34877966bdb8e9641d106a7f74d8e5)

    Shengjiu Wang
     
  • Add checking GPU module logic in qos init. This prevents kernel
    booting issue in the iMX6sx SOC where there is no GPU module.

    Signed-off-by: Shawn Xiao
    (cherry picked from commit bf3a8eeaa655a6d3642739bd5e78f70a18c7b45b)

    Shawn Xiao
     
  • In general, uart module clock require it is great than 80Mhz to match 5Mbps
    baud rate. When test below 14Mhz module clock, software reset cause state
    machines off normal. And for i.MX6SL evk board low power test, it set uart
    module clock to 4Mhz, which cause console port print out messy code.
    The patch just is workaround to fix console issue.

    Signed-off-by: Fugang Duan
    (cherry picked from commit d7061a8c6b17f1a0d9b7f161967d538b1a408e5c)

    Fugang Duan
     
  • In busfreq code, when switching between different busfreq mode,
    the PLL2_BUS clk rate will be changed in asm code. But the kernel clock
    tree is NOT aware of this change, so the clk tree information is NOT
    updated timely. We must explicitly call imx_clk_set_rate() to update the
    PLL2_BUS clk tree infomation.

    Signed-off-by: Bai Ping
    (cherry picked from commit a8cf0e4633ee897b7efff715f889026262f7a027)

    Bai Ping
     
  • When running an userspace program that does a 'tcflush(fd, TCIOFLUSH)' call
    we still see the last received character in the URXD register afterwards.

    Clear UCR2_SRST bit so that the FIFO is flushed properly.

    Since UCR2_SRST also resets some UART registers, we need to save and restore
    some of them.

    Signed-off-by: Fabio Estevam
    (cherry picked from commit 87a72b6a6367a714026d5f38207301e7f53b0aca)

    Fabio Estevam
     
  • System may hang if cpufreq is updated during pu enable/disable flow, add cpufreq
    mutex in before vddpu regulator enable/disable to make sure no any break happen.
    Unfortunetly, there is no better way on v3.10 since both PU management and cpufreq
    are based on regulator framework.
    Another change is increasing cpufreq to the highest setpoint and then disable
    cpufreq.That makes sure no any mutex OOps before reboot, such as cpufreq update thread
    is killed after get cpufreq mutex while xPU driver fall into PU enable/disable flow.

    Signed-off-by: Anson Huang
    Signed-off-by: Robin Gong
    (cherry picked from commit a43de999958a30a04f1df13475bc69b432c05308)

    Anson Huang
     
  • In non-linear_bypass_pp and non-tiled_bypass_pp modes, the triple fbdev frame
    buffer would be rendered with video frames in turn. We need to fill all the
    three frame buffers with black color before streaming on instead of filling only
    one of them.

    Signed-off-by: Liu Ying
    (cherry picked from commit e0155001082abc2432ec54ac86f56abbbb744fd3)

    Liu Ying
     
  • Add an error check after mapping the SECVIO IRQ.

    Signed-off-by: Victoria Milhoan
    (cherry picked from commit 015acaecc54e6d78a2b266cf5588b974ed235a58)

    Victoria Milhoan
     
  • commit 738459e3f88538f2ece263424dafe5d91799e46b upstream.

    If dma mapping for dma_addr_out fails, the descriptor memory is freed
    but the previous dma mapping for dma_addr_in remains.
    This patch resolves the missing dma unmap and groups resource
    allocations at function start.

    Signed-off-by: Cristian Stoica
    Signed-off-by: Herbert Xu
    Signed-off-by: Greg Kroah-Hartman

    (cherry picked from commit 77204ef5865a366573b4ee87c74daf6361039b96)
    (cherry picked from commit 04ed02fe44d3fbfe9e0ee0527718d7767f07d0d2)

    Cristian Stoica
     
  • The hwrng output buffers (2) are cast inside of a a struct (caam_rng_ctx)
    allocated in one DMA-tagged region. While the kernel's heap allocator
    should place the overall struct on a cacheline aligned boundary, the 2
    buffers contained within may not necessarily align. Consenquently, the ends
    of unaligned buffers may not fully flush, and if so, stale data will be left
    behind, resulting in small repeating patterns.

    This fix aligns the buffers inside the struct.

    Note that not all of the data inside caam_rng_ctx necessarily needs to be
    DMA-tagged, only the buffers themselves require this. However, a fix would
    incur the expense of error-handling bloat in the case of allocation failure.

    Signed-off-by: Steve Cornelius
    (cherry picked from commit 892f4439b5da36a447a16c8ea0474b51fc955274)
    (cherry picked from commit c948b6c2b49a1e06fa94c88154583fc718312bd5)

    Steve Cornelius
     
  • commit 307fd543f3d23f8f56850eca1b27b1be2fe71017 upstream.

    Replace equivalent (and partially incorrect) scatter-gather functions
    with ones from crypto-API.

    The replacement is motivated by page-faults in sg_copy_part triggered
    by successive calls to crypto_hash_update. The following fault appears
    after calling crypto_ahash_update twice, first with 13 and then
    with 285 bytes:

    Unable to handle kernel paging request for data at address 0x00000008
    Faulting instruction address: 0xf9bf9a8c
    Oops: Kernel access of bad area, sig: 11 [#1]
    SMP NR_CPUS=8 CoreNet Generic
    Modules linked in: tcrypt(+) caamhash caam_jr caam tls
    CPU: 6 PID: 1497 Comm: cryptomgr_test Not tainted
    3.12.19-rt30-QorIQ-SDK-V1.6+g9fda9f2 #75
    task: e9308530 ti: e700e000 task.ti: e700e000
    NIP: f9bf9a8c LR: f9bfcf28 CTR: c0019ea0
    REGS: e700fb80 TRAP: 0300 Not tainted
    (3.12.19-rt30-QorIQ-SDK-V1.6+g9fda9f2)
    MSR: 00029002 CR: 44f92024 XER: 20000000
    DEAR: 00000008, ESR: 00000000

    GPR00: f9bfcf28 e700fc30 e9308530 e70b1e55 00000000 ffffffdd e70b1e54 0bebf888
    GPR08: 902c7ef5 c0e771e2 00000002 00000888 c0019ea0 00000000 00000000 c07a4154
    GPR16: c08d0000 e91a8f9c 00000001 e98fb400 00000100 e9c83028 e70b1e08 e70b1d48
    GPR24: e992ce10 e70b1dc8 f9bfe4f4 e70b1e55 ffffffdd e70b1ce0 00000000 00000000
    NIP [f9bf9a8c] sg_copy+0x1c/0x100 [caamhash]
    LR [f9bfcf28] ahash_update_no_ctx+0x628/0x660 [caamhash]
    Call Trace:
    [e700fc30] [f9bf9c50] sg_copy_part+0xe0/0x160 [caamhash] (unreliable)
    [e700fc50] [f9bfcf28] ahash_update_no_ctx+0x628/0x660 [caamhash]
    [e700fcb0] [f954e19c] crypto_tls_genicv+0x13c/0x300 [tls]
    [e700fd10] [f954e65c] crypto_tls_encrypt+0x5c/0x260 [tls]
    [e700fd40] [c02250ec] __test_aead.constprop.9+0x2bc/0xb70
    [e700fe40] [c02259f0] alg_test_aead+0x50/0xc0
    [e700fe60] [c02241e4] alg_test+0x114/0x2e0
    [e700fee0] [c022276c] cryptomgr_test+0x4c/0x60
    [e700fef0] [c004f658] kthread+0x98/0xa0
    [e700ff40] [c000fd04] ret_from_kernel_thread+0x5c/0x64

    Signed-off-by: Herbert Xu
    Cc: Cristian Stoica
    Signed-off-by: Greg Kroah-Hartman

    (cherry picked from commit c9ccfcc2d0e33b3390574b41facc54cba59dbf98)
    (cherry picked from commit 3e2f6af66b8ad59ea1e4a47be9a3b5ba5c3e4a62)

    Cristian Stoica
     
  • When the M4 core is enabled on i.MX6, the QSPI2 clk can't be gated,
    otherwise, the M4 will hang. This patch add a check to make sure when
    M4 is enabled, just skip the QSPI2 clk gating operations.

    Signed-off-by: Bai Ping
    (cherry picked from commit e2f17323916eae636e63353d742c986227b72702)
    (cherry picked from commit 60def702db2c083cc6c0486100a829d71dc74845)

    Bai Ping
     
  • QSPI2/GPMI_IO share the same clock source but with the
    different gate, need explicitely gate the QSPI2 & GPMI_IO
    during the clock init phase according to the SOC design.

    The topo of the clock for the GPMI_IO and NAND as below:

    mux --> pre divider --> post divider --gate-- >GPMI_IO
    |-gate-- >QSPI2

    (Note: i.MX6SX:GPMI_NAND and GSPI2 is PINMUX conflicts.)

    The SOC design spec required that if change the parent clock
    of the GPMI_IO or QSPI2, need gate the GPMI_IO and QSPI2 first
    otherwise, there will have some glitch which cause the divider
    malfunciton. Thus, we need explicitely gate QSPI2 & GPMI_IO at
    the clock initialization phase and then later on common clock
    framework will gurantee that each time, the parent clock rate
    changes after the child clock is disabled(gated).

    Signed-off-by: Jason Liu
    (cherry picked from commit 7712fd2cfa2ba2d7577d2836cebd9ff7ac6d34a8)
    (cherry picked from commit 110d63a5886e065e77a69f816216af044c096a44)

    Jason Liu
     
  • QSPI may failed to alloc enough memory (256MB) for AHB read in
    previous implementation, especially in 3G/1G memory layout kernel.
    Dynamically alloc memory to avoid such issue.

    This implementation generally alloc 4MB memory for AHB read, it should
    be enough for common scenarios, and the side effect (0.6% performance
    drop) is minor.

    Previous implementation

    root@imx6qdlsolo:~# dd if=/dev/mtd0 of=/dev/null bs=1K count=32K
    32768+0 records in
    32768+0 records out
    33554432 bytes (34 MB) copied, 2.16006 s, 15.5 MB/s

    root@imx6qdlsolo:~# dd if=/dev/mtd0 of=/dev/null bs=32M count=1
    1+0 records in
    1+0 records out
    33554432 bytes (34 MB) copied, 1.43149 s, 23.4 MB/s

    After applied the patch

    root@imx6qdlsolo:~# dd if=/dev/mtd0 of=/dev/null bs=1K count=32K
    32768+0 records in
    32768+0 records out
    33554432 bytes (34 MB) copied, 2.1743 s, 15.4 MB/s

    root@imx6qdlsolo:~# dd if=/dev/mtd0 of=/dev/null bs=32M count=1
    1+0 records in
    1+0 records out
    33554432 bytes (34 MB) copied, 1.43158 s, 23.4 MB/s

    Signed-off-by: Allen Xu
    (cherry picked from commit ebcd4437450c4f0075988ef9c8824e837546c70b)

    Allen Xu
     
  • this is the enhanced fix for gpu kernel panic issue based on previous:
    gpu causes kernel panic when running bonnie++ with suspend/resume.

    Date: Jan 14, 2015
    Signed-off-by: Xianzhong
    Acked-by: Jason Liu
    (cherry picked from commit 5c8f06c77046e7ccca6a389af86431eb67e2b138)

    Xianzhong
     
  • In function gckKERNEL_Dispatch, powerMutexAcquired is used to track
    power mutex. It is missing from gcvHAL_WRITE_REGISTER. And in some
    places return value of gckOS_AcquireMutex is not checked.

    Date: Dec 29, 2014
    Signed-off-by: Zhenyong Chen
    Acked-by: Jason Liu
    (cherry picked from commit ee66831d2511f80416ddee8c79893c5e7d9cbad0)

    Zhenyong Chen
     
  • Only restore MII bus when MAC0 PHY is not available.

    Signed-off-by: Fugang Duan
    (cherry picked from commit 60d9d8ffd950947e52b5d99967f6741734bc5b03)

    Fugang Duan
     
  • AQAXiStatus register info is helpful to debug AXI BUS ERROR,
    need dump this GPU register when AXI BUS ERROR happen.

    Date: Dec 03, 2014
    Signed-off-by: Xianzhong
    Acked-by: Jason Liu
    (cherry picked from commit f92550c1310e339b3be4341b2032a60c1f0df280)

    Xianzhong
     

04 Jan, 2015

1 commit


24 Dec, 2014

1 commit

  • By previous implementation, there's the possibility that last picture remains
    on screen when the program exits. This can be reproduced by not calling
    STREAMOFF ioctl in v4l2 output application or just trying to kill the v4l2
    output program. The driver has faults to handle this case, since it depends on
    'pxp->s0_vbq.streaming' variable be true in close() function to call
    pxp_streamoff() while the variable is set to 0 after the application calls
    munmap(). The driver should call pxp_streamoff() even if the application
    does not call STREAMOFF ioctl.

    This patch uses the local 'streaming' variable to track the streaming
    status to fix this problem.

    Signed-off-by: Robby Cai

    Robby Cai
     

23 Dec, 2014

2 commits


22 Dec, 2014

2 commits