Commit Graph

668 Commits

Author SHA1 Message Date
Deepak Nibade
b268c91037 gpu: nvgpu: register to nvhost for debug dump
Register debug dump callback gk20a_debug_dump_device()
to nvhost using nvhost_register_dump_device()

Unregister the callback in gp10b_tegra_remove()

Bug 200188753

Change-Id: I9161cfdf969208bd8b6160742bf89e327aa2a6b4
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/1126792
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:12 +05:30
Deepak Nibade
545dd0e370 gpu: nvgpu: return from scale_init() if no profile
In gp10b_tegra_scale_init(), return immediately
if CONFIG_GK20A_DEVFREQ is disabled and
profile is NULL

Change-Id: I08e15afdc72bef62a4fb43f30b74cebf8a4b0d68
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/1125444
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2016-12-27 15:22:11 +05:30
Deepak Nibade
9acab4c975 gpu: nvgpu: pass bool pointer to debugfs_create_bool()
Port the change 621a5f7ad9cd1ce7933f1d302067cbd58354173c from
kernel.org to the nvgpu driver

Change-Id: I3a8aa873e1f0b601bfe89f836c400113e50b638e
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/1125443
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2016-12-27 15:22:11 +05:30
Terje Bergstrom
03614bff77 gpu: nvgpu: gp10b: Support GPUs with no physical mode
Support GPUs which cannot choose between SMMU and physical
addressing.

Change-Id: Ic097fccb313d98fcea918a705eefb5cd619138f1
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1122590
Reviewed-by: Konsta Holtta <kholtta@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Alex Waterman <alexw@nvidia.com>
2016-12-27 15:22:11 +05:30
Terje Bergstrom
fce01666d5 gpu: nvgpu: Use device instead of platform_device
Use struct device instead of struct platform_device wherever
possible. This allows adding other bus types later.

Change-Id: I90623c020919ca8e2e5b31d53914c324d2dc6af9
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1120464
2016-12-27 15:22:11 +05:30
Peter Daifuku
bd688d31ce gpu: nvgpu: Add fbpa number and stride
Add fbpa number and stride, used in hwpm context switch code

Bug 1648200

Change-Id: I44570c072b1266d7ec2fc5dfb7fa73000ac01831
Signed-off-by: Peter Daifuku <pdaifuku@nvidia.com>
Reviewed-on: http://git-master/r/1120451
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Seshendra Gadagottu
7ed45599dc gpu: nvgpu: gp10b: disable force_reset_in_do_idle
Since gpu rail gating is enabled, force_reset in
idle can be disabled.

Bug 200183798

Change-Id: I04ed04b66e3059459ec32cbffbfdb6756b009200
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/1120147
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Terje Bergstrom
be7ee41989 gpu: nvgpu: gp10b: Sync with register generator
Use re-generated register definitions. This synchronizes
kernel with the register generator.

Change-Id: I5ad34ad0b92327091758a2d10581a1b4170fa919
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1120811
2016-12-27 15:22:11 +05:30
Deepak Nibade
4dee2dd64c gpu: nvgpu: post CILP_PREEMPTION_STARTED/COMPLETE events
Remove posting of events using old channel event API i.e.
gk20a_channel_post_event()

Also, update gk20a_channel_semaphore_wakeup() to post
events when called from ce2_nonblockpipe_isr()

Bug 200089620

Change-Id: I677cdab11183a649663ff9272a527c63b9994430
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/1112275
(cherry picked from commit 4840efda393cd5928f1a8463db8b52cc586860bc)
Reviewed-on: http://git-master/r/1120289
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2016-12-27 15:22:11 +05:30
Sami Kiminki
58adb7385d gpu: nvgpu: Determine ECC-enabled units for GP10B
Determine ECC-enabled units for GP10B by reading fuses/registers.

Bug 1637486

Change-Id: I6431709e3c405d6156dd96438df14d4054b48644
Signed-off-by: Sami Kiminki <skiminki@nvidia.com>
Signed-off-by: Adeel Raza <araza@nvidia.com>
Reviewed-on: http://git-master/r/780992
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1120463
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Seshendra Gadagottu
0a98bb9fcf gpu: nvgpu: gp10b: add emc clock request
Use Bandwidth manager API to request required
emc clock.

