summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/nouveau/nvkm/engine/disp/ior.c
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2022-06-01 20:46:28 +1000
committerDave Airlie <airlied@redhat.com>2022-07-27 09:05:47 +1000
commit79c453af55d9f1e85b906211ea4051364d28dcb4 (patch)
treefbd5497d397d166f893f13603c8c32a5ebce28a8 /drivers/gpu/drm/nouveau/nvkm/engine/disp/ior.c
parent1c6aab75ece7c1d450e4561cb2263403eeb7ae2f (diff)
drm/nouveau/disp: replace hda func pointer check with flag
Simpler, and less error-prone than a separate set of function pointers. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Reviewed-by: Lyude Paul <lyude@redhat.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nvkm/engine/disp/ior.c')
-rw-r--r--drivers/gpu/drm/nouveau/nvkm/engine/disp/ior.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/ior.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/ior.c
index 1963cc183b87..e420bf2e4330 100644
--- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/ior.c
+++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/ior.c
@@ -55,7 +55,7 @@ nvkm_ior_del(struct nvkm_ior **pior)
int
nvkm_ior_new_(const struct nvkm_ior_func *func, struct nvkm_disp *disp,
- enum nvkm_ior_type type, int id)
+ enum nvkm_ior_type type, int id, bool hda)
{
struct nvkm_ior *ior;
if (!(ior = kzalloc(sizeof(*ior), GFP_KERNEL)))
@@ -64,6 +64,7 @@ nvkm_ior_new_(const struct nvkm_ior_func *func, struct nvkm_disp *disp,
ior->disp = disp;
ior->type = type;
ior->id = id;
+ ior->hda = hda;
snprintf(ior->name, sizeof(ior->name), "%s-%d", nvkm_ior_name[ior->type], ior->id);
list_add_tail(&ior->head, &disp->iors);
IOR_DBG(ior, "ctor");