SOURCES (LINUX_2_6): linux-PF_RING.patch - user 2.6.27 api.
pluto
pluto at pld-linux.org
Mon Oct 20 12:17:42 CEST 2008
Author: pluto Date: Mon Oct 20 10:17:42 2008 GMT
Module: SOURCES Tag: LINUX_2_6
---- Log message:
- user 2.6.27 api.
---- Files affected:
SOURCES:
linux-PF_RING.patch (1.1.2.6 -> 1.1.2.7)
---- Diffs:
================================================================
Index: SOURCES/linux-PF_RING.patch
diff -u SOURCES/linux-PF_RING.patch:1.1.2.6 SOURCES/linux-PF_RING.patch:1.1.2.7
--- SOURCES/linux-PF_RING.patch:1.1.2.6 Fri Oct 17 11:31:14 2008
+++ SOURCES/linux-PF_RING.patch Mon Oct 20 12:17:36 2008
@@ -2630,12 +2630,12 @@
+ return;
+ }
+
-+ BUG_TRAP(!atomic_read(&sk->sk_rmem_alloc));
-+ BUG_TRAP(!atomic_read(&sk->sk_wmem_alloc));
++ BUG_ON(!atomic_read(&sk->sk_rmem_alloc));
++ BUG_ON(!atomic_read(&sk->sk_wmem_alloc));
+#else
+
-+ BUG_TRAP(atomic_read(&sk->rmem_alloc)==0);
-+ BUG_TRAP(atomic_read(&sk->wmem_alloc)==0);
++ BUG_ON(atomic_read(&sk->rmem_alloc)==0);
++ BUG_ON(atomic_read(&sk->wmem_alloc)==0);
+
+ if (!sk->dead) {
+#if defined(RING_DEBUG)
@@ -3288,7 +3288,7 @@
+ skb->data -= displ;
+
+ /* send it */
-+ if (pfr->reflector_dev->xmit_lock_owner != cpu) {
++ if (netdev_get_tx_queue(pfr->reflector_dev, 0)->xmit_lock_owner != cpu) {
+ /* Patch below courtesy of Matthew J. Roth <mroth at imminc.com> */
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
+ spin_lock_bh(&pfr->reflector_dev->xmit_lock);
@@ -3718,7 +3718,7 @@
+
+/* ********************************** */
+
-+static int ring_create(struct socket *sock, int protocol) {
++static int ring_create(struct net *net, struct socket *sock, int protocol) {
+ struct sock *sk;
+ struct ring_opt *pfr;
+ int err;
@@ -3751,7 +3751,7 @@
+#else
+ // BD: API changed in 2.6.12, ref:
+ // http://svn.clkao.org/svnweb/linux/revision/?rev=28201
-+ sk = sk_alloc(PF_RING, GFP_ATOMIC, &ring_proto, 1);
++ sk = sk_alloc(net, PF_RING, GFP_ATOMIC, &ring_proto);
+#endif
+#else
+ /* Kernel 2.4 */
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/linux-PF_RING.patch?r1=1.1.2.6&r2=1.1.2.7&f=u
More information about the pld-cvs-commit
mailing list