diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2020-12-02 08:35:30 +1000 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2021-02-11 11:49:52 +1000 |
commit | c288b4de94a874ef2c4f94fcdf9ad3e2163bc4ae (patch) | |
tree | 58d72c165f8950648b4883789b46ad4541a08e4c /drivers/gpu/drm/nouveau/nvkm/subdev | |
parent | f483253f3486f2e7c669e841aceb2ac95cbb9318 (diff) | |
download | linux-c288b4de94a874ef2c4f94fcdf9ad3e2163bc4ae.tar.bz2 |
drm/nouveau/acr: switch to instanced constructor
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nvkm/subdev')
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/acr/base.c | 4 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm200.c | 5 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm20b.c | 5 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp102.c | 5 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp108.c | 5 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp10b.c | 5 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/acr/priv.h | 4 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/acr/tu102.c | 5 |
8 files changed, 22 insertions, 16 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/base.c b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/base.c index c962df9910dd..af6cac696d43 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/base.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/base.c @@ -410,14 +410,14 @@ nvkm_acr_ctor_wpr(struct nvkm_acr *acr, int ver) int nvkm_acr_new_(const struct nvkm_acr_fwif *fwif, struct nvkm_device *device, - int index, struct nvkm_acr **pacr) + enum nvkm_subdev_type type, int inst, struct nvkm_acr **pacr) { struct nvkm_acr *acr; long wprfw; if (!(acr = *pacr = kzalloc(sizeof(*acr), GFP_KERNEL))) return -ENOMEM; - nvkm_subdev_ctor(&nvkm_acr, device, index, &acr->subdev); + nvkm_subdev_ctor(&nvkm_acr, device, type, inst, &acr->subdev); INIT_LIST_HEAD(&acr->hsfw); INIT_LIST_HEAD(&acr->lsfw); INIT_LIST_HEAD(&acr->hsf); diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm200.c b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm200.c index cd41b2e6cc87..8bff384a0bb7 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm200.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm200.c @@ -478,7 +478,8 @@ gm200_acr_fwif[] = { }; int -gm200_acr_new(struct nvkm_device *device, int index, struct nvkm_acr **pacr) +gm200_acr_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, + struct nvkm_acr **pacr) { - return nvkm_acr_new_(gm200_acr_fwif, device, index, pacr); + return nvkm_acr_new_(gm200_acr_fwif, device, type, inst, pacr); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm20b.c b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm20b.c index b1ecc58152cc..54e996f2f630 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm20b.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gm20b.c @@ -129,7 +129,8 @@ gm20b_acr_fwif[] = { }; int -gm20b_acr_new(struct nvkm_device *device, int index, struct nvkm_acr **pacr) +gm20b_acr_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, + struct nvkm_acr **pacr) { - return nvkm_acr_new_(gm20b_acr_fwif, device, index, pacr); + return nvkm_acr_new_(gm20b_acr_fwif, device, type, inst, pacr); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp102.c b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp102.c index 80eb9d8dbc80..fb9132a39bb1 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp102.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp102.c @@ -276,7 +276,8 @@ gp102_acr_fwif[] = { }; int -gp102_acr_new(struct nvkm_device *device, int index, struct nvkm_acr **pacr) +gp102_acr_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, + struct nvkm_acr **pacr) { - return nvkm_acr_new_(gp102_acr_fwif, device, index, pacr); + return nvkm_acr_new_(gp102_acr_fwif, device, type, inst, pacr); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp108.c b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp108.c index 67a7c141004b..373d638a2177 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp108.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp108.c @@ -106,7 +106,8 @@ gp108_acr_fwif[] = { }; int -gp108_acr_new(struct nvkm_device *device, int index, struct nvkm_acr **pacr) +gp108_acr_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, + struct nvkm_acr **pacr) { - return nvkm_acr_new_(gp108_acr_fwif, device, index, pacr); + return nvkm_acr_new_(gp108_acr_fwif, device, type, inst, pacr); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp10b.c b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp10b.c index 8249f0d2d81d..f03ba028867b 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp10b.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/gp10b.c @@ -52,7 +52,8 @@ gp10b_acr_fwif[] = { }; int -gp10b_acr_new(struct nvkm_device *device, int index, struct nvkm_acr **pacr) +gp10b_acr_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, + struct nvkm_acr **pacr) { - return nvkm_acr_new_(gp10b_acr_fwif, device, index, pacr); + return nvkm_acr_new_(gp10b_acr_fwif, device, type, inst, pacr); } diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/priv.h b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/priv.h index d71af17a169a..c30b841c9d35 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/priv.h +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/priv.h @@ -135,8 +135,8 @@ int gp102_acr_load_load(struct nvkm_acr *, struct nvkm_acr_hsfw *); extern const struct nvkm_acr_hsf_func gp108_acr_unload_0; void gp108_acr_hsfw_bld(struct nvkm_acr *, struct nvkm_acr_hsf *); -int nvkm_acr_new_(const struct nvkm_acr_fwif *, struct nvkm_device *, int, - struct nvkm_acr **); +int nvkm_acr_new_(const struct nvkm_acr_fwif *, struct nvkm_device *, enum nvkm_subdev_type, + int inst, struct nvkm_acr **); int nvkm_acr_hsf_boot(struct nvkm_acr *, const char *name); struct nvkm_acr_lsf { diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/tu102.c b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/tu102.c index c4981bce9a2b..05a87e77525f 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/acr/tu102.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/acr/tu102.c @@ -224,7 +224,8 @@ tu102_acr_fwif[] = { }; int -tu102_acr_new(struct nvkm_device *device, int index, struct nvkm_acr **pacr) +tu102_acr_new(struct nvkm_device *device, enum nvkm_subdev_type type, int inst, + struct nvkm_acr **pacr) { - return nvkm_acr_new_(tu102_acr_fwif, device, index, pacr); + return nvkm_acr_new_(tu102_acr_fwif, device, type, inst, pacr); } |