6 years agovideo: tegra: dc: power optimize DC and host1x clk
Jon Mayo [Tue, 17 Jul 2012 22:56:44 +0000]
video: tegra: dc: power optimize DC and host1x clk

Use threaded IRQ to support enabling clocks in interrupt handling.
Use io_start and io_end to hold and release host1x clock.
Disable IRQ after it is first requested to balance enable/disable.
Use disable_irq_nosync() anywhere dc->lock is held to avoid deadlock.

Change tegra_dc_update_windows() to always be balanced with
tegra_dc_sync_windows(). Sync points (from host1x) are potentially lost if
clock gated after update, generally this only affects applications that
update at a slow frame rate.

To balance update and sync calls, Colormap/LUT code now performans a
sync_windows on a LUT change, this makes LUT changes slower and take effect
immediately.

Add a nosync version of tegra_dc_dsi_write_data to be used within dsi
module.

Bug 1031933
Bug 1002768
Bug 1036025
Bug 1013506
Bug 1025621
Bug 1028716
Bug 1029041
Bug 899059
Bug 887342
Bug 929609

Change-Id: I79454e265a96df66244275c2f3b0e4949f71bd02
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-on: http://git-master/r/123813
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Kevin Huang (Eng-SW) <kevinh@nvidia.com>
GVS: Gerrit_Virtual_Submit

6 years agoRevert "video: tegra: dc: fix boot issue with HDMI"
Jon Mayo [Fri, 17 Aug 2012 21:12:17 +0000]
Revert "video: tegra: dc: fix boot issue with HDMI"

This reverts commit 50fa5e50b74a0534d7524fb6d7dcaa65b2e6e74c.

Change-Id: I535127153082dae5ec701bbb876af002c9ebf5a3
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-on: http://git-master/r/124449
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit

6 years agoRevert "ARM: tegra: enterprise: update memory timings"
Simone Willett [Wed, 22 Aug 2012 20:58:14 +0000]
Revert "ARM: tegra: enterprise: update memory timings"

This reverts commit 64d7608ed4a0fe0964250ad0423c499841292bf6

Change-Id: I0405128605ed7a858aecb8fb9aaaf80e0e44c4b8
Reviewed-on: http://git-master/r/125322
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoi2c: tegra: Add delay before resetting the controller after NACK
Laxman Dewangan [Wed, 22 Aug 2012 08:13:08 +0000]
i2c: tegra: Add delay before resetting the controller after NACK

NACK interrupt is generated before I2C controller generates the STOP
condition on bus. Because of this reset of controller is happening
before I2C controller could complete STOP condition. So wait for some
time before resetting the controller so that STOP condition has
delivered properly on bus.

Added delay of 2 clock period before resetting the controller in case of
NACK error.

Signed-off-by: Alok Chauhan <alokc@nvidia.com>
Acked-by: Stephen Warren <swarren@wwwdotorg.org>

Taken change from mainline commit.

Change-Id: Id089aae313614e58ec6da36eda4ff2d87c5cddc3
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/125148
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>

6 years agoPM QoS: Add disable parameter
Antti P Miettinen [Mon, 20 Aug 2012 16:36:38 +0000]
PM QoS: Add disable parameter

For testing purposes it is useful to be able to disable
PM Qos.

Bug 1020898
Bug 917572

Change-Id: I266f5b5730cfe4705197d8b09db7f9eda6766c7c
Signed-off-by: Antti P Miettinen <amiettinen@nvidia.com>
Reviewed-on: http://git-master/r/124667
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>

6 years agovideo: tegra: host: Fix freeing a ERR_PTR value
Tuomas Tynkkynen [Mon, 20 Aug 2012 14:26:16 +0000]
video: tegra: host: Fix freeing a ERR_PTR value

nvhost_3dctx_alloc_common correctly checks the return value of an
allocator function, and attempts to perform cleanup. However, this
particular allocation API returns ERR_PTR values in case of failure,
which then gets passed to the deallocation function, causing a crash.

Also, the return value of that allocator API is checked with IS_ERR
in some places, and with IS_ERR_OR_NULL in others. For consistency
and avoiding surprises if the allocation implementation changes,
use IS_ERR_OR_NULL in all places.

Bug 1035878

Change-Id: I65ce97e11f9712b2e9630b38183f6e70bc14b254
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-on: http://git-master/r/124657
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>

6 years agovideo: tegra: host: Fix crash if allocation fails
Tuomas Tynkkynen [Thu, 16 Aug 2012 16:56:51 +0000]
video: tegra: host: Fix crash if allocation fails

nvhost_module_remove_client assumes that a client structure
to be freed exists in the linked list. However, if an allocation fails
in nvhost_module_add_client, no client structure is allocated, and
during cleanup, nvhost_module_remove_client would then attempt
to free an invalid pointer.

Bug 1034729

Change-Id: Ie1a641071b86f8246951e9be824a6003f14b04b6
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-on: http://git-master/r/124096
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>

6 years agoarch: arm: pcie: init TXBA registers
krishna kishore [Thu, 2 Aug 2012 12:40:08 +0000]
arch: arm: pcie: init TXBA registers

Setting default values in TXBA registers to avoid
unfair arbitration between downstream reads and
completions to upstream reads

Bug 1027024

Change-Id: I87763817b7974127f93fa18270b5245a54fc6676
Signed-off-by: krishna kishore <kthota@nvidia.com>
Reviewed-on: http://git-master/r/120359
Tested-by: Jay Agarwal <jagarwal@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>

6 years agoARM: tegra: kai: update memory timings
Ray Poudrier [Mon, 2 Jul 2012 23:41:32 +0000]
ARM: tegra: kai: update memory timings

Extend tick length to 60ns

Bug 1001229

Change-Id: I8a96dd08b6d11a196c9b82bec403ab2e4676e2f4
Signed-off-by: Ray Poudrier <rapoudrier@nvidia.com>
Reviewed-on: http://git-master/r/113081
(cherry picked from commit 487622aa43568d3f6f9a9f5fc98176e5ffdd6246)
Reviewed-on: http://git-master/r/116208
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>

6 years agoRevert "arm: tegra: la: hack latency allowance formula"
Wen Yi [Tue, 21 Aug 2012 18:35:35 +0000]
Revert "arm: tegra: la: hack latency allowance formula"

This reverts commit 935adef53692ab73a02a7d09876756b30beb5206.

The orginal patch is used to boost emc performance to
fix display underflow. It doesn't achieve the goal but with
side effect of higher power. Proper fix is required and the patch
is reverted.

Bug 996270

Signed-off-by: Wen Yi <wyi@nvidia.com>
Change-Id: I6d7364b311e4de86ceed40ff438ee9549251e02e
Reviewed-on: http://git-master/r/124975
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Reviewed-by: Michael Frydrych <mfrydrych@nvidia.com>

6 years agoARM: tegra: kai: adjust ov2710 power sequence
Sang-Hun Lee [Fri, 17 Aug 2012 23:54:05 +0000]
ARM: tegra: kai: adjust ov2710 power sequence

Update the power sequence to match the specification

Bug 1031318

Change-Id: If77777bf23fda32fa9698f53691b99b50cb35bde
Signed-off-by: Sang-Hun Lee <sanlee@nvidia.com>
Reviewed-on: http://git-master/r/124496
Reviewed-by: Charlie Huang <chahuang@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>

6 years agoARM: tegra: cardhu: adjust ov2710 power sequence
Charlie Huang [Fri, 10 Aug 2012 23:26:34 +0000]
ARM: tegra: cardhu: adjust ov2710 power sequence

To fix an instability issue, the power sequence is updated to match
the specification for this device.

bug 1031318

Change-Id: I77c16e883ce6a5a37dace9372a016b0cbc71012b
Signed-off-by: Charlie Huang <chahuang@nvidia.com>
Reviewed-on: http://git-master/r/122867
(cherry picked from commit e2862b9cd75bb9f608db0c33bef47f3952df5f26)
Reviewed-on: http://git-master/r/124443
Reviewed-by: Sang-Hun Lee <sanlee@nvidia.com>
Tested-by: Sang-Hun Lee <sanlee@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>
Reviewed-by: Manish Tuteja <mtuteja@nvidia.com>

6 years agomedia: video: tegra: ar0832: Add slew rate support
Naren Bhat [Mon, 20 Aug 2012 19:39:16 +0000]
media: video: tegra: ar0832: Add slew rate support

Add slew rate support for AR0832 focuser.

bug 1028733

Change-Id: I4fd0245fad7f7c820fc30a7c4bfc970d52903da6
Signed-off-by: Naren Bhat <nbhat@nvidia.com>
Reviewed-on: http://git-master/r/124695
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Frank Chen <frankc@nvidia.com>
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>

6 years agoARM: tegra: Remove timer workaround
Antti P Miettinen [Tue, 26 Jun 2012 13:54:37 +0000]
ARM: tegra: Remove timer workaround

