GUI: Fix Tomato RAF theme for all builds. Compilation typo.
[tomato.git] / release / src-rt-6.x.4708 / linux / linux-2.6.36 / include / Common / Queue.h
blobe4c5bcf5d3da5f66f5976fad725cb70b62bb763f
1 /*
2 * Queue.h
4 *Copyright (C) 2010 Beceem Communications, Inc.
6 *This program is free software: you can redistribute it and/or modify
7 *it under the terms of the GNU General Public License version 2 as
8 *published by the Free Software Foundation.
10 *This program is distributed in the hope that it will be useful,but
11 *WITHOUT ANY WARRANTY; without even the implied warranty of
12 *MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13 *See the GNU General Public License for more details.
15 *You should have received a copy of the GNU General Public License
16 *along with this program. If not, write to the Free Software Foundation, Inc.,
17 *51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22 #ifndef __QUEUE_H__
23 #define __QUEUE_H__
27 #define ENQUEUEPACKET(_Head, _Tail,_Packet) \
28 do \
29 { \
30 if (!_Head) { \
31 _Head = _Packet; \
32 } \
33 else { \
34 (_Tail)->next = _Packet; \
35 } \
36 (_Packet)->next = NULL; \
37 _Tail = _Packet; \
38 }while(0)
39 #define DEQUEUEPACKET(Head, Tail ) \
40 do \
41 { if(Head) \
42 { \
43 if (!Head->next) { \
44 Tail = NULL; \
45 } \
46 Head = Head->next; \
47 } \
48 }while(0)
49 #endif //__QUEUE_H__