drm/nouveau/subdev: rename some functions to avoid upcoming conflicts
authorBen Skeggs <bskeggs@redhat.com>
Thu, 20 Aug 2015 04:54:16 +0000 (14:54 +1000)
committerBen Skeggs <bskeggs@redhat.com>
Fri, 28 Aug 2015 02:40:33 +0000 (12:40 +1000)
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
24 files changed:
drivers/gpu/drm/nouveau/include/nvkm/core/engine.h
drivers/gpu/drm/nouveau/include/nvkm/core/subdev.h
drivers/gpu/drm/nouveau/include/nvkm/subdev/bus.h
drivers/gpu/drm/nouveau/include/nvkm/subdev/ibus.h
drivers/gpu/drm/nouveau/include/nvkm/subdev/mmu.h
drivers/gpu/drm/nouveau/include/nvkm/subdev/mxm.h
drivers/gpu/drm/nouveau/include/nvkm/subdev/timer.h
drivers/gpu/drm/nouveau/include/nvkm/subdev/volt.h
drivers/gpu/drm/nouveau/nvkm/core/subdev.c
drivers/gpu/drm/nouveau/nvkm/subdev/bar/priv.h
drivers/gpu/drm/nouveau/nvkm/subdev/bios/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/clk/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/devinit/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/fuse/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/gpio/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/i2c/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/instmem/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/ltc/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/mc/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/pmu/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/pmu/gk20a.c
drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c
drivers/gpu/drm/nouveau/nvkm/subdev/volt/base.c

index 0b5f05aec2dffe1e02d829d78c81024b8c94ad6e..3212b12a70eda2286c3e1c8dafff4e4f87fdda33 100644 (file)
@@ -41,9 +41,9 @@ struct nvkm_engine *nvkm_engine(void *obj, int idx);
 #define nvkm_engine_destroy(p)                                              \
        nvkm_subdev_destroy(&(p)->subdev)
 #define nvkm_engine_init(p)                                                 \
-       nvkm_subdev_init(&(p)->subdev)
+       nvkm_subdev_init_old(&(p)->subdev)
 #define nvkm_engine_fini(p,s)                                               \