Bug 1673672

Change-Id: I909213d2a69a45939247fd079b1c57ce93be6e0e
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/843777
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Thomas Fleury
f7872bec49 gpu: nvpgu: setup fecs_trace hal operations
bug 1648908

Change-Id: I630f74f09e0a4143f5028c88634b9793ec86b279
Signed-off-by: Thomas Fleury <tfleury@nvidia.com>
Reviewed-on: http://git-master/r/1022730
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Arul Sekar
9864f1b077 gpu: nvgpu: add function to access ptimer time
bug 1648908

Change-Id: I32211b13489b21eba25f7473a18b9d1a303d2642
Signed-off-by: Arul Sekar <aruls@nvidia.com>
Reviewed-on: http://git-master/r/1029733
Reviewed-by: Arun Gona <agona@nvidia.com>
Tested-by: Arun Gona <agona@nvidia.com>
Reviewed-on: http://git-master/r/1111716
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Thomas Fleury <tfleury@nvidia.com>
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Terje Bergstrom
f2bb4f10ce gpu: nvgpu: gp10b: Update regops whitelist
Update regops whitelist with two new registers.

Bug 1734151

Change-Id: Id09bdfb1733620bb75d4558299c5e9c7f66bb00b
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1029772
GVS: Gerrit_Virtual_Submit
Reviewed-by: Richard Zhao <rizhao@nvidia.com>
2016-12-27 15:22:11 +05:30
Seshendra Gadagottu
57a75c3ba6 gpu: nvgpu: gp10b: update prod setiings
Add/update following prod settings:
  blcg ce
  slcg ce2

Change-Id: I10a62d980479ad23efd7033d29e269c4aac08834
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/1030986
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Terje Bergstrom
eada66b2a9 gpu: nvgpu: gp10b: Allow importing makefile via include
Refactor makefiles so that there is one makefile, and that file
can be included in the main nvgpu build.

Bug 1476801

Change-Id: I23ac451d695fc64064de2300e83b9d9487c52743
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1028353
Reviewed-by: Konsta Holtta <kholtta@nvidia.com>
GVS: Gerrit_Virtual_Submit
2016-12-27 15:22:11 +05:30
Seshendra Gadagottu
5244299cdf gpu: nvgpu: t18x: update blcg prod settings
Update prod settings to disable stall blcg.

Bug 1729471

Change-Id: I1123bf47159fc9dbb1223aebcacf37361b90743f
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/1026611
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Mahantesh Kumbar <mkumbar@nvidia.com>
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Adeel Raza
f03ee50232 gpu: nvgpu: gp10b: only create ECC stats once
The ECC sysfs stat creation function is called on GR init. GR can get
initialized multiple times but we only need to create the ECC stats
once. Therefore, add a check to avoid creating duplicate stat sysfs
nodes.

Change-Id: Ifb338e57643f2f15492df137d2a7521e0c990cf2
Signed-off-by: Adeel Raza <araza@nvidia.com>
Reviewed-on: http://git-master/r/1021660
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:11 +05:30
Amit Sharma
63d463c1ac gpu: nvgpu: gp10b: make local symbol static
Fixed the following sparse warning by making local symbol static:
- platform_gp10b_tegra.c:365: warning: symbol 'ecc_hash_table' was not declared.
                                       Should it be static?

Bug 200088648

Change-Id: Iea1a682c3ee0609730366d44fab91849cd59c9ad
Signed-off-by: Amit Sharma <amisharma@nvidia.com>
Reviewed-on: http://git-master/r/1022410
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
Tested-by: Sachin Nikam <snikam@nvidia.com>
2016-12-27 15:22:11 +05:30
Seshendra Gadagottu
9a2ecd3efb gpu: nvgpu: t18x: update slcg prod settings
Update prod settings to disable slcg pbdma related
domains.

Bug 1703083

Change-Id: I9f9192da69d07c5cea5bc7d79a031e5d2428b685
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/1022219
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Seshendra Gadagottu
6ce874a30c Revert "Revert "gpu: nvgpu: gp10b: enable gpu rail gating""
This reverts commit 7c1f6f0b2998c354f315b431e00f3c8f861cb190.

Bug 200176691