Reprogramming running timers may cause timer interrupt state
to get out of sync and result in lost timer interrupts.

Bug 950482

Change-Id: I83c9d735f9b041e8a57d73ba466f5f9c89ca1b89
Signed-off-by: Antti P Miettinen <amiettinen@nvidia.com>
Reviewed-on: http://git-master/r/111242
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoi2c: tegra: protect suspend/resume callbacks with CONFIG_PM_SLEEP
Laxman Dewangan [Tue, 21 Aug 2012 08:08:47 +0000]
i2c: tegra: protect suspend/resume callbacks with CONFIG_PM_SLEEP

The CONFIG_PM doesn't actually enable any of the PM callbacks, it
only allows to enable CONFIG_PM_SLEEP and CONFIG_PM_RUNTIME.
This means if CONFIG_PM is used to protect system sleep callbacks
then it may end up unreferenced if only runtime PM is enabled.
Hence protecting sleep callbacks with CONFIG_PM_SLEEP.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>

Change-Id: I090e167c1de8f254a278e9e3b511292cfbc5f250
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/124872
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoi2c: tegra: better describe fast and div clocks
Laxman Dewangan [Tue, 21 Aug 2012 08:19:53 +0000]
i2c: tegra: better describe fast and div clocks

Describe the fast and div clock part of structure and prints
better error message when any failure occurs in enabling clocks.

Change-Id: I72f66b5f8cbefbe8b2c6b8c7150edff3ee2244b4
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/124873
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoi2c: tegra: declare iomap address to iomem type
Laxman Dewangan [Tue, 21 Aug 2012 08:23:08 +0000]
i2c: tegra: declare iomap address to iomem type

Declare the iomap address to __iomem type.

Change-Id: Ic855834f6e7fd417e4c2fd0415a6195655d3ed60
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/124874
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoi2c: tegra: I2_M_NOSTART functionality not supported in Tegra20
Laxman Dewangan [Tue, 21 Aug 2012 09:46:38 +0000]
i2c: tegra: I2_M_NOSTART functionality not supported in Tegra20

Tegra20 i2c controller does not support the continue transfer
which implements the I2C_M_NOSTART functionality of i2c
protocol mangling.
Removing the I2C_M_NOSTART functionality support for Tegra20.

Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Wolfram Sang <w.sang@pengutronix.de>
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Cherry-picked from mainline
72dedc2fb12ff31cc2da977d0c40c3ac58f554cf

Change-Id: I461342749a834ff2eae056f1c6616a8d7693a32c
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/124875
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoARM: tegra: usb: handle device connect in lp0
Krishna Yarlagadda [Tue, 14 Aug 2012 16:06:59 +0000]
ARM: tegra: usb: handle device connect in lp0

When a otg cable is connected along with device during lp0
system will wakeup but might not complete device enumeration
before going back to lp0. In this case we have to handle pmc
disable.

Bug 1024456

Reviewed-on: http://git-master/r/123383
(cherry picked from commit 6399f339601cee0f39e48011265d0e324e7dd99e)

Change-Id: Ib401c27a0d6729c906f5d3e1450548f21ff638f7
Signed-off-by: Krishna Yarlagadda <kyarlagadda@nvidia.com>
Reviewed-on: http://git-master/r/124317
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>

6 years agoARM: tegra: usb_phy: Fix HSIC resume code
Vinod Atyam [Fri, 17 Aug 2012 09:03:47 +0000]
ARM: tegra: usb_phy: Fix HSIC resume code

1) During remote wakeup resume, no need
   to keep 25 msec delay after resume bit
   is cleared. Updated the code now.
2) PSPD bit in HOSTPC register is read only,
   but bymistake it is getting set in our code.
   Corrected the code now.
3) During AP resume, no need to set RUN bit
   2 times. Corrected the code to do it once.

Bug 1028940
Bug 1024592

Change-Id: I872886f4cef6058d3de9d488321aa5b0925fd62a
Signed-off-by: Vinod Atyam <vatyam@nvidia.com>
Reviewed-on: http://git-master/r/124051
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoARM: tegra: cardhu: update memory timings
Ray Poudrier [Tue, 3 Jul 2012 18:43:05 +0000]
ARM: tegra: cardhu: update memory timings

Extend tick length to 60ns

Also add missed Cardhu SKU 1000 table

Bug 1001229
Bug 970610

Change-Id: I224158a88d02595d5b911f59b6920b9ed99481ab
Signed-off-by: Ray Poudrier <rapoudrier@nvidia.com>
Reviewed-on: http://git-master/r/113315
(cherry picked from commit 492193079047d9c5a4fff617a14191438f356e42)
Reviewed-on: http://git-master/r/116221
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Wen Yi <wyi@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>

6 years agoARM: tegra: enterprise: update memory timings
Ray Poudrier [Tue, 3 Jul 2012 03:17:42 +0000]
ARM: tegra: enterprise: update memory timings

Extend to 60ns tick

Bug 1001229

Change-Id: Id2b01218a7c5cb1566d0e8c175defb12c79e6497
Signed-off-by: Ray Poudrier <rapoudrier@nvidia.com>
Reviewed-on: http://git-master/r/113122
(cherry picked from commit 176fd3fbaede0d38281fe4bad721856e7fef0833)
Reviewed-on: http://git-master/r/116220
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>

6 years agovideo: tegra: dc: Add timestamp support
Raghavendra VK [Sat, 4 Aug 2012 04:25:43 +0000]
video: tegra: dc: Add timestamp support

bug 1021221

Change-Id: Ifbe007de5bdeafaa15a0b3f2a138086045eba160
Signed-off-by: Raghavendra VK <rvk@nvidia.com>
Reviewed-on: http://git-master/r/118179
(cherry picked from commit 74be8d4e7210d7bcea0d55565a7cbb06d6cc960e)
Reviewed-on: http://git-master/r/121087
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Robert Morell <rmorell@nvidia.com>

6 years agoarm: tegra: Enable LP1_950 config
Karthik Ramakrishnan [Sat, 11 Aug 2012 00:33:20 +0000]
arm: tegra: Enable LP1_950 config

Enable LP1 Core voltage settings to 950mV

The feature is added in the below change.
Refer to http://git-master/r/#change,124135 for more details.
Bug 1035684

Change-Id: I922efff17797f4666fd6ed069a8523c164445842
Signed-off-by: Karthik Ramakrishnan <karthikr@nvidia.com>
Reviewed-on: http://git-master/r/124137
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>

6 years agoarm: tegra: Board files settings for LP1 0.95V CoreV
Karthik Ramakrishnan [Sat, 11 Aug 2012 00:24:20 +0000]
arm: tegra: Board files settings for LP1 0.95V CoreV

Set the register values for each of the board files to
keep the Core voltage to 0.95V in LP1.

This change is only for those platforms where LP1 is supported.
Enterprise and Kai are the main platforms for this change. There
is no support for Cardhu for LP1 and so is left blank and the
feature will be skipped for Cardhu platforms, except for AP37.
AP37 with a PM269 board needs this change and so Cardhu board
file is updated with the values specific to AP37.

This change is part of the feature to set VCore to 0.95V
Refer to http://git-master/r/124135 for more details
Bug 1035684

Change-Id: I6d1d984b0e7968b441cebbc37705c25647a4a85a
Signed-off-by: Karthik Ramakrishnan <karthikr@nvidia.com>
Reviewed-on: http://git-master/r/124136
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>

6 years agoarm: tegra: Set Core to 0.95V in LP1
Karthik Ramakrishnan [Tue, 14 Aug 2012 02:09:16 +0000]
arm: tegra: Set Core to 0.95V in LP1

When the device prepares for LP1, the Core voltage is set to the
highest value(1.2V for Enterprise and Kai, and 1.3V for AP37 and
Cardhu). This is to set for some of the driver suspend along the
sequence need a higher emc frequency and thus a higher Core voltage.

Since the sequence of drivers suspend depends on the sequence of
their registration in the table, which in turn is platform-dependent,
there is no right place in the LP1 entry path where the Core voltage
can be set to a lower voltage. Hence, the Core voltage remains high
in LP1 resulting in higher power.

Thus, the only safe location where the Core voltage can be lowered is
once all the drivers are suspended and the DRAM is set in self-refresh,
at the final point just before the system is suspended in the IRAM code.
This location at the assembly code ensures that no other module will be
running and thus that nothing will require a higher core voltage. The Core
is set to the lowest possible value since nothing requires it. It is then
restored to the highest voltage as soon as the LP1 resume code is started
so that all drivers are resumed safely.

