diff options
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gk20a.c | 1 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gk20a.h | 1 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/pci.c | 4 |
3 files changed, 5 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.c b/drivers/gpu/nvgpu/gk20a/gk20a.c index 91c82104..79c3fd09 100644 --- a/drivers/gpu/nvgpu/gk20a/gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gk20a.c | |||
@@ -1098,6 +1098,7 @@ int gk20a_pm_finalize_poweron(struct device *dev) | |||
1098 | enable_irq(g->irq_stall); | 1098 | enable_irq(g->irq_stall); |
1099 | if (g->irq_stall != g->irq_nonstall) | 1099 | if (g->irq_stall != g->irq_nonstall) |
1100 | enable_irq(g->irq_nonstall); | 1100 | enable_irq(g->irq_nonstall); |
1101 | g->irqs_enabled = 1; | ||
1101 | 1102 | ||
1102 | if (g->ops.xve.available_speeds) { | 1103 | if (g->ops.xve.available_speeds) { |
1103 | u32 speed; | 1104 | u32 speed; |
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.h b/drivers/gpu/nvgpu/gk20a/gk20a.h index 196af3c1..31b02378 100644 --- a/drivers/gpu/nvgpu/gk20a/gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/gk20a.h | |||
@@ -990,6 +990,7 @@ struct gk20a { | |||
990 | 990 | ||
991 | struct gpu_ops ops; | 991 | struct gpu_ops ops; |
992 | 992 | ||
993 | int irqs_enabled; | ||
993 | int irq_stall; /* can be same as irq_nonstall in case of PCI */ | 994 | int irq_stall; /* can be same as irq_nonstall in case of PCI */ |
994 | int irq_nonstall; | 995 | int irq_nonstall; |
995 | u32 max_ltc_count; | 996 | u32 max_ltc_count; |
diff --git a/drivers/gpu/nvgpu/pci.c b/drivers/gpu/nvgpu/pci.c index a81090a2..3677b02d 100644 --- a/drivers/gpu/nvgpu/pci.c +++ b/drivers/gpu/nvgpu/pci.c | |||
@@ -439,7 +439,9 @@ static void nvgpu_pci_remove(struct pci_dev *pdev) | |||
439 | gk20a_dbg(gpu_dbg_shutdown, "Removing nvgpu driver!\n"); | 439 | gk20a_dbg(gpu_dbg_shutdown, "Removing nvgpu driver!\n"); |
440 | gk20a_driver_start_unload(g); | 440 | gk20a_driver_start_unload(g); |
441 | 441 | ||
442 | disable_irq(g->irq_stall); | 442 | if (g->irqs_enabled) |
443 | disable_irq(g->irq_stall); | ||
444 | |||
443 | devm_free_irq(&pdev->dev, g->irq_stall, g); | 445 | devm_free_irq(&pdev->dev, g->irq_stall, g); |
444 | 446 | ||
445 | #if defined(CONFIG_PCI_MSI) | 447 | #if defined(CONFIG_PCI_MSI) |