On 9/4/2023 5:56 AM, [email protected] wrote:
> From: Renyong Wan <[email protected]>
>
> Signed-off-by: Steven Song <[email protected]>
> Signed-off-by: Renyong Wan <[email protected]>
>
<...>
> +static inline int
> +sssnic_ethdev_tx_offload_check(struct rte_mbuf *tx_mbuf,
> + struct sssnic_ethdev_tx_info *tx_info)
> +{
> + uint64_t ol_flags = tx_mbuf->ol_flags;
> +
> + if ((ol_flags & SSSNIC_ETHDEV_TX_OFFLOAD_MASK) == 0) {
> + tx_info->offload_en = 0;
> + return 0;
> + }
> +
> +#ifdef RTE_LIBRTE_ETHDEV_DEBUG
> + if (rte_validate_tx_offload(tx_mbuf) != 0) {
> + SSSNIC_TX_LOG(ERR, "Bad tx mbuf offload flags: %" PRIx64,
> ol_flags);
> + return -EINVAL;
> + }
> +#endif
>
'RTE_LIBRTE_ETHDEV_DEBUG' kept as backward compatibilty alias, better to
prefer fine grained RTE_ETHDEV_DEBUG_TX.