At the execution point in IRAM during LP1 suspend path, even the I2C clocks
are gated. They must be reset first and then the I2C transaction is performed.
An I2C transaction involves 4 bytes of data, to send the slave address,
the Core voltage register address and 2 bytes of data which has the value
to set the voltage(the second byte is not required for this transaction).
Once these registers are set, the I2C transaction is performed by setting
the I2C transaction register to 0xA02. After sending the I2C transaction,
we wait for about 250us to check the status of the transaction and if not
updated, wait for more time to check again. If after 2ms and the transaction
fails to register, the transaction is aborted and the device is allowed
to enter at high voltage. Since the failure rate of I2C transaction is very
low at this point in execution where there will be no conflicts in the bus,
it is okay to have Core high for some of the LP1 cycles.

However, it is unacceptable for the I2C transaction to fail on the way
from LP1 resume since the device cannot come up with a lower Core
voltage. In this case, the transaction is retried again and again till
it is successful. There is no way but to keep trying as the device
would fail to resume with Core at 0.95V.

Each platform(or each PMU) has different values for the I2C transaction
ie. slave address, Core voltage register and the value to set the
voltage. For the device in IRAM, it cannot access anything in SDRAM
memory, these values needs to be pushed to IRAM memory before the device
starts execution in IRAM. This is done during initialization of suspend
code when it picks values from the board files and copies it to IRAM
part of code, before the whole memory is copied to IRAM.

This new feature is controlled by a KConfig variable TEGRA_LP1_950 which
should be enabled once the board file of the device is updated with the
right values. The device hangs when it does not have the right values for
the I2C transaction.

With this change in Core, LP1 power is reduced by 12mW in Enterprise,
20mW in AP37 and about 24mW in Kai.

Bug 1035684

Change-Id: I4318c66fd70ab227ef0786d6a13286e020e4541d
Signed-off-by: Karthik Ramakrishnan <karthikr@nvidia.com>
Reviewed-on: http://git-master/r/124135
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>

6 years agoPM: Need to wake_up_all when suspend fail
BH Hsieh [Mon, 13 Aug 2012 07:33:07 +0000]
PM: Need to wake_up_all when suspend fail

In rpm_suspend, when suspend fail,
before going to reschedule another autosuspend,
wake_up_all is required to avoid remote wakeup
issues.

Bug 1026169
Bug 1027598
Bug 1032565

Change-Id: Ieaf9282dae59b2cb343bf01aa2ba837a8cdc39c7
Signed-off-by: BH Hsieh <bhsieh@nvidia.com>
Reviewed-on: http://git-master/r/122978
(cherry picked from commit 856f955552e8dbdf3b4a25c3eb648bcd5193cacf)
Reviewed-on: http://git-master/r/124535
Reviewed-by: Neil Patel <neilp@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Tested-by: Neil Patel <neilp@nvidia.com>
Reviewed-by: Steve Lin <stlin@nvidia.com>

6 years agovideo: tegra: nvmap: Fix overflow in nvmap_heap
Tuomas Tynkkynen [Mon, 13 Aug 2012 12:43:31 +0000]
video: tegra: nvmap: Fix overflow in nvmap_heap

do_heap_alloc locates a suitable free block from a nvmap heap given a
size and alignment. Unfortunately, if a heap block happens to be
smaller than the alignment passed to the function, an integer overflow
will occur, and a block that's too small gets accidentally returned.

Bug 1032642

Change-Id: Ic650c520409134d753e968f62f144ddeb065ccc7
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-on: http://git-master/r/123076
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Krishna Reddy <vdumpa@nvidia.com>

6 years agoscripts: Make git commit info always present
Tao Hu [Wed, 8 Aug 2012 09:30:06 +0000]
scripts: Make git commit info always present

LOCALVERSION_AUTO is set by default.
And git commit will be part of the version.
E.g. "3.1.10-g0fe9b4a" where 0fe9b4a is the commit.

The version will appear in kpanic logs.
It would help developers to know the exact kernel version.

But a tagged commit (main-ics-2012.06.07-A5) will lead to no git info.
E.g. "3.1.10"
This patch will solve the issue.

Change-Id: I28370ada903b4be12bfc51eb3626512572e15c20
wChange-Id: I9dbb6c0a9e2964ead92114197a6d5c457ed7aab9
Signed-off-by: Tao Hu <taoh@nvidia.com>
Reviewed-on: http://git-master/r/123670
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Prajakta Gudadhe <pgudadhe@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Scott Peterson <speterson@nvidia.com>

6 years agoARM: tegra: e1853: Add build support for E1853
Ashwin Joshi [Fri, 27 Jul 2012 10:28:50 +0000]
ARM: tegra: e1853: Add build support for E1853

E1853 is T30 based automotive platform. Modify Makefile to support build
of E1853 board. Also, added config option to Kconfig file.

Bug 966833
Bug 1018258

Change-Id: I18dc015b79256fde1c77947198b426a0060a9017
Signed-off-by: Ashwin Joshi <asjoshi@nvidia.com>
Reviewed-on: http://git-master/r/118932
Reviewed-by: Sandeep Trasi <strasi@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
(cherry picked from commit bed57d893803f2ccef8f40bd30bdf1e8a44f184b)
Reviewed-on: http://git-master/r/119652
GVS: Gerrit_Virtual_Submit
Tested-by: Haribabu Narayanan <hnarayanan@nvidia.com>
Reviewed-by: Bob Johnston <bjohnston@nvidia.com>
Reviewed-by: Krishna Reddy <vdumpa@nvidia.com>

6 years agoARM: tegra: cardhu: adjust ov2710 power sequence
Charlie Huang [Fri, 10 Aug 2012 23:26:34 +0000]
ARM: tegra: cardhu: adjust ov2710 power sequence

To fix an instability issue, the power sequence is updated to match
the specification for this device.

bug 1031318

Change-Id: I3970af7ae8ed2baa6060f548242b0093040afb53
Signed-off-by: Charlie Huang <chahuang@nvidia.com>
Reviewed-on: http://git-master/r/122867
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Patrick Shehane <pshehane@nvidia.com>
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>

6 years agoPM: Need to wake_up_all when suspend fail
BH Hsieh [Mon, 13 Aug 2012 07:33:07 +0000]
PM: Need to wake_up_all when suspend fail

In rpm_suspend, when suspend fail,
before going to reschedule another autosuspend,
wake_up_all is required to avoid remote wakeup
issues.

Bug 1026169
Bug 1027598
Bug 1032565

Change-Id: Ieaf9282dae59b2cb343bf01aa2ba837a8cdc39c7
Signed-off-by: BH Hsieh <bhsieh@nvidia.com>
Reviewed-on: http://git-master/r/122978
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Neil Patel <neilp@nvidia.com>
Tested-by: Neil Patel <neilp@nvidia.com>
Tested-by: Steve Lin <stlin@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Steve Lin <stlin@nvidia.com>

6 years agousb: otg: tegra: fix racing USB connection events
Xin Xie [Wed, 11 Jul 2012 02:23:03 +0000]
usb: otg: tegra: fix racing USB connection events

Sometimes USB connect and disconnect events is not detected properly. The
OTG irq handler is using a workqueue which has no protection for multiple
incoming event handling.

This patch adds mutex to protect the workqueue for USB connection
handling.

BUG 968345

Change-Id: If1c6fec4231dd0dc918f7f278e0a1d7667782917
Signed-off-by: Xin Xie <xxie@nvidia.com>
Reviewed-on: http://git-master/r/122308
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Rakesh Bodla <rbodla@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>

6 years agousb: gadget: tegra: remove unnecessary bus resume
Xin Xie [Tue, 7 Aug 2012 23:07:14 +0000]
usb: gadget: tegra: remove unnecessary bus resume

Current Tegra UDC driver share same IRQ with OTG driver, and it will call
bus_resume() even if there is no UDC IRQ pending.

This patch will check UDC IRQ source and will not cause bus resume if no
IRQ pending for UDC driver.

BUG 1015685

Change-Id: Ifc5634ae5d1f7f1435c64bc527ab2e9fb8d0e36b
Signed-off-by: Xin Xie <xxie@nvidia.com>
Reviewed-on: http://git-master/r/121896
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agousb: gadget: tegra_udc: use USB charging spec 1.2
Xin Xie [Wed, 1 Aug 2012 23:18:55 +0000]
usb: gadget: tegra_udc: use USB charging spec 1.2

Enable the USB charging based on the USB charging spec 1.2. Now we can
detect:
1. SDP (stanardard downstream port)
2. CDP (charging downstream port)
3. DCP (dedicated charging port)
4. None (no cable connected)
5. Non-standard charger

For some non-standard charger, we cannot detect it as DCP device.
If we find a charger detected as USB device but no EP0 packet recieved
with 1s, we then decided this is 1A charger.

bug 968345

Change-Id: I804f90ea6e4794da8f52b1c3ebd694828d99f40e
Signed-off-by: Xin Xie <xxie@nvidia.com>
Reviewed-on: http://git-master/r/120218
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: baseband: Fix sysfs node permissions
Steve Lin [Tue, 31 Jul 2012 00:34:00 +0000]
arm: tegra: baseband: Fix sysfs node permissions

