Subject: Re: [PATCH] PKT_SCHED: dsmark must take care of shared/cloned skbs

From: Patrick McHardy <[email-masked]>
Date: Mon, 20 Dec 2004 09:06:06 +0100

Thomas Graf wrote:
> * jamal <[email-masked]> 2004-12-19 15:23
> 
>>If the qdisc at that level muddies the packet thats fair game - thats
>>what goes out on the wire. So we should leave the code as is.
> 
> 
> Agreed for egress but I think it is needed for stuff like IMQ. It's
> debatable whether we should take care of IMQ and alike though.
> 

You shouldn't care about IMQ, but we still need to copy the packet
before modifying it if the data is shared. Otherwise we have a race
on SMP with AF_PACKET sockets, depending on when the packet is read
it can be either modified or not.

Converting dsmark to an action sounds like the best long-term solution.

Regards
Patrick