mirror of
https://github.com/torvalds/linux.git
synced 2026-05-25 23:52:08 +02:00
gpu: nova-core: gsp: derive Zeroable for GspStaticConfigInfo
We can now derive `Zeroable` on tuple structs, so do this instead of providing our own implementation. Reviewed-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Danilo Krummrich <dakr@kernel.org> Link: https://patch.msgid.link/20260217-nova-misc-v3-6-b4e2d45eafbc@nvidia.com Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
This commit is contained in:
parent
f86226d3c6
commit
8e10d462e6
|
|
@ -107,6 +107,7 @@ unsafe impl FromBytes for PackedRegistryTable {}
|
|||
|
||||
/// Payload of the `GetGspStaticInfo` command and message.
|
||||
#[repr(transparent)]
|
||||
#[derive(Zeroable)]
|
||||
pub(crate) struct GspStaticConfigInfo(bindings::GspStaticConfigInfo_t);
|
||||
|
||||
impl GspStaticConfigInfo {
|
||||
|
|
@ -122,7 +123,3 @@ unsafe impl AsBytes for GspStaticConfigInfo {}
|
|||
// SAFETY: This struct only contains integer types for which all bit patterns
|
||||
// are valid.
|
||||
unsafe impl FromBytes for GspStaticConfigInfo {}
|
||||
|
||||
// SAFETY: This struct only contains integer types and fixed-size arrays for which
|
||||
// all bit patterns are valid.
|
||||
unsafe impl Zeroable for GspStaticConfigInfo {}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user