diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2020-12-04 11:16:21 +1000 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2021-02-11 11:49:52 +1000 |
commit | b7a9369ae6f2da41b1d9f01a1d84e10e39bca293 (patch) | |
tree | e94c91a25c9f94ab5921d30462d3f8701d1c7567 /drivers | |
parent | 77689f1b6b0a99179b764035b186d30ee8ef938f (diff) |
drm/nouveau/fb: switch to instanced constructor
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Diffstat (limited to 'drivers')
43 files changed, 206 insertions, 210 deletions
diff --git a/drivers/gpu/drm/nouveau/include/nvkm/core/device.h b/drivers/gpu/drm/nouveau/include/nvkm/core/device.h index 0b5c85218c71..c1cb34ba1d40 100644 --- a/drivers/gpu/drm/nouveau/include/nvkm/core/device.h +++ b/drivers/gpu/drm/nouveau/include/nvkm/core/device.h @@ -60,7 +60,6 @@ struct nvkm_device { struct notifier_block nb; } acpi; - struct nvkm_fb *fb; struct nvkm_fuse *fuse; struct nvkm_gpio *gpio; struct nvkm_gsp *gsp; @@ -141,7 +140,6 @@ struct nvkm_device_chip { #include <core/layout.h> #undef NVKM_LAYOUT_INST #undef NVKM_LAYOUT_ONCE - int (*fb )(struct nvkm_device *, int idx, struct nvkm_fb **); int (*fuse )(struct nvkm_device *, int idx, struct nvkm_fuse **); int (*gpio )(struct nvkm_device *, int idx, struct nvkm_gpio **); int (*gsp )(struct nvkm_device *, int idx, struct nvkm_gsp **); diff --git a/drivers/gpu/drm/nouveau/include/nvkm/core/layout.h b/drivers/gpu/drm/nouveau/include/nvkm/core/layout.h index 9f5fad93eacc..85092d589ad4 100644 --- a/drivers/gpu/drm/nouveau/include/nvkm/core/layout.h +++ b/drivers/gpu/drm/nouveau/include/nvkm/core/layout.h @@ -2,6 +2,7 @@ NVKM_LAYOUT_ONCE(NVKM_SUBDEV_VBIOS , struct nvkm_bios , bios) NVKM_LAYOUT_ONCE(NVKM_SUBDEV_DEVINIT , struct nvkm_devinit , devinit) NVKM_LAYOUT_ONCE(NVKM_SUBDEV_BUS , struct nvkm_bus , bus) +NVKM_LAYOUT_ONCE(NVKM_SUBDEV_FB , struct nvkm_fb , fb) NVKM_LAYOUT_ONCE(NVKM_SUBDEV_BAR , struct nvkm_bar , bar) NVKM_LAYOUT_ONCE(NVKM_SUBDEV_FAULT , struct nvkm_fault , fault) NVKM_LAYOUT_ONCE(NVKM_SUBDEV_ACR , struct nvkm_acr , acr) diff --git a/drivers/gpu/drm/nouveau/include/nvkm/subdev/fb.h b/drivers/gpu/drm/nouveau/include/nvkm/subdev/fb.h index 7fb5cd8e29af..ef6a6297148c 100644 --- a/drivers/gpu/drm/nouveau/include/nvkm/subdev/fb.h +++ b/drivers/gpu/drm/nouveau/include/nvkm/subdev/fb.h @@ -58,40 +58,40 @@ void nvkm_fb_tile_init(struct nvkm_fb *, int region, u32 addr, u32 size, void nvkm_fb_tile_fini(struct nvkm_fb *, int region, struct nvkm_fb_tile *); void nvkm_fb_tile_prog(struct nvkm_fb *, int region, struct nvkm_fb_tile *); -int nv04_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv10_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv1a_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv20_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv25_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv30_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv35_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv36_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv40_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv41_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv44_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv46_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv47_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv49_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv4e_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int nv50_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int g84_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gt215_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int mcp77_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int mcp89_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gf100_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gf108_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gk104_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gk110_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gk20a_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gm107_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gm200_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gm20b_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gp100_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gp102_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gp10b_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int gv100_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int ga100_fb_new(struct nvkm_device *, int, struct nvkm_fb **); -int ga102_fb_new(struct nvkm_device *, int, struct nvkm_fb **); +int nv04_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv10_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv1a_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv20_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv25_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv30_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv35_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv36_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv40_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv41_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv44_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv46_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv47_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv49_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv4e_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int nv50_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int g84_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gt215_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int mcp77_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int mcp89_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gf100_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gf108_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gk104_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gk110_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gk20a_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gm107_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gm200_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gm20b_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gp100_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gp102_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gp10b_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int gv100_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int ga100_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); +int ga102_fb_new(struct nvkm_device *, enum nvkm_subdev_type, int inst, struct nvkm_fb **); #include <subdev/bios.h> #include <subdev/bios/ramcfg.h> diff --git a/drivers/gpu/drm/nouveau/nvkm/core/subdev.c b/drivers/gpu/drm/nouveau/nvkm/core/subdev.c index 56b61a266f1f..e43a88fff9bb 100644 --- a/drivers/gpu/drm/nouveau/nvkm/core/subdev.c +++ b/drivers/gpu/drm/nouveau/nvkm/core/subdev.c @@ -33,7 +33,6 @@ nvkm_subdev_type[NVKM_SUBDEV_NR] = { #include <core/layout.h> #undef NVKM_LAYOUT_ONCE #undef NVKM_LAYOUT_INST - [NVKM_SUBDEV_FB ] = "fb", [NVKM_SUBDEV_FUSE ] = "fuse", [NVKM_SUBDEV_GPIO ] = "gpio", [NVKM_SUBDEV_GSP ] = "gsp", diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/device/base.c b/drivers/gpu/drm/nouveau/nvkm/engine/device/base.c index 123a01f26830..a4ef6cac85fa 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/device/base.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/device/base.c @@ -81,7 +81,7 @@ nv4_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv04_devinit_new }, - .fb = nv04_fb_new, + .fb = { 0x00000001, nv04_fb_new }, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, .mc = nv04_mc_new, @@ -102,7 +102,7 @@ nv5_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv05_devinit_new }, - .fb = nv04_fb_new, + .fb = { 0x00000001, nv04_fb_new }, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, .mc = nv04_mc_new, @@ -123,7 +123,7 @@ nv10_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv10_devinit_new }, - .fb = nv10_fb_new, + .fb = { 0x00000001, nv10_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -143,7 +143,7 @@ nv11_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv10_devinit_new }, - .fb = nv10_fb_new, + .fb = { 0x00000001, nv10_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -165,7 +165,7 @@ nv15_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv10_devinit_new }, - .fb = nv10_fb_new, + .fb = { 0x00000001, nv10_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -187,7 +187,7 @@ nv17_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv10_devinit_new }, - .fb = nv10_fb_new, + .fb = { 0x00000001, nv10_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -209,7 +209,7 @@ nv18_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv10_devinit_new }, - .fb = nv10_fb_new, + .fb = { 0x00000001, nv10_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -231,7 +231,7 @@ nv1a_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv1a_fb_new, + .fb = { 0x00000001, nv1a_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -253,7 +253,7 @@ nv1f_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv1a_fb_new, + .fb = { 0x00000001, nv1a_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -275,7 +275,7 @@ nv20_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv20_devinit_new }, - .fb = nv20_fb_new, + .fb = { 0x00000001, nv20_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -297,7 +297,7 @@ nv25_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv20_devinit_new }, - .fb = nv25_fb_new, + .fb = { 0x00000001, nv25_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -319,7 +319,7 @@ nv28_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv20_devinit_new }, - .fb = nv25_fb_new, + .fb = { 0x00000001, nv25_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -341,7 +341,7 @@ nv2a_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv20_devinit_new }, - .fb = nv25_fb_new, + .fb = { 0x00000001, nv25_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -363,7 +363,7 @@ nv30_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv20_devinit_new }, - .fb = nv30_fb_new, + .fb = { 0x00000001, nv30_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -385,7 +385,7 @@ nv31_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv20_devinit_new }, - .fb = nv30_fb_new, + .fb = { 0x00000001, nv30_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -408,7 +408,7 @@ nv34_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv10_devinit_new }, - .fb = nv10_fb_new, + .fb = { 0x00000001, nv10_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -431,7 +431,7 @@ nv35_chipset = { .bus = { 0x00000001, nv04_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv20_devinit_new }, - .fb = nv35_fb_new, + .fb = { 0x00000001, nv35_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -453,7 +453,7 @@ nv36_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv04_clk_new }, .devinit = { 0x00000001, nv20_devinit_new }, - .fb = nv36_fb_new, + .fb = { 0x00000001, nv36_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv04_instmem_new, @@ -476,7 +476,7 @@ nv40_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv40_fb_new, + .fb = { 0x00000001, nv40_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -502,7 +502,7 @@ nv41_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv41_fb_new, + .fb = { 0x00000001, nv41_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -528,7 +528,7 @@ nv42_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv41_fb_new, + .fb = { 0x00000001, nv41_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -554,7 +554,7 @@ nv43_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv41_fb_new, + .fb = { 0x00000001, nv41_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -580,7 +580,7 @@ nv44_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv44_fb_new, + .fb = { 0x00000001, nv44_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -606,7 +606,7 @@ nv45_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv40_fb_new, + .fb = { 0x00000001, nv40_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -632,7 +632,7 @@ nv46_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv46_fb_new, + .fb = { 0x00000001, nv46_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -658,7 +658,7 @@ nv47_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv47_fb_new, + .fb = { 0x00000001, nv47_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -684,7 +684,7 @@ nv49_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv49_fb_new, + .fb = { 0x00000001, nv49_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -710,7 +710,7 @@ nv4a_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv44_fb_new, + .fb = { 0x00000001, nv44_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -736,7 +736,7 @@ nv4b_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv49_fb_new, + .fb = { 0x00000001, nv49_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -762,7 +762,7 @@ nv4c_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv46_fb_new, + .fb = { 0x00000001, nv46_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -788,7 +788,7 @@ nv4e_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv4e_fb_new, + .fb = { 0x00000001, nv4e_fb_new }, .gpio = nv10_gpio_new, .i2c = nv4e_i2c_new, .imem = nv40_instmem_new, @@ -815,7 +815,7 @@ nv50_chipset = { .bus = { 0x00000001, nv50_bus_new }, .clk = { 0x00000001, nv50_clk_new }, .devinit = { 0x00000001, nv50_devinit_new }, - .fb = nv50_fb_new, + .fb = { 0x00000001, nv50_fb_new }, .fuse = nv50_fuse_new, .gpio = nv50_gpio_new, .i2c = nv50_i2c_new, @@ -843,7 +843,7 @@ nv63_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv46_fb_new, + .fb = { 0x00000001, nv46_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -869,7 +869,7 @@ nv67_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv46_fb_new, + .fb = { 0x00000001, nv46_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -895,7 +895,7 @@ nv68_chipset = { .bus = { 0x00000001, nv31_bus_new }, .clk = { 0x00000001, nv40_clk_new }, .devinit = { 0x00000001, nv1a_devinit_new }, - .fb = nv46_fb_new, + .fb = { 0x00000001, nv46_fb_new }, .gpio = nv10_gpio_new, .i2c = nv04_i2c_new, .imem = nv40_instmem_new, @@ -922,7 +922,7 @@ nv84_chipset = { .bus = { 0x00000001, nv50_bus_new }, .clk = { 0x00000001, g84_clk_new }, .devinit = { 0x00000001, g84_devinit_new }, - .fb = g84_fb_new, + .fb = { 0x00000001, g84_fb_new }, .fuse = nv50_fuse_new, .gpio = nv50_gpio_new, .i2c = nv50_i2c_new, @@ -954,7 +954,7 @@ nv86_chipset = { .bus = { 0x00000001, nv50_bus_new }, .clk = { 0x00000001, g84_clk_new }, .devinit = { 0x00000001, g84_devinit_new }, - .fb = g84_fb_new, + .fb = { 0x00000001, g84_fb_new }, .fuse = nv50_fuse_new, .gpio = nv50_gpio_new, .i2c = nv50_i2c_new, @@ -986,7 +986,7 @@ nv92_chipset = { .bus = { 0x00000001, nv50_bus_new }, .clk = { 0x00000001, g84_clk_new }, .devinit = { 0x00000001, g84_devinit_new }, - .fb = g84_fb_new, + .fb = { 0x00000001, g84_fb_new }, .fuse = nv50_fuse_new, .gpio = nv50_gpio_new, .i2c = nv50_i2c_new, @@ -1018,7 +1018,7 @@ nv94_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, g84_clk_new }, .devinit = { 0x00000001, g84_devinit_new }, - .fb = g84_fb_new, + .fb = { 0x00000001, g84_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1050,7 +1050,7 @@ nv96_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, g84_clk_new }, .devinit = { 0x00000001, g84_devinit_new }, - .fb = g84_fb_new, + .fb = { 0x00000001, g84_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1082,7 +1082,7 @@ nv98_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, g84_clk_new }, .devinit = { 0x00000001, g98_devinit_new }, - .fb = g84_fb_new, + .fb = { 0x00000001, g84_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1114,7 +1114,7 @@ nva0_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, g84_clk_new }, .devinit = { 0x00000001, g84_devinit_new }, - .fb = g84_fb_new, + .fb = { 0x00000001, g84_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = nv50_i2c_new, @@ -1146,7 +1146,7 @@ nva3_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, gt215_clk_new }, .devinit = { 0x00000001, gt215_devinit_new }, - .fb = gt215_fb_new, + .fb = { 0x00000001, gt215_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1180,7 +1180,7 @@ nva5_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, gt215_clk_new }, .devinit = { 0x00000001, gt215_devinit_new }, - .fb = gt215_fb_new, + .fb = { 0x00000001, gt215_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1213,7 +1213,7 @@ nva8_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, gt215_clk_new }, .devinit = { 0x00000001, gt215_devinit_new }, - .fb = gt215_fb_new, + .fb = { 0x00000001, gt215_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1246,7 +1246,7 @@ nvaa_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, mcp77_clk_new }, .devinit = { 0x00000001, g98_devinit_new }, - .fb = mcp77_fb_new, + .fb = { 0x00000001, mcp77_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1278,7 +1278,7 @@ nvac_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, mcp77_clk_new }, .devinit = { 0x00000001, g98_devinit_new }, - .fb = mcp77_fb_new, + .fb = { 0x00000001, mcp77_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1310,7 +1310,7 @@ nvaf_chipset = { .bus = { 0x00000001, g94_bus_new }, .clk = { 0x00000001, gt215_clk_new }, .devinit = { 0x00000001, mcp89_devinit_new }, - .fb = mcp89_fb_new, + .fb = { 0x00000001, mcp89_fb_new }, .fuse = nv50_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1343,7 +1343,7 @@ nvc0_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf100_fb_new, + .fb = { 0x00000001, gf100_fb_new }, .fuse = gf100_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1380,7 +1380,7 @@ nvc1_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf108_fb_new, + .fb = { 0x00000001, gf108_fb_new }, .fuse = gf100_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1416,7 +1416,7 @@ nvc3_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf100_fb_new, + .fb = { 0x00000001, gf100_fb_new }, .fuse = gf100_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1452,7 +1452,7 @@ nvc4_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf100_fb_new, + .fb = { 0x00000001, gf100_fb_new }, .fuse = gf100_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1489,7 +1489,7 @@ nvc8_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf100_fb_new, + .fb = { 0x00000001, gf100_fb_new }, .fuse = gf100_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1526,7 +1526,7 @@ nvce_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf100_fb_new, + .fb = { 0x00000001, gf100_fb_new }, .fuse = gf100_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1563,7 +1563,7 @@ nvcf_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf100_fb_new, + .fb = { 0x00000001, gf100_fb_new }, .fuse = gf100_fuse_new, .gpio = g94_gpio_new, .i2c = g94_i2c_new, @@ -1599,7 +1599,7 @@ nvd7_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf100_fb_new, + .fb = { 0x00000001, gf100_fb_new }, .fuse = gf100_fuse_new, .gpio = gf119_gpio_new, .i2c = gf117_i2c_new, @@ -1634,7 +1634,7 @@ nvd9_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gf100_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gf100_fb_new, + .fb = { 0x00000001, gf100_fb_new }, .fuse = gf100_fuse_new, .gpio = gf119_gpio_new, .i2c = gf119_i2c_new, @@ -1670,7 +1670,7 @@ nve4_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gk104_fb_new, + .fb = { 0x00000001, gk104_fb_new }, .fuse = gf100_fuse_new, .gpio = gk104_gpio_new, .i2c = gk104_i2c_new, @@ -1709,7 +1709,7 @@ nve6_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gk104_fb_new, + .fb = { 0x00000001, gk104_fb_new }, .fuse = gf100_fuse_new, .gpio = gk104_gpio_new, .i2c = gk104_i2c_new, @@ -1748,7 +1748,7 @@ nve7_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gk104_fb_new, + .fb = { 0x00000001, gk104_fb_new }, .fuse = gf100_fuse_new, .gpio = gk104_gpio_new, .i2c = gk104_i2c_new, @@ -1785,7 +1785,7 @@ nvea_chipset = { .bar = { 0x00000001, gk20a_bar_new }, .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk20a_clk_new }, - .fb = gk20a_fb_new, + .fb = { 0x00000001, gk20a_fb_new }, .fuse = gf100_fuse_new, .ibus = gk20a_ibus_new, .imem = gk20a_instmem_new, @@ -1812,7 +1812,7 @@ nvf0_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gk110_fb_new, + .fb = { 0x00000001, gk110_fb_new }, .fuse = gf100_fuse_new, .gpio = gk104_gpio_new, .i2c = gk110_i2c_new, @@ -1850,7 +1850,7 @@ nvf1_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gk110_fb_new, + .fb = { 0x00000001, gk110_fb_new }, .fuse = gf100_fuse_new, .gpio = gk104_gpio_new, .i2c = gk110_i2c_new, @@ -1888,7 +1888,7 @@ nv106_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gk110_fb_new, + .fb = { 0x00000001, gk110_fb_new }, .fuse = gf100_fuse_new, .gpio = gk104_gpio_new, .i2c = gk110_i2c_new, @@ -1926,7 +1926,7 @@ nv108_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gf100_devinit_new }, - .fb = gk110_fb_new, + .fb = { 0x00000001, gk110_fb_new }, .fuse = gf100_fuse_new, .gpio = gk104_gpio_new, .i2c = gk110_i2c_new, @@ -1964,7 +1964,7 @@ nv117_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gm107_devinit_new }, - .fb = gm107_fb_new, + .fb = { 0x00000001, gm107_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gk110_i2c_new, @@ -2000,7 +2000,7 @@ nv118_chipset = { .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gk104_clk_new }, .devinit = { 0x00000001, gm107_devinit_new }, - .fb = gm107_fb_new, + .fb = { 0x00000001, gm107_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gk110_i2c_new, @@ -2034,7 +2034,7 @@ nv120_chipset = { .bios = { 0x00000001, nvkm_bios_new }, .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, - .fb = gm200_fb_new, + .fb = { 0x00000001, gm200_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2072,7 +2072,7 @@ nv124_chipset = { .bios = { 0x00000001, nvkm_bios_new }, .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, - .fb = gm200_fb_new, + .fb = { 0x00000001, gm200_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2110,7 +2110,7 @@ nv126_chipset = { .bios = { 0x00000001, nvkm_bios_new }, .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, - .fb = gm200_fb_new, + .fb = { 0x00000001, gm200_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2146,7 +2146,7 @@ nv12b_chipset = { .bar = { 0x00000001, gm20b_bar_new }, .bus = { 0x00000001, gf100_bus_new }, .clk = { 0x00000001, gm20b_clk_new }, - .fb = gm20b_fb_new, + .fb = { 0x00000001, gm20b_fb_new }, .fuse = gm107_fuse_new, .ibus = gk20a_ibus_new, .imem = gk20a_instmem_new, @@ -2173,7 +2173,7 @@ nv130_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, .fault = { 0x00000001, gp100_fault_new }, - .fb = gp100_fb_new, + .fb = { 0x00000001, gp100_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2213,7 +2213,7 @@ nv132_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, .fault = { 0x00000001, gp100_fault_new }, - .fb = gp102_fb_new, + .fb = { 0x00000001, gp102_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2251,7 +2251,7 @@ nv134_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, .fault = { 0x00000001, gp100_fault_new }, - .fb = gp102_fb_new, + .fb = { 0x00000001, gp102_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2289,7 +2289,7 @@ nv136_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, .fault = { 0x00000001, gp100_fault_new }, - .fb = gp102_fb_new, + .fb = { 0x00000001, gp102_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2326,7 +2326,7 @@ nv137_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, .fault = { 0x00000001, gp100_fault_new }, - .fb = gp102_fb_new, + .fb = { 0x00000001, gp102_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2364,7 +2364,7 @@ nv138_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gm200_devinit_new }, .fault = { 0x00000001, gp100_fault_new }, - .fb = gp102_fb_new, + .fb = { 0x00000001, gp102_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, @@ -2398,7 +2398,7 @@ nv13b_chipset = { .bar = { 0x00000001, gm20b_bar_new }, .bus = { 0x00000001, gf100_bus_new }, .fault = { 0x00000001, gp10b_fault_new }, - .fb = gp10b_fb_new, + .fb = { 0x00000001, gp10b_fb_new }, .fuse = gm107_fuse_new, .ibus = gp10b_ibus_new, .imem = gk20a_instmem_new, @@ -2424,7 +2424,7 @@ nv140_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, gv100_devinit_new }, .fault = { 0x00000001, gv100_fault_new }, - .fb = gv100_fb_new, + .fb = { 0x00000001, gv100_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .gsp = gv100_gsp_new, @@ -2468,7 +2468,7 @@ nv162_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, tu102_devinit_new }, .fault = { 0x00000001, tu102_fault_new }, - .fb = gv100_fb_new, + .fb = { 0x00000001, gv100_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .gsp = gv100_gsp_new, @@ -2506,7 +2506,7 @@ nv164_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, tu102_devinit_new }, .fault = { 0x00000001, tu102_fault_new }, - .fb = gv100_fb_new, + .fb = { 0x00000001, gv100_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .gsp = gv100_gsp_new, @@ -2545,7 +2545,7 @@ nv166_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, tu102_devinit_new }, .fault = { 0x00000001, tu102_fault_new }, - .fb = gv100_fb_new, + .fb = { 0x00000001, gv100_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .gsp = gv100_gsp_new, @@ -2585,7 +2585,7 @@ nv167_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, tu102_devinit_new }, .fault = { 0x00000001, tu102_fault_new }, - .fb = gv100_fb_new, + .fb = { 0x00000001, gv100_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .gsp = gv100_gsp_new, @@ -2623,7 +2623,7 @@ nv168_chipset = { .bus = { 0x00000001, gf100_bus_new }, .devinit = { 0x00000001, tu102_devinit_new }, .fault = { 0x00000001, tu102_fault_new }, - .fb = gv100_fb_new, + .fb = { 0x00000001, gv100_fb_new }, .fuse = gm107_fuse_new, .gpio = gk104_gpio_new, .gsp = gv100_gsp_new, @@ -2658,7 +2658,7 @@ nv170_chipset = { .bar = { 0x00000001, tu102_bar_new }, .bios = { 0x00000001, nvkm_bios_new }, .devinit = { 0x00000001, ga100_devinit_new }, - .fb = ga100_fb_new, + .fb = { 0x00000001, ga100_fb_new }, .gpio = gk104_gpio_new, .i2c = gm200_i2c_new, .ibus = gm200_ibus_new, @@ -2675,7 +2675,7 @@ nv172_chipset = { .bar = { 0x00000001, tu102_bar_new }, .bios = { 0x00000001, nvkm_bios_new }, .devinit = { 0x00000001, ga100_devinit_new }, - .fb = ga102_fb_new, + .fb = { 0x00000001, ga102_fb_new }, .gpio = ga102_gpio_new, .i2c = gm200_i2c_new, .ibus = gm200_ibus_new, @@ -2694,7 +2694,7 @@ nv174_chipset = { .bar = { 0x00000001, tu102_bar_new }, .bios = { 0x00000001, nvkm_bios_new }, .devinit = { 0x00000001, ga100_devinit_new }, - .fb = ga102_fb_new, + .fb = { 0x00000001, ga102_fb_new }, .gpio = ga102_gpio_new, .i2c = gm200_i2c_new, .ibus = gm200_ibus_new, @@ -3248,7 +3248,6 @@ nvkm_device_ctor(const struct nvkm_device_func *func, #include <core/layout.h> #undef NVKM_LAYOUT_INST #undef NVKM_LAYOUT_ONCE - _(NVKM_SUBDEV_FB , fb); _(NVKM_SUBDEV_FUSE , fuse); _(NVKM_SUBDEV_GPIO , gpio); _(NVKM_SUBDEV_GSP , gsp); diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c index 7a13165915c9..6faaea948fc4 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/base.c @@ -227,9 +227,9 @@ nvkm_fb = { void nvkm_fb_ctor(const struct nvkm_fb_func *func, struct nvkm_device *device, - int index, struct nvkm_fb *fb) + enum nvkm_subdev_type type, int inst, struct nvkm_fb *fb) { - nvkm_subdev_ctor(&nvkm_fb, device, index, &fb->subdev); + nvkm_subdev_ctor(&nvkm_fb, device, type, inst, &fb->subdev); fb->func = func; fb->tile.regions = fb->func->tile.regions; fb->page = nvkm_longopt(device->cfgopt, "NvFbBigPage", fb->func->default_bigpage); @@ -238,10 +238,10 @@ nvkm_fb_ctor(const struct nvkm_fb_func *func, struct nvkm_device *device, int nvkm_fb_new_(const struct nvkm_fb_func *func, struct nvkm_device *device, - int index, struct nvkm_fb **pfb) + enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { if (!(*pfb = kzalloc(sizeof(**pfb), GFP_KERNEL))) return -ENOMEM; - nvkm_fb_ctor(func, device, index, *pfb); + nvkm_fb_ctor(func, device, type, inst, *pfb); return 0; } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/g84.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/g84.c index 06bf95c0c549..770a4ad39122 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/g84.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/g84.c @@ -32,7 +32,7 @@ g84_fb = { }; int -g84_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +g84_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nv50_fb_new_(&g84_fb, device, index, pfb); + return nv50_fb_new_(&g84_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga100.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga100.c index bf82686851cd..b47bebfbc26f 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga100.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga100.c @@ -34,7 +34,7 @@ ga100_fb = { }; int -ga100_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +ga100_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gp102_fb_new_(&ga100_fb, device, index, pfb); + return gp102_fb_new_(&ga100_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga102.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga102.c index bcecf84a6e67..6ea7908f0563 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga102.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ga102.c @@ -34,7 +34,7 @@ ga102_fb = { }; int -ga102_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +ga102_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gp102_fb_new_(&ga102_fb, device, index, pfb); + return gp102_fb_new_(&ga102_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.c index e8dc4e913494..9dcc40f9ef79 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.c @@ -117,13 +117,13 @@ gf100_fb_dtor(struct nvkm_fb *base) int gf100_fb_new_(const struct nvkm_fb_func *func, struct nvkm_device *device, - int index, struct nvkm_fb **pfb) + enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { struct gf100_fb *fb; if (!(fb = kzalloc(sizeof(*fb), GFP_KERNEL))) return -ENOMEM; - nvkm_fb_ctor(func, device, index, &fb->base); + nvkm_fb_ctor(func, device, type, inst, &fb->base); *pfb = &fb->base; return 0; @@ -141,7 +141,7 @@ gf100_fb = { }; int -gf100_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gf100_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gf100_fb, device, index, pfb); + return gf100_fb_new_(&gf100_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.h b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.h index 2ed7cdaab37c..0cac7b06acc8 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.h +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.h @@ -10,8 +10,8 @@ struct gf100_fb { dma_addr_t r100c10; }; -int gf100_fb_new_(const struct nvkm_fb_func *, struct nvkm_device *, - int index, struct nvkm_fb **); +int gf100_fb_new_(const struct nvkm_fb_func *, struct nvkm_device *, enum nvkm_subdev_type, int, + struct nvkm_fb **); void *gf100_fb_dtor(struct nvkm_fb *); void gf100_fb_init(struct nvkm_fb *); void gf100_fb_intr(struct nvkm_fb *); diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf108.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf108.c index 4a9f463745b5..76678dd60f93 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf108.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf108.c @@ -36,7 +36,7 @@ gf108_fb = { }; int -gf108_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gf108_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gf108_fb, device, index, pfb); + return gf100_fb_new_(&gf108_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk104.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk104.c index 48fd98e08baa..f73442ccb424 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk104.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk104.c @@ -83,7 +83,7 @@ gk104_fb = { }; int -gk104_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gk104_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gk104_fb, device, index, pfb); + return gf100_fb_new_(&gk104_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk110.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk110.c index 0695e5dd360e..45d6cdffafee 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk110.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk110.c @@ -65,7 +65,7 @@ gk110_fb = { }; int -gk110_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gk110_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gk110_fb, device, index, pfb); + return gf100_fb_new_(&gk110_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk20a.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk20a.c index a7e29b125094..6bc42f89d8c4 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk20a.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gk20a.c @@ -34,7 +34,7 @@ gk20a_fb = { }; int -gk20a_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gk20a_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gk20a_fb, device, index, pfb); + return gf100_fb_new_(&gk20a_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm107.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm107.c index 69c876d5d1c1..de52462a92bf 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm107.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm107.c @@ -36,7 +36,7 @@ gm107_fb = { }; int -gm107_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gm107_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gm107_fb, device, index, pfb); + return gf100_fb_new_(&gm107_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm200.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm200.c index d3b8c3367152..5acf8d15d06f 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm200.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm200.c @@ -67,7 +67,7 @@ gm200_fb = { }; int -gm200_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gm200_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gm200_fb, device, index, pfb); + return gf100_fb_new_(&gm200_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm20b.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm20b.c index 12db61e31128..86f61a3f2fea 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm20b.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gm20b.c @@ -34,7 +34,7 @@ gm20b_fb = { }; int -gm20b_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gm20b_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gm20b_fb, device, index, pfb); + return gf100_fb_new_(&gm20b_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp100.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp100.c index 8205ce436b3e..09e943edc362 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp100.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp100.c @@ -71,7 +71,7 @@ gp100_fb = { }; int -gp100_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gp100_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gp100_fb, device, index, pfb); + return gf100_fb_new_(&gp100_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp102.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp102.c index fc8c93aa3da5..0e78b3d734a0 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp102.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp102.c @@ -114,9 +114,9 @@ gp102_fb = { int gp102_fb_new_(const struct nvkm_fb_func *func, struct nvkm_device *device, - int index, struct nvkm_fb **pfb) + enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - int ret = gf100_fb_new_(func, device, index, pfb); + int ret = gf100_fb_new_(func, device, type, inst, pfb); if (ret) return ret; @@ -126,9 +126,9 @@ gp102_fb_new_(const struct nvkm_fb_func *func, struct nvkm_device *device, } int -gp102_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gp102_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gp102_fb_new_(&gp102_fb, device, index, pfb); + return gp102_fb_new_(&gp102_fb, device, type, inst, pfb); } MODULE_FIRMWARE("nvidia/gp102/nvdec/scrubber.bin"); diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp10b.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp10b.c index af8e43979dc1..84c9815a6d48 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp10b.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gp10b.c @@ -31,7 +31,7 @@ gp10b_fb = { }; int -gp10b_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gp10b_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gf100_fb_new_(&gp10b_fb, device, index, pfb); + return gf100_fb_new_(&gp10b_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gt215.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gt215.c index 9266559b45f9..c1ec9758617c 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gt215.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gt215.c @@ -32,7 +32,7 @@ gt215_fb = { }; int -gt215_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gt215_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nv50_fb_new_(>215_fb, device, index, pfb); + return nv50_fb_new_(>215_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gv100.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gv100.c index feda86a5fba8..63daa83ae12d 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gv100.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/gv100.c @@ -42,9 +42,9 @@ gv100_fb = { }; int -gv100_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +gv100_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return gp102_fb_new_(&gv100_fb, device, index, pfb); + return gp102_fb_new_(&gv100_fb, device, type, inst, pfb); } MODULE_FIRMWARE("nvidia/gv100/nvdec/scrubber.bin"); diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/mcp77.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/mcp77.c index 73b3b86a2826..70c7b08ee0a6 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/mcp77.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/mcp77.c @@ -31,7 +31,7 @@ mcp77_fb = { }; int -mcp77_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +mcp77_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nv50_fb_new_(&mcp77_fb, device, index, pfb); + return nv50_fb_new_(&mcp77_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/mcp89.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/mcp89.c index 6d11e32ec7ad..308d955168e8 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/mcp89.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/mcp89.c @@ -31,7 +31,7 @@ mcp89_fb = { }; int -mcp89_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +mcp89_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nv50_fb_new_(&mcp89_fb, device, index, pfb); + return nv50_fb_new_(&mcp89_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv04.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv04.c index c886664533c8..8d5a007ecc47 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv04.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv04.c @@ -44,7 +44,7 @@ nv04_fb = { }; int -nv04_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv04_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv04_fb, device, index, pfb); + return nvkm_fb_new_(&nv04_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv10.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv10.c index c998b7e96aa3..7d2c16b27032 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv10.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv10.c @@ -64,7 +64,7 @@ nv10_fb = { }; int -nv10_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv10_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv10_fb, device, index, pfb); + return nvkm_fb_new_(&nv10_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv1a.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv1a.c index 7b9f04f44af8..4bdad2abd56f 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv1a.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv1a.c @@ -36,7 +36,7 @@ nv1a_fb = { }; int -nv1a_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv1a_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv1a_fb, device, index, pfb); + return nvkm_fb_new_(&nv1a_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv20.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv20.c index e5ddbe6b698e..d254f27f9b37 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv20.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv20.c @@ -96,7 +96,7 @@ nv20_fb = { }; int -nv20_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv20_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv20_fb, device, index, pfb); + return nvkm_fb_new_(&nv20_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv25.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv25.c index fb87e699ff54..47da66dea6e6 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv25.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv25.c @@ -54,7 +54,7 @@ nv25_fb = { }; int -nv25_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv25_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv25_fb, device, index, pfb); + return nvkm_fb_new_(&nv25_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv30.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv30.c index 6e033495fc1a..0f87efb636d5 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv30.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv30.c @@ -127,7 +127,7 @@ nv30_fb = { }; int -nv30_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv30_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv30_fb, device, index, pfb); + return nvkm_fb_new_(&nv30_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv35.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv35.c index 02a38d83c812..0694dcfd107e 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv35.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv35.c @@ -56,7 +56,7 @@ nv35_fb = { }; int -nv35_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv35_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv35_fb, device, index, pfb); + return nvkm_fb_new_(&nv35_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv36.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv36.c index f45143ebded3..1a39770372f1 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv36.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv36.c @@ -56,7 +56,7 @@ nv36_fb = { }; int -nv36_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv36_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv36_fb, device, index, pfb); + return nvkm_fb_new_(&nv36_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv40.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv40.c index f51ba70c673a..77dbb9d6ba48 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv40.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv40.c @@ -62,7 +62,7 @@ nv40_fb = { }; int -nv40_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv40_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv40_fb, device, index, pfb); + return nvkm_fb_new_(&nv40_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv41.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv41.c index b77f08d34cc3..0f9d9e48e7ad 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv41.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv41.c @@ -56,7 +56,7 @@ nv41_fb = { }; int -nv41_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv41_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv41_fb, device, index, pfb); + return nvkm_fb_new_(&nv41_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv44.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv44.c index b59dc486083d..b1046ee9f0ea 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv44.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv44.c @@ -65,7 +65,7 @@ nv44_fb = { }; int -nv44_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv44_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv44_fb, device, index, pfb); + return nvkm_fb_new_(&nv44_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv46.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv46.c index cab7d20fa039..0d78de422dfa 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv46.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv46.c @@ -51,7 +51,7 @@ nv46_fb = { }; int -nv46_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv46_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv46_fb, device, index, pfb); + return nvkm_fb_new_(&nv46_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv47.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv47.c index a8b0ad4c871d..5cedde29c8ee 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv47.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv47.c @@ -39,7 +39,7 @@ nv47_fb = { }; int -nv47_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv47_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv47_fb, device, index, pfb); + return nvkm_fb_new_(&nv47_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv49.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv49.c index d0b317bb0252..95cc099603d8 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv49.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv49.c @@ -39,7 +39,7 @@ nv49_fb = { }; int -nv49_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv49_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv49_fb, device, index, pfb); + return nvkm_fb_new_(&nv49_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv4e.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv4e.c index 6a6f0c086071..c9f3148f4e75 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv4e.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv4e.c @@ -37,7 +37,7 @@ nv4e_fb = { }; int -nv4e_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv4e_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nvkm_fb_new_(&nv4e_fb, device, index, pfb); + return nvkm_fb_new_(&nv4e_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv50.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv50.c index b2f5bf8144ea..95fd8f834010 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv50.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv50.c @@ -262,16 +262,15 @@ nv50_fb_ = { int nv50_fb_new_(const struct nv50_fb_func *func, struct nvkm_device *device, - int index, struct nvkm_fb **pfb) + enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { struct nv50_fb *fb; if (!(fb = kzalloc(sizeof(*fb), GFP_KERNEL))) return -ENOMEM; - nvkm_fb_ctor(&nv50_fb_, device, index, &fb->base); + nvkm_fb_ctor(&nv50_fb_, device, type, inst, &fb->base); fb->func = func; *pfb = &fb->base; - return 0; } @@ -283,7 +282,7 @@ nv50_fb = { }; int -nv50_fb_new(struct nvkm_device *device, int index, struct nvkm_fb **pfb) +nv50_fb_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, struct nvkm_fb **pfb) { - return nv50_fb_new_(&nv50_fb, device, index, pfb); + return nv50_fb_new_(&nv50_fb, device, type, inst, pfb); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv50.h b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv50.h index 5e2b0c9539ed..a5e673859a90 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv50.h +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/nv50.h @@ -17,6 +17,6 @@ struct nv50_fb_func { u32 trap; }; -int nv50_fb_new_(const struct nv50_fb_func *, struct nvkm_device *, int index, +int nv50_fb_new_(const struct nv50_fb_func *, struct nvkm_device *, enum nvkm_subdev_type, int, struct nvkm_fb **pfb); #endif diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/priv.h b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/priv.h index 66932ac10d15..3f1be9780c65 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/priv.h +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/priv.h @@ -38,9 +38,9 @@ struct nvkm_fb_func { }; void nvkm_fb_ctor(const struct nvkm_fb_func *, struct nvkm_device *device, - int index, struct nvkm_fb *); + enum nvkm_subdev_type type, int inst, struct nvkm_fb *); int nvkm_fb_new_(const struct nvkm_fb_func *, struct nvkm_device *device, - int index, struct nvkm_fb **); + enum nvkm_subdev_type type, int inst, struct nvkm_fb **); int nvkm_fb_bios_memtype(struct nvkm_bios *); void nv10_fb_tile_init(struct nvkm_fb *, int i, u32 addr, u32 size, @@ -78,7 +78,7 @@ int gm200_fb_init_page(struct nvkm_fb *); void gp100_fb_init_remapper(struct nvkm_fb *); void gp100_fb_init_unkn(struct nvkm_fb *); -int gp102_fb_new_(const struct nvkm_fb_func *, struct nvkm_device *, int, +int gp102_fb_new_(const struct nvkm_fb_func *, struct nvkm_device *, enum nvkm_subdev_type, int, struct nvkm_fb **); bool gp102_fb_vpr_scrub_required(struct nvkm_fb *); int gp102_fb_vpr_scrub(struct nvkm_fb *); |