From 5fa32145f1a59b0e1684d51ec82f505ba789c872 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Fri, 23 Nov 2007 15:24:26 -0500 Subject: [PATCH] Linux 2.2.22 Linux 2.2.22 is primarily an errata release backporting fixes for multiple small kernel errors found during auditing of the 2.4 code. 2.2 based users who have untrusted local users should update to this kernel. In addition the kernel fixes some bugs in the HDLC layer and adds support for the newest 3ware IDE RAID cards. Feature Updates - Support for newest 3ware IDE RAID - Set accessed time on AF_UNIX sockets Kernel Bug Fixes - Fix isofs over loopback in 2.2 - Send SIGIO on socket shutdown - Correct out of memory socket error reporting - Fix handling of buffer internal pointers in HDLC - Correct order of neighbour sending - Identify VIA C3 processors properly - Fix netlink/ipfw error handling path - Fix Alpha ptrace Security Fixes - Multiple numbers of potential sign handling, maths overflow and casting errors were fixed. Some of them are theoretically locally exploitable. No remote holes were found. --- Makefile | 2 +- drivers/net/hdlc.c | 12 +++++++++++- drivers/net/syncppp.c | 13 ++++++++++++- 3 files changed, 24 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 8226e28db811..008a61d089d7 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ VERSION = 2 PATCHLEVEL = 2 SUBLEVEL = 22 -EXTRAVERSION = rc3 +EXTRAVERSION = ARCH := $(shell uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ -e s/arm.*/arm/ -e s/sa110/arm/) diff --git a/drivers/net/hdlc.c b/drivers/net/hdlc.c index 2ac145a1198e..75e682be4ed4 100644 --- a/drivers/net/hdlc.c +++ b/drivers/net/hdlc.c @@ -19,6 +19,13 @@ * * Use sethdlc utility to set line parameters, protocol and PVCs */ + /* + Patched by Pavel Selivanov. 08 Aug. 2001 + If we are using dev_queue_xmit, and we have a listeners, + we should set skb->nh.raw. If no, we'll get a lot of warnings in + /var/log/debug + Look at core/net/dev.c dev_queue_xmit_nit +*/ #include #include @@ -103,6 +110,7 @@ static void cisco_keepalive_send(hdlc_device *hdlc, u32 type, skb_put(skb, sizeof(cisco_packet)); skb->priority=TC_PRIO_CONTROL; skb->dev = hdlc_to_dev(hdlc); + skb->nh.raw = skb->data; dev_queue_xmit(skb); } @@ -384,7 +392,8 @@ static void fr_lmi_send(hdlc_device *hdlc, int fullrep) skb_put(skb, i); skb->priority=TC_PRIO_CONTROL; skb->dev = hdlc_to_dev(hdlc); - + skb->nh.raw = skb->data; + dev_queue_xmit(skb); } @@ -820,6 +829,7 @@ static int pvc_xmit(struct sk_buff *skb, struct device *dev) { pvc_device *pvc=dev_to_pvc(dev); + skb->nh.raw = skb->data; if (pvc->state & PVC_STATE_ACTIVE) { skb->dev = hdlc_to_dev(pvc->master); pvc->stats.tx_bytes+=skb->len; diff --git a/drivers/net/syncppp.c b/drivers/net/syncppp.c index 4b0870e42e9f..1d658ff09948 100644 --- a/drivers/net/syncppp.c +++ b/drivers/net/syncppp.c @@ -16,7 +16,14 @@ * * Port for Linux-2.1 by Jan "Yenya" Kasprzak */ - + /* + Patched by Pavel Selivanov. 08 Aug. 2001 + If we are using dev_queue_xmit, and we have a listeners, + we should set skb->nh.raw. If no, we'll get a lot of warnings in + /var/log/debug + Look at core/net/dev.c dev_queue_xmit_nit +*/ + /* * Synchronous PPP/Cisco link level subroutines. * Keepalive protocol implemented in both Cisco and PPP modes. @@ -781,6 +788,8 @@ static void sppp_cp_send (struct sppp *sp, u16 proto, u8 type, /* Control is high priority so it doesnt get queued behind data */ skb->priority=TC_PRIO_CONTROL; skb->dev = dev; + skb->nh.raw = skb->data; + dev_queue_xmit(skb); } @@ -823,6 +832,8 @@ static void sppp_cisco_send (struct sppp *sp, int type, long par1, long par2) sp->obytes += skb->len; skb->priority=TC_PRIO_CONTROL; skb->dev = dev; + skb->nh.raw = skb->data; + dev_queue_xmit(skb); } -- 2.39.5