Restricting the modem sysfs node permissions to owner only.
Bug 1025901

Change-Id: I85095c06b6f5329403b66389a5f27383464f2c64
Signed-off-by: Steve Lin <stlin@nvidia.com>
(cherry picked from commit 21bbdcd602f8de21ab09de64cf15fee20643c8ea)
Reviewed-on: http://git-master/r/124131
Reviewed-by: Automatic_Commit_Validation_User
Tested-by: Peter Zu <pzu@nvidia.com>

6 years agosecurity: tf_driver: integrate latest TL release
Hyung Taek Ryoo [Fri, 10 Aug 2012 18:48:56 +0000]
security: tf_driver: integrate latest TL release

Tegra 3 version: TF_TEGRA3_AB01.15.36932
1)Fix an issue in GIC controller
2)Add a task profiler option into the Trusted Foundations
3)Fixes the RCU stalls

Bug 1030417

Reviewed-on: http://git-master/r/122808

Change-Id: I9fc15c69da94d5a2c56fc8582ccb1db0cf8936b4
Signed-off-by: Hyung Taek Ryoo <hryoo@nvidia.com>
Reviewed-on: http://git-master/r/123773
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: James Zhao <jamesz@nvidia.com>
Reviewed-by: Pradeep Thiruchelvam <pradeept@nvidia.com>

6 years agovideo: tegra: dc: fix boot issue with HDMI
Deepak Nibade [Thu, 16 Aug 2012 11:58:51 +0000]
video: tegra: dc: fix boot issue with HDMI

Set default mode for probe and resume to enable initialization of dc.1
Skipping this initialization results in hard system hang.

bug 1030415

Change-Id: Icd8fe08a7803490117ed20caf0185f5cd4fb0d0b
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/124001
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Tested-by: Jon Mayo <jmayo@nvidia.com>

6 years agoarm: tegra: E1506 Tristate, pull down LCD pins
Prem Sasidharan [Mon, 13 Aug 2012 20:54:16 +0000]
arm: tegra: E1506 Tristate, pull down LCD pins

Tristate and pull down LCD pins D0-D23, LCD_PWR* and
LCD_CS*_N pins for E1506 DSI panel. Reduced the power
consumption on VDDIO_LCD to 0.37mW for PM269 with E1506
DSI panel.

Bug 1007512
Bug 1015349

Signed-off-by: Prem Sasidharan <psasidharan@nvidia.com>
Change-Id: Ic54d1ca71f5ff92742f70915b7b27104c0a508a6
Reviewed-on: http://git-master/r/123172
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
(cherry picked from commit a8047fabd0ae8fc767ce6f276d8bfb53fc838d05)
Reviewed-on: http://git-master/r/123848
Tested-by: Jon Mayo <jmayo@nvidia.com>

6 years agovideo: tegra: nvmap: Add sanity checks for page pools.
Krishna Reddy [Wed, 1 Aug 2012 22:15:21 +0000]
video: tegra: nvmap: Add sanity checks for page pools.

Check return code for set_page_array_* calls.

Change-Id: Ie62ac78b82321939d5bd9d2a636d72dadea50d28
Signed-off-by: Krishna Reddy <vdumpa@nvidia.com>
Reviewed-on: http://git-master/r/123544

6 years agonet: wireless: bcmdhd: Update to 5.90.195.75
Narayan Reddy [Fri, 27 Jul 2012 09:57:53 +0000]
net: wireless: bcmdhd: Update to 5.90.195.75

Bug 1023045
Bug 1026444

Reviewed-on: http://git-master/r/117637
(cherry picked from commit 57716f1d1f8381ff50874cb81c326e203909b4f3)

Signed-off-by: Narayan Reddy <narayanr@nvidia.com>
Change-Id: I9da8fd7775cafae9284380723c81cb2bbfe61006
Reviewed-on: http://git-master/r/123986
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Rakesh Goyal <rgoyal@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Pradeep Thiruchelvam <pradeept@nvidia.com>

6 years agoARM: tegra: usb: handle device connect in lp0
Krishna Yarlagadda [Tue, 14 Aug 2012 16:06:59 +0000]
ARM: tegra: usb: handle device connect in lp0

When a otg cable is connected along with device during lp0
system will wakeup but might not complete device enumeration
before going back to lp0. In this case we have to handle pmc
disable.

Bug 1024456

Change-Id: I9acbf434e58776c3d58de1b28d442d6b20b256d0
Signed-off-by: Krishna Yarlagadda <kyarlagadda@nvidia.com>
Reviewed-on: http://git-master/r/123383
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>

6 years agoUSB: gadget: f_audio_source: Adjust packet timing to reduce glitches
Mike Lockwood [Sun, 27 May 2012 22:41:53 +0000]
USB: gadget: f_audio_source: Adjust packet timing to reduce glitches

Increase max packet size and clean up timing logic so we can better
recover from not getting an interrupt in time for a SOF.

Bug 1026047

Signed-off-by: Mike Lockwood <lockwood@google.com>
(cherry picked from commit 3d2096a7959d023bc31a3cf934c3d425de01c94f)

Signed-off-by: Rakesh Bodla <rbodla@nvidia.com>
Change-Id: I0a0a6f448e71e4a0c478bb44cadc54fa021e13e4
Reviewed-on: http://git-master/r/123344
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>

6 years agoUSB: gadget: f_audio_source: New gadget driver for audio output
Mike Lockwood [Fri, 11 May 2012 16:01:08 +0000]
USB: gadget: f_audio_source: New gadget driver for audio output

This driver presents a standard USB audio class interface to the host
and an ALSA PCM device to userspace

Bug 1026047

Signed-off-by: Mike Lockwood <lockwood@google.com>
(cherry picked from commit a23ff394752015a233dd3b27b05c9d913cbf5536)

Signed-off-by: Rakesh Bodla <rbodla@nvidia.com>
Change-Id: I4054e09888f17d9cdfcfd4a3d430ca5cfb3fd9fa
Reviewed-on: http://git-master/r/123343
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>

6 years agoUSB: gadget: f_accessory: Add support for HID input devices
Rakesh Bodla [Tue, 14 Aug 2012 12:06:15 +0000]
USB: gadget: f_accessory: Add support for HID input devices

Bug 1026047

Signed-off-by: Mike Lockwood <lockwood@google.com>
(cherry picked from commit 7a3d01af4f04950a86a18f5a439f1802d8093650)

Conflicts:

drivers/usb/gadget/f_accessory.c

Change-Id: I30bc02a1bcf636967d56370db83578f49f0e7514
Signed-off-by: Rakesh Bodla <rbodla@nvidia.com>
Reviewed-on: http://git-master/r/123342
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>

6 years agoAdd ACCESSORY_SET_AUDIO_MODE control request and ioctl
Mike Lockwood [Fri, 11 May 2012 16:00:40 +0000]
Add ACCESSORY_SET_AUDIO_MODE control request and ioctl

The control request will be used by the host to enable/disable USB audio
and the ioctl will be used by userspace to read the audio mode

Bug 1026047

Signed-off-by: Mike Lockwood <lockwood@google.com>
(cherry picked from commit 3e1ff6142761eef148c667e540381d1fbc437d4f)

Signed-off-by: Rakesh Bodla <rbodla@nvidia.com>
Change-Id: I5f449de230ca8f44e2dae30a0f87772310b68f20
Reviewed-on: http://git-master/r/123341
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>

6 years agopower: max17048: update charge status when resume
Kerwin Wan [Tue, 14 Aug 2012 09:31:11 +0000]
power: max17048: update charge status when resume

bug 1033234

Change-Id: I67a28113fbf0a2461886658322f9106d17a69f23
Signed-off-by: Kerwin Wan <kerwinw@nvidia.com>
Reviewed-on: http://git-master/r/123301
Reviewed-by: Chandler Zhang <chazhang@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Varun Wadekar <vwadekar@nvidia.com>

6 years agovideo: tegra: nvmap: fix input check in mmap ioctl
Tuomas Tynkkynen [Tue, 31 Jul 2012 14:49:49 +0000]
video: tegra: nvmap: fix input check in mmap ioctl

nvmap_map_into_caller_ptr takes a memory handle from usermode
and adds a memory mapping for the handle. However, the handle
is not checked for being allocated. An unallocated handle
would cause a kernel panic later on from a NULL dereference.

Change-Id: I73987b097a0c843b913660445e8bd1b4755dac61
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-on: http://git-master/r/119689
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agogpio: tegra: hide tegra_gpio_enable()/disable()
Laxman Dewangan [Tue, 31 Jul 2012 10:08:43 +0000]
gpio: tegra: hide tegra_gpio_enable()/disable()

The direction apis and irq_set_wake() support the
configuration of pins in gpio mode and hence it
is not require to export the apis for gpio_enable()/
gpio_disable().
Hiding these api.

Change-Id: I5493e4f270df85da21afb6500ac841f4fa4b522a
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/119616
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
GVS: Gerrit_Virtual_Submit

