From owner-freebsd-isdn Sat Jan 13 13:27:53 2001 Delivered-To: freebsd-isdn@freebsd.org Received: from liliput.tmp.com.br (liliput.tmp.com.br [200.244.62.12]) by hub.freebsd.org (Postfix) with ESMTP id CFE9B37B69E for ; Sat, 13 Jan 2001 13:27:34 -0800 (PST) Received: (from prallon@localhost) by liliput.tmp.com.br (8.8.8/8.8.8) id TAA03283; Sat, 13 Jan 2001 19:27:28 -0200 Date: Sat, 13 Jan 2001 19:27:28 -0200 From: Sergio de Souza Prallon To: Thomas Moestl Cc: freebsd-isdn@freebsd.org Subject: Re: [PATCH] isppp with uncompressed VJ packets broken in -CURRENT Message-ID: <20010113192727.A3058@tmp.com.br> References: <20010113205331.A2143@crow.dom2ip.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0i In-Reply-To: <20010113205331.A2143@crow.dom2ip.de>; from tmoestl@gmx.net on Sat, Jan 13, 2001 at 08:53:31PM +0100 X-URL: http://www.tmp.com.br Sender: owner-freebsd-isdn@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On Sat, Jan 13, 2001 at 08:53:31PM +0100, Thomas Moestl wrote: I believe it's my fault. The commit was part of my driver for the Tiger ASICs. The previous version (before the commit had a mistake that caused data corruption with my driver (itjc) and possibly others. The problem is present in my original diffs to 0.96 also, so I obviously made a mistake with the editor. Sorry for the inconvenience. -- Prallon > Hi, > > it seems that a commit to i4b/drivers/i4b_ispppsubr.c on 2000-01-12 has > broken the handling of uncompressed VJ packets. The attached diff should > hopefully fix that. > >From what I can tell, the second call to sl_uncompress_tcp_core needs > the TYPE_UNCOMPRESSED_TCP flag (as it was before the commit). > Additionally, sl_uncompress_core may return 0 if the packet was > uncompressed previously, so this is no error condition. > The first call (not visible in the diff) is IMHO correct as it is, > because the 0 return value should not happen. > The second call should always return 0, so I check explicitely for > it (other cases are not handled anyway). > > Could someone please review/comment/commit this? > > - thomas > *** sys/i4b/driver/i4b_ispppsubr.c.orig Sat Jan 13 12:30:20 2001 > --- sys/i4b/driver/i4b_ispppsubr.c Sat Jan 13 20:08:11 2001 > *************** > *** 580,587 **** > int hlen, vjlen; > > if ((vjlen = sl_uncompress_tcp_core(m->m_data, > ! m->m_len, m->m_len, TYPE_COMPRESSED_TCP, > ! &sp->pp_comp, &iphdr, &hlen)) <= 0) > goto drop; > > schednetisr (NETISR_IP); > --- 580,587 ---- > int hlen, vjlen; > > if ((vjlen = sl_uncompress_tcp_core(m->m_data, > ! m->m_len, m->m_len, TYPE_UNCOMPRESSED_TCP, > ! &sp->pp_comp, &iphdr, &hlen)) != 0) > goto drop; > > schednetisr (NETISR_IP); To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isdn" in the body of the message