summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorTerje Bergstrom <tbergstrom@nvidia.com>2017-11-29 18:37:48 -0500
committermobile promotions <svcmobile_promotions@nvidia.com>2017-12-01 12:55:22 -0500
commit823ae76b1bc7e82c1532c9298c57f644b4791535 (patch)
tree1fb6c09cc135424c95d50399bb54a356574420ca /drivers
parentb6ed2c6d96fc6c37830b1450921f080c47b4a7bc (diff)
gpu: nvgpu: Remove extra CPU flushes in sim_gk20a.c
Simulation does not model CPU caches, so remove extra CPU flushes. The flushes are defined only in Tegra Linux kernel, so they cause build errors on other kernels. Change-Id: I5530a9ea8beac4b7c1ac30f32524afa418110daf Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1607582 Reviewed-by: Konsta Holtta <kholtta@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/nvgpu/common/linux/sim.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/drivers/gpu/nvgpu/common/linux/sim.c b/drivers/gpu/nvgpu/common/linux/sim.c
index b7481784..0e158063 100644
--- a/drivers/gpu/nvgpu/common/linux/sim.c
+++ b/drivers/gpu/nvgpu/common/linux/sim.c
@@ -179,10 +179,6 @@ static int rpc_send_message(struct gk20a *g)
179 g->sim->send_ring_put = (g->sim->send_ring_put + 2 * sizeof(u32)) % 179 g->sim->send_ring_put = (g->sim->send_ring_put + 2 * sizeof(u32)) %
180 PAGE_SIZE; 180 PAGE_SIZE;
181 181
182 __cpuc_flush_dcache_area(sim_linux->msg_bfr.kvaddr, PAGE_SIZE);
183 __cpuc_flush_dcache_area(sim_linux->send_bfr.kvaddr, PAGE_SIZE);
184 __cpuc_flush_dcache_area(sim_linux->recv_bfr.kvaddr, PAGE_SIZE);
185
186 /* Update the put pointer. This will trap into the host. */ 182 /* Update the put pointer. This will trap into the host. */
187 sim_writel(sim_linux, sim_send_put_r(), g->sim->send_ring_put); 183 sim_writel(sim_linux, sim_send_put_r(), g->sim->send_ring_put);
188 184
@@ -234,10 +230,6 @@ static int rpc_recv_poll(struct gk20a *g)
234 g->sim->recv_ring_get = (g->sim->recv_ring_get + 2*sizeof(u32)) % 230 g->sim->recv_ring_get = (g->sim->recv_ring_get + 2*sizeof(u32)) %
235 PAGE_SIZE; 231 PAGE_SIZE;
236 232
237 __cpuc_flush_dcache_area(sim_linux->msg_bfr.kvaddr, PAGE_SIZE);
238 __cpuc_flush_dcache_area(sim_linux->send_bfr.kvaddr, PAGE_SIZE);
239 __cpuc_flush_dcache_area(sim_linux->recv_bfr.kvaddr, PAGE_SIZE);
240
241 sim_writel(sim_linux, sim_recv_get_r(), g->sim->recv_ring_get); 233 sim_writel(sim_linux, sim_recv_get_r(), g->sim->recv_ring_get);
242 234
243 g->sim->recv_ring_put = sim_readl(sim_linux, sim_recv_put_r()); 235 g->sim->recv_ring_put = sim_readl(sim_linux, sim_recv_put_r());
@@ -362,4 +354,4 @@ int gk20a_init_sim_support(struct gk20a *g)
362 fail: 354 fail:
363 gk20a_free_sim_support(g); 355 gk20a_free_sim_support(g);
364 return err; 356 return err;
365} \ No newline at end of file 357}