svn commit: r254524 - head/sys/sys

Andre Oppermann andre at freebsd.org
Tue Aug 20 17:43:04 UTC 2013


On 19.08.2013 19:37, Navdeep Parhar wrote:
> On 08/19/13 06:56, Andre Oppermann wrote:
>> Author: andre
>> Date: Mon Aug 19 13:56:14 2013
>> New Revision: 254524
>> URL: http://svnweb.freebsd.org/changeset/base/254524
>>
>> Log:
>>    Add four additional M_PROTOFLAGS[9-12] for protocol specific use.
>>
>>    Discussed with:	trociny, glebius, adrian
>>
>> Modified:
>>    head/sys/sys/mbuf.h
>>
>> Modified: head/sys/sys/mbuf.h
>> ==============================================================================
>> --- head/sys/sys/mbuf.h	Mon Aug 19 13:27:32 2013	(r254523)
>> +++ head/sys/sys/mbuf.h	Mon Aug 19 13:56:14 2013	(r254524)
>> @@ -196,22 +196,24 @@ struct mbuf {
>>   #define	M_FRAG		0x00000800 /* packet is a fragment of a larger packet */
>>   #define	M_FIRSTFRAG	0x00001000 /* packet is first fragment */
>>   #define	M_LASTFRAG	0x00002000 /* packet is last fragment */
>> -		     /*	0x00004000    free */
>> -		     /*	0x00008000    free */
>> +#define	M_PROTO9	0x00004000 /* protocol-specific */
>> +#define	M_PROTO10	0x00008000 /* protocol-specific */
>>   #define	M_VLANTAG	0x00010000 /* ether_vtag is valid */
>>   #define	M_PROMISC	0x00020000 /* packet was not for us */
>> -		     /*	0x00040000    free */
>> +#define	M_PROTO11	0x00040000 /* protocol-specific */
>>   #define	M_PROTO6	0x00080000 /* protocol-specific */
>>   #define	M_PROTO7	0x00100000 /* protocol-specific */
>>   #define	M_PROTO8	0x00200000 /* protocol-specific */
>>   #define	M_FLOWID	0x00400000 /* deprecated: flowid is valid */
>> +#define	M_PROTO12	0x00800000 /* protocol-specific */
>>   #define	M_HASHTYPEBITS	0x0F000000 /* mask of bits holding flowid hash type */
>
> Why reuse the freed up bits so soon (at least one of which I think was
> prematurely GC'ed -- see my other email on M_NOFREE).  There was room
> beyond M_HASHTYPEBITS, no?

This is HEAD where kernel and modules have to be (re)compiled together
at any point in time.  On stable this reuse would not have been possible.

In a subsequent commit I compacted and ordered the flags.  There's a couple
of free ones remaining.

I have some additional mbuf changes coming up to be posted for possible
objections later today.  The close HEAD freeze deadline has got me rushed
a bit to allow 10.x backporting of the checksum/offload overhaul.

-- 
Andre



More information about the svn-src-head mailing list