05/10/2021 02:36, Ivan Malov:
> Introduce a helper API to let applications find transfer
> admin port for a given ethdev to avoid failures when
> managing "transfer" flows through unprivileged ports.

Please explain what is transfer admin port.
We may find a simpler wording.

> --- a/lib/ethdev/rte_flow.h
> +++ b/lib/ethdev/rte_flow.h
> +      *
> +      * Communicating "transfer" flows via unprivileged ethdevs may not
> +      * be possible. In order to pick the ethdev suitable for that, the

ethdev -> port

> +      * application should use @p rte_flow_pick_transfer_proxy().
>        */
>       uint32_t transfer:1;
[...]
> +/**

Please insert an one-line description here.

> + * An application receiving packets on a given ethdev may want to have their
> + * processing offloaded to the e-switch lying beneath this ethdev by means

Is "e-switch" a common word? Or should we say "embedded switch"?

> + * of maintaining "transfer" flows. However, it need never use this exact
> + * ethdev as an entry point for such flows to be managed through. More to
> + * that, this particular ethdev may be short of privileges to control the
> + * e-switch. Instead, the application should find an admin ethdev sitting
> + * on top of the same e-switch to be used as the entry point (a "proxy").

I recognize the nice right-alignment, but I think this text can be shorter.

> + *
> + * This API is a helper to find such "transfer proxy" for a given ethdev.
> + *
> + * @note
> + *   If the PMD serving @p port_id doesn't have the corresponding method
> + *   implemented, the API will return @p port_id via @p proxy_port_id.
> + *
> + * @param port_id
> + *   ID of the ethdev in question

The rest of the API says "port", not "ethdev".
Here I would suggest "ID of the port to look from."

> + * @param[out] proxy_port_id
> + *   ID of the "transfer proxy"
> + *
> + * @return
> + *   0 on success, a negative error code otherwise
> + */
> +__rte_experimental
> +int
> +rte_flow_pick_transfer_proxy(uint16_t port_id, uint16_t *proxy_port_id,
> +                          struct rte_flow_error *error);



Reply via email to