On Wed, 08 Jul 2026 15:55:04 -0700 Bobby Eshleman wrote:
> diff --git a/Documentation/netlink/specs/netdev.yaml 
> b/Documentation/netlink/specs/netdev.yaml
> index 5f143da7458c..70b902008bd3 100644
> --- a/Documentation/netlink/specs/netdev.yaml
> +++ b/Documentation/netlink/specs/netdev.yaml
> @@ -598,6 +598,13 @@ attribute-sets:
>          type: u32
>          checks:
>            min: 1
> +      -
> +        name: rx-buf-size

rx-page-size, we're modeling device pages.
rx-buf-len exists in ethtool and is something else.

> +     if (info->attrs[NETDEV_A_DMABUF_RX_BUF_SIZE]) {
> +             u32 rx_buf_size = 
> nla_get_u32(info->attrs[NETDEV_A_DMABUF_RX_BUF_SIZE]);
> +
> +             if (!rx_buf_size || !is_power_of_2(rx_buf_size) ||
> +                 rx_buf_size < PAGE_SIZE) {

we should add a check: min: page-size in the Netlink policy?

> +                     NL_SET_ERR_MSG_FMT(info->extack,
> +                                        "rx_buf_size %u must be a power of 2 
> >= page size (%lu)",
> +                                        rx_buf_size, PAGE_SIZE);

This must point at _ATTR, the _FMT is unnecessary.
-- 
pw-bot: cr

Reply via email to