Greg Meiste [Fri, 27 May 2011 16:17:28 +0000 (11:17 -0500)]
[ARM] tegra: sdhci: Add new flag for runtime clock disable
The rt_disable flag can be used to disable the sdhci clock when
not needed.
Change-Id: I5b3d593f046627ce17405133c744e409dba7e241
Signed-off-by: Greg Meiste <w30289@motorola.com>
Michael I. Gold [Thu, 31 Mar 2011 02:07:07 +0000 (19:07 -0700)]
video: tegra: add support for tiled surfaces
Change-Id: I82497fc756552740836eaa2f608fecaea409cfeb
Signed-off-by: Michael I. Gold <gold@nvidia.com>
Ari Hirvonen [Wed, 2 Mar 2011 00:06:27 +0000 (02:06 +0200)]
video: tegra: add display inversion support
Change-Id: Ied3851e0cb801f607499493f1e552f42daa97e6b
Signed-off-by: Ari Hirvonen <ahirvonen@nvidia.com>
Nathan Connell [Mon, 2 May 2011 19:32:36 +0000 (14:32 -0500)]
usb: ehci: tegra: Correctly handle GetPortStatus during Resume
Multiple GetPortStatus requests can be made while the
USB bus is resuming. All requests must be handled
properly to prevent incorrect disconnect detection
during Resume and improper indentification of
Resume signaling as a remote wakeup event.
Change-Id: Ib07f83a2bab5699b2d95533d26d0a6bf541c697d
Signed-off-by: Nathan Connell <w14185@motorola.com>
James Wylder [Fri, 11 Mar 2011 22:39:43 +0000 (16:39 -0600)]
usb: host: tegra: update memory frequency requests to 150 MHz
With the previous change in memory frequency (200 MHz
to 150 MHz) requests of 200 MHz will round up to full
speed. This negatively impacts current drain.
Change-Id: Ib67d8eaff57836a2f1756d84cce6533539911178
Signed-off-by: James Wylder <james.wylder@motorola.com>
James Wylder [Fri, 11 Mar 2011 22:39:43 +0000 (16:39 -0600)]
usb: gadget: tegra: update memory frequency requests to 150 MHz
With the previous change in memory frequency (200 MHz
to 150 MHz) requests of 200 MHz will round up to full
speed. This negatively impacts current drain.
Change-Id: Iefdb3a50aff338b44daa8311218400e4b4586152
Signed-off-by: James Wylder <james.wylder@motorola.com>
Andrei Warkentin [Tue, 3 May 2011 21:41:08 +0000 (16:41 -0500)]
video: tegra: dc: Fix introduced regression.
Removes changes to DC reset flow.
Change-Id: I491b6771c205bec7e19d4c661bb6d376ea8e25e4
Signed-off-by: Andrei Warkentin <andreiw@motorola.com>
Nathan Connell [Mon, 25 Apr 2011 19:17:13 +0000 (14:17 -0500)]
ARM: tegra: Verify PHY clock valid before clearing USB_SUSP_CLR bit
When enabling the external ULPI PHY, the clock from the PHY must be
valid before the USB_SUSP_CLR bit is cleared in the USB2 controller
interface register. If the clock from the PHY is not valid when
this bit is cleared, the AHB clock to the host controller may be
stopped, preventing any access to the host controller.
Replace hard-coded delay with poll for USB_PHY_CLK_VALID bit.
Signed-off-by: Nathan Connell <w14185@motorola.com>
Change-Id: I24fa7575641f20ffdba7737776a81ba453f54395
Signed-off-by: Nathan Connell <w14185@motorola.com>
James Wylder [Thu, 7 Apr 2011 21:02:19 +0000 (16:02 -0500)]
ARM: tegra: usb_phy: Resolve ulpi disconnect issue
Correct phy start-up sequence.
Put the phy in low power mode.
Tristate ulpi interface when USB controller is resuming
Change-Id: I1b326c16b56b9fd2d424afb8cf0888da6c9e245e
Signed-off-by: James Wylder <james.wylder@motorola.com>
Andrei Warkentin [Thu, 21 Apr 2011 16:57:57 +0000 (11:57 -0500)]
video: tegra: dc: Fix several problems
Resolve potential race between resume and reset
Fix wmb after return
Change-Id: I98ad1e713b9781d780bf93561496011bf62b86d1
Signed-off-by: Andrei Warkentin <andreiw@motorola.com>
Andrei Warkentin [Tue, 19 Apr 2011 19:20:48 +0000 (14:20 -0500)]
video: tegra: prevent double disable in suspend
Prevents HDMI detect worker from re-disabling DC during
suspend (after tegra_dc_suspend has disabled DC itself)/
Change-Id: I90016fb709934ab8fb5135443980898069f8071f
Signed-off-by: Andrei Warkentin <andreiw@motorola.com>
Signed-off-by: Erik Gilling <konkers@android.com>
Peter Zu [Thu, 7 Apr 2011 04:42:33 +0000 (21:42 -0700)]
video: tegra: dc: hdcp: handle the case of DEVICE_COUNT = 0 properly
When HDCP repeater has no device attached, DEVICE_COUNT reports back as 0.
HDCP driver should handle this case as a good case and continue downstream
authentication, other than fail it.
Change-Id: Ied2e46428c0247f14fbd96016cd4fdbf358f6587
Erik Gilling [Fri, 15 Apr 2011 21:49:53 +0000 (14:49 -0700)]
video: tegra: fix more unplug/suspend timeout in nvhdcp
Change-Id: I30dfa03324eb5c4c344c62578eb808a150c80deb
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Wed, 13 Apr 2011 15:03:41 +0000 (08:03 -0700)]
video: tegra: fix unplug/suspend timeout in nvhdcp
If HDCP was turned off (either by unplug or suspend) the work funciton
would wait the full timeout 5 * l.75s before exiting. This
causes suspend to timeout and crash.
Change-Id: I8eb185452ad09e34f4573874e9766c0e1cec15de
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Wed, 13 Apr 2011 00:36:04 +0000 (17:36 -0700)]
video: tegra: zero out var before calling fb_videomode_to_var
Change-Id: I23f01da0a7dcd62594faa828676ffb7a4bc72d9f
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Mon, 11 Apr 2011 22:15:15 +0000 (15:15 -0700)]
video: tegra: add debouncing to hdmi hotplug
Change-Id: Ic998e183e79faabc36d96720dcbae2640e8cf419
Signed-off-by: Erik Gilling <konkers@android.com>
Jon Mayo [Wed, 6 Apr 2011 20:20:15 +0000 (13:20 -0700)]
video: tegra: reset hdcp failure count on hotplug
use tegra_nvhdcp_on/tegra_nvhdcp_off in hotplug handler to clean up
state machine.
Change-Id: I62fe503f0628ad4b49d5d7d66fe1702122179877
Signed-off-by: Erik Gilling <konkers@android.com>
Jon Mayo [Wed, 6 Apr 2011 20:15:20 +0000 (13:15 -0700)]
video: tegra: use longer retries for hdcp
use 3 seconds for i2c/ddc failures on hdcp (15 attempts at 250mS each)
Change-Id: Ia755c9b42d5a0d8467b68c9d334638bcb015eabd
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Thu, 7 Apr 2011 17:33:55 +0000 (10:33 -0700)]
video: tegra: attempt HDCP on DVI
Change-Id: If9efc63de3427f263b121e102cd0168883a236a3
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Thu, 31 Mar 2011 23:26:59 +0000 (16:26 -0700)]
video: tegra: reset hdcp failure count on hotplug
Change-Id: Iba5041f8428b13791004c96e6e8c2ed4dbcc37b8
Signed-off-by: Erik Gilling <konkers@android.com>
Venkata (Muni) Anda [Tue, 29 Mar 2011 06:15:40 +0000 (23:15 -0700)]
usb: host: ehci-tegra: Wait for SOF before resume
Wait for Start Of Frame interrupt, then wait 20 us, before starting
port resume. Workaround for hardware issue that can cause the SOF to
be sent out at the same time as the phy speed change.
Change-Id: I91ccbd2902448e87aa3cdf1970305de22efa1c10
Signed-off-by: Colin Cross <ccross@android.com>
Andrei Warkentin [Tue, 22 Mar 2011 18:37:47 +0000 (11:37 -0700)]
serial: tegra_hsuart: Make sure current byte rx complete in suspend
Make sure that the last byte has been received by the uart during
suspend after RTS is deasserted.
Change-Id: I3517ec058fdca912ff5ad8770d2b1c5015385385
Signed-off-by: Andrei Warkentin <andreiw@motorola.com>
Signed-off-by: Colin Cross <ccross@android.com>
Chris Johnson [Tue, 22 Mar 2011 01:20:51 +0000 (18:20 -0700)]
video: tegra: add HOST1_SYNC regs to nvhost_debug_show dump
Change-Id: I48cccf5b0df768b9cfc774803f3945f4806a62ac
Colin Cross [Wed, 16 Mar 2011 23:56:23 +0000 (16:56 -0700)]
serial: tegra_hsuart: Call complete callbacks when cancelling reqs
Updates the tegra_hsuart driver to match the changes in the Tegra
dma engine.
Change-Id: Iaaf8770166156c1a6d889a6a11bae517626781ee
Signed-off-by: Colin Cross <ccross@android.com>
Colin Cross [Wed, 16 Mar 2011 23:53:24 +0000 (16:53 -0700)]
ARM: tegra: dma: Do not call complete callback on canceled requests
Calling the complete callback when a request is cancelled leads to
locking problems in the callback, which could be called from an IRQ
with no locks held, or from whatever context called
tegra_dma_dequeue_req. Instead, expect the caller to handle the
now-cancelled request as needed.
Also removes tegra_dma_dequeue, since all users can be trivially
converted to tegra_dma_dequeue_req.
Change-Id: If699239c09c78d1cd3afa0eaad46535b1d401a24
Signed-off-by: Colin Cross <ccross@android.com>
Rebecca Schultz Zavin [Mon, 21 Mar 2011 21:09:44 +0000 (14:09 -0700)]
Revert "[ARM] tegra: Enable pl310 data prefetching and prefetch offset"
This reverts commit
6c77fdda35688ae3c9d9029a9824f7cf941f348d.
Conflicts:
arch/arm/mach-tegra/common.c
Change-Id: I35858f63da5cfd00885dd765da45db39be16b8b7
Chris Johnson [Wed, 16 Mar 2011 21:25:22 +0000 (14:25 -0700)]
video: tegra: cleanup debug syncpt output
In debug prints for stuck WAITs differentiate WAIT_SYNCPT
vs. WAIT_SYNCPT_BASE and fix some build warnings.
Change-Id: Ia47375614c676a9f93216fbfaaf6856c3df42e2e
Signed-off-by: Chris Johnson <cwj@nvidia.com>
Rebecca Schultz Zavin [Tue, 8 Mar 2011 20:15:30 +0000 (12:15 -0800)]
Revert "Revert "tegra: host: move stale wait checking into the kernel""
This reverts commit
b3cc1d84d0b962fe80fc297d2e2417c3157508b6.
James Wylder [Tue, 1 Mar 2011 15:25:06 +0000 (09:25 -0600)]
ARM: tegra: add generic memory vendor matching
Update tegra_init_emc to provide generic memory
vendor matching. Read values from EMC_MRR_0, to
uniquely identify memory types and compare them
to table of memory passed in.
Change-Id: Ie116fa6f497076149c87ff6c0ae0621309bac65f
Signed-off-by: James Wylder <james.wylder@motorola.com>
Colin Cross [Wed, 2 Mar 2011 20:34:38 +0000 (12:34 -0800)]
ARM: tegra: Use readl/writel_relaxed for reset
tegra_assert_system_reset is called after the cache is disabled.
Calling writel will cause the PL310 store buffers to be drained,
which requires taking a spinlock. Taking a spinlock is not safe
after the caches are disabled. Convert to readl_relaxed and
writel_relaxed.
Change-Id: I6850179b931ca865580c0fd3fe003b46bdfa43ae
Signed-off-by: Colin Cross <ccross@android.com>
Rebecca Schultz Zavin [Thu, 3 Mar 2011 22:28:07 +0000 (14:28 -0800)]
Revert "tegra: host: move stale wait checking into the kernel"
This reverts commit
2d49bf33f3885aab293f12d54447f66e911e3226.
Prajakta Gudadhe [Sat, 5 Feb 2011 09:37:38 +0000 (01:37 -0800)]
tegra: host: move stale wait checking into the kernel
The kernel now receives wait tracking data (similar to gathers and
relocs) and compares the current syncpt with the threshold value.
If it's old, it gets a kernel mapping and rewrites the method data
to use a kernel reserved syncpt that is always 0 (so trivially pops
when seen by the HW).
Patch has dependency to the user-space patches
Submitted on behalf of: Chris Johnson <cjohnson@nvidia.com>
original work by: Chris Johnson <cjohnson@nvidia.com>
Change-Id: I4d4e5d3b49cab860485c4172f87247f5b4f5ea6e
Benoit Goby [Tue, 1 Mar 2011 01:45:34 +0000 (17:45 -0800)]
usb: host: Renamed USB_TEGRA_HCD -> USB_EHCI_TEGRA
Change-Id: I2eec79186d6dc258caa2f3c8f3cd071222d1c5c7
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Fri, 11 Feb 2011 02:47:46 +0000 (18:47 -0800)]
ARM: tegra: select USB_ARCH_HAS_EHCI
usb_phy now depends on USB_ULPI_VIEWPORT
Change-Id: I5f3c996b41b50e74aa2b53eb246e100926108bff
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Fri, 11 Feb 2011 02:47:20 +0000 (18:47 -0800)]
usb: do not force select has_ehci for tegra
Change-Id: If6219a3ba9671a2c4c10b35461e1cc2ffe50ab0a
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Fri, 11 Feb 2011 23:55:38 +0000 (15:55 -0800)]
ARM: tegra: use generic ulpi operations
Change-Id: I5b56a8a1b10532683accfe885387afb309b26b19
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Fri, 11 Feb 2011 23:20:43 +0000 (15:20 -0800)]
usb: otg: Add ulpi viewport access ops
Add generic access ops for controllers with a ulpi viewport register
(e.g. Chipidea based controller).
Change-Id: I53d50857d4716f8df708af199ad1def1ff9d4beb
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Tue, 8 Feb 2011 02:40:47 +0000 (18:40 -0800)]
usb: host: tegra: Cleanup before sending upstream
Change-Id: I846d43b1ecbe6c726f024b6a0fb318d6300a3746
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Fri, 11 Feb 2011 01:41:00 +0000 (17:41 -0800)]
ARM: tegra: usb_phy: Fix return values
Changed frequency table into a struct
Change-Id: I202f808b912ce61e1f804103ea6d1197a57c1e62
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Tue, 8 Feb 2011 03:23:25 +0000 (19:23 -0800)]
ARM: tegra: usb_phy: Cleanup before sending upstream
Change-Id: I2548ca931f8ae37757115b7753d520d576bb173d
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Wed, 2 Mar 2011 01:03:51 +0000 (17:03 -0800)]
usb: otg: tegra: Moved tegra_usb.h to include/linux/platform_data
Change-Id: I201b6476979f6e1ef8ffadb4398b99a1728f3083
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Wed, 2 Mar 2011 00:58:44 +0000 (16:58 -0800)]
usb: host: Moved tegra_usb.h to include/linux/platform_data
Change-Id: Ic093d07858eb6e27aae9cd04d4c59407b5b1d76d
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Tue, 1 Mar 2011 01:40:54 +0000 (17:40 -0800)]
Revert "usb: host: ehci-hcd: add controller_resets_phy quirk"
This reverts commit
2c7d591aa11086ba841f8712b7cee33e245b62f6.
Change-Id: Ic9994dafc424e16d5d8251c287f8be65832b611b
Andrei Warkentin [Tue, 15 Feb 2011 22:18:59 +0000 (16:18 -0600)]
serial: tegra_hsuart: Clean-up FIFO flush and set baudrate operations.
Do necessary waits and fifo clear according to NV. Also use 115200
as the rate set while bringing-up rx dma during init, to decrease
start-up time.
Change-Id: I5211c75607cf2880ab2b1c22ab30f2c265534a1c
Signed-off-by: Andrei Warkentin <andreiw@motorola.com>
Erik Gilling [Mon, 28 Feb 2011 21:25:44 +0000 (13:25 -0800)]
video: tegra: hdmi: enable wakeup on hotplug
Change-Id: Idbb3f81c3c2d8a4f7f6b76736e11dd07cdd3a413
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Mon, 28 Feb 2011 21:24:30 +0000 (13:24 -0800)]
video: tegra: hdcp: move call to hdcp suspend out of atomic context
Change-Id: I62a9d810637df221862898536f990eda77e50644
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Mon, 28 Feb 2011 21:13:09 +0000 (13:13 -0800)]
video: tegra: hdmi: fix vic detection for avi infoframe
typeo was causing 1080p VICs to never be populated
Change-Id: Idde037cf0d4b71370cff7e65a2135b8c60a91fa0
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Sat, 19 Feb 2011 00:24:37 +0000 (16:24 -0800)]
video: tegra: de-assert reset after clocks are turned on
In underflow recovery, if the clocks are not enabled when the dc is brought
out of reset writes to the DC will sometimes hang.
Change-Id: If37de79f755196550018f94080ab2beed84ca326
Signed-off-by: Erik Gilling <konkers@android.com>
Colin Cross [Sun, 27 Feb 2011 00:45:47 +0000 (16:45 -0800)]
ARM: tegra: fuse: Fix bug in get_spare_fuse
get_spare_fuse was calling tegra_apb_readl and passing an
offset, but tegra_apb_readl requires a physical address.
Fix it by calling tegra_fuse_readl instead, which takes
an offset.
Fixes a crash booting on A03 parts, where get_spare_fuse
is used to determine the difference between A03 and A03
prime.
Change-Id: Ie386dc099e1c14eeb36262bfcc882e29a40a8da6
Signed-off-by: Colin Cross <ccross@android.com>
Jon Mayo [Tue, 21 Dec 2010 23:09:33 +0000 (15:09 -0800)]
[ARM] tegra: use APB DMA for accessing APB devices
Change-Id: I165411a14342666cbac02fb8cb171580ab0826aa
Reviewed-on: http://git-master/r/14464
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Tested-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Jon Mayo [Wed, 5 Jan 2011 19:15:21 +0000 (11:15 -0800)]
[ARM] tegra: add kfuse peripherial clk entry
Change-Id: I89fc144428b140288126790065902ea9e49b41e4
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Tested-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Jon Mayo [Wed, 5 Jan 2011 19:17:30 +0000 (11:17 -0800)]
[ARM] tegra: enable kfuse clock on boot
Change-Id: I7e8d9b5fa275af738fe22be2082a709a3902bdee
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Tested-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Jon Mayo [Wed, 5 Jan 2011 19:18:46 +0000 (11:18 -0800)]
[ARM] tegra: kfuse driver
factory programmed encrypted key fuses held in kfuse module.
use APB DMA for accessing kfuse registers, reading directly can hang if any
other DMA is active.
Change-Id: I85e44cc169607bc22116075e28938014aa299d75
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Tested-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Jon Mayo [Fri, 7 Jan 2011 03:05:38 +0000 (19:05 -0800)]
[ARM] tegra: edid modes uninitialized on i2c fail
fix unhandled i2c errors in tegra_edid_get_monspecs() that resulted in
truncated mode lists(stale data).
Change-Id: Iec7878f2a3071c5297d0569d4f1cce1c9ed48979
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Tested-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Peter Zu <pzu@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Jon Mayo [Tue, 4 Jan 2011 01:26:25 +0000 (17:26 -0800)]
[ARM] tegra: hdmi nvhdcp driver
Device /dev/nvhdcpX is used to manage NVHDCP on framebuffer /dev/fbX.
These devices are created on hdmi driver initialition when it is
attached to dc. Currently only one nvhdcp device may be created. An ioctl
interface is in video/nvhdcp.h
Check for repeaters and store repeater info. userspace application
queries this status to authenticate the connection. When authentication
fails, auto-renegotiate every 1.75 seconds. Give up after 5 failed attempts,
reset after hotplug or policy change.
use TEGRA_DC_OUT_NVHDCP_POLICY_ON_DEMAND in tegra_dc_out.flags in board
panel configuration to select a different default policy at probe. Currently
only TEGRA_DC_OUT_NVHDCP_POLICY_ALWAYS_ON is supported.
Change-Id: I0db66fc86096b98d2604544061721d291523de75
Reviewed-by: Jon Mayo <jmayo@nvidia.com>
Tested-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-by: Phillip Smith <psmith@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>
Signed-off-by: Erik Gilling <konkers@android.com>
Todd Poynor [Fri, 25 Feb 2011 00:24:37 +0000 (16:24 -0800)]
ARM: tegra: PL310 restore dynamic clock gating on resume
Tegra 2.6.36 code needs to restore PL310 dynamic clock gating upon
resume from a power event.
As of 2.6.39 the PL310 is re-init'ed from scratch upon resume,
and this patch can be dropped.
Change-Id: I8c1fb1add3c3cfcffff58fab642b84d8d5a7a90a
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Todd Poynor [Wed, 16 Feb 2011 20:25:36 +0000 (12:25 -0800)]
ARM: tegra: Enable PL310 dynamic clock gating
The cache controller will stop its clock when idle after several
clock cycles.
Change-Id: Ifc9997d4e7fd4f1e3c6129bac2fd42f8995a069e
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Todd Poynor [Wed, 16 Feb 2011 04:41:45 +0000 (20:41 -0800)]
ARM: PL310: Add power control register definition
Change-Id: Ia1f759aab15a241e8e29447622cd1e2998fa745c
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Prajakta Gudadhe [Tue, 1 Feb 2011 22:56:00 +0000 (14:56 -0800)]
video: tegra: add some missing mutex locking to nvhost_cdma
Change-Id: Ie4606d9a5154090274168babc110ea2d79747c05
Signed-off-by: Erik Gilling <konkers@android.com>
kartamonov [Mon, 14 Feb 2011 12:22:46 +0000 (14:22 +0200)]
video: tegra: nvmap: Fix broken optimization
An attempt had been made to reduce the number of pte operations
while patching relocs. The optimization was incorrectly coded
and was not providing the expected speedup.
Credit for the find goes to Peter Pipkorn.
Change-Id: Ic83b20ee470e54d5053f747dbcbdf7b038b7c7c4
Signed-off-by: Rebecca Schultz Zavin <rebecca@android.com>
Chris Fries [Fri, 11 Feb 2011 20:26:20 +0000 (14:26 -0600)]
[ARM] tegra: Enable pl310 data prefetching and prefetch offset
Enable data prefetching in the L2 cache controller, and set
the prefetch offset to 7.
Memcpy performance measured copying 16 MB buffers 78 times:
Data prefetch disabled, prefetch offset 0: 440 MB/s
Enabling data prefetching, prefetch offset 0: 430 MB/s
Enabling data prefetching, prefetch offset 7: 502 MB/s
Overall, this patch gives a 14% improvement in memcpy performance.
Prefetch offset of 8 causes prefetches to cross 4k boundaries
and cannot be used.
Original-author: Gary King <gking@nvidia.com>
Signed-off-by: Chris Fries <C.Fries@motorola.com>
Signed-off-by: Colin Cross <ccross@android.com>
Change-Id: I7ce0810b3f94edc2640df3f643cf81357052f2f1
Colin Cross [Fri, 28 Jan 2011 00:12:58 +0000 (16:12 -0800)]
Revert "mmc: subtract boot sectors from disk size for eMMC 4.3+ devices"
This reverts commit
2cdc235bbeb09b2b78cd02a94ab79c265861aea9.
The reverted commit incorrectly calculates the size of eMMC
devices in some (all?) cases.
This revert may cause problems in cases where the bootloader was
bug-compatible and puts a GPT partition at the incorrect end of
the eMMC device.
Change-Id: Icc9ddb3d294aa2a1caeddfe8fedd2e12aa7691e1
Colin Cross [Fri, 28 Jan 2011 00:12:55 +0000 (16:12 -0800)]
Revert "mmc: fix non-arm build due to eMMC 4.3+ change"
This reverts commit
1c119f2c1667ea2747693f7fd2166205e1a10b09.
Todd Poynor [Mon, 7 Feb 2011 21:42:34 +0000 (13:42 -0800)]
ARM: tegra: Handle timers during LP2 idle ticks
Timer ticks aren't properly serviced while a CPU is in LP2 idle.
Although the Tegra LP2 idle code calls hrtimer_peek_ahead_timers,
because no IRQ regs have been saved, update_process_times is not
called, and thus the timer list is not serviced (and neither is
SMP rebalancing, etc.) This can cause significant delays
scheduling timer-based activity, especially on CPU 1 (which is
not servicing most other IRQs).
Colin Cross suggested a patch based on upstream review feedback
that uses clock notifiers to switch to the "broadcast" clock event
source ("timer0" Tegra timer 3) during LP2, which has a real
interrupt handler defined that calls the clock event handler in
IRQ context, allowing timers to be checked.
Change-Id: Ifa3f4ec662f07dc9636e433f278358f75b65d10c
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Robert Morell [Thu, 27 Jan 2011 03:06:49 +0000 (19:06 -0800)]
USB: ehci: tegra: Align DMA transfers to 32 bytes
The Tegra2 USB controller doesn't properly deal with misaligned DMA
buffers, causing corruption. This is especially prevalent with USB
network adapters, where skbuff alignment is often in the middle of a
4-byte dword.
To avoid this, allocate a temporary buffer for the DMA if the provided
buffer isn't sufficiently aligned.
Signed-off-by: Robert Morell <rmorell@nvidia.com>
Robert Morell [Thu, 27 Jan 2011 03:06:48 +0000 (19:06 -0800)]
USB: HCD: Add driver hooks for (un)?map_urb_for_dma
Provide optional hooks for the host controller driver to override the
default DMA mapping and unmapping routines. In general, these shouldn't
be necessary unless the host controller has special DMA requirements,
such as alignment contraints. If these are not specified, the
general usb_hcd_(un)?map_urb_for_dma functions will be used instead.
Also, pass the status to unmap_urb_for_dma so it can know whether the
DMA buffer has been overwritten.
Finally, add a flag to be used by these implementations if they
allocated a temporary buffer so it can be freed properly when unmapping.
Signed-off-by: Robert Morell <rmorell@nvidia.com>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Robert Morell [Thu, 27 Jan 2011 03:06:47 +0000 (19:06 -0800)]
USB: HCD: Add usb_hcd prefix to exported functions
The convention is to prefix symbols exported from the USB HCD core with
"usb_hcd". This change makes unmap_urb_setup_for_dma() and
unmap_urb_for_dma() consistent with that.
Signed-off-by: Robert Morell <rmorell@nvidia.com>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Erik Gilling [Mon, 7 Feb 2011 03:33:45 +0000 (19:33 -0800)]
video: tegra: only enable HDMI features if detected from edid
Change-Id: I94c5c83c25a8aa1de344339f5759953074488720
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Mon, 7 Feb 2011 03:32:17 +0000 (19:32 -0800)]
video: fbmon: add HDMI dectetion to fbmod edid parsing
Looks for ieee registration numver 0x000c03 as per HDMI spec.
Change-Id: I6875b24c66e8754510edabcb4f9ba682a50d6ac1
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Thu, 3 Feb 2011 21:15:50 +0000 (13:15 -0800)]
video: tegra: add height/width to dc and fb
Change-Id: I22c280928079af04263375fce63a87776588a457
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Wed, 2 Feb 2011 23:28:32 +0000 (15:28 -0800)]
video: tegra: set h/v sync polarity for HDMI
Change-Id: I4be0eb963c3779b9313ef94476b1589059d4aa3c
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Wed, 2 Feb 2011 20:12:31 +0000 (12:12 -0800)]
video: tegra: support v/h sync polarity
Change-Id: Ida82a70efaeadc9d5b11d8703e688063680b72a8
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Tue, 1 Feb 2011 21:01:55 +0000 (13:01 -0800)]
video: tegra: correct HDMI h/vsync polairty in some modes
Change-Id: I0e988d1724461ff2d5bd1009f2fdc379bd154703
Signed-off-by: Erik Gilling <konkers@android.com>
Eric Laurent [Fri, 28 Jan 2011 17:13:22 +0000 (09:13 -0800)]
[ARM] tegra_i2s_audio: separate TX/RX DMA setup
Fixed a problem preventing independent setup/teardown
of TX and RX DMAs when setting playback or capture buffer count.
Signed-off-by: Eric Laurent <elaurent@google.com>
Nathan Connell [Wed, 12 Jan 2011 20:32:24 +0000 (14:32 -0600)]
ARM: tegra: usb_phy: Configure USB1 PHY to use programmed value
instead of fused value. This is required
to meet High Speed USB signaling requirements.
Change-Id: I659b33faa950605ecf040598112e1972047ae7ad
Signed-off-by: Nathan Connell <w14185@motorola.com>
Dmitriy Gruzman [Tue, 25 Jan 2011 02:52:02 +0000 (20:52 -0600)]
watchdog: tegra_wdt: Several changes to watchdog driver
Fix not re-enabling watchdog resume if it was enabled in probe
Add clearing watchdog interrupt in probe
Remove tegra_wdt_set_timeout
Change-Id: I8fdbb6da3eda64a85a73ed85ab979a5ee0261c37
Signed-off-by: Dmitriy Gruzman <dmitriy.gruzman@motorola.com>
Benoit Goby [Tue, 25 Jan 2011 20:14:52 +0000 (12:14 -0800)]
usb: host: tegra: Request 400MHz emc clock
while USB is active to eliminate all USB buffer underruns.
Change-Id: I9977224601e715e950284708958be98d37b3e6b1
Signed-off-by: Nathan Connell <w14185@motorola.com>
Benoit Goby [Tue, 25 Jan 2011 20:13:52 +0000 (12:13 -0800)]
usb: gadget: tegra_udc: Request 400MHz emc clock
while USB is active to eliminate all USB buffer underruns.
Change-Id: I7ad8ebfa2d802f91b81839e14fde906da1a0569e
Signed-off-by: Nathan Connell <w14185@motorola.com>
Rebecca Schultz Zavin [Mon, 24 Jan 2011 22:16:47 +0000 (14:16 -0800)]
video: tegra: nvmap: Several changes to carveout killer
-Add a module param to enable/disable carveout killer
-Fix race condition in code to wait for something to free memory
after firing carveout killer
-Fix the check for current so we always compare task->group_leaders
Change-Id: Ie030978827dce6b0fbbfa1db0d80e4abe59eaa51
Signed-off-by: Rebecca Schultz Zavin <rebecca@android.com>
Erik Gilling [Mon, 24 Jan 2011 23:28:31 +0000 (15:28 -0800)]
video: tegra: incresase delay in underflow recovery
Change-Id: I8093c83a2749c63b6ece051cc9b892d87e55fe04
Signed-off-by: Erik Gilling <konkers@android.com>
Erik Gilling [Mon, 24 Jan 2011 20:35:11 +0000 (12:35 -0800)]
video: tegra: dump host state when timing out on suspend
Change-Id: I718fb071ac74f5a051a7d5b9fcdd782163ed48b6
Signed-off-by: Erik Gilling <konkers@android.com>
Colin Cross [Sat, 22 Jan 2011 01:04:36 +0000 (17:04 -0800)]
ARM: tegra: Prevent dynamically ioremapping device io memory
Change-Id: I893a42bd773b1acdf2b83f8602fe1aa6a8ea6741
Signed-off-by: Colin Cross <ccross@android.com>
Colin Cross [Sat, 22 Jan 2011 01:04:07 +0000 (17:04 -0800)]
ARM: tegra: Statically map all device io memory
Change-Id: I0c750b766dcdd166ddff6317b93556f9f5cce899
Signed-off-by: Colin Cross <ccross@android.com>
Benoit Goby [Thu, 20 Jan 2011 23:42:52 +0000 (15:42 -0800)]
usb: gadget: tegra: Enable emc clock while usb is connected
Change-Id: Icb94c516a580e29b42b1899e622c9b91f8701dd2
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Thu, 20 Jan 2011 23:41:58 +0000 (15:41 -0800)]
ARM: tegra: clocks: Add shared emc clocks for usb gadget
Change-Id: Idf1982fac02b987cb16ef89509cfe4d72953d1e5
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Thu, 20 Jan 2011 22:19:04 +0000 (14:19 -0800)]
usb: host: tegra: Enable emc clock while usb is resumed
Change-Id: I03a102f40134686fabbd5cfa1830816a691cf876
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Thu, 20 Jan 2011 23:18:18 +0000 (15:18 -0800)]
ARM: tegra: clocks: Add shared emc clocks for ehci driver
Change-Id: I02f9d798159e14007fa2e5abfc3493a2d779d515
Signed-off-by: Benoit Goby <benoit@android.com>
Jay Cheng [Thu, 20 Jan 2011 21:09:32 +0000 (16:09 -0500)]
ARM: tegra: DVFS: set 1.2V core voltage for USB to work
Change-Id: Idb7822329f1975307748a72d1786da68c0635738
Signed-off-by: Jay Cheng <jacheng@nvidia.com>
Benoit Goby [Wed, 19 Jan 2011 03:38:23 +0000 (19:38 -0800)]
usb: host: tegra: Fix SetPortFeature PORT_SUSPEND
This fixes a regression where hubs cannot detect new devices once they
have been auto-suspended.
Change-Id: I4b3efcaa9634b9a912060e438527000bbc83dc32
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Tue, 18 Jan 2011 20:56:16 +0000 (12:56 -0800)]
usb: host: tegra: Fix resuming low speed devices from lp0
Change-Id: I9576853bbe0fae52c5c2cfab26ce8f2017077d4e
Signed-off-by: Benoit Goby <benoit@android.com>
Benoit Goby [Wed, 19 Jan 2011 00:57:48 +0000 (16:57 -0800)]
ARM: tegra: usb_phy: Program DPDM_OBSERVE depending on the device speed
Low speed devices require a K-state resume signaling instead of J.
Change-Id: Ic06011f45c2b0f4cd969d018f2783acea57cb510
Signed-off-by: Benoit Goby <benoit@android.com>
Varun Wadekar [Fri, 14 Jan 2011 07:49:25 +0000 (13:19 +0530)]
crypto: tegra-aes: perf: remove unnecessary polling and memset
Change-Id: I69731fcd50933ccea73542d046c3c5d86d03fcd9
Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
Colin Cross [Fri, 14 Jan 2011 23:07:27 +0000 (15:07 -0800)]
video: tegra: host: Force memory bus to full when using 2d, 3d or mpe
Change-Id: I7138af5d26c3f406537bc4b2bc4bb052de37f7bf
Signed-off-by: Colin Cross <ccross@android.com>
Colin Cross [Fri, 14 Jan 2011 23:06:58 +0000 (15:06 -0800)]
ARM: tegra: clock: Add shared emc clock for tegra_grhost
Change-Id: Ie2814726d151777140c20d2bc0a3c1a3822043a8
Signed-off-by: Colin Cross <ccross@android.com>
Colin Cross [Fri, 14 Jan 2011 23:06:29 +0000 (15:06 -0800)]
ARM: tegra: clock: Add round_rate op for shared clocks
Change-Id: Ica3f9fd9db4fe38f2c9ca3fc248526211f59c622
Signed-off-by: Colin Cross <ccross@android.com>
Mayuresh Kulkarni [Fri, 14 Jan 2011 02:22:43 +0000 (18:22 -0800)]
video: tegra: host: disable MPE auto-power-gate
It is seen that auto-power-gate of MPE causes some issues when long run
camera stress test is run. The issue manifest itself in the form of
MPE sync-point not getting triggered from hardware and hence the caller
who is waiting on it hangs up the system.
Disabling auto-power-gate for MPE seems to resolve this issue.
Original work of Jay Cheng <jacheng@nvidia.com>
Signed-off-by: Mayuresh Kulkarni <mkulkarni@nvidia.com>
Change-Id: Iaef9f959cbc00dd715352ca637955cd2bea6f355
Rebecca Schultz Zavin [Thu, 13 Jan 2011 00:22:36 +0000 (16:22 -0800)]
video: tegra: nvmap: Several fixes to the carveout killer
-Modify the carveout killer to only kill tasks with lower priorities
than the one that's trying to allocate
-After delivering a sigkill to a task, wait for something to exit and
cleanup before retrying the allocation
Change-Id: If62b6ed008a73fc3c347ff26735a83eee284909e
Signed-off-by: Rebecca Schultz Zavin <rebecca@android.com>
Sergey Kudakov [Thu, 21 Oct 2010 22:55:50 +0000 (17:55 -0500)]
video: tegra: reset default window in release
Change-Id: I242e9fac525472c5c20f213a6de516f95b2f6a12
Cc: Sergey Kudakov <sergey.kudakov@motorola.com>
Signed-off-by: Erik Gilling <konkers@android.com>
Ken Sumrall [Wed, 12 Jan 2011 23:58:37 +0000 (15:58 -0800)]
crypto: tegra-aes: Hack to disable HW AES for dm-crypt
The hardware aes engine is required for key management for
HDCP, but since it's performance is bad, we don't want it
enabled for dm-crypt. This hack changes the cra_name field
so dm-crypt won't find a match, but leaves the cra_driver_name
field unchanged to the device file interface will still find it.
Signed-off-by: Ken Sumrall <ksumrall@android.com>
Varun Wadekar [Wed, 12 Jan 2011 20:59:14 +0000 (02:29 +0530)]
crypto: tegra-aes: improve encrypt/decrypt performance
- enable/disable clocks only once per request
- create a thread for handling the driver's work queue
- always set vde clocks to the max before processing a request
Change-Id: I935e5523e9e913c93705cc694f8a475d212c15ce
Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>