Files
nvdriver/tests/vm/gpu_close_fault.c
nvidia-driver-rs 4526e6a816 Baseline: validated 30/30 tree with passing Level 7 hardware regression
- Updated tools/post_reboot.sh to check kernel oops taint bit and stuck driver tasks instead of <86400s uptime
- Level 7 hardware regression passed on 0000:b3:00.0 (module 37e6fa430835eee2b426019db3ad70eeb7a9e9070c09c84bd9b973cf56cbe529, 107 inventory words, 0 static mismatches, CUDA baseline verified before and after)
- Updated .gitignore to exclude build archives (*.a, *.rlib), __pycache__, and raw trace dumps
2026-11-23 23:48:38 +00:00

13 lines
487 B
C

// Guest-only fault injection around the unchanged production DMA close body.
#include <linux/atomic.h>
#include <linux/errno.h>
#include "dma_adapter.h"
#undef nv_rs_dma_context_close
static atomic_t failures = ATOMIC_INIT(0);
void vm_gpu_fail_closes(unsigned int count) { atomic_set(&failures, count); }
int nv_rs_dma_context_close(struct nv_rs_dma_context *context)
{
if (atomic_dec_if_positive(&failures) >= 0) return -EBUSY;
return nv_rs_dma_context_close_inner(context);
}