[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <58715579-1dc4-acc7-0cd4-870f1cd1f579@quicinc.com>
Date: Fri, 13 Dec 2024 09:55:42 -0700
From: Jeffrey Hugo <quic_jhugo@...cinc.com>
To: Lizhi Hou <lizhi.hou@....com>, <ogabbay@...nel.org>,
<dri-devel@...ts.freedesktop.org>
CC: <linux-kernel@...r.kernel.org>, <min.ma@....com>, <max.zhen@....com>,
<sonal.santan@....com>, <king.tam@....com>,
<mario.limonciello@....com>,
Narendra Gutta <VenkataNarendraKumar.Gutta@....com>,
George Yang
<George.Yang@....com>
Subject: Re: [PATCH V2 6/8] accel/amdxdna: Enhance power management settings
On 12/6/2024 2:59 PM, Lizhi Hou wrote:
> +/**
> + * struct amdxdna_drm_get_power_mode - Get the configured power mode
> + * @power_mode: The mode type from enum amdxdna_power_mode_type
> + * @pad: MBZ.
I don't see a check for zero in the implementation
> + */
> +struct amdxdna_drm_get_power_mode {
> + __u8 power_mode;
> + __u8 pad[7];
> +};
> +
> /**
> * struct amdxdna_drm_query_firmware_version - Query the firmware version
> * @major: The major version number
> @@ -397,6 +416,7 @@ enum amdxdna_drm_get_param {
> DRM_AMDXDNA_QUERY_SENSORS,
> DRM_AMDXDNA_QUERY_HW_CONTEXTS,
> DRM_AMDXDNA_QUERY_FIRMWARE_VERSION = 8,
> + DRM_AMDXDNA_GET_POWER_MODE,
> };
>
> /**
> @@ -411,6 +431,34 @@ struct amdxdna_drm_get_info {
> __u64 buffer; /* in/out */
> };
>
> +enum amdxdna_drm_set_param {
> + DRM_AMDXDNA_SET_POWER_MODE,
> + DRM_AMDXDNA_WRITE_AIE_MEM,
> + DRM_AMDXDNA_WRITE_AIE_REG,
> +};
> +
> +/**
> + * struct amdxdna_drm_set_state - Set the state of the AIE hardware.
> + * @param: Value in enum amdxdna_drm_set_param.
> + * @buffer_size: Size of the input param.
> + * @buffer: Input param.
Is this a pointer address? Maybe clarify that?
> + */
> +struct amdxdna_drm_set_state {
> + __u32 param; /* in */
> + __u32 buffer_size; /* in */
> + __u64 buffer; /* in */
> +};
> +
> +/**
> + * struct amdxdna_drm_set_power_mode - Set the power mode of the AIE hardware
> + * @power_mode: The sensor type from enum amdxdna_power_mode_type
> + * @pad: MBZ.
I don't see a check for zero in the implementation.
Powered by blists - more mailing lists