23 Feb, 2017

40 commits

  • Most of i.mx6 and i.mx7 board need to support WDOG_B reboot to workaroud some
    issues such as ldo-bypass, QSPI-NOR boot issue. Please enable 'fsl,wdog_b'
    property if you want to use WDOG_B reboot(trigger PMIC reboot).

    Signed-off-by: Robin Gong

    Robin Gong
     
  • This patch cherry-pick from below:
    "ENGR00317981: regulator: anatop: force vddpu to use same voltage level as vddsoc"

    The anatop on i.MX6 requires that vddpu use the same voltage level as
    vddsoc. It's a quick hacking to force the check whenever vddpu is
    about to be enabled.

    Signed-off-by: Shawn Guo
    Signed-off-by: Robin Gong
    (cherry picked from commit ab0c52e019cacc89aec3dbb104360b4715d49796)

    Conflicts:
    drivers/regulator/anatop-regulator.c

    Shawn Guo
     
  • add ldo bypass support on i.mx6q/dl and i.mx6sl.

    Signed-off-by: Robin Gong

    Robin Gong
     
  • enable PU bypass support on i.mx6 family.

    Signed-off-by: Robin Gong

    Robin Gong
     
  • Add LDO enable dtb for i.MX66UL-9x9-EVK board for those customers
    who want to use ldo enable mode.

    Conflicts:
    arch/arm/boot/dts/Makefile

    Signed-off-by: Anson Huang
    (cherry picked from commit 7e6c509e6ca1c4e83f72339f5bfb1ebb410d77ef)

    Anson Huang
     
  • i.MX6UL-9x9-EVK board has PFUZE3000, enable LDO bypass support.

    Signed-off-by: Anson Huang
    (cherry picked from commit 5118bf0b755a0b4fbd1f2999f3aa023208c8de82)

    Anson Huang
     
  • This patch adds suspend/resume with Mega/Fast mix off
    support for i.MX6UL-9x9-LPDDR2-EVK board, LPDDR2 has
    different MMDC restore flow compared to DDR3.

    Conflicts:
    arch/arm/mach-imx/pm-imx6.c

    Signed-off-by: Anson Huang
    (cherry picked from commit d5d3915aac04c2a80827d215d703e0f46309ed14)

    Anson Huang
     
  • Add i.MX6UL-9x9-LPDDR2-EVK board support.

    Conflicts:
    arch/arm/boot/dts/Makefile

    Signed-off-by: Anson Huang
    (cherry picked from commit d68759b1d9d769c83816d327fbeb1d85762a8e79)

    Anson Huang
     
  • Fixed wrong symbols of GPU in mxc/Makefile.

    Date Sep 22, 2015

    Signed-off-by: Shawn Xiao

    Shawn Xiao
     
  • The pm power's usage_count should be first added by
    one before putting it into suspend state. Otherwise
    the usage_count will be negative and the power cannot
    be put into suspend state correctly.

    Signed-off-by: Fancy Fang
    (cherry picked from commit a48460b41399112f5d3ae03b30e3f9e885346ff7)

    Conflicts:
    drivers/video/mxsfb.c

    Fancy Fang
     
  • On i.MX6UL, the VDD_ARM_IN and VDD_SOC_IN use the same power rail
    VDD_ARM_SOC_IN. For imx6ul-14x14-lpddr2-arm2 board, default, we use
    ldo-bypass mode and use the external PMIC regulator for cpufreq.so
    on this board, should use the setpoint of ldo-bypass mode.

    Signed-off-by: Bai Ping
    Signed-off-by: Peng Fan
    (cherry picked from commit d924e23fa60023bdbc601797ccda30c2c341a34a)

    Bai Ping
     
  • Add dts for mx6ul-14x14-lpddr2-arm2 board.
    Basic function tested: SD1/EMMC2/ENET/UART1 is ok.

    This patch takes mx6ul-14x14-ddr3-arm2.dts as a reference.

    Conflicts:
    arch/arm/boot/dts/Makefile

    Signed-off-by: Peng Fan
    (cherry picked from commit 8d10e92ed1b7d49332dec6f28c98250c28cdfa3f)

    Peng Fan
     
  • Add hs400 support for usdhc3 and add sd3.0 support for usdhc2.

    Signed-off-by: Haibo Chen

    Haibo Chen
     
  • Currently we only use 'tsc' for touch screen, so here remove
    the redundancy 'touchctrl'.

    Signed-off-by: Haibo Chen

    Haibo Chen
     
  • Add imx6ul touch screen driver support in imx_v7_defconfig
    and imx_v7_mfg_defconfig

    Signed-off-by: Haibo Chen

    Haibo Chen
     
  • Add usdhc1 support for SD3.0 and add usdhc3 support for HS400 mode.

    Signed-off-by: Haibo Chen

    Haibo Chen
     
  • The reason for this issue is that, on imx6sx platform, there is a display mix
    to control the display modules(including lcdif) power on/off. When the fb
    driver calls the 'pm_runtime_put_sync_suspend()', the display mix will be
    powered down. And at this moment, all the register settings for lcdif always
    have no effects. So the pm_runtime calling points in mxsfb driver should be
    optimized to avoid this kind of cases.

    Signed-off-by: Fancy Fang
    (cherry picked from commit 3b85eb989c89fb1c6d08215e435d72ab175e4e1e)

    Conflicts:
    drivers/video/mxsfb.c

    Fancy Fang
     
  • As streamoff/streamon will reset all buffer list, video output count should
    be reset to zero. Or timer will get wrong schedule time if input buffer time
    stamp is 0.

    Signed-off-by: Song Bing b06498@freescale.com

    Song Bing
     
  • Add IPU v4l2 output driver.

    Signed-off-by: Sandor Yu

    Sandor Yu
     
  • Forward imx_3.14.y mxc video output drivers to 4.1 kernel.

    The priv field of v4l2_pix_format is used to expand colorspace,
    and can not use to pass IPU input crop size.
    Add private IOCTL VIDIOC_S_INPUT_CROP and VIDIOC_G_INPUT_CROP
    to pass input crop size.

    Signed-off-by: Sandor Yu

    Sandor Yu
     
  • Regarding to the limitation of the iMX ADAP(pcie connector),
    only imx7d 12x12 arm2 board is used to verify the pcie
    ep/rc validation system on imx7d platforms

    Enalbe the msi pcie ep rc on it.
    Test howto:
    - Enable CONFIG_PCI_MSI=y, when rebuild the rc/ep images

    - EP side(console command and kernel message):
    root@imx6sxsabresd:~# ./memtool -32 =0
    Writing 32-bit value 0x0 to address

    - RC side(console command and kernel message):
    root@imx6sxsabresd:~# cat /proc/interrupts | grep MSI
    384: 1 PCI-MSI

    Note:
    imx6q msi_addr 0x01ff_8000
    imx6sx msi_addr 0x08ff_8000
    imx7d msi_addr 0x4ffc_0000

    Signed-off-by: Richard Zhu

    Richard Zhu
     
  • Regarding to the limitation of the iMX ADAP(pcie connector),
    only imx7d 12x12 arm2 board is used to verify the pcie
    ep/rc validation system on imx7d platforms

    hw setup:
    * two imx boards, one is used as pcie rc, the other is used
    as pcie ep. Connected by fsl pcie adap adaptor.

    sw setup:
    * when build rc image, make sure that
    CONFIG_IMX_PCIE=y
    # CONFIG_EP_MODE_IN_EP_RC_SYS is not set
    CONFIG_RC_MODE_IN_EP_RC_SYS=y
    * when build ep image
    CONFIG_IMX_PCIE=y
    CONFIG_EP_MODE_IN_EP_RC_SYS=y
    # CONFIG_RC_MODE_IN_EP_RC_SYS is not set

    features:
    * set-up link between rc and ep by their stand-alone
    ref clk running internally.

    * in ep's system, ep can access the reserved ddr memory
    (default address:0x4000_0000 on imx6q sd board, and
    0xb000_0000 on imx6sx sdb and imx7d arm2 boards) of
    pcie rc's system, by the interconnection between pcie
    ep and pcie rc.

    * add the configuration methods in the ep side, used to
    configure the start address and the size of the reserved
    rc's memory window.
    - cat /sys/devices/soc0/soc.1/1ffc000.pcie/rc_memw_info
    - echo 0x41000000 > /sys/devices/soc0/soc.1/1ffc000.pcie/rc_memw_start_set
    - echo 0x200000 > /sys/devices/soc0/soc.1/1ffc000.pcie/rc_memw_size_set

    * provide one example, howto configure the bar# and so on,
    when pcie ep emaluates one memory ram ep device

    * setup one new outbound memory region at rc side, used
    to let imx pcie rc can access the memory of imx pcie ep
    in imx pcie rc ep validation system.
    - set the default address of the ddr memory to be 0x4000_0000
    on imxq sd board, and 0xb000_0000 on imx6sx sdb and imx7d
    arm2 boards.

    NOTE:
    * boot up ep platform firstly, then boot up rc platform.
    * make sure that mem=768M is contained in the kernel command line,
    since the start address of the upper 256mb of the 1g ddr mem is
    reserved to do the pcie ep rc access operations in default.

    Test howto of the RC access memory of EP on imx6q sd platforms.
    step1:
    EP side:
    1.1:
    echo > /sys/devices/.../pcie/ep_bar0_addr

    1.2:
    memtool -32 4
    E
    Reading 0x4 count starting at address 0x40000000

    : 6FE9E9F6 7583FBB9 39EAEFEA FBDCFD78

    step2:
    RC side:
    memtool -32 =58D454DA
    memtool -32 =7332095B

    step3:
    EP side:
    memtool -32 4
    E
    Reading 0x4 count starting at address 0x40000000

    : 58D454DA 7332095B 39EAEFEA FBDCFD78

    Signed-off-by: Richard Zhu

    Richard Zhu
     
  • - enable pcie functions on imx7d platforms
    - grst/brst should be asserted/de-asserted during resume,
    since the pcie power would be cut off automatically by HW
    during system suspend/resume

    Signed-off-by: Richard Zhu

    Richard Zhu
     
  • - move "program correct class for RC" from dw_pcie_host_init()
    to dw_pcie_setup_rc(). since this is RC setup, it's
    better to contained in dw_pcie_setup_rc function.
    Then, RC can be re-setup really by dw_pcie_setup_rc().
    - add one store/re-store msi cfg functions. Because that
    pcie controller maybe powered off during system suspend,
    and the msi data configuration would be lost.
    these functions can be used to store/restore the msi data
    and msi_enable during the suspend/resume callback.

    Signed-off-by: Richard Zhu

    Richard Zhu
     
  • - For PCIe module on i.mx7d, some GPC operations would
    be mandatory required when PCIe PHY is powered on/off.
    So we need update gpc driver for the new requirements.
    We implement it by regulator notify framwork in gpcv2
    driver.
    NOTE:
    make sure gpc driver is ready before PCIe driver is probed.
    Otherwise, cause system hang during PCIe driver probe,
    because the notify NOT installed ready and the gpc will
    NOT power on PCIe.
    - config the imx7d pcie

    Signed-off-by: Richard Zhu

    Richard Zhu
     
  • enable pcie support on imx7d platforms.

    Signed-off-by: Richard Zhu

    Richard Zhu
     
  • default is 8. android require more.
    Change to 16.

    Signed-off-by: Frank Li

    Frank Li
     
  • arch/arm/mach-imx/built-in.o: In function `clk_pllv3_do_shared_clks':
    :(.text+0xed8): undefined reference to `imx_sema4_mutex_lock'
    :(.text+0xf04): undefined reference to `imx_sema4_mutex_unlock'
    arch/arm/mach-imx/built-in.o: In function `clk_gate2_do_shared_clks':
    :(.text+0x1208): undefined reference to `imx_sema4_mutex_lock'
    :(.text+0x1234): undefined reference to `imx_sema4_mutex_unlock'
    arch/arm/mach-imx/built-in.o: In function `clk_pfd_do_shared_clks':
    :(.text+0x15f4): undefined reference to `imx_sema4_mutex_lock'
    :(.text+0x1620): undefined reference to `imx_sema4_mutex_unlock'
    arch/arm/mach-imx/built-in.o: In function `imx_amp_power_init':
    :(.init.text+0x10d50): undefined reference to `imx_sema4_mutex_create'
    drivers/built-in.o: In function `mxcfb_unregister':
    :(.text+0x20e70): undefined reference to `ipu_free_irq'
    :(.text+0x20e94): undefined reference to `ipu_free_irq'
    :(.text+0x20eac): undefined reference to `ipu_free_irq'
    drivers/built-in.o: In function `fbi_to_pixfmt':

    Signed-off-by: Frank Li

    Frank Li
     
  • This reverts commit b71c99801e18eb172ae34851daf25044a3bf644a.

    Signed-off-by: Oliver Brown
    (cherry picked from commit 5c74966c0e7deb0ac84b3fa8a84c6c942e7d434f)

    Conflicts:
    drivers/media/v4l2-core/v4l2-compat-ioctl32.c
    include/media/v4l2-subdev.h

    Oliver Brown
     
  • 1. Upstream 5.0.11p7 driver to kernel

    2. Add the GPU configuration to imx6q.dtsi

    3. Remove IRQF_DISABLED in GPU driver
    The IRQF_DISABLED has been removed from 4.1.0 kernel. To accomodate with
    the change, add version check logic and use 0x0 instead of IRQF_DISABLED
    from 4.1.0 kernel on.

    4. Convert file->f_dentry->d_inode to file_inode() in GPU driver
    The file struct has changed since 3.19. Changed the usage in GPU driver
    too.

    5. Add version check for CONFIG_PM_RUNTIME
    The CONFIG_PM_RUNTIME will never be used in 4.1.0 kernel. Add version
    check to avoid calling it in GPU driver.

    Signed-off-by: Shawn Xiao

    Shawn Xiao
     
  • We should use hwirq instead of logic number at gpc driver, otherwise,
    it may override other global memory due to write out of boundary
    for array, eg: below oops may kernel at imx7d sdb board during suspend/
    resume test:

    INFO: rcu_preempt detected stalls on CPUs/tasks:
    1: (2 GPs behind) idle=b25/140000000000000/0 softirq=1951/1957 fqs=0
    (detected by 0, t=2102 jiffies, g=847, c=846, q=4)
    Task dump for CPU 1:
    swapper/1 R running 6088 0 1 0x00000000
    [] (__schedule) from [] (schedule+0x4c/0xa4)
    [] (schedule) from [] (arch_cpu_idle_dead+0x18/0x1c)
    [] (arch_cpu_idle_dead) from [] (cpu_startup_entry+0x2e0/0x450)
    [] (cpu_startup_entry) from [] (secondary_start_kernel+0x13c/0x15c)
    [] (secondary_start_kernel) from [] (__enable_mmu+0x0/0x14)
    rcu_preempt kthread starved for 2102 jiffies!
    NMI watchdog: BUG: soft lockup - CPU#0 stuck for 22s! [rtcwakeup.out:735]
    Modules linked in: evbug
    CPU: 0 PID: 735 Comm: rtcwakeup.out Tainted: G W 4.1.4-00701-g32bb3ba-dirty #370
    Hardware name: Freescale i.MX7 Dual (Device Tree)
    task: a8920a00 ti: a99bc000 task.ti: a99bc000
    PC is at _raw_spin_lock+0x4c/0x60
    LR is at get_parent_ip+0x14/0x30
    pc : [] lr : [] psr: 80000013
    sp : a99bdcd8 ip : a99bdca8 fp : a99bdcec
    r10: 80d4455c r9 : 00008070 r8 : 00000010
    r7 : 00000000 r6 : 00000000 r5 : 00000001 r4 : 80e09934
    r3 : 00000001 r2 : 00000000 r1 : 00000000 r0 : 00000000
    Flags: Nzcv IRQs on FIQs on Mode SVC_32 ISA ARM Segment user
    Control: 10c5387d Table: a9f0006a DAC: 00000015
    CPU: 0 PID: 735 Comm: rtcwakeup.out Tainted: G W 4.1.4-00701-g32bb3ba-dirty #370
    Hardware name: Freescale i.MX7 Dual (Device Tree)
    [] (unwind_backtrace) from [] (show_stack+0x20/0x24)
    [] (show_stack) from [] (dump_stack+0x8c/0xcc)
    [] (dump_stack) from [] (show_regs+0x1c/0x20)
    [] (show_regs) from [] (watchdog_timer_fn+0x290/0x2fc)
    [] (watchdog_timer_fn) from [] (__run_hrtimer+0x90/0x294)
    [] (__run_hrtimer) from [] (hrtimer_interrupt+0x11c/0x2ac)
    [] (hrtimer_interrupt) from [] (arch_timer_handler_phys+0x40/0x48)
    [] (arch_timer_handler_phys) from [] (handle_percpu_devid_irq+0xac/0x1d0)
    [] (handle_percpu_devid_irq) from [] (generic_handle_irq+0x3c/0x4c)
    [] (generic_handle_irq) from [] (__handle_domain_irq+0x8c/0xfc)
    [] (__handle_domain_irq) from [] (gic_handle_irq+0x34/0x6c)
    [] (gic_handle_irq) from [] (__irq_svc+0x40/0x74)
    Exception stack(0xa99bdc90 to 0xa99bdcd8)
    dc80: 00000000 00000000 00000000 00000001
    dca0: 80e09934 00000001 00000000 00000000 00000010 00008070 80d4455c a99bdcec
    dcc0: a99bdca8 a99bdcd8 8005c080 808a2e74 80000013 ffffffff
    [] (__irq_svc) from [] (_raw_spin_lock+0x4c/0x60)
    [] (_raw_spin_lock) from [] (imx_enable_cpu+0x34/0xc8)
    [] (imx_enable_cpu) from [] (imx_cpu_kill+0x60/0x94)
    [] (imx_cpu_kill) from [] (__cpu_die+0x60/0x94)
    [] (__cpu_die) from [] (_cpu_down+0x1e4/0x2fc)
    [] (_cpu_down) from [] (disable_nonboot_cpus+0xd0/0x264)
    [] (disable_nonboot_cpus) from [] (suspend_devices_and_enter+0x344/0x910)
    [] (suspend_devices_and_enter) from [] (pm_suspend+0x3ec/0x6e4)
    [] (pm_suspend) from [] (state_store+0x7c/0xcc)
    [] (state_store) from [] (kobj_attr_store+0x1c/0x28)
    [] (kobj_attr_store) from [] (sysfs_kf_write+0x54/0x58)
    [] (sysfs_kf_write) from [] (kernfs_fop_write+0xc8/0x1ac)
    [] (kernfs_fop_write) from [] (__vfs_write+0x34/0xe8)
    [] (__vfs_write) from [] (vfs_write+0xa0/0x174)
    [] (vfs_write) from [] (SyS_write+0x54/0xb0)
    [] (SyS_write) from [] (ret_fast_syscall+0x0/0x3c)

    Signed-off-by: Peter Chen

    Peter Chen
     
  • In the frame_to_bytes(), when hw_ptr*frame_bits exceed the maxmum of unsigned
    long, the return value is saturated, so the appl_bytes is wrong.
    This patch is to correct the usage of frame_to_bytes().

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

    Shengjiu Wang
     
  • No need to alloc bd for hdmi audio, and the period len of hdmi audio is
    0, so add constraint for it.

    And correct per_address and per_address2 for hdmi audio.

    Signed-off-by: Zidan Wang

    Zidan Wang
     
  • enable hdmi audio sound card

    Signed-off-by: Zidan Wang

    Zidan Wang
     
  • correct hdmi peripheral type

    Signed-off-by: Zidan Wang

    Zidan Wang
     
  • cherry-pick below patch from v3.14.y:
    ENGR00330403-2: ASoC: fsl_hdmi: port hdmi audio driver from imx_3.10.y

    Port HDMI audio driver (CPU driver, machine driver, platform driver) from
    imx_3.10.y.

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

    Shengjiu Wang
     
  • export this for 'make headers_install'

    Signed-off-by: Robby Cai

    Robby Cai
     
  • export this for 'make headers_install'

    Signed-off-by: Robby Cai

    Robby Cai
     
  • Add mxc_asrc.h to Kbuild. otherwise this header is not installed by
    "make headers_install INSTALL_HDR_PATH=XXX".

    Signed-off-by: Shengjiu Wang

    Shengjiu Wang
     
  • Add v4l2 and dcic head file.

    Signed-off-by: Sandor Yu

    Sandor Yu