From: Richard Purdie <rpurdie@rpsys.net>
To: Stefan Wenk <stefan.wenk@gmx.at>
Cc: Andrew Morton <akpm@linux-foundation.org>,
netdev@vger.kernel.org,
"bugme-daemon@kernel-bugs.osdl.org"
<bugme-daemon@bugzilla.kernel.org>
Subject: Re: [Bugme-new] [Bug 8405] New: pppd does stops compresion with "Lost compression sync"
Date: Tue, 01 May 2007 22:22:40 +0100 [thread overview]
Message-ID: <1178054560.5883.87.camel@localhost.localdomain> (raw)
In-Reply-To: <200705010927.52426.stefan.wenk@gmx.at>
On Tue, 2007-05-01 at 09:27 +0200, Stefan Wenk wrote:
> Now I have changed these modifications
> back, and I do not see more debug information except those below:
>
> z_decompress0: Would have triggered an error as inflate returned -5 ()
> z_decompress0: Would have triggered an error as inflate returned -5 ()
> z_decompress0: Would have triggered an error as inflate returned -5 ()
> ..
> As there are no debug logs in inflate.c I can't provide more information by
> now.
I had a look at that trace you sent, the echo and replys were normal but
obviously something is going wrong and it tries to negotiate turning off
the compression...
Having looked at the code a bit further, I have a theory that it was
impossible to reach the zlib_inflateSyncPacket call ppp deflate needs.
The patch below fixes that and also adds some debugging so if that isn't
the problem, we might get some further clues as to what the problem
is...
Thanks for the patience :)
Richard
Index: linux/drivers/net/ppp_deflate.c
===================================================================
--- linux.orig/drivers/net/ppp_deflate.c 2007-01-18 00:52:50.000000000 +0000
+++ linux/drivers/net/ppp_deflate.c 2007-05-01 22:21:27.000000000 +0100
@@ -488,6 +488,13 @@ int z_decompress(void *arg, unsigned cha
for (;;) {
r = zlib_inflate(&state->strm, Z_PACKET_FLUSH);
if (r != Z_OK) {
+ printk(KERN_ERR "z_decompress%d: inflate returned %d (%s)"
+ ",av in %d, av out %d, t in %ld, t out %ld, dp %d,"
+ " of %d, is %d, os %d\n",
+ state->unit, r, (state->strm.msg? state->strm.msg: ""),
+ state->strm.avail_in, state->strm.avail_out,
+ state->strm.total_in, state->strm.total_out,
+ decode_proto, overflow, isize, osize);
if (state->debug)
printk(KERN_DEBUG "z_decompress%d: inflate returned %d (%s)\n",
state->unit, r, (state->strm.msg? state->strm.msg: ""));
Index: linux/lib/zlib_inflate/inflate.c
===================================================================
--- linux.orig/lib/zlib_inflate/inflate.c 2007-01-18 00:53:08.000000000 +0000
+++ linux/lib/zlib_inflate/inflate.c 2007-05-01 22:03:53.000000000 +0100
@@ -743,12 +743,14 @@ int zlib_inflate(z_streamp strm, int flu
strm->data_type = state->bits + (state->last ? 64 : 0) +
(state->mode == TYPE ? 128 : 0);
- if (((in == 0 && out == 0) || flush == Z_FINISH) && ret == Z_OK)
- ret = Z_BUF_ERROR;
if (flush == Z_PACKET_FLUSH && ret == Z_OK &&
(strm->avail_out != 0 || strm->avail_in == 0))
return zlib_inflateSyncPacket(strm);
+
+ if (((in == 0 && out == 0) || flush == Z_FINISH) && ret == Z_OK)
+ ret = Z_BUF_ERROR;
+
return ret;
}
next prev parent reply other threads:[~2007-05-01 21:23 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200704292001.l3TK1P6d000716@fire-2.osdl.org>
2007-04-29 21:20 ` [Bugme-new] [Bug 8405] New: pppd does stops compresion with "Lost compression sync" Andrew Morton
2007-04-30 12:08 ` Stefan Wenk
2007-04-30 13:31 ` Richard Purdie
2007-04-30 19:12 ` Stefan Wenk
2007-05-01 3:20 ` Stefan Wenk
2007-05-01 3:36 ` Andrew Morton
2007-05-01 7:27 ` Stefan Wenk
2007-05-01 21:22 ` Richard Purdie [this message]
2007-05-02 16:59 ` Stefan Wenk
2007-05-03 0:23 ` Richard Purdie
2007-05-03 17:18 ` Stefan Wenk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1178054560.5883.87.camel@localhost.localdomain \
--to=rpurdie@rpsys.net \
--cc=akpm@linux-foundation.org \
--cc=bugme-daemon@bugzilla.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=stefan.wenk@gmx.at \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).