-       nvkm_subdev_fini(&(p)->subdev, (s))
+       nvkm_subdev_fini_old(&(p)->subdev, (s))
 
 int nvkm_engine_create_(struct nvkm_object *, struct nvkm_object *,
                           struct nvkm_oclass *, bool, const char *,
index ce5f1b93ef9aa804e6c910f46af088493fa01e93..d3e08bf8d977e1fa202a6fde35115a598aec88f2 100644 (file)
@@ -44,8 +44,8 @@ int  nvkm_subdev_create_(struct nvkm_object *, struct nvkm_object *,
                            const char *sname, const char *fname,
                            int size, void **);
 void nvkm_subdev_destroy(struct nvkm_subdev *);
-int  nvkm_subdev_init(struct nvkm_subdev *);
-int  nvkm_subdev_fini(struct nvkm_subdev *, bool suspend);
+int  nvkm_subdev_init_old(struct nvkm_subdev *);
+int  nvkm_subdev_fini_old(struct nvkm_subdev *, bool suspend);
 void nvkm_subdev_reset(struct nvkm_object *);
 
 void _nvkm_subdev_dtor(struct nvkm_object *);
index ce7663c60015c76d098750e9dba1e1c2582df21d..5cf58a15bf41f0ac9c13b0e9c23e6b0a31a7d9af 100644 (file)
@@ -25,9 +25,9 @@ nvkm_bus(void *obj)
 #define nvkm_bus_destroy(p)                                                 \
        nvkm_subdev_destroy(&(p)->subdev)
 #define nvkm_bus_init(p)                                                    \
-       nvkm_subdev_init(&(p)->subdev)
+       nvkm_subdev_init_old(&(p)->subdev)
 #define nvkm_bus_fini(p, s)                                                 \
-       nvkm_subdev_fini(&(p)->subdev, (s))
+       nvkm_subdev_fini_old(&(p)->subdev, (s))
 
 #define _nvkm_bus_dtor _nvkm_subdev_dtor
 #define _nvkm_bus_init _nvkm_subdev_init
index 3538e87a44528b6499661bd454d3c345e9cc8c0c..8fc7946b8a42fe0f09d0bd3554bd674cec16a7f3 100644 (file)
@@ -18,9 +18,9 @@ nvkm_ibus(void *obj)
 #define nvkm_ibus_destroy(p)                                                \
        nvkm_subdev_destroy(&(p)->subdev)
 #define nvkm_ibus_init(p)                                                   \
-       nvkm_subdev_init(&(p)->subdev)
+       nvkm_subdev_init_old(&(p)->subdev)
 #define nvkm_ibus_fini(p,s)                                                 \
-       nvkm_subdev_fini(&(p)->subdev, (s))
+       nvkm_subdev_fini_old(&(p)->subdev, (s))
 
 #define _nvkm_ibus_dtor _nvkm_subdev_dtor
 #define _nvkm_ibus_init _nvkm_subdev_init
index b596a1dd5b81c67448b98780ac12a60fd278e037..2bf8f46c1bb05ef6b6850dbca2edf9492df4b530 100644 (file)
@@ -71,9 +71,9 @@ nvkm_mmu(void *obj)
 #define nvkm_mmu_destroy(p)                                               \
        nvkm_subdev_destroy(&(p)->subdev)
 #define nvkm_mmu_init(p)                                                  \
-       nvkm_subdev_init(&(p)->subdev)
+       nvkm_subdev_init_old(&(p)->subdev)
 #define nvkm_mmu_fini(p,s)                                                \
-       nvkm_subdev_fini(&(p)->subdev, (s))
+       nvkm_subdev_fini_old(&(p)->subdev, (s))
 
 #define _nvkm_mmu_dtor _nvkm_subdev_dtor
 #define _nvkm_mmu_init _nvkm_subdev_init
index 98904392547d66ca1b161ee8b2a5508367a0e855..93f9a4ec232051adffb2116a873ca9eac7ad90e2 100644 (file)
@@ -19,9 +19,9 @@ nvkm_mxm(void *obj)
 #define nvkm_mxm_create(p,e,o,d)                                            \
        nvkm_mxm_create_((p), (e), (o), sizeof(**d), (void **)d)
 #define nvkm_mxm_init(p)                                                    \
-       nvkm_subdev_init(&(p)->subdev)
+       nvkm_subdev_init_old(&(p)->subdev)
 #define nvkm_mxm_fini(p,s)                                                  \
-       nvkm_subdev_fini(&(p)->subdev, (s))
+       nvkm_subdev_fini_old(&(p)->subdev, (s))
 int  nvkm_mxm_create_(struct nvkm_object *, struct nvkm_object *,
                         struct nvkm_oclass *, int, void **);
 void nvkm_mxm_destroy(struct nvkm_mxm *);
index 4ae73689488bd609b899b59e05ebcffb704688af..f818adcc74670df6dcdc9924c337c5b08e20738c 100644 (file)
@@ -70,9 +70,9 @@ nvkm_timer(void *obj)
 #define nvkm_timer_destroy(p)                                               \
        nvkm_subdev_destroy(&(p)->subdev)
 #define nvkm_timer_init(p)                                                  \
-       nvkm_subdev_init(&(p)->subdev)
+       nvkm_subdev_init_old(&(p)->subdev)
 #define nvkm_timer_fini(p,s)                                                \
-       nvkm_subdev_fini(&(p)->subdev, (s))
+       nvkm_subdev_fini_old(&(p)->subdev, (s))
 
 int nvkm_timer_create_(struct nvkm_object *, struct nvkm_engine *,
                          struct nvkm_oclass *, int size, void **);
index 1eeb80a380d2218bc625463e48fa1a47d357c5e5..dc8846899a60ac17bfebdd375da47ffe3c06dea0 100644 (file)
@@ -41,7 +41,7 @@ nvkm_volt(void *obj)
        _nvkm_volt_init(nv_object(v));                                      \
 })
 #define nvkm_volt_fini(p,s)                                                 \
-       nvkm_subdev_fini((p), (s))
+       nvkm_subdev_fini_old((p), (s))
 
 int  nvkm_volt_create_(struct nvkm_object *, struct nvkm_object *,
                          struct nvkm_oclass *, int, void **);
index 0c313468d94e502e5a32cae131a550d77b135d47..3f6795f512185fe829ef82353465e7c82179bcc5 100644 (file)
@@ -46,7 +46,7 @@ nvkm_subdev_reset(struct nvkm_object *obj)
 }
 
 int
