Subject: Re: [[email-masked]: [PATCH] ethernet-bridge: update skb->priority in case forwarded frame has VLAN-header]

From: Patrick McHardy <[email-masked]>
Date: Sat, 05 Mar 2005 17:08:47 +0100

Lennert Buytenhek wrote:
> ----- Forwarded message from Leo Yuriev <[email-masked]> -----
> 
> From: Leo Yuriev <[email-masked]>
> To: Lennert Buytenhek <[email-masked]>,
> 	Alexey Kuznetsov <[email-masked]>
> Cc: [email-masked]
> Subject: [PATCH] ethernet-bridge: update skb->priority in case forwarded frame has VLAN-header
> 
> Kernel 2.6 (2.6.11)
> 
> When ethernet-bridge forward a packet and such ethernet-frame has
> VLAN-tag, bridge should update skb->prioriry for properly QoS
> handling.
> 
> This small patch does this. Currently vlan_TCI-priority directly
> mapped to skb->priority, but this looks enough.
> 
> Patch-by: Leo Yuriev <[email-masked]>

It needs to verify the tag is present and accessible using
pskb_may_pull(). But I think an ebtables target similar to the iptables
CLASSIFY target is a better place for this. It could allow setting
skb->priority to an arbitary value or derive it from vlan priority or IP
tos.

Regards
Patrick