|
XenevaOS
|
#include <asahi_drm.h>
struct drm_asahi_params_global - Global parameters.
This struct may be queried by drm_asahi_get_params.
| __u32 drm_asahi_params_global::chip_id |
@chip_id: Chip ID in BCD, e.g. 0x8103 for T8103
| __u64 drm_asahi_params_global::command_timestamp_frequency_hz |
@command_timestamp_frequency_hz: Timebase frequency for timestamps written during command execution, specified via drm_asahi_timestamp structures. As this rate is controlled by the firmware, it is a queryable parameter.
Userspace must divide by this frequency to convert timestamps to seconds, rather than hardcoding a particular firmware's rate.
| __u64 drm_asahi_params_global::core_masks[DRM_ASAHI_MAX_CLUSTERS] |
@core_masks: Bitmask of present/enabled cores per cluster
| __u64 drm_asahi_params_global::features |
@features: Feature bits from drm_asahi_feature
| __u32 drm_asahi_params_global::gpu_generation |
@gpu_generation: GPU generation, e.g. 13 for G13G
| __u32 drm_asahi_params_global::gpu_revision |
@gpu_revision: GPU revision in BCD, e.g. 0x00 for 'A0' or 0x21 for 'C1'
| __u32 drm_asahi_params_global::gpu_variant |
@gpu_variant: GPU variant as a character, e.g. 'C' for G13C
| __u32 drm_asahi_params_global::max_attachments |
@max_attachments: Maximum number of drm_asahi_attachment's per command
| __u32 drm_asahi_params_global::max_commands_per_submission |
@max_commands_per_submission: Maximum number of supported commands per submission. This mirrors firmware limits. Userspace must split up larger command buffers, which may require inserting additional synchronization.
| __u32 drm_asahi_params_global::max_frequency_khz |
@max_frequency_khz: Maximum GPU core clock frequency
| __u32 drm_asahi_params_global::num_clusters_total |
@num_clusters_total: Number of GPU clusters (across all dies)
| __u32 drm_asahi_params_global::num_cores_per_cluster |
@num_cores_per_cluster: Number of logical cores per cluster (including inactive/nonexistent)
| __u32 drm_asahi_params_global::num_dies |
@num_dies: Number of dies in the SoC
| __u64 drm_asahi_params_global::vm_end |
@vm_end: VM range end VMA
| __u64 drm_asahi_params_global::vm_kernel_min_size |
@vm_kernel_min_size: Minimum kernel VMA window size.
When creating a VM, userspace is required to carve out a section of virtual addresses (within the range given by @vm_start and @vm_end). The kernel will allocate various internal structures within the specified VA range.
Allowing userspace to choose the VA range for the kernel, rather than the kernel reserving VAs and requiring userspace to cope, can assist in implementing SVM.
| __u64 drm_asahi_params_global::vm_start |
@vm_start: VM range start VMA. Together with @vm_end, this defines the window of valid GPU VAs. Userspace is expected to subdivide VAs out of this window.
This window contains all virtual addresses that userspace needs to know about. There may be kernel-internal GPU VAs outside this range, but that detail is not relevant here.