mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-22 17:36:20 +03:00
Currently, we just deinitialize the nvlink in the shutdown path. This alone is not sufficient and can lead to someone trying to use dGPU while being shutdown. Avoid triggers to dGPU usage by - 1. Set NVGPU_DRIVER_IS_DYING to let users know that the driver is currently in the process of dying. 2. Disable IRQs 3. Prepare for poweroff using nvgpu_prepare_poweroff 4. Stop CPU from accessing GPU registers 5. Set GPU state to POWEROFF Bug 200601517 JIRA NVGPU-5991 Change-Id: Ie185516618678bb893bcc3c3dcb514701483ecf2 Signed-off-by: Tejal Kudav <tkudav@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2393565 Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: automaticguardword <automaticguardword@nvidia.com>