6 years agoARM: tegra: clocks: Frequency stats for SCLK/CBUS
Srikanth Nori [Tue, 3 Jul 2012 00:35:38 +0000]
ARM: tegra: clocks: Frequency stats for SCLK/CBUS

This adds a frequency histogram of the frequencies that SCLK
and CBUS clocks go to over time. Stats are presented in the
debugfs at /d/clock_stats/cbus and /d/clock_stats/sclk only if
debugfs is enabled in config

Change-Id: Icae83329612958d8ed4318b2e10c487683d9d734
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
Reviewed-on: http://git-master/r/118380
Reviewed-by: Wen Yi <wyi@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Thomas Cherry <tcherry@nvidia.com>

6 years agousb: gadget: tegra_udc: Enable DR IRQ in udc_start
Preetham Chandru [Tue, 10 Jul 2012 13:12:16 +0000]
usb: gadget: tegra_udc: Enable DR IRQ in udc_start

Currently dr_controller_run() is called only during otg state
change.
When we unload a gadget driver, for example g_mass_storage
gadget driver, dr_controller_stop() is called but when it is
loaded back dr_controller_run() won't get called becasue of the
if condition failure. i.e
if (!udc->transceiver) {
dr_controller_run(udc);
}

So when the gadget driver is loaded for the second time
without removing the cable (i.e without otg state change),
the device won't get enumerated on the host because DR
IRQs are not enabled.

This CL fixes the above issue.

Bug 1012787
Signed-off-by: Preetham Chandru <pchandru@nvidia.com>

Change-Id: Ia127630e24dbe4c1e418163c2b858efb3baa8e45
Reviewed-on: http://git-master/r/114592
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agopower: max17048: update charge status when resume
Kerwin Wan [Tue, 14 Aug 2012 09:31:11 +0000]
power: max17048: update charge status when resume

bug 1033234

original change is http://git-master/r/123301

Change-Id: I8722d3657bb61493bc5b58de584904fdf961e580
Signed-off-by: Kerwin Wan <kerwinw@nvidia.com>
Reviewed-on: http://git-master/r/123917
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Varun Wadekar <vwadekar@nvidia.com>

6 years agovideo: tegra: dc: disuse notifier
Ilan Aelion [Fri, 10 Aug 2012 19:53:10 +0000]
video: tegra: dc: disuse notifier

Due to issues with rcu notifiers on secureos, modifying dc flip
notifications to use a simple callback instead.

Bug 1028850

Change-Id: Iebf2a6d64d7316e3df2b88444201f9f9a29698c5
Signed-off-by: Ilan Aelion <iaelion@nvidia.com>
Reviewed-on: http://git-master/r/123103
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-by: Nitin Kumbhar <nkumbhar@nvidia.com>

6 years agosecurity: tf_driver: integrate latest TL release
Hyung Taek Ryoo [Fri, 10 Aug 2012 18:48:56 +0000]
security: tf_driver: integrate latest TL release

Tegra 3 version: TF_TEGRA3_AB01.15.36932
1)Fix an issue in GIC controller
2)Add a task profiler option into the Trusted Foundations
3)Fixes the RCU stalls

Change-Id: Ib137dc4f155765cb7d7084f1f9a6f75d3bf38116
Signed-off-by: Hyung Taek Ryoo <hryoo@nvidia.com>
Reviewed-on: http://git-master/r/122808
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: James Zhao <jamesz@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>

6 years agovideo: tegra: dc: disuse notifier
Ilan Aelion [Fri, 10 Aug 2012 19:53:10 +0000]
video: tegra: dc: disuse notifier

Due to issues with rcu notifiers on secureos, modifying dc flip
notifications to use a simple callback instead.

Bug 1028850

Change-Id: Iebf2a6d64d7316e3df2b88444201f9f9a29698c5
Signed-off-by: Ilan Aelion <iaelion@nvidia.com>
(cherry picked from commit 62c5a94c283de070d8a8d9ace60f944100216afc)
Reviewed-on: http://git-master/r/#change,123103
Reviewed-on: http://git-master/r/123789
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Pradeep Thiruchelvam <pradeept@nvidia.com>
Tested-by: Varun Colbert <vcolbert@nvidia.com>
Tested-by: Sang-Hun Lee <sanlee@nvidia.com>

6 years agoarm: tegra: la: refactor la code.
Krishna Reddy [Mon, 13 Aug 2012 19:37:32 +0000]
arm: tegra: la: refactor la code.

This is necessary to support future tegra SOC's.

Change-Id: I2f6ce328e30a6895dce16d82c4097291339155cd
Signed-off-by: Krishna Reddy <vdumpa@nvidia.com>
Reviewed-on: http://git-master/r/123146
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Mark Stadler <mastadler@nvidia.com>
GVS: Gerrit_Virtual_Submit

6 years agovideo: tegra: host: Fix leak in 3D register read
Terje Bergstrom [Wed, 15 Aug 2012 09:12:16 +0000]
video: tegra: host: Fix leak in 3D register read

When 3D register is read, and we need to do a context switch, the old
context reference is incremented, but it never gets decremented. Fix
by using nvhost_job_get_hwctx() to acquire the reference.

Bug 1031746

Change-Id: Ic72637cb2399f960e2297733bfe45e585a8ec180
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/123678
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Arto Merilainen <amerilainen@nvidia.com>
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>
GVS: Gerrit_Virtual_Submit

6 years agomm: Avoid freeing init and initrd memory when CPA is enabled.
Krishna Reddy [Sun, 29 Jul 2012 22:32:14 +0000]
mm: Avoid freeing init and initrd memory when CPA is enabled.

Align memblock reserve for text area to PMD size.
Reserve the memory hole between DRAM start and Page table start.
Add Sanity check to avoid section split in text area.

Bug 1028787

Change-Id: I586e4ad6e3a94aa0c79b302e51156dbe089e481f
Signed-off-by: Krishna Reddy <vdumpa@nvidia.com>
Reviewed-on: http://git-master/r/121883
(cherry picked from commit 65d02640b4b0b38263687c7f3e664c873237dc43)
Reviewed-on: http://git-master/r/123431
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoARM: tegra: power: Trace LP2 entry and exit
Antti P Miettinen [Tue, 14 Aug 2012 10:14:00 +0000]
ARM: tegra: power: Trace LP2 entry and exit

Add traces for measuring LP2 entry/exit times.

Bug 960304

Change-Id: I20bb0f8d55a7ed6f7e88e10d924871a3d09f2507
Signed-off-by: Antti P Miettinen <amiettinen@nvidia.com>
Reviewed-on: http://git-master/r/123313
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>

6 years agoarm: tegra: E1506 Tristate, pull down LCD pins
Prem Sasidharan [Mon, 13 Aug 2012 20:54:16 +0000]
arm: tegra: E1506 Tristate, pull down LCD pins

Tristate and pull down LCD pins D0-D23, LCD_PWR* and
LCD_CS*_N pins for E1506 DSI panel. Reduced the power
consumption on VDDIO_LCD to 0.37mW for PM269 with E1506
DSI panel.

Bug 1007512
Bug 1015349

Signed-off-by: Prem Sasidharan <psasidharan@nvidia.com>
Change-Id: Ic54d1ca71f5ff92742f70915b7b27104c0a508a6
Reviewed-on: http://git-master/r/123172
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Jon Mayo <jmayo@nvidia.com>

6 years agoARM: tegra: enterprise: set I2S as slave mode.
Ankit Gupta [Mon, 13 Aug 2012 06:44:51 +0000]
ARM: tegra: enterprise: set I2S as slave mode.

Setting default I2S mode as slave. This will help in power
optimization of around 4mW.

Change-Id: Ic2d702c332283bd0f6c4f73615e8097fb3b16ef9
Signed-off-by: Ankit Gupta <ankitgupta@nvidia.com>
Reviewed-on: http://git-master/r/122943
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoARM: tegra: p1853: get rid of tegra_gpio_enable()
Laxman Dewangan [Mon, 13 Aug 2012 05:51:45 +0000]
ARM: tegra: p1853: get rid of tegra_gpio_enable()

The gpio mode is enabled when setting direction and
disabled when freeing gpio and hence this call is no
more required.

Change-Id: Ic40a506a54ee8fe125c0c1f56a8857fb290fcccb
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/122938
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoARM: tegra: p852: get rid of tegra_gpio_enable()
Laxman Dewangan [Mon, 13 Aug 2012 05:49:41 +0000]
ARM: tegra: p852: get rid of tegra_gpio_enable()

The gpio mode is enabled when setting direction and
disabled when freeing gpio and hence this call is no
more required.

Change-Id: I30647b96fa2a120fb323c18e97bc9936a95c305d
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/122937
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agovideo: tegra: nvmap: Add support for zeroed pages
Alex Waterman [Wed, 1 Aug 2012 18:02:30 +0000]
video: tegra: nvmap: Add support for zeroed pages

