summaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2010-06-16touchscreen: tegra_odm: fix infinite loopVarun Wadekar
fix the infinite loop triggered by multi-touch controllers also, modify the multi-touch loops to loop over the number of fingers supported by the controller, rather than MAX_FINGERS bug 699471 Change-Id: I7c83aa87f9d5c75600cae36c1b40615903a95cec Reviewed-on: http://git-master/r/2747 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-06-16[arm/tegra] hsuart: Fixing parity setting issue.Laxman Dewangan
It is observed that parity is getting configured properly on set_termio() but immediately get reset before setting the wordlen. Fixing this issue by not resetting the parity configuartion once it is configured. Change-Id: Ie815adc20e883ba05245f6dd2e93b5d0cd81845a Reviewed-on: http://git-master/r/2760 Reviewed-by: Suresh Mangipudi <smangipudi@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-06-16[arm/tegra] hsuart: Configuring tristate correctly.Laxman Dewangan
To enable the tristate of the pin, the argument should be either TEGRA_TRI_TRISTATE or true and for setting it to normal, the argument should be either false or the TEGRA_TRI_NORMAL. The code was passing the value of the argument in reverse, for tristate it was passing the false and for normal it was true. Passing the correct argument value for setting the tristate and normal. Change-Id: I3f83ae7672dc4323f695e57c46c3878316a03324 Reviewed-on: http://git-master/r/2749 Reviewed-by: Anantha Idapalapati <aidapalapati@nvidia.com> Tested-by: Anantha Idapalapati <aidapalapati@nvidia.com> Reviewed-by: Suresh Mangipudi <smangipudi@nvidia.com> Tested-by: Suresh Mangipudi <smangipudi@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-15tegra touch: support more than 2 fingersVarun Wadekar
The kernel touch stack can support a max of 5 fingers at a time. Adding support in the driver to suport 5 fingers too. The touch odm for whistler is broken, hence disable pressure and width support. Change-Id: I9e148bab2efa0116a6513cc8b1cb2ffc2ea27cc8 Reviewed-on: http://git-master/r/2327 Tested-by: Varun Wadekar <vwadekar@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-15nvec-keyboard: move suspend-resume code to odmBharat Nihalani
Moved NvEc calls from nvec-keyboard driver to keyboard odm kit where all the remaining communication with NvEc resides. Change-Id: I12c528a7b54a02ccef5129d022934da3476e0fcf Reviewed-on: http://git-master/r/2471 Tested-by: Bharat Nihalani <bnihalani@nvidia.com> Reviewed-by: Varun Wadekar <vwadekar@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-15tegra mtd: Fixed read api to return correct length.vdumpa
Fixed tegra_nand_read api to return correct number of read bytes. Change-Id: If08514052fa266b27d1a5d5d4139ae35e185f853 Reviewed-on: http://git-master/r/2593 Reviewed-by: Krishna Reddy <vdumpa@nvidia.com> Tested-by: Krishna Reddy <vdumpa@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-11sdhci: set MMC_CAP_MMC_HIGHSPEED for high-speed controllers.Pavan Kunapuli
Setting MMC_CAP_HIGHSPEED in host capabilites to detect high speed eMMC cards, set high speed mode and configure maximum supported clock frequency(52MHz). Tested on: AP20 Android with high speed eMMC card Change-Id: I0da6a4122a2caec1c70918b5801ddb5ac53dcbb5 Reviewed-on: http://git-master/r/2485 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-06-11framebuffer: tegra: fix compiler warningGary King
redefine an unsigned long variable as NvU32 to make gcc happy Change-Id: I4f949c9f812e5834f61899a57a8c4a957b571c62 Reviewed-on: http://git-master/r/2521 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-06-11nvmap: tighten handle validation before pinningAnssi Kalliolahti
Added check for handle poison before pinning. This prevents panic (BUG_ON in _nvmap_handle_pin_locked) when trying to pin already freed handle. Bug 684375 Change-Id: I85ba4b37b2f193c19782edeaa562b7f77915cfc4 Reviewed-on: http://git-master/r/2478 Tested-by: Anssi Kalliolahti <akalliolahti@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-11tegra: EHCI bus suspend/resume requires CONFIG_PMScott Williams
Change-Id: I86faa2f56dbfd0ed145f40b04346a85f64bab12c Reviewed-on: http://git-master/r/2508 Reviewed-by: Scott Williams <scwilliams@nvidia.com> Tested-by: Scott Williams <scwilliams@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-11sdhci-tegra: always call sdhci_suspend_controller, use dev_pm_opsGary King
sdhci_suspend_controller should be called regardless of the type of media in the SD slot (SDIO or memory); rip out the code which conditionally suspended the host based on the card type additionally, move the suspend and resume functions out of platform_driver and into dev_pm_ops Change-Id: I7403aec8c26ef1c4374bb376f99b54767177504b Reviewed-on: http://git-master/r/2488 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-06-10usb gadget: preventing reg access after phy is powered downAbhishek Aggarwal
The device was hanging on USB cable disconnect because fsl_ep_dequeue() function in fsl_udc_core.c was trying to access USB registers after the phy has been powered down. Fixed this by putting a check for vbus status and preventing the register access if the vbus status is 0. Bug: 696989 Change-Id: I802d6efa84b3cf20da736dfce1d546f044576b37 Reviewed-on: http://git-master/r/2394 Tested-by: Abhishek Aggarwal <aaggarwal@nvidia.com> Reviewed-by: Pavan Kunapuli <pkunapuli@nvidia.com> Tested-by: Pavan Kunapuli <pkunapuli@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-10 tegra usb: Resume the device without re-enumerationSeshendra Gadagottu
When fast wakeup feature is supported by a host controller port, then avoid the restarting of controller. Fast wakeup is enabled on the port where device like usb modem is connected always. BUG 692574: Fast Wakeup for USB modems BUG 594395: Fast Wakeup Change-Id: Iaee9f184189f8a1aa8aa0e440879600c0eb625cc Reviewed-on: http://git-master/r/2375 Tested-by: Seshendra Gadagottu <sgadagottu@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-09mmc: sdhci-tegra: set SDHCI_QUIRK_RUNTIME_DISABLEGary King
sd controllers in tegra socs should be disabled when idle to save power Change-Id: If1c20e43187356c94f4c5b846e3862e30834d842 Reviewed-on: http://git-master/r/2344 Reviewed-by: Narendra Damahe <ndamahe@nvidia.com> Tested-by: Narendra Damahe <ndamahe@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-09mmc: sdhci: add mmc_host_ops->enable and ->disableGary King
add support for the mmc delayed suspend interface to the sdhci driver, so that hosts which support it (controlled by a new quirk: SDHCI_QUIRK_RUNTIME_DISABLE) can use runtime delayed suspends to reduce the power consumption from idle SD controllers Change-Id: Iaa6a9dfad4cb9496caca715b5a7ce9e1b533d998 Reviewed-on: http://git-master/r/2343 Reviewed-by: Narendra Damahe <ndamahe@nvidia.com> Tested-by: Narendra Damahe <ndamahe@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-09tegra framebuffer - dsi one shot supportArthur Spence
DSI one shot support requires register access in the tegra framebuffer to poke the frame trigger bit (with both the trigger bit and the tearing effect signal are high, a frame of pixels will be sent to the panel). The boot args must also be expanded to have a "use tearing effect" flag. tegra RM: Expanded Display clock configuration options. Added an option for restricted Display clock synchronization with MIPI PLL - select MIPI PLL as a pixel clock source, but preserve PLL settings. To specify this option flag NvRmClockConfig_InternalClockForPads should be set by RM client along with NvRmClockConfig_MipiSync flag (in the absence of the former flag, MIPI PLL can be re-configured at RM discretion - current behavior). Change-Id: I495c2d76656efe8653aa5731c07180c2bfcd2fc0 Reviewed-on: http://git-master/r/2342 Tested-by: Arthur Spence <aspence@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-09usbnet: smsc9514: fix build break with USB_SUSPENDGary King
ccf5b801c changed uintf.pm_usage_cnt to an atomic_t; update this driver to reflect the change bug 696988 Change-Id: If587ca9c98a7f92f35a0143283c6d13a862c3d6e Reviewed-on: http://git-master/r/2336 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-06-09serial: tegra_hsuart: Cleanups and bug fixesColin Cross
tegra_start_tx was called directly by the serial core, as well as from dma and serial interrupts to queue the next block of data. Separate out the "queue next data" functionality into tegra_start_next_tx. Also fixes TX PIO by adjusting FIFO sizes and prevents last characters from getting lost by spinning on TEMT before disabling clocks. Change-Id: If8ce15490f77dcbde48f1e64959d5c3f0ec35120 Signed-off-by: Colin Cross <ccross@android.com> Reviewed-on: http://git-master/r/2288 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-06-09serial: tegra_hsuart: Fix DMA receive, drop err in dma callbacksColin Cross
Change-Id: I4c4bc12e8c883912f8979b75a8eb418a62e77f94 Signed-off-by: Colin Cross <ccross@android.com> Reviewed-on: http://git-master/r/2287 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-06-08ehci-tegra: do not request_mem_region for OTG controllerstegra-9.12.13.ERGary King
if the platform data indicates that the controller will be used in OTG mode, do not call request_mem_region since this would conflict with the gadget controller, causing one of the two probes to fail bug 696526 Change-Id: I64f71af8adf7ffa27e98e4fdb42d90de4203efde Reviewed-on: http://git-master/r/2298 Reviewed-by: Venkata (Muni) Anda <vanda@nvidia.com> Tested-by: Venkata (Muni) Anda <vanda@nvidia.com> Tested-by: Trivikram Kasivajhula <tkasivajhula@nvidia.com> Reviewed-by: Abhishek Aggarwal <aaggarwal@nvidia.com> Tested-by: Abhishek Aggarwal <aaggarwal@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-07USBNET:adding smsc power(suspend/resume)aware driverNarendra Damahe
Bug 693439 Change-Id: Id251d6be11e1b251c45e811173ba770683f11c48 Reviewed-by: Narendra Damahe <ndamahe@nvidia.com> Tested-by: Narendra Damahe <ndamahe@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-06-07mmc: core: do not acquire wakelock during rescan pollingGary King
if rescan is scheduled on the work queue because the host requires periodic polling to detect card insertions, do not acquire the wakelock; otherwise, the system will never enter suspend. Change-Id: I11b2711112a771a69f25b99c0234f22ceff4d9d6 Reviewed-on: http://git-master/r/2248 Reviewed-by: Trivikram Kasivajhula <tkasivajhula@nvidia.com> Tested-by: Trivikram Kasivajhula <tkasivajhula@nvidia.com> Reviewed-by: Gary King <gking@nvidia.com>
2010-05-28ehci-tegra: fix OTG state detection at boot-time on USB1Abhishek Aggarwal
The USB device connected to USB1(OTG) port was not getting detected at boot time. Reason being that on phy power down (host mode), there was some delay in VBUS getting disabled. Because of this the OTG state was getting set to "peripheral" instead of "host". Fixed this by waiting for VBUS to be disabled in phy power down with a max wait time of phy hardware time out (1 sec). Change-Id: I78e561e28d942fa9931dfb88656281b02264859f Reviewed-on: http://git-master/r/1837 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-05-28input: misc: add accelerometer driver for tegra ODM kitGary King
Change-Id: I60f52fc6e91839abb11333e44fb77fdda85841f1 Reviewed-on: http://git-master/r/1830 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-05-28input: misc: add input driver for tegra scrollwheel ODM kitGary King
Change-Id: I79ca91a26094567207eb55837b908086209cfcf2 Reviewed-on: http://git-master/r/1829 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-05-28power: add battery driver for tegra PMU ODM kitGary King
registers itself with the same "tegra_battery" driver name as the NvEc battery, so disallow platforms from selecting both the ODM battery and the NvEc battery fix the nvec_battery driver compilation to only occur when it is selected, rather than whenever the NvEc infrastructure is enabled Change-Id: I9716824d0882d8cd8e693ebdad6bcc96c3f035c5 Reviewed-on: http://git-master/r/1822 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-05-28w1: add one-wire master driver for tegraGary King
Change-Id: I9b7a7cb461f5b7f5d4623050ed6184426e14400f Reviewed-on: http://git-master/r/1820 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-05-28nvmap: fix Kconfig dependencies for nvmap driverGary King
nvmap shouldn't require MACH_TEGRA_GENERIC; it should be buildable (sans NvRm APIs or NvOs preserved memory handle bootargs) in a stock kernel. move the NvOs and NvRm dependencies to ifdef'd source code, rather than Kconfigs Change-Id: I11d4049460975bc9f2bf779c4c2fa6c7a8747583 Reviewed-on: http://git-master/r/1807 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
2010-05-27usb: fsl_udc_core: fix tegra regulator supportGary King
the driver should get the vbus_regulator using its platform device, not an arbitrary platform device provided via platform data; now that tegra regulators are registered semi-correctly, this hack is not needed Change-Id: I93e2455b7897402767d9e798cb88bc5d48b81250
2010-05-27regulator: tegra: add charger support to the tegra regulator driverGary King
add new fields to the platform data structure to allow specification of chargers (current sources) vs regulators (voltage sources) on the platform Change-Id: If4d0b2520a37afb96d103d6cbf78ec2fba2d02f9
2010-05-27Input: add tegra_odm generic touchscreen driverGary King
Change-Id: Ife43077e4699e38339a637be5a21f1f75fb46543
2010-05-27spi: add spi master driver for NVIDIA Tegra SoCsGary King
Change-Id: I8d2834f5b7e73cd6a1eb6584715bdd707e23e830
2010-05-27[ARM/tegra] board-nvodm: register I2C devices for simple platformsGary King
on platforms which have simple configurations (specifically no pinmux multiplexing for I2C controllers), implement a helper function in board-nvodm to register all of the I2C master controllers on the system based on the ODM kit-specified values. the code will skip registering I2C slave controllers, which are currently detected by the SMBUS GUID. also, since board-generic is really intended to be only for NVIDIA development boards, make the terminology in the file more clearly NVIDIA-specific. Change-Id: I115fb6bf68d93f62a548d65fa5bfdd2d00c13fbc
2010-05-27i2c: tegra: switch to using the NVIDIA RM-based I2C driverGary King
since the RM APIs are used by ODM kits prior to device initialization (to read EEPROMs and the like), implementing the RM on top of Linux's I2C API won't happen immediately Change-Id: I8a97e13a7fda8bafaf74e2251e8bd1b0e32dc058
2010-05-26cpufreq: check for NULL before copying governor nameGary King
if a CPU is hot-unplugged before a governor is applied to the CPU's policy, the string copy to save off the governor's name in __cpufreq_remove_dev (introduced in e77b89f13) will deref a NULL pointer. Change-Id: I7b4069c8cd4048699e7a827a3838c8653183f93b
2010-05-25regulator: tegra: add support for SoC power-offGary King
SoC power-off in the ODM PMU adaptation is triggered by requesting a voltage of 0 for the voltage rails specified by the NV_VDD_SoC_ODM_ID GUID. mark this regulator as enabled-on-boot. Change-Id: I5b8b3df6176a5cd67b2041c328014291d6d0feb0
2010-05-25misc: rfkill: add rfkill driver for Murata LBEE9QMBC moduleGary King
Change-Id: Ib2d277392f9c2e2aa0c3ecb3e3c1f936cd5150b0
2010-05-24input: mouse: add tegra nvec mouse driverGary King
Change-Id: Id1bc377bc730198f2482f7ffa6b91d540fa1bc2c
2010-05-23regulator: add tegra SoC regulator driverGary King
enables platform code to register ODM queriable GUIDs as named regulators, and to specify the list of consumers for each registered regulator. uses NvRm PMU API to program the PMU Change-Id: I0cd04ad4bebc610d945daaf575f5d09e8d838385
2010-05-23staging: android: lowmemorykiller: Remove bitrotted codepathSan Mehat
Now that we're murder-synchronous, this code path will never be called (and if it does, it doesn't tell us anything useful other than we killed a task that was already being killed by somebody else but hadn't gotten its' signal yet) Signed-off-by: San Mehat <san@google.com>
2010-05-23staging: android: lowmemorykiller: Fix task_struct leakSan Mehat
As it turns out, the CONFIG_PROFILING interfaces leak a task struct if the notifier chain returns NOTIFY_OK.. doh. This patch reworks lowmemkiller to use the new generic task free notifier chain. Signed-off-by: San Mehat <san@google.com>
2010-05-23binder: Fix memory corruption via page aliasingChristopher Lais
binder_deferred_release was not unmapping the page from the buffer before freeing it, causing memory corruption. This only happened when page(s) had not been freed by binder_update_page_range, which properly unmaps the pages. This only happens on architectures with VIPT aliasing. To reproduce, create a program which opens, mmaps, munmaps, then closes the binder very quickly. This should leave a page allocated when the binder is released. When binder_deferrred_release is called on the close, the page will remain mapped to the address in the linear proc->buffer. Later, we may map the same physical page to a different virtual address that has different coloring, and this may cause aliasing to occur. PAGE_POISONING will greatly increase your chances of noticing any problems. Change-Id: I6941bf212881b8bf846bdfda43d3609c7ae4892e Signed-off-by: Christopher Lais <chris+android@zenthought.org>
2010-05-23staging: android: lowmemkiller: Substantially reduce overhead during reclaimSan Mehat
This patch optimizes lowmemkiller to not do any work when it has an outstanding kill-request. This greatly reduces the pressure on the task_list lock (improving interactivity), as well as improving the vmscan performance when under heavy memory pressure (by up to 20x in tests). Note: For this enhancement to work, you need CONFIG_PROFILING Signed-off-by: San Mehat <san@google.com>
2010-05-23USB: android gadget: mass storage: Fix format issue for Vista HostVelempati Chiranjeevi
As part of formating the mass storage device, Host sends the INQUIRY scsi command. As per the standard, the command length for this command should be 6 bytes, whereas the Vista host sends 12 bytes. When the command length of the command is not equal to the standard length, the device sends a phase error as part of the status phase. When the host receives a phase error, it re-enumerates, hence the error. If the command is INQUIRY, and the command length is 12 bytes, treating this as a good command and not sending the phase error to the host fixes this issue. Signed-off-by: Velempati Chiranjeevi <c_cvelem@qualcomm.com> Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-05-23lowmemorykiller: Don't try to kill the same pid over and overSan Mehat
Under certain circumstances, a process can take awhile to handle a sig-kill (especially if it's in a scheduler group with a very low share ratio). When this occurs, lowmemkiller returns to vmscan indicating the process memory has been freed - even though the process is still waiting to die. Since the memory hasn't actually freed, lowmemkiller is called again shortly after, and picks the same process to die; regardless of the fact that it has already been 'scheduled' to die and the memory has already been reported to vmscan as having been freed. Solution is to check fatal_signal_pending() on the selected task, and if it's already pending destruction return; indicating to vmscan that no resources were freed on this pass. Signed-off-by: San Mehat <san@google.com>
2010-05-23Staging: android: binder: Create dedicated workqueue for binder deferred workArve Hjønnevåg
Some drivers flush the global workqueue when closed. This would deadlock if the last reference to the file was released from the binder. Change-Id: Ifdabc0b383fecb20836d1bbb9786c632402a14e1 Signed-off-by: Arve Hjønnevåg <arve@android.com>
2010-05-23Staging: android: timed_gpio: Properly discard invalid timeout values.Mike Lockwood
The timed output device never previously checked the return value of sscanf, resulting in an uninitialized int being passed to enable() if input value was invalid. Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-05-23USB: gadget: f_mass_storage: Defer handling interface changes until it is safe.Mike Lockwood
Pulling in some code from file_storage.c, we now handle interface changes in do_set_config(), which is now not called until any pending requests have been successfully completed or cancelled. This fixes a race condition that resulted in usb_ep_free_request() being called while the request is still busy. Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-05-21[ARM] tegra: i2c: Fix i2c driver behavior on timeout/nackColin Cross
Change-Id: Ib7c22898783fdc66fa626e06360bd5ca9637067e
2010-05-21[ARM/tegra] dma: add transfer count query, correct spelling of CONTINUOUSGary King
add an API to return the completed transfer count of a pending, active or finished DMA request CONTINUOUS was misspelled CONTINOUS; fix this in the hsuart and dma drivers Change-Id: I732396f60f876c92fe3b74ad1d2fc02d00868d24