-nvkm_subdev_init(struct nvkm_subdev *subdev)
+nvkm_subdev_init_old(struct nvkm_subdev *subdev)
 {
        int ret = _nvkm_object_init(&subdev->object);
        if (ret)
@@ -59,11 +59,12 @@ nvkm_subdev_init(struct nvkm_subdev *subdev)
 int
 _nvkm_subdev_init(struct nvkm_object *object)
 {
-       return nvkm_subdev_init(nv_subdev(object));
+       struct nvkm_subdev *subdev = (void *)object;
+       return nvkm_subdev_init_old(subdev);
 }
 
 int
-nvkm_subdev_fini(struct nvkm_subdev *subdev, bool suspend)
+nvkm_subdev_fini_old(struct nvkm_subdev *subdev, bool suspend)
 {
        struct nvkm_device *device = subdev->device;
 
@@ -78,7 +79,8 @@ nvkm_subdev_fini(struct nvkm_subdev *subdev, bool suspend)
 int
 _nvkm_subdev_fini(struct nvkm_object *object, bool suspend)
 {
-       return nvkm_subdev_fini(nv_subdev(object), suspend);
+       struct nvkm_subdev *subdev = (void *)object;
+       return nvkm_subdev_fini_old(subdev, suspend);
 }
 
 void
index e6e4dfc97dcc1589853c9f4d1da4f3672c4420df..e9d2f7b6b22f8350894bed9ace8cc21c23eff19b 100644 (file)
@@ -5,9 +5,9 @@
 #define nvkm_bar_create(p,e,o,d)                                            \
        nvkm_bar_create_((p), (e), (o), sizeof(**d), (void **)d)
 #define nvkm_bar_init(p)                                                    \
-       nvkm_subdev_init(&(p)->subdev)
+       nvkm_subdev_init_old(&(p)->subdev)
 #define nvkm_bar_fini(p,s)                                                  \
-       nvkm_subdev_fini(&(p)->subdev, (s))
+       nvkm_subdev_fini_old(&(p)->subdev, (s))
 
 int nvkm_bar_create_(struct nvkm_object *, struct nvkm_object *,
                        struct nvkm_oclass *, int, void **);
index cc434268d9958b093480db0b0354cb9900b6ada6..b48ec70d9c553072dc96173c78709da845b60c83 100644 (file)
@@ -149,14 +149,14 @@ static int
 nvkm_bios_init(struct nvkm_object *object)
 {
        struct nvkm_bios *bios = (void *)object;
-       return nvkm_subdev_init(&bios->subdev);
+       return nvkm_subdev_init_old(&bios->subdev);
 }
 
 static int
 nvkm_bios_fini(struct nvkm_object *object, bool suspend)
 {
        struct nvkm_bios *bios = (void *)object;
-       return nvkm_subdev_fini(&bios->subdev, suspend);
+       return nvkm_subdev_fini_old(&bios->subdev, suspend);
 }
 
 struct nvkm_oclass
index cfd1feed99c3838c881326419e329a6f0155cbca..659122721b7db81ba7101d999928edae647056b0 100644 (file)
@@ -479,7 +479,7 @@ _nvkm_clk_fini(struct nvkm_object *object, bool suspend)
 {
        struct nvkm_clk *clk = (void *)object;
        nvkm_notify_put(&clk->pwrsrc_ntfy);
-       return nvkm_subdev_fini(&clk->subdev, suspend);
+       return nvkm_subdev_fini_old(&clk->subdev, suspend);
 }
 
 int
@@ -490,7 +490,7 @@ _nvkm_clk_init(struct nvkm_object *object)
        struct nvkm_domain *clock = clk->domains;
        int ret;
 
-       ret = nvkm_subdev_init(&clk->subdev);
+       ret = nvkm_subdev_init_old(&clk->subdev);
        if (ret)
                return ret;
 
index 989513fae7d5a893331409b1c9368907412e666a..e5ef999adbb939037587391ec9b20470a15086f6 100644 (file)
@@ -38,7 +38,7 @@ _nvkm_devinit_fini(struct nvkm_object *object, bool suspend)
        /* unlock the extended vga crtc regs */
        nvkm_lockvgac(init->subdev.device, false);
 
-       return nvkm_subdev_fini(&init->subdev, suspend);
+       return nvkm_subdev_fini_old(&init->subdev, suspend);
 }
 
 int
@@ -48,7 +48,7 @@ _nvkm_devinit_init(struct nvkm_object *object)
        struct nvkm_devinit *init = (void *)object;
        int ret;
 
-       ret = nvkm_subdev_init(&init->subdev);
+       ret = nvkm_subdev_init_old(&init->subdev);
        if (ret)
                return ret;
 
index 328381b8f0acf53a89ae7552fa4d8accb12a376c..d435bd155684f19ab391bb42e7ee234da45c408b 100644 (file)
@@ -56,7 +56,7 @@ int
 _nvkm_fb_fini(struct nvkm_object *object, bool suspend)
 {
        struct nvkm_fb *fb = (void *)object;
-       return nvkm_subdev_fini(&fb->subdev, suspend);
+       return nvkm_subdev_fini_old(&fb->subdev, suspend);
 }
 
 int
@@ -65,7 +65,7 @@ _nvkm_fb_init(struct nvkm_object *object)
        struct nvkm_fb *fb = (void *)object;
        int ret, i;
 
-       ret = nvkm_subdev_init(&fb->subdev);
+       ret = nvkm_subdev_init_old(&fb->subdev);
        if (ret)
                return ret;
 
index 4c1884ee7e385e218ce363d2efb5bf0011767c56..8889925da3d7b55a32069757838c9ee80ed4f5f8 100644 (file)
@@ -27,7 +27,7 @@ int
 _nvkm_fuse_init(struct nvkm_object *object)
 {
        struct nvkm_fuse *fuse = (void *)object;
-       return nvkm_subdev_init(&fuse->subdev);
+       return nvkm_subdev_init_old(&fuse->subdev);
 }
 
 void
index 1f10e7e773c2782de19806ccffab81bcb946063f..07db5845f8b20a0ae0307cd93bb66d0d2c688b32 100644 (file)
@@ -168,7 +168,7 @@ _nvkm_gpio_fini(struct nvkm_object *object, bool suspend)
        impl->intr_mask(gpio, NVKM_GPIO_TOGGLED, mask, 0);
        impl->intr_stat(gpio, &mask, &mask);
 
-       return nvkm_subdev_fini(&gpio->subdev, suspend);
+       return nvkm_subdev_fini_old(&gpio->subdev, suspend);
 }
 
 static struct dmi_system_id gpio_reset_ids[] = {
@@ -188,7 +188,7 @@ _nvkm_gpio_init(struct nvkm_object *object)
        struct nvkm_gpio *gpio = nvkm_gpio(object);
        int ret;
 
-       ret = nvkm_subdev_init(&gpio->subdev);
+       ret = nvkm_subdev_init_old(&gpio->subdev);
        if (ret)
                return ret;
 
index 86bff984e7e10bf8c95ab9409d131c6cdb08b3b4..fe29e728a60298a01766eff24dd911cc972847b1 100644 (file)
@@ -175,7 +175,7 @@ _nvkm_i2c_fini(struct nvkm_object *object, bool suspend)
                nvkm_i2c_pad_fini(pad);
        }
 