Add support to alloc zeroed pages for user space alloc requests. Also
define a config option to force userspace allocation requests to be
zeroed.

Change-Id: I75d3b2bc36e808f1470b423578ec4cba99e0f967
Signed-off-by: Alex Waterman <alexw@nvidia.com>
Reviewed-on: http://git-master/r/122549
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agomm: Fix incorrect cache attribute restoration.
Krishna Reddy [Thu, 9 Aug 2012 18:18:21 +0000]
mm: Fix incorrect cache attribute restoration.

armv7 uses cache policy as WRITEALLOC. CPA is
restoring the cache attributes to WRITEBACK during
set_pages_array_wb().
Fixed issues in pmd to pte prot translation and vice versa.

Change-Id: I8406b784f62d559f657ef7bc08e77c83ac6e5690
Signed-off-by: Krishna Reddy <vdumpa@nvidia.com>
Reviewed-on: http://git-master/r/122472
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: xmm: adding callback for L0 sequence.
Shawn Joo [Mon, 13 Aug 2012 07:50:48 +0000]
arm: tegra: xmm: adding callback for L0 sequence.

adding callback of xmm modem for L3->L0 power sequence.

Bug 1030815

Change-Id: I4997f56819726a55fc8268a1011bc98ff6baf8ca
Signed-off-by: Shawn Joo <sjoo@nvidia.com>
Reviewed-on: http://git-master/r/122960
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agovideo: tegra: host: Disable host1x irqs at suspend
Terje Bergstrom [Mon, 13 Aug 2012 12:06:23 +0000]
video: tegra: host: Disable host1x irqs at suspend

host1x interrupts have been left on at suspend due to using wrong
constant for the interrupt register. Disable host1x interrupts at
suspend.

Change-Id: I915fc4e663e6ad90fccacff6fb223c5080e21fcd
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/123055
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Andrew Howe <ahowe@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Mayuresh Kulkarni <mkulkarni@nvidia.com>
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>

6 years agopower: tps80031-battery: enable battery full event
Xin Xie [Thu, 12 Jul 2012 22:17:37 +0000]
power: tps80031-battery: enable battery full event

BUG 1015045

Change-Id: Id9ac783365f08787638edc057d55f29c9a0e46eb
Signed-off-by: Xin Xie <xxie@nvidia.com>
Reviewed-on: http://git-master/r/122310
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>

6 years agopower: tps80031: charger: handle re-charge event
Xin Xie [Fri, 13 Jul 2012 01:26:59 +0000]
power: tps80031: charger: handle re-charge event

After the charging completed, TPS80031 can re-enable the charging if it
sense the voltage dropping (120mV below target). Current drive does not
handle this event and causing the charging forever stopped.

This patch will check the above re-charging happens in the charging WDT
handler, and will ack WDT in order to continue charging.

BUG 1015045

Change-Id: Ia0a53d29cd0e73e7ebcd53f8176c8ef81b6c6090
Signed-off-by: Xin Xie <xxie@nvidia.com>
Reviewed-on: http://git-master/r/122309
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>

6 years agoarm: tegra: enterprise: Pinmux changes for Enterprise A04
Karthik Ramakrishnan [Wed, 20 Jun 2012 07:23:07 +0000]
arm: tegra: enterprise: Pinmux changes for Enterprise A04

Pinmux configurations updated according to the schematics of
Enterprise A04. The unused pins are marked Tristate and turned
low. The directions are updated for other pins.

Bug 990845

Change-Id: I787bdd77848af59b5c33d030f0c040e7431d6c06
Signed-Off-By: Karthik Ramakrishnan <karthikr@nvidia.com>
Reviewed-on: http://git-master/r/105205
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit 79fa97af045b942bb61507bbeffb0fa6d7055347)

Signed-off-by: Peter Zu <pzu@nvidia.com>
Change-Id: I3e0ae511b76a89fec8dd8f00304388a6dcabdf4b
Reviewed-on: http://git-master/r/123490
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agousb: host: fix tegra_ehci_remove() warnings
Venu Byravarasu [Wed, 8 Aug 2012 11:59:36 +0000]
usb: host: fix tegra_ehci_remove() warnings

usb_put_hcd calls hcd_release which frees up memory allocated
for hcd. As iounmap is called after usb_put_hcd and it is trying
to access hcd->regs, getting warning messages during unload of
USB. Hence fixing it.

bug 1023362

Change-Id: Ic339395edad9a76a9eeae290eff3517d2c714477
Signed-off-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Reviewed-on: http://git-master/r/122088
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Krishna Yarlagadda <kyarlagadda@nvidia.com>
Tested-by: Krishna Yarlagadda <kyarlagadda@nvidia.com>
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>
(cherry picked from commit 7b3a327acb3a63fddc14f2b3ecd19a7ea8f41b3e)
Reviewed-on: http://git-master/r/123489
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoUSB: otg: delay device disconnect
Krishna Yarlagadda [Wed, 8 Aug 2012 11:31:10 +0000]
USB: otg: delay device disconnect

Device disconnect during resume might fail if notification
clients for this device removal are not ready.
Disconnecting device after the resume is complete.

Bug 1024496

Change-Id: Ia806e177d2dd2b1b43d3fea7a4af45f0d4a93cd4
Signed-off-by: Krishna Yarlagadda <kyarlagadda@nvidia.com>
Reviewed-on: http://git-master/r/122079
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit df73b460996b2f6e2c0b0d93b3679d6dca9d4615)
Reviewed-on: http://git-master/r/123488
Reviewed-by: Automatic_Commit_Validation_User

6 years agopower: smb349: correct charger status
Allen Yu [Wed, 8 Aug 2012 06:50:40 +0000]
power: smb349: correct charger status

When tegra-otg suspends with charger cable connected, the charger
state and type should not be changed, neither should the charger
callback be executed.

SMB349 has a debounce delay of ~20ms +/- 3 after cable is unpluged
and will stop all I2C functions for 2.3ms when getting reset to POR.
Add 50ms' delay before reading charger status to avoid I2C error and
make sure we get the right charger state.

Bug 1024735

Change-Id: I1667b23df768b46b524c6578c4bee09e131d9f96
Signed-off-by: Allen Yu <alleny@nvidia.com>
Reviewed-on: http://git-master/r/120905
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
GVS: Gerrit_Virtual_Submit
(cherry picked from commit 71f038602f3417417aec99470fabb287ec8886fd)
Reviewed-on: http://git-master/r/123487
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: usb_phy: fix null pointer dereference
Rakesh Bodla [Wed, 8 Aug 2012 09:06:13 +0000]
arm: tegra: usb_phy: fix null pointer dereference

Fixing the null pointer dereference crash. Also
modifying USB driver not to give up in case if there
is no avdd_usb regulator.

Bug 1029852

Change-Id: I3232b7fa1580a0dc1aadd47b138e5eeae05af6f0
Signed-off-by: Rakesh Bodla <rbodla@nvidia.com>
Reviewed-on: http://git-master/r/121984
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>
(cherry picked from commit 48d8c7c91ea5acddf23f74abc801c89c9f16680f)
Reviewed-on: http://git-master/r/123486
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agousb: gadget: tegra: fix compilation issue
Rakesh Bodla [Wed, 8 Aug 2012 08:44:53 +0000]
usb: gadget: tegra: fix compilation issue

Fixing the potential compilation this is
currently masked as CONFIG_USB_OTG_UTILS
is enabled.

Change-Id: Ie10e5fc252156b8b904d387d87a11136fcc3f4c1
Signed-off-by: Rakesh Bodla <rbodla@nvidia.com>
Reviewed-on: http://git-master/r/122043
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>
(cherry picked from commit a50e57e22bb42aa20e59686af148d24f09291c54)
Reviewed-on: http://git-master/r/123485
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agousb: otg: tegra: fix compilations errors
Rakesh Bodla [Wed, 8 Aug 2012 06:48:03 +0000]
usb: otg: tegra: fix compilations errors

Werror flag is enabled now. Fixing the compilations
errors when DEBUG is enabled.

Change-Id: I909dd177eedfd72f1f71d1a546fc40c301bd1aa7
Signed-off-by: Rakesh Bodla <rbodla@nvidia.com>
Reviewed-on: http://git-master/r/122033
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>
(cherry picked from commit eb623030d171e1369760107886636f2985b39fc3)
Reviewed-on: http://git-master/r/123484
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: usb_phy: remove duplicate code
Rakesh Bodla [Wed, 8 Aug 2012 05:45:31 +0000]
arm: tegra: usb_phy: remove duplicate code

Remove duplicate code.

