drm/nouveau/bios/init: handle INIT_RESET_END devinit opcode
authorRhys Kidd <rhyskidd@gmail.com>
Sun, 2 Jun 2019 14:13:15 +0000 (00:13 +1000)
committerBen Skeggs <bskeggs@redhat.com>
Fri, 23 Aug 2019 02:55:32 +0000 (12:55 +1000)
Signal that the reset sequence has completed.

This opcode signals that the software reset sequence has completed.
Ordinarily, no actual operations are performed by the opcode.
However it allows for possible software work arounds by devinit
engines in software agents other than the VBIOS, such as the resman,
FCODE, and EFI driver.

Signed-off-by: Rhys Kidd <rhyskidd@gmail.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/nvkm/subdev/bios/init.c

index 5e02832304e2152d4d66d86758a2f722d903de87..9de74f41dcd2a89087c6a38b32d8121e4606295b 100644 (file)
@@ -1945,6 +1945,17 @@ init_reset_begun(struct nvbios_init *init)
        init->offset += 1;
 }
 
+/**
+ * INIT_RESET_END - opcode 0x8d
+ *
+ */
+static void
+init_reset_end(struct nvbios_init *init)
+{
+       trace("RESET_END\n");
+       init->offset += 1;
+}
+
 /**
  * INIT_GPIO - opcode 0x8e
  *
@@ -2272,7 +2283,7 @@ static struct nvbios_init_opcode {
        [0x7a] = { init_zm_reg },
        [0x87] = { init_ram_restrict_pll },
        [0x8c] = { init_reset_begun },
-       [0x8d] = { init_reserved },
+       [0x8d] = { init_reset_end },
        [0x8e] = { init_gpio },
        [0x8f] = { init_ram_restrict_zm_reg_group },
        [0x90] = { init_copy_zm_reg },