Skip to contentSkip to conversation

gk20a: add LTC device

PATCH Applied Alexandre Courbot 2 participants 4 messages Aug 12, 2014 – Aug 13, 2014 2 messages not in the archive

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gk20a: add LTC device

LTC device is now required for PGRAPH to work, add it.

---
 nvkm/engine/device/nve0.c | 1 +
 1 file changed, 1 insertion(+)
nvkm/engine/device/nve0.c +1 -0
index 54ec53bc6252..cdf9147f32a1 100644
@@ -163,6 +163,7 @@ nve0_identify(struct nouveau_device *device)
 		device->oclass[NVDEV_SUBDEV_BUS    ] =  nvc0_bus_oclass;
 		device->oclass[NVDEV_SUBDEV_TIMER  ] = &gk20a_timer_oclass;
 		device->oclass[NVDEV_SUBDEV_FB     ] =  gk20a_fb_oclass;
+		device->oclass[NVDEV_SUBDEV_LTC    ] =  gk104_ltc_oclass;
 		device->oclass[NVDEV_SUBDEV_IBUS   ] = &gk20a_ibus_oclass;
 		device->oclass[NVDEV_SUBDEV_INSTMEM] = nv50_instmem_oclass;
 		device->oclass[NVDEV_SUBDEV_VM     ] = &nvc0_vmmgr_oclass;
Signature · 1 line
2.0.4
#2 lore raw

PATCH 1/1 platform: fix compilation error

In reply to a message not in the archive

nouveau_platform.c was still using the old nouveau_dev() macro, triggering a compilation error. Fix this.

---
Hi Ben,

This one should probably go for 3.17 as Linus' tree currently does not compile if NOUVEAU_PLATFORM is selected. :(

 drm/nouveau_platform.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
drm/nouveau_platform.c +2 -1
index 0ffeb50d0088..246a824c16ca 100644
@@ -149,7 +149,8 @@ power_down:
 static int nouveau_platform_remove(struct platform_device *pdev)
 {
 	struct drm_device *drm_dev = platform_get_drvdata(pdev);
-	struct nouveau_device *device = nouveau_dev(drm_dev);
+	struct nouveau_drm *drm = nouveau_drm(drm_dev);
+	struct nouveau_device *device = nvkm_device(&drm->device);
 	struct nouveau_platform_gpu *gpu = nv_device_to_platform(device)->gpu;
 
 	nouveau_drm_device_remove(drm_dev);
Signature · 1 line
2.0.4
#4 lore raw

Re: [PATCH] platform: fix compilation error

In reply to a message not in the archive
Quoted 2 lines · Alexandre Courbot

nouveau_platform.c was still using the old nouveau_dev() macro, triggering a compilation error. Fix this.

Hey Alex,

Apologies for missing this. I rebased on top of your patches, and it got missed in the grep.

Thank you,
Ben.

Quoted 32 lines

---
Hi Ben,

This one should probably go for 3.17 as Linus' tree currently does not compile if NOUVEAU_PLATFORM is selected. :(

 drm/nouveau_platform.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
drm/nouveau_platform.c +2 -2
index 0ffeb50d0088..246a824c16ca 100644
@@ -149,7 +149,8 @@ power_down:
 static int nouveau_platform_remove(struct platform_device *pdev)
 {
        struct drm_device *drm_dev = platform_get_drvdata(pdev);
-       struct nouveau_device *device = nouveau_dev(drm_dev);
+       struct nouveau_drm *drm = nouveau_drm(drm_dev);
+       struct nouveau_device *device = nvkm_device(&drm->device);
        struct nouveau_platform_gpu *gpu = nv_device_to_platform(device)->gpu;
 
        nouveau_drm_device_remove(drm_dev);
--

2.0.4

_______________________________________________
Nouveau mailing list [email protected]
http://lists.freedesktop.org/mailman/listinfo/nouveau

Applied
#5 lore raw
In reply to a message not in the archive
Quoted 1 line · Alexandre Courbot

LTC device is now required for PGRAPH to work, add it.

Applied.

I had no idea you didn't use it already. Any particular reason? It provides a nice performance boost, so is good to have P I'm fixing up our implementation to not over-allocate vram so much, based on the Android driver's calculations. But generally, it looks like what we have was "safe" and compatible anyways.

Thanks,
Ben.

Quoted 25 lines
---
 nvkm/engine/device/nve0.c | 1 +
 1 file changed, 1 insertion(+)
nvkm/engine/device/nve0.c +1 -1
index 54ec53bc6252..cdf9147f32a1 100644
@@ -163,6 +163,7 @@ nve0_identify(struct nouveau_device *device)
                device->oclass[NVDEV_SUBDEV_BUS    ] =  nvc0_bus_oclass;
                device->oclass[NVDEV_SUBDEV_TIMER  ] = &gk20a_timer_oclass;
                device->oclass[NVDEV_SUBDEV_FB     ] =  gk20a_fb_oclass;
+               device->oclass[NVDEV_SUBDEV_LTC    ] =  gk104_ltc_oclass;
                device->oclass[NVDEV_SUBDEV_IBUS   ] = &gk20a_ibus_oclass;
                device->oclass[NVDEV_SUBDEV_INSTMEM] = nv50_instmem_oclass;
                device->oclass[NVDEV_SUBDEV_VM     ] = &nvc0_vmmgr_oclass;
--

2.0.4

_______________________________________________
Nouveau mailing list [email protected]
http://lists.freedesktop.org/mailman/listinfo/nouveau