Change-Id: I9c9979f489d93c458f5e494fbb69008b89578b8d
Signed-off-by: Rakesh Bodla <rbodla@nvidia.com>
Reviewed-on: http://git-master/r/121988
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>
(cherry picked from commit 89c0dc999188865e0e6d58327d7beafb65587ea2)
Reviewed-on: http://git-master/r/123483
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: usbphy: disable PLLU clock
Suresh Mangipudi [Wed, 1 Aug 2012 11:27:51 +0000]
arm: tegra: usbphy: disable PLLU clock

Disable the MASTER_BLASTER clock for the null phy interface
when usb_bus is suspended.

Bug 992861

Change-Id: I86ff559148f9a128ee48bbea2564493f4286b420
Signed-off-by: Suresh Mangipudi <smangipudi@nvidia.com>
Reviewed-on: http://git-master/r/120006
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit 6e789ddf027ae942bfb7e442cc66e218f919bb28)
Reviewed-on: http://git-master/r/123482
Reviewed-by: Automatic_Commit_Validation_User

6 years agoarm: tegra: usb: link ulpi resume sequence
Suresh Mangipudi [Wed, 1 Aug 2012 05:50:58 +0000]
arm: tegra: usb: link ulpi resume sequence

lp0 resume for link_ulpi_phy has been modified.To fix the issue of
frequent disconnects while resuming from LP0.

Bug 997267

Change-Id: If92b8245b154e9b872b80d80a2ab359c87107a39
Signed-off-by: Suresh Mangipudi <smangipudi@nvidia.com>
Reviewed-on: http://git-master/r/119511
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit d228a8472dfa7b12e8841bc340ce54b9a7c1db10)
Reviewed-on: http://git-master/r/123481
Reviewed-by: Automatic_Commit_Validation_User

6 years agoarm: tegra: xmm: protect xmm power state
Vinayak Pane [Wed, 30 May 2012 01:00:26 +0000]
arm: tegra: xmm: protect xmm power state

Added protection locks for xmm power state. Moving
prints outside of spinlock. Revisit spinlock on global
flags and rearrange in irq.
Avoid kernel crash in case of remote-wakeup detected.
Protect ipc_ap_wake_state in xmm on & off.

Bug 1010131

Change-Id: Id53598b09bececd6f4ff1a948a492e6fcc56628c
Signed-off-by: Vinayak Pane <vpane@nvidia.com>
Reviewed-on: http://git-master/r/108427
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Michael Hsu <mhsu@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Steve Lin <stlin@nvidia.com>
(cherry picked from commit cd0b0f629c7709411600a944a72b06225a523bac)
Reviewed-on: http://git-master/r/123480
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agovideo: tegra: nvmap: fix usermode input validation
Tuomas Tynkkynen [Tue, 31 Jul 2012 12:01:04 +0000]
video: tegra: nvmap: fix usermode input validation

nvmap_pin_ids accepts a list of handles to pin, which are passed
directly from usermode when called from nvmap_ioctl_pinop.

However, if invalid handles are passed in, the function might
still access them as valid handles, and cause a crash.

Bug 1023954

Change-Id: I6b98a2ef448bb496be7d569ddd4fb516fc399cba
Signed-off-by: Tuomas Tynkkynen <ttynkkynen@nvidia.com>
Reviewed-on: http://git-master/r/119667
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>
(cherry picked from commit 70d4ced2d12a1251202d67ffae7f5c0b3013cc94)
Reviewed-on: http://git-master/r/123478
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoMPU6050: Disable irq when suspend all sensors
Hunk Lin [Mon, 30 Jul 2012 16:19:09 +0000]
MPU6050: Disable irq when suspend all sensors

When we suspend all sensors, MPU6050 continue generating irqs.
So set MPUREG_INT_ENABLE to 0 for saving power.

Bug 1021448

Signed-off-by: Hunk Lin <hulin@nvidia.com>
Change-Id: I90acb0b5e297c61c205a20b8eb54e6164a4d5b32
Reviewed-on: http://git-master/r/119344
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Prem Sasidharan <psasidharan@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Varun Wadekar <vwadekar@nvidia.com>
(cherry picked from commit 420cba2c46f70f77945653be51656b6ae89d5397)
Reviewed-on: http://git-master/r/123477
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: xmm: repair ipc_ap_wake_state at reset
Vinayak Pane [Wed, 25 Jul 2012 04:13:56 +0000]
arm: tegra: xmm: repair ipc_ap_wake_state at reset

Preparing strict checking for ipc_ap_wake_state during
modem initialization.

Modify the flashless xmm wake irq part to avoid mixing
with flashed modem irq handler.

Remove unused init1 workqueue from the driver.

Bug 1003141

Change-Id: I7b06b1783a140c0cc5121478e4983fab39862d7c
Signed-off-by: Vinayak Pane <vpane@nvidia.com>
Reviewed-on: http://git-master/r/118475
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Steve Lin <stlin@nvidia.com>
(cherry picked from commit e7a7520c6494c6610835bd6e5c83e790a05892eb)
Reviewed-on: http://git-master/r/123476
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agovideo: tegra: host: use strcmp in nvhost_bus_match
Mayuresh Kulkarni [Tue, 24 Jul 2012 07:17:24 +0000]
video: tegra: host: use strcmp in nvhost_bus_match

- replace the usage of strncmp with strcmp in
nvhost_bus_match()
- strncmp was needed when we had device name as
<name.ip-version>. but now the device name is <name>
which matches with the driver name.
- multiple devices get bind with the same driver using
id_table which uses .version field as an index in id_table

Change-Id: If0b6f0ee18626d5e7ff801b8515ef5168069c3f2
Signed-off-by: Mayuresh Kulkarni <mkulkarni@nvidia.com>
Reviewed-on: http://git-master/r/117953
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Ken Adams <kadams@nvidia.com>
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
(cherry picked from commit ece74a0888415460a005d52bcf2d5f6cf535597d)
Reviewed-on: http://git-master/r/123475
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: xmm: device set to null in unregister
Vinayak Pane [Wed, 18 Jul 2012 02:06:54 +0000]
arm: tegra: xmm: device set to null in unregister

hsic_unregister is being called multiple times
during two step enumeration process of xmm.
In failure cases when enumeration does not
complete properly, kernel panic is seen because
of extra unregister-ehci device.

Bug 1016593

Change-Id: Ibaeb20ed0dab0e906741fdfad78f7d89a3672f60
Signed-off-by: Vinayak Pane <vpane@nvidia.com>
Reviewed-on: http://git-master/r/116626
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit 675dfd18c952e6cf5748aaa305086d86b0358582)
Reviewed-on: http://git-master/r/123474
Reviewed-by: Automatic_Commit_Validation_User

6 years agoarm: tegra: enterprise: Use pll_p as clk source for PWR_I2C
Chaitanya Bandi [Tue, 10 Jul 2012 12:59:19 +0000]
arm: tegra: enterprise: Use pll_p as clk source for PWR_I2C

Using pll_p as clock source for PWR_I2C and set bus frequency
to 390Khz to make clock divider as 0x82.

Bug 1001924

Change-Id: Ib7936b0da9a754cc6b4858eb40a941eee606ac65
Signed-off-by: Chaitanya Bandi <bandik@nvidia.com>
Reviewed-on: http://git-master/r/114577
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit ce9fc97cf95c463dff8156dffd5632e5336e4adc)
Reviewed-on: http://git-master/r/123473
Reviewed-by: Automatic_Commit_Validation_User

6 years agoalsa: hda: add alsa ctl to query max channels
Nikesh Oswal [Thu, 26 Jul 2012 10:28:46 +0000]
alsa: hda: add alsa ctl to query max channels

add alsa ctl to query maximum supported
channels

Bug: 998697

Signed-off-by: Nikesh Oswal <noswal@nvidia.com>
Change-Id: Id2f0e6a62d2413615f13a0c18757c05610ef0c2c
Reviewed-on: http://git-master/r/118602
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Scott Peterson <speterson@nvidia.com>
(cherry picked from commit 93fa2d495c82c5b63572e62e8bba6a6acf3269f9)
Reviewed-on: http://git-master/r/123472
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: usb_phy: remote-wake for LS devices
Suresh Mangipudi [Thu, 9 Aug 2012 08:24:57 +0000]
arm: tegra: usb_phy: remote-wake for LS devices

Remote wakeup was not working for low speed devices.
Remote wakeup interrupt is now handled properly for low speed
devices.

Bug 1029608

Change-Id: If224f30ccc6275b97d50120fe04d9aa53d495e2e
Signed-off-by: Suresh Mangipudi <smangipudi@nvidia.com>
Reviewed-on: http://git-master/r/122367
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit c065d9e47085fbb98924d986c3915f279e504fc8)
Reviewed-on: http://git-master/r/123471
Reviewed-by: Automatic_Commit_Validation_User

6 years agousb: ehci: tegra: Fix Slab corruption error
Preetham Chandru [Thu, 9 Aug 2012 08:21:39 +0000]
usb: ehci: tegra: Fix Slab corruption error