Change-Id: Ia546513ec5c61999f6eb4d56ccd7e45ae072167c
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/1020813
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Supriya
640d0e2c3b gpu: nvgpu: ECC override
-sysfs functions to call into LS PMU and modify
 ECC overide register

Bug 1699676

Change-Id: Iaf6cc3a86160b806e52ab168577caad42b2c5d22
Signed-off-by: Supriya <ssharatkumar@nvidia.com>
Reviewed-on: http://git-master/r/921252
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Vijayakumar Subbu <vsubbu@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Prashant Gaikwad
02ee4d4188 Revert "gpu: nvgpu: gp10b: enable gpu rail gating"
This reverts commit 71b59d75fc49e2159830026bce387ef4d829faa8
since it causes suspend_sanity to fail on quill platform.

On system resume, we see the following error dump from GPU

gk20a 17000000.gp10b: gk20a_channel_timeout_handler: Job on channel 501 timed out

gk20a 17000000.gp10b: gk20a_fifo_set_ctx_mmu_error_ch: channel 501 generated a mmu fault
gk20a 17000000.gp10b: gk20a_set_error_notifier: error notifier set to 31 for ch 501
gk20a 17000000.gp10b: gk20a_channel_timeout_handler: Job on channel 509 timed out

Change-Id: I61bc3b0745fe136675ab79b13f54e9126602f51c
Signed-off-by: Prashant Gaikwad <pgaikwad@nvidia.com>
Reviewed-on: http://git-master/r/1017967
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2016-12-27 15:22:10 +05:30
Seshendra Gadagottu
cdf3fdd63b gpu: nvgpu: gp10b: enable gpu rail gating
Bug 1698618

Change-Id: Iabfd726891165d7879376ab96445b7b81b907153
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/841856
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Mahantesh Kumbar
6ad20e9004 gpu: nvgpu: gp10b: Enable adaptive ELPG
ELPG is enabled on TOT.

Bug 200144583

Change-Id: Icbdcb5f575a4ca37becf47b098fbd6a1f89feec7
Signed-off-by: Mahantesh Kumbar <mkumbar@nvidia.com>
Reviewed-on: http://git-master/r/1013845
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Adeel Raza
e9b03e903c gpu: nvgpu: gp10b: add ECC stats sysfs nodes
Add sysfs nodes for querying ECC single/double bit error counts.

Bug 1699676

Change-Id: I6d5219facadaa17207ac759b88fe19077207d8f1
Signed-off-by: Adeel Raza <araza@nvidia.com>
Reviewed-on: http://git-master/r/935363
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Deepak Nibade
f7d327985f gpu: nvgpu: pass channel pointer to handle sm exception
Pass faulting channel pointer to gr_gk20a_handle_sm_exception()
instead of NULL

Bug 200156699

Change-Id: I909327e2a000bea8bc91cfd0820a759960664b46
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/1011289
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2016-12-27 15:22:10 +05:30
Deepak Nibade
0c9ba5c067 gpu: nvgpu: fix sparse warning
fix below sparse warning :
drivers/gpu/nvgpu/gp10b/gr_gp10b.c:1364:5: warning: symbol
'gr_gp10b_pre_process_sm_exception' was not declared. Should it be
static?

Bug 200088648

Change-Id: Ie55ffc12eb653b10358001e2aef8766562fd0df9
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/1009938
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
2016-12-27 15:22:10 +05:30
Deepak Nibade
333b839b27 gpu: nvgpu: post events on all channels of TSG
While posting CILP preemption complete event to
user space, raise the event to all channels of TSG
(if channel is part of TSG)

This is a WAR until we have proper sync mechanism
with user space to raise CILP events

Bug 200156699

Change-Id: Ieedc866498a8c5464cf65962257a803b37da6826
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/1001696
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Deepak Nibade
de47308b2c gpu: nvgpu: add CILP support for gp10b
Add CILP support for gp10b by defining below function
pointers (with detailed explanation)

pre_process_sm_exception()
- for CILP enabled channels, get the mask of errors
- if we need to broadcast the stop_trigger, suspend all SMs
- otherwise suspend only current SM
- clear hww_global_esr values in h/w
- gr_gp10b_set_cilp_preempt_pending()
  - get ctx_id
  - using sideband method, program FECS to generate
    interrupt on next ctxsw
  - disable and preempt the channel/TSG
  - set cilp_preempt_pending = true
