summaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2014-04-29serial: imx: Remove init() and exit() platform callbacksrel_imx_3.10.31_1.1.0_alphaAlexander Shiyan
Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Huang Shijie <b32955@freescale.com>
2014-04-29serial: imx: Use dev_name() for request_irq() to distinguish UARTsAlexander Shiyan
Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Huang Shijie <b32955@freescale.com>
2014-04-29serial: imx: Use devm_ioremap_resource()Alexander Shiyan
Use devm_ioremap_resource() in order to make the code simpler and it gives proper codes on errors. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Huang Shijie <b32955@freescale.com>
2014-04-28bluetooth: hci_ldisc: fix deadlock conditionFelipe Balbi
LDISCs shouldn't call tty->ops->write() from within ->write_wakeup(). ->write_wakeup() is called with port lock taken and IRQs disabled, tty->ops->write() will try to acquire the same port lock and we will deadlock. Acked-by: Marcel Holtmann <marcel@holtmann.org> Reviewed-by: Peter Hurley <peter@hurleysoftware.com> Reported-by: Huang Shijie <b32955@freescale.com> Signed-off-by: Felipe Balbi <balbi@ti.com> Tested-by: Andreas Bießmann <andreas@biessmann.de> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Huang Shijie <b32955@freescale.com>
2014-04-28ENGR00310742 [#1087] fixed gpu database query failureXianzhong
this patch fix gpu database query failure with gmem_info Date: Apr 28, 2014 Signed-off-by: Xianzhong <b07117@freescale.com> Acked-by: Jason Liu (cherry picked from commit e04a8681a977153c7adf34c36d7ee33218cfcab3)
2014-04-25ENGR00310498 usb: chipidea: otg: fix otg role switch from host to device failureLi Jun
This patch fix the failure when OTG port switch from host to device mode after removes ID cable with usb device(e.g usb hub) connected. How to reproduce: - Enable console wakeup: echo enabled > /sys/class/tty/ttymxc0/power/wakeup - Connect a usb hub with ID cable to OTG port. - Suspend the system: ehco mem > /sys/power/state - Wakeup the system by console. - Remove ID cable together with usb hub. - OTG port cannot switch to device role. Root cause: In this case, ID change interrupt generates before port change interrupt, so with irq disabled, ci_handle_id_switch() will find there is usb device still connected and wait it to disconnect by sleep, but disconnect will not happen since usb irq still disabled so port change irq has no chance to be handled. How this patch is fixing this issue: This patch enables irq before sleep and disables irq after, thus port change irq can be handled and usb device disconnection can timely happen, then ci_handle_id_switch() can stop host and switch to device role correctly. meanwhile change the delay time to 10~15 ms to avoid too frequent connection check and irq enable/disable. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-24ENGR00301281 media: mxc vout: set input resolution back after PP check/processLiu Ying
In VDOA PP mode, the input resolution would be changed to be VDOA's output for PP to use as its input resolution to go on to do resizing or color space conversion. The input resolution will be different from the original one when VDOA input cropping is enabled. And, this finally causes a wrong input resolution being used if the users do rotation by calling the S_CTRL ioctrl in runtime. In order to fix this issue, this patch sets the original input resolution back after PP task check and process. The issue can be reproduced by the following command line(enable VDOA mode in the gst plugin configuration file first): gplay AVC_MP30_854x356_23.976_679_AACLC_44.1_96_2_TRON_LEGACY.flv (Enter 't 90' to change to rotate 90 degrees in runtime.) In this case, VDOA input cropping(854x356 -> 848x352) is enabled because VDOA input resolution should align to macro block size. Signed-off-by: Liu Ying <Ying.Liu@freescale.com> (cherry picked from commit 4c732ad69265d8e441e6c15a2e87f5aeef234624)
2014-04-24ENGR00309915 [#1087] enhanced video memory mutexXianzhong
this patch can fix NULL pointer issue in GPU kernel driver with the following log [<7f240438>] (gckEVENT_AddList+0x0/0x810 [galcore]) from [<7f239ebc>] (gckCOMMAND_Commit+0xf28/0x118c [galcore]) [<7f238f94>] (gckCOMMAND_Commit+0x0/0x118c [galcore]) from [<7f2362dc>] (gckKERNEL_Dispatch+0x120c/0x24e4 [galcore]) [<7f2350d0>] (gckKERNEL_Dispatch+0x0/0x24e4 [galcore]) from [<7f222280>] (drv_ioctl+0x390/0x540 [galcore]) [<7f221ef0>] (drv_ioctl+0x0/0x540 [galcore]) from [<800facd0>] (vfs_ioctl+0x30/0x44) The false code is at 0x217bc where the 0-pointer happens (r3 = 0) gcuVIDMEM_NODE_PTR node = (gcuVIDMEM_NODE_PTR)(gcmUINT64_TO_PTR(Record->info.u.FreeVideoMemory.node)); 217b8: e5953028 ldr r3, [r5, #40] ; 0x28 if (node->VidMem.memory->object.type == gcvOBJ_VIDMEM) 217bc: e5932000 ldr r2, [r3] 217c0: e5922000 ldr r2, [r2] 217c4: e152000a cmp r2, sl { gcmkVERIFY_OK(gckKERNEL_RemoveProcessDB(Event->kernel, Date: Apr 23, 2014 Signed-off-by: Xianzhong <b07117@freescale.com> Acked-by: Jason Liu (cherry picked from commit 13859c2276997dbfd1b45aff1ff598e2ee1d4f74)
2014-04-23ENGR00310027 net:fec: return the suitable value in irq handlerFugang Duan
The current return value is not right beacause there may have irq interrupt that is processed. So correct the return value. Signed-off-by: Fugang Duan <B38611@freescale.com>
2014-04-22ENGR00309727 net:fec: fix mdio timeout issueFugang Duan
The issue can be reproduced after overninght test, reproduced step: nfs mount rootfs, don't do any other ethernet test cases. If the issue generates, there has log: fec 2188000.ethernet eth0: MDIO read timeout The origin interrupt handler may ignore to process mdio interrupt in current irq handler until the next irq action. If the next irq comes in time that is less than the mdio wait time, the next irq handler wake up a single thread waiting on this completion, MDIO read function can get the single before time expired. Otherwise, MDIO read generate timeout issue. The patch just to fix the issue. Signed-off-by: Fugang Duan <B38611@freescale.com>
2014-04-22ENGR00309701 usb: phy: otg-fsm: export symbol of otg_statemachineLi Jun
This patch exports symbol of otg_statemachine for kernel module to use it. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-22ENGR00309582 [#1129] fixed context switch issue on GC400TXianzhong
fixed 3D context switch issue, the original comments from Vivante Set command->using2D correctly when gcdCMD_NO_2D_CONTEXT = 1 this patch is to fix Android mess UI issue on GC400T Date: Apr 21, 2014 Signed-off-by: Xianzhong <b07117@freescale.com> Acked-by: Jason Liu (cherry picked from commit 31ced071862c9e28d10c8680919637b716296786)
2014-04-22ENGR00309261 Wrong version number in gpu 5.0.11Zhenyong Chen
gcvVERSION_STRING is not consistent with gcvVERSION_BUILD. Vivante will provide a more flexible way in future release. Date: Apr 18, 2014 Signed-off-by: Zhenyong Chen <b07273@freescale.com> Acked-by: Jason Liu (cherry picked from commit e3a5ec334a239599f7ea2ab98ec5fc8c576b614f)
2014-04-21ENGR00292154-13 [#1141]Fix Kernel panic when contiguous memory used upLoren Huang
-When allocation failed, the node will be null. node->Virtual.type access will cause kernel panic when forceContiguous is enabled. Date: Apr 21,2014 Signed-off-by: Loren Huang <b02279@freescale.com> Acked-by: Shawn Guo (cherry picked from commit 9b5b98b69201135fef0500907ecb3320b128ef0f)
2014-04-21ENGR00308898 [#1135] fixed gc400t gpu hang with 5.0.11Xianzhong
Virtual command buffer is forcibly enabled and causes gpu hang on i.MX6SLX - Android GPU hang - X11 GPU hang when run es2gears - Dfb 2D test case df_dok may cause gpu hang. The safe fix is to disable virtual command buffer temporarily Date: Apr 17, 2014 Signed-off-by: Xianzhong <b07117@freescale.com> Acked-by: Jason Liu (cherry picked from commit f0aaa7521e0e58b4a7c9f104271343ab277fed56) (cherry picked from commit a5730ef091adfc28b8fd3866bf9a771bff09d8ea)
2014-04-20ENGR00308631 usb: chipidea: fix oops if unload module too fastPeter Chen
We have a 2s timer once the wakeup occurs, if we unload module within 2s before wakeup occurs, the timer is still active, so we need to delete the timer before the destroy of struct ci_hdrc, otherwise, the below oops will occur. ci_hdrc ci_hdrc.1: remove, state 1 usb usb1: USB disconnect, device number 1 usb 1-1: USB disconnect, device number 2 ci_hdrc ci_hdrc.1: USB bus 1 deregistered ci_hdrc ci_hdrc.1: ci_otg_thread quits Unable to handle kernel NULL pointer dereference at virtual address 00000000 pgd = a9474000 [00000000] *pgd=a84b1831, *pte=00000000, *ppte=00000000 Internal error: Oops: 80000007 [#1] PREEMPT SMP ARM Modules linked in: ci_hdrc_imx(-) usbmisc_imx ci_hdrc ehci_hcd udc_core phy_mxs_usb evbug [last unloaded: configfs] CPU: 0 PID: 11542 Comm: modprobe Not tainted 3.10.17-01265-ga8a6771-dirty #561 task: a81243c0 ti: a94b4000 task.ti: a94b4000 PC is at 0x0 LR is at call_timer_fn.isra.29+0x24/0x84 pc : [<00000000>] lr : [<8003189c>] psr: 200b0113 sp : a94b5d68 ip : 00000000 fp : 00000000 r10: a94b5d88 r9 : 00000000 r8 : 00200200 r7 : 00000000 r6 : 80c320c0 r5 : 00000100 r4 : a94b4000 r3 : a94b5d68 r2 : a94b5d80 r1 : 00000000 r0 : 00000000 Flags: nzCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment user Control: 10c53c7d Table: a947404a DAC: 00000015 Process modprobe (pid: 11542, stack limit = 0xa94b4238) Stack: (0xa94b5d68 to 0xa94b6000) 5d60: 000797ae 00015220 80c2c620 80cc1ac0 00000000 80c320c0 5d80: 80cc22d4 80031ab4 a94b5d88 a94b5d88 00000000 00000101 80c32084 a94b4000 5da0: 00000100 80cc1880 00000000 80c32080 00000001 8002c4b4 000000c3 a8009240 5dc0: 00000004 0000000a 000797af 00404100 018c8300 600b0193 00000057 00000000 5de0: c0802100 8000e2c4 a94b4000 00000000 018c8300 8002c624 a94b4000 8002c898 5e00: 80c2cef0 8000ea04 c080210c 80c38904 a94b5e30 80008538 80115b7c 80115b8c 5e20: a00b0013 ffffffff a94b5e64 8000dd40 80c45808 00000000 00000001 00000000 5e40: a83f8900 00000000 a94b5e98 00000081 8000e2c4 a94b4000 00000000 018c8300 5e60: 00000001 a94b5e78 80115b7c 80115b8c a00b0013 ffffffff 00000000 00000000 5e80: a83f83c0 a83f83c0 a83f83c0 80b349b4 00000000 801140fc a83f83c0 a83f8900 5ea0: 80c56ae8 a83f83c0 a80c4610 80117454 00000000 80c56aa0 a88bc018 8030b9ac 5ec0: ffffffff a88bc010 a80c4610 8030437c a88bc000 a80c4600 a80c4610 80308510 5ee0: 7f7d21c0 a88bc000 a80c4600 803088b4 00000000 7f7c0500 a83c4c10 7f7d21e0 5f00: a80c4610 7f7d3250 a80c4644 8030827c 80308264 80306b70 7f7d3250 a80c4610 5f20: 7f7d3250 80307360 7f7d3290 7f7d3250 80c56710 803069a0 7f7d3290 00000000 5f40: a94b4000 800679d0 00000020 685f6963 5f637264 00786d69 a81243c0 800495b4 5f60: 80c2ceac 00000000 018c8300 80049578 018c8300 8003f614 8000e2c4 000f000f 5f80: a89b7840 004b4000 7f7d3290 00000800 a94b5f94 00000000 018c8300 018c8334 5fa0: 018c8334 8000e140 018c8300 018c8334 018c8334 00000800 7ee8aa50 0002e6b0 5fc0: 018c8300 018c8334 018c8334 00000081 00000001 7ee8be0c 7ee8be04 018c8300 5fe0: 76ebcf40 7ee8aa2c 00019268 76ebcf4c 60070010 018c8334 abf58811 abf58c11 [<8003189c>] (call_timer_fn.isra.29+0x24/0x84) from [<80031ab4>] (run_timer_softirq+0x1b8/0x1cc) [<80031ab4>] (run_timer_softirq+0x1b8/0x1cc) from [<8002c4b4>] (__do_softirq+0xd8/0x1b8) [<8002c4b4>] (__do_softirq+0xd8/0x1b8) from [<8002c624>] (do_softirq+0x4c/0x58) [<8002c624>] (do_softirq+0x4c/0x58) from [<8002c898>] (irq_exit+0x90/0xc8) [<8002c898>] (irq_exit+0x90/0xc8) from [<8000ea04>] (handle_IRQ+0x3c/0x90) [<8000ea04>] (handle_IRQ+0x3c/0x90) from [<80008538>] (gic_handle_irq+0x28/0x5c) [<80008538>] (gic_handle_irq+0x28/0x5c) from [<8000dd40>] (__irq_svc+0x40/0x70) Exception stack(0xa94b5e30 to 0xa94b5e78) 5e20: 80c45808 00000000 00000001 00000000 5e40: a83f8900 00000000 a94b5e98 00000081 8000e2c4 a94b4000 00000000 018c8300 5e60: 00000001 a94b5e78 80115b7c 80115b8c a00b0013 ffffffff [<8000dd40>] (__irq_svc+0x40/0x70) from [<80115b8c>] (sysfs_addrm_finish+0x24/0xd4) [<80115b8c>] (sysfs_addrm_finish+0x24/0xd4) from [<801140fc>] (sysfs_hash_and_remove+0x4c/0x88) [<801140fc>] (sysfs_hash_and_remove+0x4c/0x88) from [<80117454>] (sysfs_unmerge_group+0x40/0x7c) [<80117454>] (sysfs_unmerge_group+0x40/0x7c) from [<8030b9ac>] (dpm_sysfs_remove+0x20/0x3c) [<8030b9ac>] (dpm_sysfs_remove+0x20/0x3c) from [<8030437c>] (device_del+0x34/0x178) [<8030437c>] (device_del+0x34/0x178) from [<80308510>] (platform_device_del+0x14/0xa8) [<80308510>] (platform_device_del+0x14/0xa8) from [<803088b4>] (platform_device_unregister+0xc/0x18) [<803088b4>] (platform_device_unregister+0xc/0x18) from [<7f7c0500>] (ci_hdrc_remove_device+0xc/0x20 [ci_hdrc]) [<7f7c0500>] (ci_hdrc_remove_device+0xc/0x20 [ci_hdrc]) from [<7f7d21e0>] (ci_hdrc_imx_remove+0x20/0xc8 [ci_hdrc_imx]) [<7f7d21e0>] (ci_hdrc_imx_remove+0x20/0xc8 [ci_hdrc_imx]) from [<8030827c>] (platform_drv_remove+0x18/0x1c) [<8030827c>] (platform_drv_remove+0x18/0x1c) from [<80306b70>] (__device_release_driver+0x70/0xcc) [<80306b70>] (__device_release_driver+0x70/0xcc) from [<80307360>] (driver_detach+0xac/0xb0) [<80307360>] (driver_detach+0xac/0xb0) from [<803069a0>] (bus_remove_driver+0x7c/0xc0) [<803069a0>] (bus_remove_driver+0x7c/0xc0) from [<800679d0>] (SyS_delete_module+0x144/0x1f8) [<800679d0>] (SyS_delete_module+0x144/0x1f8) from [<8000e140>] (ret_fast_syscall+0x0/0x30) Code: bad PC value Signed-off-by: Peter Chen <peter.chen@freescale.com>
2014-04-19clocksource: vf_pit_timer: use complement for sched_clock readingStefan Agner
commit 224aa3ed45c8735ae02bb2ecca002409fa6aa772 upstream. Vybrids PIT register is monitonic decreasing. However, sched_clock reading needs to be monitonic increasing. Use bitwise not to get the complement of the clock register. This fixes the clock going backward. Also, the clock now starts at 0 since we load the register with the maximum value at start. Signed-off-by: Stefan Agner <stefan@agner.ch> Acked-by: Shawn Guo <shawn.guo@linaro.org> Cc: daniel.lezcano@linaro.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux@arm.linux.org.uk Link: http://lkml.kernel.org/r/d25af915993aec1b486be653eb86f748ddef54fe.1394057313.git.stefan@agner.ch Cc: stable@vger.kernel.org Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Shawn Guo <shawn.guo@freescale.com>
2014-04-18ENGR00309045 net: fec_ptp: fix timestamp errors when do stress testFugang Duan
"FSL_stressPTP" tool is supposed to test the capability characteristics of a ptp stack porting. The stresstest shall measure the overall load of the stack under test by sending delay request and signalling messages.The higher the overall load on the stack is, the higher your packet loss will be. The patch fix the timestamp error in high overall load stress test like: ./FSL_stressPTP -u -b 10.192.242.10 -d 10.192.242.6 -e eth0 -m 00:01:02:04:04:19 -i 100 -t 10 -f -6 -s -6 -c 10 And enet interrupt coalescing feature introduce ptp packet latency, which may cause that the timestamp don't store the related timestamp buffer when stack use ioctl interface to access the message. So add some 4ms delay after getting timestamp fail to let the next looking up success. Suggest to disable interrupt coalescing feature by ethtool when run 1588 cases. Signed-off-by: Fugang Duan <B38611@freescale.com> (cherry picked from commit 11107938cc5a4a7cb4e5fc5e00d248183ed43d93)
2014-04-18ENGR00309055 net: fec_ptp: optimize 1588 convergent performanceFugang Duan
1588 convergence process (setup time about 15s) is not ideal: Applied a time jump on the reference master which causes both slaves to apply a time jump as well and then synchronize back to the nanoseconds. Optimize the 1588 adjust algorithm to get better convergent action. Signed-off-by: Fugang Duan <B38611@freescale.com> (cherry picked from commit 46a727f7ef469ae7c77c3458efd8a0de2396c360)
2014-04-18ENGR00308397 video: mxsfb: unblank fb explicitly in probe()Liu Ying
The following two commits for backlight core driver introduce an usecount for each backlight device and on/off usage info of each framebuffer associated with it so that we may enable/disable a backlight device when necessary. commit dcb7e61054b959dc4d601a96cce5cc85ad1568ef commit b48b097319587422195adc3f8b2b3b0c067943cc The problem is that some framebuffer drivers would enable their display controllers in probe() and some backlight device drivers would enable their backlights in probe() so that the backlight device usecounts and the on/off usage info of framebuffers are out of counting at the probing stage. This causes a backlight cannot be disabled by blanking the relevant framebuffer(s) before any fb unblanking operation, though it's quite reasonable for the userland to unblank the framebuffer(s) before using it. In order to avoid the potential unnecessary lighten backlight left behind for the mxsfb driver, this patch unblanks framebuffer explicitly in probe() since the LCDIF display controller is actually enabled there. Signed-off-by: Liu Ying <Ying.Liu@freescale.com> (cherry picked from commit 61667ae1430849af17e2431bbe9290295e0ec492)
2014-04-17ENGR00308770-2 : dma: sdma: add new sdma scripts for qspi/canfdRobin Gong
update sdma script and the script number. Signed-off-by: Robin Gong <b38343@freescale.com>
2014-04-17ENGR00307014-06 vadc: Enable vadc functionSandor Yu
Enable vadc function. That can work at PAL 720x576 and NTSC 720x480 mode. Signed-off-by: Sandor Yu <R01008@freescale.com>
2014-04-17ENGR00307014-03 v4l2 capture: support for vadcSandor Yu
-Add v4l2 capture ioctl VIDIOC_S_INPUT, VIDIOC_G_INPUT,VIDIOC_ENUMINPUT, VIDIOC_S_STD,VIDIOC_G_STD support. -Add NTSC, PAL format define. -Add parameter cam_input_fmt to save camera sensor format. Signed-off-by: Sandor Yu <R01008@freescale.com>
2014-04-17ENGR00307014-02 csi: update csi driver to support vadcSandor Yu
-Add csi control register 18 define. -Add csi_tvdec_enable and csi_deinterlace_mode for vadc. -Add csi_set_32bit_imagpara function to support YUV444 format. Signed-off-by: Sandor Yu <R01008@freescale.com>
2014-04-17ENGR00307014-01 dma: pxp: Add YUV444 csc supportSandor Yu
Add YUV444 csc support in pxp driver. Signed-off-by: Sandor Yu <R01008@freescale.com>
2014-04-17ENGR00309070 [#1136] fixed GPU kernel random crash in 5.x driverXianzhong
database list corruption is caused by the extensive surface type(>=0x100) some random kernel crash issues will be introduced by data corruption this fix is to clear the extensive surface type with 0xFF mask, referring to gcvSURF_NUM_TYPES, /* Make sure this is the last one! */ /* Combinations. */ gcvSURF_NO_TILE_STATUS = 0x100, gcvSURF_NO_VIDMEM = 0x200, /* Used to allocate surfaces with no underlying vidmem node. In Android, vidmem node is allocated by another process. */ gcvSURF_CACHEABLE = 0x400, /* Used to allocate a cacheable surface */ Date: Apr 17, 2014 Signed-off-by: Xianzhong <b07117@freescale.com> Acked-by: Jason Liu (cherry picked from commit 0f79bbd805402a8dcdf22bb119f99f05d8b9e4c3)
2014-04-17ENGR00308899 [#1087] enhanced GPU database protectionXianzhong
the potential risk is found in special case when application exit, deleting record will cause the unexpected issue when process database is destoryed without atom protection the enhanced database patch should be applied to avoid the unexpected kernel issue Date: Apr 17, 2014 Signed-off-by: Xianzhong <b07117@freescale.com> Acked-by: Jason Liu (cherry picked from commit 00ef75b4f50933749a2fd569488510ab760de4a9)
2014-04-17ENGR00292154-12 gpu:Correct freescale memory allocation functionLoren Huang
-Fix a issue during cma 5.0.11 integration. With this issue cma allocation will not return error when allocation failed. Date: Apr 17, 2014 Signed-off-by: Loren Huang <b02279@freescale.com> Acked-by: Shawn Guo
2014-04-16ENGR00307558-13 usb: chipidea: otg-fsm: enable low power mode for otg fsm mode.Li Jun
This patch enables runtime pm support for otg fsm mode. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-12 usb: chipidea: udc: usb charger handling when otg fsm modeLi Jun
This patch adds usb charger notify condition when usb otg fsm is enabled, do not do charger notify when doing role switch. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-9 usb: chipidea: debug: add debug file for OTG variablesLi Jun
This patch adds a debug file for OTG vairables show. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-8 usb: chipidea: add sys inputs for OTG fsm input.Li Jun
This patch adds sys input to control and show OTG fsm inputs by application, user can do host and preipheral role switch by change these inputs. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-7 usb: chipidea: OTG HNP and SRP fsm implementation.Li Jun
USB OTG interrupt handling and fsm transitions according to USB OTG and EH 2.0. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-6 usb: chipidea: OTG fsm timers initialization.Li Jun
This patch adds OTG fsm timers initialization, which use controller's 1ms interrupt as timeout counter, also adds some local timers which are not in otg_fsm_timer list. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-5 usb: chipidea: add OTG fsm operation functions implemenation.Li Jun
Add OTG HNP and SRP operation functions implementation: - charge vbus - drive vbus - connection signaling - drive sof - start data pulse - add fsm timer - delete fsm timer - start host - start gadget Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-4 usb: chipidea: udc: driver update for OTG HNP.Li Jun
Add b_hnp_enable request handling and enable gadget->is_otg Acked-by: Peter Chen <peter.chen@freescale.com> Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-3 usb: chipidea: host: init otg port number.Li Jun
Init otg_port number of otg capable host to be 1 at host start. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-2 usb: chipidea: host: vbus control change for OTGLi Jun
Leave vbus on/off hanlded by OTG fsm if in OTG mode. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00307558-1 usb: chipidea: usb OTG fsm initialization.Li Jun
This patch adds OTG fsm related initialization when do otg init, add a seperate file for OTG fsm related utilities. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00308442-2 usb: chipidea: otg: wait devices disconnected before stop hostLi Jun
This patch adds device connection check before stop host for id change to be 0, wait until there is no any devices connected, then do host stop to avoid deadlock. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00308442-1 usb: chipidea: otg: revert thread solution to restore work queueLi Jun
Revert "ENGR00286962-2 usb: chipidea: fix the system will be deadlock with ID wakeup" since dedicated thread solution is some expensive, and for otg fsm extension, work queue is requred. This reverts commit 7d6fa1243c29562461752c2115a25cb54dc49217. Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00308436-3 usb: chipidea: debug: add debug file for controller registers ↵Li Jun
dump. This patch adds below registers dump for debug: - USBINTR - USBSTS - USBMODE - USBCMD - PORTSC - OTGSC Acked-by: Peter Chen <peter.chen@freescale.com> Signed-off-by: Peter Chen <peter.chen@freescale.com> Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00308436-2 usb: chipidea: export interrupt enable and status register ↵Li Jun
read functions. This patch moves usb interrupt enable and status register read functions from udc driver to core driver to use them in all ci drivers. Acked-by: Peter Chen <peter.chen@freescale.com> Signed-off-by: Peter Chen <peter.chen@freescale.com> Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16ENGR00308436-1 usb: chipidea: operate on otgsc register in a general wayLi Jun
Use a more general way to read and write otgsc register. Signed-off-by: Peter Chen <peter.chen@freescale.com> Signed-off-by: Li Jun <b47624@freescale.com>
2014-04-16usb: phy: fsm: update OTG HNP state transition conditions according to OTG ↵Li Jun
and EH 2.0 spec. According to:"On-The-Go and Embedded Host Supplement to the USB Revision 2.0 Specification July 27, 2012 Revision 2.0 version 1.1a" - From a_host to a_wait_bcon if !b_conn - Add transition from a_host to a_wait_vfall if id state is high or a_bus_drop - From a_wait_vfall to a_idle if a_wait_vfall_tmout Signed-off-by: Li Jun <b47624@freescale.com> Signed-off-by: Felipe Balbi <balbi@ti.com> (cherry-picked from commit 8bebbe8dc6145303db05964fb09657aac2a7e909)
2014-04-16usb: phy: Fix double lock in OTG FSMAnton Tikhomirov
Mutex obtained at the beginning of the function should be released at the end to avoid double locking. Signed-off-by: Anton Tikhomirov <av.tikhomirov@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com> (cherry-picked from commit 16da4b174b08c42076cd3384c420f352c909d467)
2014-04-16usb: phy: Add OTG FSM configuration optionAnton Tikhomirov
This patch removes dependency on Freescale USB UTG Transceiver driver and makes OTG FSM implementation selectable. Signed-off-by: Anton Tikhomirov <av.tikhomirov@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com> (cherry-picked from commit e1d2e31975e1e3a31ac592d5b1c5cb5d655b3f4e)
2014-04-16usb: phy: make PHY driver selection possible by controller driversRoger Quadros
Convert PHY Drivers from menuconfig to menu so that the PHY drivers can be explicitely selected by the controller drivers. USB_PHY is no longer a user visible option. It is upto to the PHY drivers to select it if needed. This patch does so for the existing PHY drivers that use the USB_PHY library. Doing so moves the USB_PHY and PHY driver selection problem from the end user to the PHY and controller driver developer. e.g. Earlier, a controller driver (e.g. EHCI_OMAP) that needs to select a PHY driver (e.g. NOP_PHY) couldn't do so because the PHY driver depended on USB_PHY. Making the controller driver depend on USB_PHY has a negative effect i.e. it becomes invisible to the user till USB_PHY is enabled. Most end users will not familiar with this. With this patch, the end user just needs to select the controller driver needed for his/her platform without worrying about which PHY driver to select. Also update USB_EHCI_MSM, USB_LPC32XX and USB_OMAP to not depend on USB_PHY any more. They can safely select the necessary PHY drivers. [ balbi@ti.com : refreshed on top of my next branch. Changed bool followed by default n into def_bool n ] CC: Pavankumar Kondeti <pkondeti@codeaurora.org> Acked-by: Roland Stigge <stigge@antcom.de> Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Felipe Balbi <balbi@ti.com> (cherry-picked from commit 052a11d13bdecb77ee4cdbdccfce5434a12209af)
2014-04-16usb: phy: move OTG FSM headerAnton Tikhomirov
Other USB drivers may want to use OTG final state machine implementation, so make this header available for them. Signed-off-by: Anton Tikhomirov <av.tikhomirov@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com> (cherry-picked from commit 5653668c9585441926dd2575791f6b5bb84bb254)
2014-04-16usb: phy: replace spinlock with mutex in OTG FSMAnton Tikhomirov
OTG Final State Machine calls functions which may sleep. For example, start_gadget callback implementation can use usb_gadget_vbus_connect(), whose context: can sleep. If so, mutex should be used instead of spinlock. Signed-off-by: Anton Tikhomirov <av.tikhomirov@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com> (cherry-picked from commit 16e569e9661ea2b964b8abb607a51e5285254021)