summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2014-06-15pwr: expose ppwr's performance counters to the userspaceppwr_reworkMartin Peres5-0/+105
2014-06-15pwr: add performance monitoring supportMartin Peres7-1347/+2148
Signed-off-by: Martin Peres <martin.peres@free.fr>
2014-06-15pwr/fuc: make $r1-$r10 registers callee-saved in kernel.fucMartin Peres5-53/+54
2014-06-15pwr/fuc: add ld/st macrosMartin Peres1-0/+10
Signed-off-by: Martin Peres <martin.peres@free.fr>
2014-06-15pwr: add helpers for delay-to-ticks and ticks-to-delayMartin Peres9-2299/+2461
Signed-off-by: Martin Peres <martin.peres@free.fr>
2014-06-15pwr: add some arith functions (mul32_32_64, subu64 and addu64)Martin Peres12-1749/+1935
Signed-off-by: Martin Peres <martin.peres@free.fr>
2014-06-15pwr: fix the timers implementation with concurent processesMartin Peres5-994/+1137
The problem with the current implementation is that adding a timer improperly checked which process would time up first by not taking into account how much time elapsed since their timer got scheduled. Rework the re-scheduling decision t fix this. The catch with this fix is that we are limited to scheduling timers of up to 2^31 ticks to avoid any potential overflow. Since we are unlikely to need to wait for more than a second, this won't be a problem :) Another possible fix would be to decrement the timeouts of all processes but it would duplicate a lot of code and dealing with edge cases wasn't pretty last time I checked. Signed-off-by: Martin Peres <martin.peres@free.fr>
2014-06-13fb/ram/gk104: fixups from an earlier search+replaceBen Skeggs1-38/+38
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-13drm: expose pstate selection per-power source in sysfsBen Skeggs3-18/+52
echo ac:id >> pstate # select mode when on mains power echo dc:id >> pstate # select mode when on battery echo id >> pstate # select mode for both Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-13clk: allow selection of different power state for ac vs batteryBen Skeggs5-30/+105
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-13clk: schedule pstate changes through a workqueueBen Skeggs2-11/+39
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-13device: register for acpi eventsBen Skeggs9-3/+104
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-13gr/nv50: remove an unneeded write while initialising PGRAPHPierre Moreau1-1/+0
The blob does not seem to write at that place for my NVAC, though it does for my NV96, agreeing with what is done in the if/else structure below. I guess someone forgot to remove the line when the if/else was put in place. Signed-off-by: Pierre Moreau <pierre.morrow@free.fr> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-13gr/nv50: fix overlap while zeroing zcull regionsPierre Moreau1-4/+4
The specified stride was not correct, resulting in erases overlapping and part of the zcull regions being not erased at all. Signed-off-by: Pierre Moreau <pierre.morrow@free.fr> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-13gr/gf100-: report class data to host on fwmthd failureBen Skeggs13-703/+1004
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-12gr/gk208-: stop touching 0x260 inappropriatelyBen Skeggs18-46/+117
As a side note.. It's a bit hard to figure out how to name this commit.. GK20A is NVEA, which is before NV108 (GK208).. Confusing. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-12gr/gk110b: initvals differ from gk110Ben Skeggs12-14/+248
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-12gr/gk104: disable PGOB at init timeBen Skeggs2-25/+7
This removes the previous hack that worked on some boards. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-12pwr/gk104: implement PGOB disable methodBen Skeggs8-3/+88
As documented at: ftp://download.nvidia.com/open-gpu-doc/gk104-disable-graphics-power-gating/1/gk104-disable-graphics-power-gating.txt NVIDIA were not able document the steps necessary to detect whether this is required or not at this time. However, they did confirm that this procedure is safe to perform unconditionally on GK104/6. GK107 does not have the power gating feature, and it was recommended that we do not perform these steps there as the effects were not verified. The disable path is from observing the binary driver, and not documented in the link above. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-12pwr: tidyBen Skeggs13-193/+134
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-12fb/ram/gk104: bash mpll bit 31 onBen Skeggs1-0/+1
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-12ibus/gk104: increase various random timeoutsBen Skeggs1-1/+18
Fixes (at least) PTHERM accesses timing out at higher clock speeds. Values and registers taken from what the binary driver does. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-12clk/gk104: only touch divider for mode we'll be usingBen Skeggs1-3/+5
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/dp: fix tmds passthrough on dp connectorBen Skeggs2-10/+54
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11kms/dp: probe dpcd to determine connectednessBen Skeggs3-40/+26
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11kms/nv50-: trigger update after all connectors disabledBen Skeggs1-0/+1
We were sending the necessary state changes to unset the mode, but never actually hit the big GO button unless another modeset happens afterwards. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11kms/nv50-: prepare for attaching a SOR to multiple headsBen Skeggs3-42/+46
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/gf119-: fix debug output on update failureBen Skeggs1-3/+3
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/dp: make use of postcursor when its availableBen Skeggs1-8/+18
And at the same time, obey the spec better wrt out-of-range requests. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/g94-/dp: take max pullup value across all lanesBen Skeggs2-2/+6
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11bios/dp: parse lane postcursor dataBen Skeggs4-24/+27
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11kms/dp: fix support for dpmsBen Skeggs2-4/+50
SOR_PWR has no effect to power-off DP links, unlike other SOR protocols. Instead, on the source side, we cut power to the lanes after having put the sink into D3. Link training takes care of everything required to bring it back again. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11kms: register a drm_dp_aux channel for each dp connectorBen Skeggs2-3/+55
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/g94-: add method to power-off dp lanesBen Skeggs5-0/+35
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/dp: maintain link in response to hpd signalBen Skeggs6-12/+125
This previously worked for the most part due to userspace doing a modeset in response to HPD interrupts. This will allow us to properly handle cases where sync is lost for other reasons, or if userspace isn't caring. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/g94-: bash and wait for something after changing lane power regsBen Skeggs1-0/+3
Some kind of update? Needed to make the power-down take effect at least. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/dp: split link config/power into two stepsBen Skeggs6-12/+29
We want to be able to power down the lanes for DPMS off. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/nv50: train PIOR-attached DP from second supervisorBen Skeggs1-21/+11
Same place as for SOR, between detach and attach phases. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/dp: make use of existing output data for link trainingBen Skeggs16-248/+133
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/gf119: start removing direct vbios parsing from supervisorBen Skeggs1-75/+83
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/nv50: start removing direct vbios parsing from supervisorBen Skeggs1-107/+116
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/dp: maintain receiver caps in response to hpd signalBen Skeggs3-8/+70
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp/dp: create subclass for dp outputsBen Skeggs19-9/+268
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11kms: use connector events for HPD instead of GPIO watchingBen Skeggs3-44/+34
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp: add internal representaion of output paths and connectorsBen Skeggs15-2/+625
This will, at some point, be used to replace various bits and pieces of code doing direct bios parsing. For now, it'll just be used for some DP improvements. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11bios: extend connector table parsingBen Skeggs4-16/+79
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11disp: nothing to see hereBen Skeggs3-21/+42
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11i2c/anx9805: add debugging to aux transactionsBen Skeggs3-5/+35
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11i2c: introduce locking at a per-port levelBen Skeggs19-34/+387
There's also provisions to allow a pad to be locked with a specific routing, for an indefinite period of time. This will be used in future patches. The G94+ pad driver will now also power-down pads when not required. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2014-06-11i2c: balance port acquire/releaseBen Skeggs5-18/+63
This was a half-finished hack before, just enough to handle the shared aux/i2c pad thing on G94 and up. We got lucky with locking etc up until now, as this was (generally) all protected by the DRM mode_config lock. It's about to become a lot more likely to hit the races. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>