-       return nvkm_subdev_fini(&i2c->subdev, suspend);
+       return nvkm_subdev_fini_old(&i2c->subdev, suspend);
 }
 
 int
@@ -186,7 +186,7 @@ _nvkm_i2c_init(struct nvkm_object *object)
        struct nvkm_i2c_pad *pad;
        int ret;
 
-       ret = nvkm_subdev_init(&i2c->subdev);
+       ret = nvkm_subdev_init_old(&i2c->subdev);
        if (ret)
                return ret;
 
index 495da913bd1111710d957b831585a09ef9d06ce8..8ac8e4f4fa4b556a82452d1dcf22525455432215 100644 (file)
@@ -102,7 +102,7 @@ _nvkm_instmem_fini(struct nvkm_object *object, bool suspend)
                        return ret;
        }
 
-       return nvkm_subdev_fini(&imem->subdev, suspend);
+       return nvkm_subdev_fini_old(&imem->subdev, suspend);
 }
 
 int
@@ -112,7 +112,7 @@ _nvkm_instmem_init(struct nvkm_object *object)
        struct nvkm_instobj *iobj;
        int ret, i;
 
-       ret = nvkm_subdev_init(&imem->subdev);
+       ret = nvkm_subdev_init_old(&imem->subdev);
        if (ret)
                return ret;
 
index f9cfbabeeeb32a40acc06e7441177854e5fb7790..d0af1aec0fc6ac45a1da128f319c1231f9c72dd7 100644 (file)
@@ -83,7 +83,7 @@ _nvkm_ltc_init(struct nvkm_object *object)
        const struct nvkm_ltc_impl *impl = (void *)nv_oclass(object);
        int ret, i;
 
