Deleted Added
full compact
cxgb_osdep.h (185162) cxgb_osdep.h (185199)
1/**************************************************************************
2
3Copyright (c) 2007, Chelsio Inc.
4All rights reserved.
5
6Redistribution and use in source and binary forms, with or without
7modification, are permitted provided that the following conditions are met:
8

--- 12 unchanged lines hidden (view full) ---

21CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
23INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
24CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
26POSSIBILITY OF SUCH DAMAGE.
27
28
1/**************************************************************************
2
3Copyright (c) 2007, Chelsio Inc.
4All rights reserved.
5
6Redistribution and use in source and binary forms, with or without
7modification, are permitted provided that the following conditions are met:
8

--- 12 unchanged lines hidden (view full) ---

21CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
23INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
24CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
26POSSIBILITY OF SUCH DAMAGE.
27
28
29$FreeBSD: head/sys/dev/cxgb/cxgb_osdep.h 185162 2008-11-22 05:55:56Z kmacy $
29$FreeBSD: head/sys/dev/cxgb/cxgb_osdep.h 185199 2008-11-23 07:30:07Z kmacy $
30
31***************************************************************************/
32
33#include <sys/param.h>
34#include <sys/systm.h>
35#include <sys/ctype.h>
36#include <sys/endian.h>
37#include <sys/bus.h>

--- 74 unchanged lines hidden (view full) ---

112#if __FreeBSD_version >= 701000
113#include "opt_inet.h"
114#ifdef INET
115#define LRO_SUPPORTED
116#endif
117#define TOE_SUPPORTED
118#endif
119
30
31***************************************************************************/
32
33#include <sys/param.h>
34#include <sys/systm.h>
35#include <sys/ctype.h>
36#include <sys/endian.h>
37#include <sys/bus.h>

--- 74 unchanged lines hidden (view full) ---

112#if __FreeBSD_version >= 701000
113#include "opt_inet.h"
114#ifdef INET
115#define LRO_SUPPORTED
116#endif
117#define TOE_SUPPORTED
118#endif
119
120#if __FreeBSD_version < 800054
121#if defined (__GNUC__)
122 #if #cpu(i386) || defined __i386 || defined i386 || defined __i386__ || #cpu(x86_64) || defined __x86_64__
123 #define mb() __asm__ __volatile__ ("mfence;": : :"memory")
124 #define wmb() __asm__ __volatile__ ("sfence;": : :"memory")
125 #define rmb() __asm__ __volatile__ ("lfence;": : :"memory")
126 #elif #cpu(sparc64) || defined sparc64 || defined __sparcv9
127 #define mb() __asm__ __volatile__ ("membar #MemIssue": : :"memory")
128 #define wmb() mb()
129 #define rmb() mb()
130 #elif #cpu(sparc) || defined sparc || defined __sparc__
131 #define mb() __asm__ __volatile__ ("stbar;": : :"memory")
132 #define wmb() mb()
133 #define rmb() mb()
134#else
135 #define wmb() mb()
136 #define rmb() mb()
137 #define mb() /* XXX just to make this compile */
138 #endif
139#else
140 #error "unknown compiler"
141#endif
142#endif
143
120#define __read_mostly __attribute__((__section__(".data.read_mostly")))
121
122/*
123 * Workaround for weird Chelsio issue
124 */
125#if __FreeBSD_version > 700029
126#define PRIV_SUPPORTED
127#endif

--- 219 unchanged lines hidden ---
144#define __read_mostly __attribute__((__section__(".data.read_mostly")))
145
146/*
147 * Workaround for weird Chelsio issue
148 */
149#if __FreeBSD_version > 700029
150#define PRIV_SUPPORTED
151#endif

--- 219 unchanged lines hidden ---