- clear single step mode
- resume current SM

handle_fecs_error()
- we get ctxsw_intr1 upon next ctxsw
- clear this interrupt
- get handle of channel on which we first
  triggered SM exception
- gr_gp10b_clear_cilp_preempt_pending()
  - set cilp_preempt_pending = false
- send events to channel and debug session fd

Bug 200156699

Change-Id: Ia765db47e68fb968fada6409609af505c079df53
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/925897
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Deepak Nibade
095bd5e59d gpu: nvgpu: mask hww_warp_esr for gp10b
Add API gp10b_mask_hww_warp_esr() to mask
hww_warp_esr appropriately on gp10b

Bug 200156699

Change-Id: I451b5e949bd4e6d286e5d0c7cd7616e6cfaf3ea9
Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
Reviewed-on: http://git-master/r/927129
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Adeel Raza
f17e0d822b gpu: nvgpu: gp10b: add ECC support
Add ECC exception handling support for SM, TEX, and LTC.

Bug 1635727
Bug 1637486

Change-Id: I8862ead5784f48742355432ec07c71a82b1b6735
Signed-off-by: Adeel Raza <araza@nvidia.com>
Reviewed-on: http://git-master/r/935362
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
GVS: Gerrit_Virtual_Submit
2016-12-27 15:22:10 +05:30
Seshendra Gadagottu
4c5bc9c93b gpu: nvgpu: gp10b: clean-up pmu init operations
Removed unwanted initlization of function pointer.

Bug 200157852

Change-Id: I3b44ccce366f1b72c3ff769a7b9ab350bb2c0066
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/843218
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Seshendra Gadagottu
acc62a236f gpu: nvgpu: gp10b: enable power gating
Enable engine level power gating(elpg)

Bug 200144583

Change-Id: I66f3be841625c2c9e07cafbf19af8f1dbdbfd390
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/818637
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Seshendra Gadagottu
d730381f93 gpu: nvgpu: gp10b: add delay cycles before engine gating
For copy engine, add 16 clock cycle delay
before engine clock gating.

Bug 1717152

Change-Id: Ife92299c052f44000bc0d900f0129a2eab13f3b5
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/998408
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Seshendra Gadagottu
b8db86a6b6 gpu: nvgpu: gp10b: enable gradual slowdown
Enable gradual slowdown for gp10b and also correct
thermal slowdown factors with extended mode.

Bug 1719974

Change-Id: I31a5d7df71c98135273a980c49b70bc76fac0b40
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/933279
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Konsta Holtta
1ec6d2b6d6 gpu: nvgpu: bitmap allocator for comptags
Restore comptags to be bitmap-allocated, like they were before we had
the buddy allocator.

Bug 200145635

Change-Id: I681493871096f437014b7eca1182fefbaf7f6a74
Signed-off-by: Konsta Holtta <kholtta@nvidia.com>
Reviewed-on: http://git-master/r/839240
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Richard Zhao
5dcbe39a71 gpu: nvgpu: enable semaphore acquire timeout for gp10b
It'll detect dead semaphore acquire. The worst case is when
ACQUIRE_SWITCH is disabled, semaphore acquire will poll and
consume full gpu timeslicees.

The timeout value is set to half of channel WDT.

Bug 1636800

Change-Id: Idbd4bfa52981e8a849b62a168e3a6828330112f5
Signed-off-by: Richard Zhao <rizhao@nvidia.com>
Reviewed-on: http://git-master/r/928830
Reviewed-by: Aingara Paramakuru <aparamakuru@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
Terje Bergstrom
03afa9b060 gpu: nvgpu: gp10b: Refresh regops whitelist
Context & global whitelists are same, so delete second copy. Update
the list.

Bug 200164983

Change-Id: I440ce04316120b8128baeabc002c55436cf41d5b
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/931178
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sandarbh Jain <sanjain@nvidia.com>
Tested-by: Sandarbh Jain <sanjain@nvidia.com>
2016-12-27 15:22:10 +05:30
David Li
97ba307f51 gpu: nvgpu: fix setting gr_pd_ab_dist_cfg1_r()
gr_*__set_alpha_circular_buffer_size() left max_batches field of
  gr_pd_ab_dist_cfg1_r as 0 which results in too many alpha beta
  transitions and poor performance when tessellation or geometry
  shaders are used