-       ret = nvkm_subdev_init(&ltc->base.subdev);
+       ret = nvkm_subdev_init_old(&ltc->base.subdev);
        if (ret)
                return ret;
 
index babd6d8725f0f404d792f460eeeb4cb6eba7fca0..f861a02d8d59f30ca0878fc56870a5c990b7773f 100644 (file)
@@ -86,7 +86,7 @@ _nvkm_mc_fini(struct nvkm_object *object, bool suspend)
        struct nvkm_mc *mc = (void *)object;
        struct nvkm_device *device = mc->subdev.device;
        nvkm_wr32(device, 0x000140, 0x00000000);
-       return nvkm_subdev_fini(&mc->subdev, suspend);
+       return nvkm_subdev_fini_old(&mc->subdev, suspend);
 }
 
 int
@@ -94,7 +94,7 @@ _nvkm_mc_init(struct nvkm_object *object)
 {
        struct nvkm_mc *mc = (void *)object;
        struct nvkm_device *device = mc->subdev.device;
-       int ret = nvkm_subdev_init(&mc->subdev);
+       int ret = nvkm_subdev_init_old(&mc->subdev);
        if (ret)
                return ret;
        nvkm_wr32(device, 0x000140, 0x00000001);
index 247994017965802874734217f4dad3291a143f19..c700d3d956e81925a7b6d4ee8d766825a6bff93e 100644 (file)
@@ -189,7 +189,7 @@ _nvkm_pmu_fini(struct nvkm_object *object, bool suspend)
        nvkm_wr32(device, 0x10a014, 0x00000060);
        flush_work(&pmu->recv.work);
 
-       return nvkm_subdev_fini(&pmu->subdev, suspend);
+       return nvkm_subdev_fini_old(&pmu->subdev, suspend);
 }
 
 int
@@ -200,7 +200,7 @@ _nvkm_pmu_init(struct nvkm_object *object)
        struct nvkm_device *device = pmu->subdev.device;
        int ret, i;
 
-       ret = nvkm_subdev_init(&pmu->subdev);
+       ret = nvkm_subdev_init_old(&pmu->subdev);
        if (ret)
                return ret;
 
index 1003013666a94190ace14bcec4533310f87e9435..47c6dbe8fff3e892190ef3417f4b258b90a2dc5f 100644 (file)
@@ -171,7 +171,7 @@ gk20a_pmu_fini(struct nvkm_object *object, bool suspend)
 
        nvkm_timer_alarm_cancel(pmu, &pmu->alarm);
 
-       return nvkm_subdev_fini(&pmu->base.subdev, suspend);
+       return nvkm_subdev_fini_old(&pmu->base.subdev, suspend);
 }
 
 static int
@@ -181,7 +181,7 @@ gk20a_pmu_init(struct nvkm_object *object)
        struct nvkm_device *device = pmu->base.subdev.device;
        int ret;
 
-       ret = nvkm_subdev_init(&pmu->base.subdev);
+       ret = nvkm_subdev_init_old(&pmu->base.subdev);
        if (ret)
                return ret;
 
index 18fa0443b6d3edd6c24d367f05657f13684e79be..e757fd9b7a07e153f55d9a197a633553adcf112c 100644 (file)
@@ -288,7 +288,7 @@ _nvkm_therm_init(struct nvkm_object *object)
        struct nvkm_therm_priv *therm = (void *)object;
        int ret;
 
-       ret = nvkm_subdev_init(&therm->base.subdev);
+       ret = nvkm_subdev_init_old(&therm->base.subdev);
        if (ret)
                return ret;
 
@@ -316,7 +316,7 @@ _nvkm_therm_fini(struct nvkm_object *object, bool suspend)
                therm->mode = NVKM_THERM_CTRL_NONE;
        }
 
-       return nvkm_subdev_fini(&therm->base.subdev, suspend);
+       return nvkm_subdev_fini_old(&therm->base.subdev, suspend);
 }
 
 int
index 67650a351a96a0f813804d1751ca71036367ddd8..88e5f62ec77228075fa8998eaea893fed538be2e 100644 (file)
@@ -142,7 +142,7 @@ _nvkm_volt_init(struct nvkm_object *object)
        struct nvkm_subdev *subdev = &volt->subdev;
        int ret;
 
-       ret = nvkm_subdev_init(&volt->subdev);
+       ret = nvkm_subdev_init_old(&volt->subdev);
        if (ret)
                return ret;