Re: [PATCH net,v4] net: flow_offload: skip hw stats check for FLOW_ACTION_HW_STATS_DONT_CARE

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, May 07, 2020 at 11:38:24AM +0100, Edward Cree wrote:
> On 06/05/2020 19:34, Pablo Neira Ayuso wrote> -	} else if (act->hw_stats != FLOW_ACTION_HW_STATS_DISABLED) {
> > +	} else if (act->hw_stats != FLOW_ACTION_HW_STATS_DISABLED &&
> > +		   act->hw_stats != FLOW_ACTION_HW_STATS_DONT_CARE) {
> >  		NL_SET_ERR_MSG_MOD(extack, "Unsupported action HW stats type");
> >  		return -EOPNOTSUPP;
> >  	}
> FWIW my whole reason for suggesting DONT_CARE==0 in the first place
>  was so that drivers could just use it as a boolean, e.g.
>     if (act->hw_stats && !(act->hw_stats & FLOW_ACTION_HW_STATS_BLAH))
>         error("driver only supports BLAH stats");
>
> If you're not even doing that then the case for DONT_CARE == ~0 is
>  even stronger.

Could you point to what driver might have any problem with this update?

Thank you.



[Index of Archives]     [Netfitler Users]     [Berkeley Packet Filter]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux