tools/testing/selftests/kvm/lib/riscv/ucall.c

Source file repositories/reference/linux-study-clean/tools/testing/selftests/kvm/lib/riscv/ucall.c

File Facts

System
Linux kernel
Corpus path
tools/testing/selftests/kvm/lib/riscv/ucall.c
Extension
.c
Size
757 bytes
Lines
33
Domain
Support Tooling And Documentation
Bucket
tools
Inferred role
Support Tooling And Documentation: implementation source
Status
source implementation candidate

Why This File Exists

Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.

Dependency Surface

Detected Declarations

Annotated Snippet

switch (run->riscv_sbi.function_id) {
		case KVM_RISCV_SELFTESTS_SBI_UCALL:
			return (void *)run->riscv_sbi.args[0];
		case KVM_RISCV_SELFTESTS_SBI_UNEXP:
			vcpu_dump(stderr, vcpu, 2);
			TEST_ASSERT(0, "Unexpected trap taken by guest");
			break;
		default:
			break;
		}
	}
	return NULL;
}

Annotation

Implementation Notes