Give ownership of the DMA buffer back to the processor first and
then free the buffer. Otherwise processor won't be able to
access the dma mapped buffers and this would lead to slab
corruption.
When the DMA buffer is freed without a call to dma_sync_single_for_cpu(),
the kernel won't be able to set the buffer as POISON FREE and when we
acquire this memory back again the kernel will start printing slab
corruption output as the memory is not set to POISON FREE

Bug 1017884
Bug 1018161
Reviewed-on: http://git-master/r/#change,122151
Signed-off-by: Preetham Chandru R <pchandru@nvidia.com>

Change-Id: I00d6cb185cd2314cccb56f968eb0a05288588c13
Reviewed-on: http://git-master/r/122390
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit 642d37a0eee196d0ce811dd11bb7af5ba281ee3a)

Signed-off-by: Peter Zu <pzu@nvidia.com>
Change-Id: I3ff611a3674536a93233da53488840fb77c5d4ef
Reviewed-on: http://git-master/r/123470
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: config: tegra3: enable ipv4/ipv6 filters
Mohan T [Thu, 9 Aug 2012 04:21:11 +0000]
arm: config: tegra3: enable ipv4/ipv6 filters

Android jb need ip filters to be enabled
to track data uses.

Bug 1019233

Change-Id: I8073643a4a7c34e428c02682a3afc5a23fbcf344
Signed-off-by: Mohan T <mohant@nvidia.com>
Reviewed-on: http://git-master/r/122051
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Rakesh Kumar <krakesh@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
(cherry picked from commit bbdf4403412df9151864bd633519f828ea27c8c6)
Reviewed-on: http://git-master/r/123469
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoALSA: usb-audio: fix compilation error
Rhyland Klein [Thu, 2 Aug 2012 19:29:35 +0000]
ALSA: usb-audio: fix compilation error

change 8843c49092b6ed903e88eded1f1c9b9a7f432dfe introduced
a compliation error if CONFIG_SWITCH is not enabled.

Signed-off-by: Rhyland Klein <rklein@nvidia.com>
Change-Id: I4b4c547394f424bd90837726b08d9feccd4207de
Reviewed-on: http://git-master/r/120444
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Ravindra Lokhande <rlokhande@nvidia.com>
Reviewed-by: Scott Peterson <speterson@nvidia.com>
(cherry picked from commit 991fbf047fca8a4fa729d090b5c3f65a89acb9ba)
Reviewed-on: http://git-master/r/123468
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoasoc: tegra: fix compilation error in max98095
Rhyland Klein [Thu, 2 Aug 2012 19:27:53 +0000]
asoc: tegra: fix compilation error in max98095

change 4b70cc537cadc787b748c7c246d703a240b08985 introduced
a compilation error.

Signed-off-by: Rhyland Klein <rklein@nvidia.com>
Change-Id: I59e54537d9bb4b30e807478e5b7634db0813a739
Reviewed-on: http://git-master/r/120443
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Ankit Gupta (Engrg-SW) <ankitgupta@nvidia.com>
Reviewed-by: Scott Peterson <speterson@nvidia.com>
(cherry picked from commit c5dea888253285e23107585805b7728ebe46e17e)
Reviewed-on: http://git-master/r/123467
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agomfd: Don't use I2C-specific suspend and resume operations for tps65090
Mark Brown [Mon, 7 May 2012 09:03:18 +0000]
mfd: Don't use I2C-specific suspend and resume operations for tps65090

The legacy suspend operations have been deprecated and printing warnings
on boot for over a year now.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
(Cherry-picked from mainline
b6c9eeef4e775e1fff76f4395d11638dc198271d)

Change-Id: Ia8b79787c813327fe1d1ccb5a5ad19da57f2212f
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/120369
(cherry picked from commit b7582d0944f6329e8eb3804fd0a53eaacefe4395)

Signed-off-by: Peter Zu <pzu@nvidia.com>
Change-Id: I844f6f7962794c52a15a498fd6f83c5b413a9984
Reviewed-on: http://git-master/r/123466
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agomfd: Fix tps65090 ifdefs for suspend mode
Mark Brown [Mon, 7 May 2012 09:03:17 +0000]
mfd: Fix tps65090 ifdefs for suspend mode

CONFIG_PM also covers runtime only PM.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
(Cherry-picked from mainline
1ca5513af77307eccea7efd4d12ef5c14f1b12ab)

Change-Id: I5d8d35f72f46dec28d62e6b01fbc915049185ec3
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/120368
Reviewed-by: Automatic_Commit_Validation_User
(cherry picked from commit 4cf205f2c1ed24511e672bb8ffb8720516216dc8)

Signed-off-by: Peter Zu <pzu@nvidia.com>
Change-Id: I754e9e8b94e87455d64303014eaae72115a58d68
Reviewed-on: http://git-master/r/123465
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: usb_phy: Hard code HSIC phy params
Venu Byravarasu [Mon, 30 Jul 2012 12:47:34 +0000]
arm: tegra: usb_phy: Hard code HSIC phy params

As HSIC does not have any customizable phy params,
hard coding them in the phy driver.

bug 1024260

Change-Id: I64d5c7f91b077134b54b0aadaf44f129ceaa99e5
Signed-off-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Reviewed-on: http://git-master/r/119299
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit ae0fe0f2527af92bc0ba9213ea0668ec6c7b19e8)
Reviewed-on: http://git-master/r/123464
Reviewed-by: Automatic_Commit_Validation_User

6 years agoarm: tegra: remove hsic phy params from boards
Venu Byravarasu [Mon, 30 Jul 2012 11:04:24 +0000]
arm: tegra: remove hsic phy params from boards

As HSIC phy params are not customizable, removing
them from board files.

bug 1024260

Change-Id: I6b7702c95810c683ab3d9f79e975657f3f601cd0
Signed-off-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Reviewed-on: http://git-master/r/119300
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
(cherry picked from commit f34ad144dd221836787fd9bc6871274174364a66)
Reviewed-on: http://git-master/r/123462
Reviewed-by: Automatic_Commit_Validation_User

6 years agoarm: tegra: usb: Remove HSIC phy params
Venu Byravarasu [Mon, 30 Jul 2012 10:57:32 +0000]
arm: tegra: usb: Remove HSIC phy params

As HSIC phy parameters are not customizable, removing them
from platform_data structure.

bug 1024260

Change-Id: I00fcc0559be43ad336b5b03a7a47443dfaa80d06
Signed-off-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Reviewed-on: http://git-master/r/119298
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>
(cherry picked from commit 8fa2ae311f67f90a85a746a659a75bb431314df3)
Reviewed-on: http://git-master/r/123461
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoarm: tegra: fuse: check SENSE_DONE after fuse programming
Roger Hsieh [Mon, 30 Jul 2012 08:20:38 +0000]
arm: tegra: fuse: check SENSE_DONE after fuse programming

Make fuse burning take effect by checking SENSE_DONE. Without this
chip options will not be available on fuse registers until
power on reset or LP0 resume.

Bug 1020726

Change-Id: Id547d1ea51b023ba904f5751c2ad65667375777d
Signed-off-by: Roger Hsieh <rhsieh@nvidia.com>
Reviewed-on: http://git-master/r/119271
Reviewed-by: Varun Wadekar <vwadekar@nvidia.com>
(cherry picked from commit 940211c305fe0bed54b19847633800b77c369a46)
Reviewed-on: http://git-master/r/123460
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agoARM: tegra: lp0 WAKE2 status clear
Bitan Biswas [Mon, 6 Aug 2012 05:47:25 +0000]
ARM: tegra: lp0 WAKE2 status clear

Tegra pmc WAKE2 status registers also need to be cleared
before re-entering lp0 mode.

Change-Id: I1bd5c48baf86ba23d0352594e97c360d363ce991
Signed-off-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-on: http://git-master/r/121185
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
(cherry picked from commit 7f9749a0050aa4bbe770f1a061f5ae8c8545dfa8)
Reviewed-on: http://git-master/r/123459
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>

6 years agomfd: tps65090: align driver with mainline
Venu Byravarasu [Fri, 16 Mar 2012 05:40:19 +0000]
mfd: tps65090: align driver with mainline

Align the driver with mainline.

This is vbased on commit
3c33be06f9aa0949ad24e67dfcae1f2a3006f4e1
---------------
mfd: Add support for TPS65090

TPS65090 is a Texas Instrument PMIC. It contains 3 Step-Down converters, 2
always on LDO's and  7 current limited load switches.

Signed-off-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
--------------

Change-Id: I26545520f2cc72100a927cb60b38693153a4afce
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: http://git-master/r/119320
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Venu Byravarasu <vbyravarasu@nvidia.com>
(cherry picked from commit a108454c2b8e037a82e49e14ceb3d9c0228af963)

Signed-off-by: Peter Zu <pzu@nvidia.com>
Change-Id: I1f7d303ae8a306aa61cf627f40474b1e098cef23
Reviewed-on: http://git-master/r/123458
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>