On Tue, Jun 30, 2020 at 12:24:10PM +0300, Amit Cohen wrote:
> Add ETHTOOL_A_LINKSTATE_EXT_STATE to expose general extended state.
> 
> Add ETHTOOL_A_LINKSTATE_EXT_SUBSTATE to expose more information in
> addition to the extended state.
> 
> Signed-off-by: Amit Cohen <am...@mellanox.com>
> ---
>  netlink/desc-ethtool.c       | 2 ++
>  uapi/linux/ethtool_netlink.h | 2 ++
>  2 files changed, 4 insertions(+)
> 
> diff --git a/netlink/desc-ethtool.c b/netlink/desc-ethtool.c
> index 98b898e..bce22e2 100644
> --- a/netlink/desc-ethtool.c
> +++ b/netlink/desc-ethtool.c
> @@ -95,6 +95,8 @@ static const struct pretty_nla_desc __linkstate_desc[] = {
>       NLATTR_DESC_BOOL(ETHTOOL_A_LINKSTATE_LINK),
>       NLATTR_DESC_U32(ETHTOOL_A_LINKSTATE_SQI),
>       NLATTR_DESC_U32(ETHTOOL_A_LINKSTATE_SQI_MAX),
> +     NLATTR_DESC_U8(ETHTOOL_A_LINKSTATE_EXT_STATE),
> +     NLATTR_DESC_U8(ETHTOOL_A_LINKSTATE_EXT_SUBSTATE),
>  };
>  
>  static const struct pretty_nla_desc __debug_desc[] = {
> diff --git a/uapi/linux/ethtool_netlink.h b/uapi/linux/ethtool_netlink.h
> index b18e7bc..0922ca6 100644
> --- a/uapi/linux/ethtool_netlink.h
> +++ b/uapi/linux/ethtool_netlink.h
> @@ -236,6 +236,8 @@ enum {
>       ETHTOOL_A_LINKSTATE_LINK,               /* u8 */
>       ETHTOOL_A_LINKSTATE_SQI,                /* u32 */
>       ETHTOOL_A_LINKSTATE_SQI_MAX,            /* u32 */
> +     ETHTOOL_A_LINKSTATE_EXT_STATE,          /* u8 */
> +     ETHTOOL_A_LINKSTATE_EXT_SUBSTATE,       /* u8 */
>  
>       /* add new constants above here */
>       __ETHTOOL_A_LINKSTATE_CNT,

Please do not mix uapi header updates with other changes. Once the
kernel counterpart is in net-next, update all headers in uapi/ to
a net-next snapshot as described at

  https://www.kernel.org/pub/software/network/ethtool/devel.html

and use that as first commit of your series.

Michal

Reply via email to