Change-Id: Ic3673f45b60674b3527641a6fdda0cedc6861db5
Signed-off-by: David Li <davli@nvidia.com>
Reviewed-on: http://git-master/r/840079
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:10 +05:30
David Li
6430abceef gpu: nvgpu: gp10b: fix set_circular_buffer_size
It didn't set gr_gpc0_ppc0_cbm_beta_steady_state_cb_size_r
  causing a GPU MMU fault when used.

Bug 200141640
Bug 200141981
Bug 200141640

Change-Id: I8b9f71e480553ead2827ff1f1dde2ba2e6efe697
Signed-off-by: David Li <davli@nvidia.com>
Reviewed-on: http://git-master/r/807694
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:09 +05:30
Terje Bergstrom
d44b5ecc30 gpu: nvgpu: Recreate HW headers
Add gradual slowdown registers, and fix names for L2 flush registers.

Change-Id: If085c4febef494ae299d2147ca5201cd373bee0b
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/839369
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
2016-12-27 15:22:09 +05:30
Terje Bergstrom
108c0ac8bd gpu: nvgpu: gp10b: Add tile caching registers
Add tile caching registers to access map.

Bug 1692373

Change-Id: Ic95fce02c564fa8d5556543a744c9828b542fb1f
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/812352
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
2016-12-27 15:22:09 +05:30
Terje Bergstrom
fd624a1f4e gpu: nvgpu: gp10b: Install gp10b access map
Bug 1692373

Change-Id: I63bb1f8a40fe5d2c7b61440c989b78e4cb3ece98
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/812351
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
2016-12-27 15:22:09 +05:30
Seshendra Gadagottu
1cde817120 gpu: nvgpu: t18x: make gp10b_freq_table static
Make gp10b_freq_table static to fix sparse warning

Bug 200088648

Change-Id: Ibaaabd145e37685e049ac3a49e2b276fb6545d0e
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/837421
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:09 +05:30
Mahantesh Kumbar
b76acb0ef6 gpu: nvgpu: ELPG prod values update
Bug 200151348

Change-Id: I44851b69adfe9c6bf5d4c897730d6da7df9bedd8
Signed-off-by: Mahantesh Kumbar <mkumbar@nvidia.com>
Reviewed-on: http://git-master/r/836877
(cherry picked from commit 69de3f3c439f544fd5f9223f5663010f5ec80193)
Reviewed-on: http://git-master/r/837228
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:09 +05:30
Seshendra Gadagottu
1146dbae18 gpu: nvgpu: gp10b: add support for freq scaling
Add support for gp10b freq scaling.

Bug 200147662

Reviewed-on: http://git-master/r/816962
(cherry picked from commit 62de7dba758e46ee80c896dcfcbccb0f8b979438)

Change-Id: I71ddfa394d490c002761d2a8bbb95090a4c0e799
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/834758
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:09 +05:30
Sami Kiminki
4181fa7185 gpu: nvgpu: User-space managed address space support (gp10b)
Tell gk20a_init_vm() that bar2 VM is kernel-managed.

Bug 200077571

Change-Id: I151c540a6dec76238e7959f745cfca280927f2d4
Signed-off-by: Sami Kiminki <skiminki@nvidia.com>
Reviewed-on: http://git-master/r/746803
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:09 +05:30
Seshendra Gadagottu
ac335e6fb5 gpu: nvgpu: gp10b: correct initial gpcclk rate
Set initial gpcclk rate to 1GHz.

Bug 200151332

Reviewed-on: http://git-master/r/834113
(cherry picked from commit 9ed69164da7afeec20c3a557885f74db4cbea9cb)

Change-Id: I85107eb5852b25977b30663f6ae173b271ecafeb
Signed-off-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: http://git-master/r/834322
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
2016-12-27 15:22:09 +05:30
Terje Bergstrom
e390f6e95a gpu: nvgpu: ZBC update without idle
Do ZBC updates without forcing engine idle first.

Bug 1698013

Change-Id: I188563dd60ba511b087e9b9bdacd7f9445efd7a4
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/829146
2016-12-27 15:22:09 +05:30