Subject: Re: [PATCH net-next 4/4] net_sched: act_vlan: Add priority option

From: Shmulik Ladkani <[email-masked]>
Date: Fri, 12 Aug 2016 11:18:42 +0300

Hi,

On Wed, 10 Aug 2016 16:32:23 +0300 Hadar Hen Zion <[email-masked]> wrote:
> @@ -181,7 +188,9 @@ static int tcf_vlan_dump(struct sk_buff *skb, struct tc_action *a,
>  	if (v->tcfv_action == TCA_VLAN_ACT_PUSH &&
>  	    (nla_put_u16(skb, TCA_VLAN_PUSH_VLAN_ID, v->tcfv_push_vid) ||
>  	     nla_put_be16(skb, TCA_VLAN_PUSH_VLAN_PROTOCOL,
> -			  v->tcfv_push_proto)))
> +			  v->tcfv_push_proto) ||
> +	     (v->tcfv_push_prio && nla_put_u8(skb, TCA_VLAN_PUSH_VLAN_PRIORITY,
> +					      v->tcfv_push_prio))))
>  		goto nla_put_failure;

nit: We could avoid the 'v->tcfv_push_prio' test, so user can explicitly
observe the associated priority, even if it is set to zero.

Reviewed-by: Shmulik Ladkani <[email-masked]>