> -----邮件原件-----
> 发件人: U-Boot <[email protected]> 代表 Marek Vasut
> 发送时间: 2025年10月26日 6:35
> 收件人: [email protected]
> 抄送: Marek Vasut <[email protected]>; Alice Guo
> <[email protected]>; Patrice Chotard <[email protected]>; Peng
> Fan <[email protected]>; Tom Rini <[email protected]>; Valentin Caron
> <[email protected]>; Ye Li <[email protected]>
> 主题: [PATCH] firmware: scmi: Fix up code comments
> 
> Fix multiple instances of copy-paste errors. Fill in missing headers for
> CLOCK_GET_PERMISSIONS message and response.
> 
> Signed-off-by: Marek Vasut <[email protected]>
> ---
> Cc: Alice Guo <[email protected]>
> Cc: Patrice Chotard <[email protected]>
> Cc: Peng Fan <[email protected]>
> Cc: Tom Rini <[email protected]>
> Cc: Valentin Caron <[email protected]>
> Cc: Ye Li <[email protected]>
> Cc: [email protected]
> ---
>  include/scmi_protocols.h | 10 ++++++----
>  1 file changed, 6 insertions(+), 4 deletions(-)
> 
> diff --git a/include/scmi_protocols.h b/include/scmi_protocols.h index
> ce767117570..c889f62424b 100644
> --- a/include/scmi_protocols.h
> +++ b/include/scmi_protocols.h
> @@ -751,13 +751,13 @@ enum scmi_clock_message_id {
>  #define SCMI_CLK_RATE_ROUND_UP               BIT(2)
>  #define SCMI_CLK_RATE_ROUND_CLOSEST  BIT(3)
> 
>  #define SCMI_CLOCK_NAME_LENGTH_MAX 16
> 
>  /**
> - * struct scmi_clk_get_nb_out - Response for SCMI_PROTOCOL_ATTRIBUTES
> command
> + * struct scmi_clk_protocol_attr_out - Response for
> + SCMI_PROTOCOL_ATTRIBUTES command
>   * @status:  SCMI command status
>   * @attributes:      Attributes of the clock protocol, mainly number of 
> clocks
> exposed
>   */
>  struct scmi_clk_protocol_attr_out {
>       s32 status;
>       u32 attributes;
> @@ -817,13 +817,13 @@ struct scmi_clk_state_in {
>   */
>  struct scmi_clk_state_out {
>       s32 status;
>  };
> 
>  /**
> - * struct scmi_clk_state_in - Message payload for CLOCK_RATE_GET command
> + * struct scmi_clk_rate_get_in - Message payload for CLOCK_RATE_GET
> + command
>   * @clock_id:        SCMI clock ID
>   * @attributes:      Attributes of the targets clock state
>   */
>  struct scmi_clk_rate_get_in {
>       u32 clock_id;
>  };
> @@ -838,13 +838,13 @@ struct scmi_clk_rate_get_out {
>       s32 status;
>       u32 rate_lsb;
>       u32 rate_msb;
>  };
> 
>  /**
> - * struct scmi_clk_state_in - Message payload for CLOCK_RATE_SET command
> + * struct scmi_clk_rate_set_in - Message payload for CLOCK_RATE_SET
> + command
>   * @flags:   Flags for the clock rate set request
>   * @clock_id:        SCMI clock ID
>   * @rate_lsb:        32bit LSB of the clock rate in Hertz
>   * @rate_msb:        32bit MSB of the clock rate in Hertz
>   */
>  struct scmi_clk_rate_set_in {
> @@ -860,13 +860,13 @@ struct scmi_clk_rate_set_in {
>   */
>  struct scmi_clk_rate_set_out {
>       s32 status;
>  };
> 
>  /**
> - * struct scmi_clk_parent_state_in - Message payload for CLOCK_PARENT_SET
> command
> + * struct scmi_clk_parent_set_in - Message payload for CLOCK_PARENT_SET
> + command
>   * @clock_id:                SCMI clock ID
>   * @parent_clk:              SCMI clock ID
>   */
>  struct scmi_clk_parent_set_in {
>       u32 clock_id;
>       u32 parent_clk;
> @@ -878,19 +878,21 @@ struct scmi_clk_parent_set_in {
>   */
>  struct scmi_clk_parent_set_out {
>       s32 status;
>  };
> 
>  /**
> + * struct scmi_clk_get_permissions_in - Message payload for
> + CLOCK_GET_PERMISSIONS command
>   * @clock_id:        Identifier for the clock device.
>   */
>  struct scmi_clk_get_permissions_in {
>       u32 clock_id;
>  };
> 
>  /**
> + * struct scmi_clk_get_permissions_out - Response payload for
> + CLOCK_GET_PERMISSIONS command
>   * @status:  Negative 32-bit integers are used to return error status codes.
>   * @permissions:     Bit[31] Clock state control, Bit[30] Clock parent 
> control,
>   * Bit[29] Clock rate control, Bits[28:0] Reserved, must be zero.
>   */
>  struct scmi_clk_get_permissions_out {
>       s32 status;
> --
> 2.51.0

Hi,

While reviewing include/scmi_protocols.h, I noticed that there are still a few 
functions and struct definitions whose names do not match their associated 
comments. For example: scmi_base_protocol_attrs, 
scmi_base_protocol_message_attrs, struct scmi_clk_attribute_out, struct 
scmi_clk_attribute_out_v2, struct scmi_pinctrl_config_set_in. I think the 
remaining inconsistencies should also be cleaned up.

Best regards,
Alice Guo

Reply via email to