mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-22 17:36:20 +03:00
For safety build, nvgpu driver should enter SW quiesce state in case an uncorrectable error has occurred. In this state, any activity on the GPU should be prevented, without powering off the GPU. Also, a minimal set of operations should be used to enter SW quiesce state. Entering SW quiesce state does the following: - set sw_quiesce_pending: when this flag is set, interrupt handlers exit after masking interrupts. This should help mitigate an interrupt storm. - wake up thread to complete quiescing. The thread performs the following: - set NVGPU_DRIVER_IS_DYING to prevent allocation of new resources - disable interrupts - disable fifo scheduling - preempt all runlists - set error notifier for all active channels Note: for channels with usermode submit enabled, userspace can still ring doorbell, but this will not trigger any work on engines since fifo scheduling is disabled. Jira NVGPU-3493 Change-Id: I639a32da754d8833f54dcec1fa23135721d8d89a Signed-off-by: Thomas Fleury <tfleury@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2172391 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
38 lines
1.5 KiB
C
38 lines
1.5 KiB
C
/*
|
|
* Copyright (c) 2011-2018, NVIDIA CORPORATION. All rights reserved.
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify it
|
|
* under the terms and conditions of the GNU General Public License,
|
|
* version 2, as published by the Free Software Foundation.
|
|
*
|
|
* This program is distributed in the hope it will be useful, but WITHOUT
|
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
|
* more details.
|
|
*/
|
|
#ifndef __NVGPU_COMMON_LINUX_MODULE_H__
|
|
#define __NVGPU_COMMON_LINUX_MODULE_H__
|
|
|
|
struct gk20a;
|
|
struct device;
|
|
struct platform_device;
|
|
struct nvgpu_os_linux;
|
|
|
|
int gk20a_pm_finalize_poweron(struct device *dev);
|
|
int nvgpu_finalize_poweron_linux(struct nvgpu_os_linux *l);
|
|
void gk20a_remove_support(struct gk20a *g);
|
|
void gk20a_driver_start_unload(struct gk20a *g);
|
|
int nvgpu_quiesce(struct gk20a *g);
|
|
int nvgpu_remove(struct device *dev, struct class *class);
|
|
int nvgpu_wait_for_gpu_idle(struct gk20a *g);
|
|
void nvgpu_free_irq(struct gk20a *g);
|
|
struct device_node *nvgpu_get_node(struct gk20a *g);
|
|
void __iomem *nvgpu_devm_ioremap_resource(struct platform_device *dev, int i,
|
|
struct resource **out);
|
|
void __iomem *nvgpu_devm_ioremap(struct device *dev, resource_size_t offset,
|
|
resource_size_t size);
|
|
u64 nvgpu_resource_addr(struct platform_device *dev, int i);
|
|
extern struct class nvgpu_class;
|
|
void gk20a_init_linux_characteristics(struct gk20a *g);
|
|
#endif
|