mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Torsten Kaiser" <just.for.lkml@googlemail.com>
To: "J. Bruce Fields" <bfields@fieldses.org>
Cc: "Herbert Xu" <herbert@gondor.apana.org.au>,
	"Andrew Morton" <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org, "Neil Brown" <neilb@suse.de>,
	netdev@vger.kernel.org, "Tom Tucker" <tom@opengridcomputing.com>
Subject: Re: 2.6.24-rc6-mm1
Date: Thu, 3 Jan 2008 06:02:49 +0100	[thread overview]
Message-ID: <64bb37e0801022102n54d85772p698055dd83b34d7c@mail.gmail.com> (raw)
In-Reply-To: <20080102215706.GB6480@fieldses.org>

On Jan 2, 2008 10:57 PM, J. Bruce Fields <bfields@fieldses.org> wrote:
> On Thu, Jan 03, 2008 at 08:51:54AM +1100, Herbert Xu wrote:
> > On Wed, Jan 02, 2008 at 07:29:59PM +0100, Torsten Kaiser wrote:
> > >
> > > Vanilla 2.6.24-rc6 seems stable. I did not see any crash or warnings.
> >
> > OK that's great.  The next step would be to try excluding specific git
> > trees from mm to see if they make a difference.
> >
> > The two specific trees of interest would be git-nfsd and git-net.
>
> Also, if it's git-nfsd, it'd be useful to test with the current git-nfsd
> from the for-mm branch at:
>
>         git://linux-nfs.org/~bfields/linus.git for-mm
>
> and then any bisection results (even partial) from that tree would help
> immensely....

The problem with that is, that triggering the bug is not easy so
marking anything 'good' is questionable.
This time I needed to compile over 50 packages until it triggered.

I was using 2.6.24-rc6-mm1 again, but with a crude hack (see end of
mail) that I hope should catch any double-frees of skbs.
None of my warnings triggered, only a list corruption again in
svc_xprt_enqueue(), but this time with an additional output about
whats wrong with the list:
[17023.029519] list_add corruption. prev->next should be next
(ffff8100d20ec1c8), but was ffff81009c5a6
c28. (prev=ffff81009c5a6c28).
[17023.029537] ------------[ cut here ]------------
[17023.031445] kernel BUG at lib/list_debug.c:33!
[17023.033280] invalid opcode: 0000 [1] SMP
[17023.034967] last sysfs file:
/sys/devices/system/cpu/cpu3/cache/index2/shared_cpu_map
[17023.038209] CPU 3
[17023.039047] Modules linked in: radeon drm w83792d ipv6 tuner
tea5767 tda8290 tuner_xc2028 tda9887 tu
ner_simple mt20xx tea5761 tvaudio msp3400 bttv ir_common
compat_ioctl32 videobuf_dma_sg videobuf_core b
tcx_risc usbhid tveeprom videodev hid v4l2_common v4l1_compat sg
pata_amd i2c_nforce2
[17023.039519] Pid: 20564, comm: nfsv4-svc Not tainted 2.6.24-rc6-mm1 #14
[17023.039519] RIP: 0010:[<ffffffff803bd834>]  [<ffffffff803bd834>]
__list_add+0x54/0x60
[17023.039519] RSP: 0018:ffff8101002c9dc0  EFLAGS: 00010282
[17023.039519] RAX: 0000000000000088 RBX: ffff810110125c00 RCX: 0000000000000000
[17023.039519] RDX: ffff81010067c000 RSI: 0000000000000001 RDI: ffffffff80764140
[17023.039519] RBP: ffff8101002c9dc0 R08: 0000000000000001 R09: 0000000000000000
[17023.039519] R10: ffff81000100a088 R11: 0000000000000001 R12: ffff8100d20ec180
[17023.039519] R13: ffff8100d20ec1b8 R14: ffff8100d20ec1b8 R15: ffff8101188e4600
[17023.039519] FS:  00007ff7a870c6f0(0000) GS:ffff81011ff0cd00(0000)
knlGS:0000000000000000
[17023.039519] CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
[17023.039519] CR2: 00000000024df510 CR3: 0000000032539000 CR4: 00000000000006e0
[17023.039519] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[17023.039519] DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
[17023.039519] Process nfsv4-svc (pid: 20564, threadinfo
ffff8101002c8000, task ffff81010067c000)
[17023.039519] Stack:  ffff8101002c9e00 ffffffff805c18ab
ffff8100d20ec188 ffff8101188e4600
[17023.039519]  ffff81009c5a6c00 ffff81010d118000 ffff810110125c00
ffff8101188e4610
[17023.039519]  ffff8101002c9e10 ffffffff805c1997 ffff8101002c9ee0
ffffffff805c2ac4
[17023.039519] Call Trace:
[17023.039519]  [<ffffffff805c18ab>] svc_xprt_enqueue+0x1ab/0x240
[17023.039519]  [<ffffffff805c1997>] svc_xprt_received+0x17/0x20
[17023.039519]  [<ffffffff805c2ac4>] svc_recv+0x394/0x7c0
[17023.039519]  [<ffffffff805c1ece>] svc_send+0xae/0xd0
[17023.039519]  [<ffffffff802305f0>] default_wake_function+0x0/0x10
[17023.039519]  [<ffffffff803178b9>] nfs_callback_svc+0x79/0x130
[17023.039519]  [<ffffffff80232a67>] finish_task_switch+0x67/0xe0
[17023.039519]  [<ffffffff8020c4b8>] child_rip+0xa/0x12
[17023.039519]  [<ffffffff8020bbcf>] restore_args+0x0/0x30
[17023.039519]  [<ffffffff805b69cd>] __svc_create_thread+0xdd/0x200
[17023.039519]  [<ffffffff80317840>] nfs_callback_svc+0x0/0x130
[17023.039519]  [<ffffffff8020c4ae>] child_rip+0x0/0x12
[17023.039519]
[17023.039519]
[17023.039519] Code: 0f 0b eb fe 0f 1f 84 00 00 00 00 00 55 48 8b 16 48 89 e5 e8
[17023.039519] RIP  [<ffffffff803bd834>] __list_add+0x54/0x60
[17023.039519]  RSP <ffff8101002c9dc0>
[17023.039524] ---[ end trace a9257b24a4b10968 ]---
[17023.041451] Kernel panic - not syncing: Aiee, killing interrupt handler!

I also wonder if this really is only one bug, or two. (One in skb
handling and one in svc_xprt_enqueue's list code)

Summary of what I think is related to this:

* 2.6.24-rc2-mm1 might not have it, but had a bug in the nfsv4 sillyrenames.
* 2.6.24-rc3-mm1 did not work for me at all (IO-APIC problem)
* 2.6.24-rc3-mm2 has the bug
  - I have seen a crash in ether1394_complete_cb
  - I have seen 3 crashes in svc_xprt_enqueue, two with slub_debug=FZP
  - I have seen a crash in tcp_send_ack -> __alloc_skb
  - patched with svc_xprt_received(&svsk->sk_xprt); removed from
svc_create_socket()
    -> still crashed in svc_xprt_enqueue
  - patched "skb_release_all(dst);" back to "skb_release_data(dst);"
in skb_morph() (net/core/skbuff.c).
    -> seemed to work (200+ packages compiled+installed)
* 2.6.24-rc4-mm1 and -rc5-mm1: not tried, was still testing -rc3-mm2
* 2.6.24-rc6 did not crash, but I did not test it for too long
* 2.6.24-rc6-mm1 has the bug
  - I have seen a crash in skb_release_data with vanilla -mm1
  - patched "skb_release_all(dst);" back to "skb_release_data(dst);" in
skb_morph() (net/core/skbuff.c).
    -> crashed in xs_tcp_data_recv, skb_morph() was not called once
  - patched with notfreed-hack
    -> crashed in svc_xprt_enqueue, skb_morph() was not called once

I will see if I have the time to try git-nfsd, but as I'm not able to
trigger the bug reliable, I will not be able to really declare any
tree unrelated...

Torsten

My skb-double-free-hack: I added a new __u8 field to sk_buff after its
cb field and the following warnings:
--- skbuff.c~   2008-01-03 05:29:32.092408637 +0100
+++ skbuff.c    2008-01-02 23:00:14.114535678 +0100
@@ -205,6 +205,7 @@ struct sk_buff *__alloc_skb(unsigned int
        memset(skb, 0, offsetof(struct sk_buff, tail));
        skb->truesize = size + sizeof(struct sk_buff);
        atomic_set(&skb->users, 1);
+       skb->notfreed=1;
        skb->head = data;
        skb->data = data;
        skb_reset_tail_pointer(skb);
@@ -317,13 +318,18 @@ static void kfree_skbmem(struct sk_buff

        switch (skb->fclone) {
        case SKB_FCLONE_UNAVAILABLE:
+               WARN_ON(!skb->notfreed);
+               skb->notfreed=0;
                kmem_cache_free(skbuff_head_cache, skb);
                break;

        case SKB_FCLONE_ORIG:
                fclone_ref = (atomic_t *) (skb + 2);
-               if (atomic_dec_and_test(fclone_ref))
+               if (atomic_dec_and_test(fclone_ref)) {
+                 WARN_ON(!skb->notfreed);
+                 skb->notfreed=0;
                        kmem_cache_free(skbuff_fclone_cache, skb);
+                }
                break;

        case SKB_FCLONE_CLONE:
@@ -335,8 +341,11 @@ static void kfree_skbmem(struct sk_buff
                 */
                skb->fclone = SKB_FCLONE_UNAVAILABLE;

-               if (atomic_dec_and_test(fclone_ref))
+               if (atomic_dec_and_test(fclone_ref)) {
+                 WARN_ON(!other->notfreed);
+                 other->notfreed=0;
                        kmem_cache_free(skbuff_fclone_cache, other);
+                }
                break;
        }
 }

  reply	other threads:[~2008-01-03  5:03 UTC|newest]

Thread overview: 146+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-23  7:30 2.6.24-rc6-mm1 Andrew Morton
2007-12-23 11:04 ` 2.6.24-rc6-mm1 Ingo Molnar
2007-12-23 11:10   ` 2.6.24-rc6-mm1 Ingo Molnar
2007-12-23 11:34     ` 2.6.24-rc6-mm1 Andrew Morton
2007-12-23 11:57       ` 2.6.24-rc6-mm1 Ingo Molnar
2007-12-23 12:12         ` 2.6.24-rc6-mm1 Christoph Hellwig
2007-12-23 12:35 ` 2.6.24-rc6-mm1 Rafael J. Wysocki
2007-12-23 13:00   ` 2.6.24-rc6-mm1 Ingo Molnar
2007-12-23 13:48     ` 2.6.24-rc6-mm1 Rafael J. Wysocki
2007-12-23 13:53       ` 2.6.24-rc6-mm1 Rafael J. Wysocki
2007-12-23 20:09         ` 2.6.24-rc6-mm1 Sam Ravnborg
2007-12-23 22:44           ` 2.6.24-rc6-mm1 Rafael J. Wysocki
2008-01-02 20:05             ` [patch] x86 compat_binfmt_elf, Makefile fixes (was: Re: 2.6.24-rc6-mm1) Ingo Molnar
2008-01-02 20:32               ` Rafael J. Wysocki
2008-01-02 20:43                 ` Ingo Molnar
2007-12-23 23:09   ` 2.6.24-rc6-mm1 H. Peter Anvin
2007-12-23 16:27 ` 2.6.24-rc6-mm1 Torsten Kaiser
2007-12-23 20:39   ` 2.6.24-rc6-mm1 Andrew Morton
2007-12-27 11:42     ` 2.6.24-rc6-mm1 Torsten Kaiser
2007-12-27 14:30       ` 2.6.24-rc6-mm1 Torsten Kaiser
2007-12-28 22:53   ` 2.6.24-rc6-mm1 Torsten Kaiser
2007-12-28 23:07     ` 2.6.24-rc6-mm1 Andrew Morton
2007-12-29 16:51       ` 2.6.24-rc6-mm1 Torsten Kaiser
2007-12-30  1:30         ` 2.6.24-rc6-mm1 Herbert Xu
2007-12-30  3:34           ` 2.6.24-rc6-mm1 Torsten Kaiser
2007-12-30  5:41             ` 2.6.24-rc6-mm1 Randy Dunlap
2007-12-31 20:15             ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-01 12:04               ` 2.6.24-rc6-mm1 Herbert Xu
2008-01-01 12:59                 ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-01 18:29                   ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-02 18:29                 ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-02 21:51                   ` 2.6.24-rc6-mm1 Herbert Xu
2008-01-02 21:57                     ` 2.6.24-rc6-mm1 J. Bruce Fields
2008-01-03  5:02                       ` Torsten Kaiser [this message]
2008-01-03 15:37                       ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-03 18:52                         ` 2.6.24-rc6-mm1 J. Bruce Fields
2008-01-04 10:23                     ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-04 13:30                       ` 2.6.24-rc6-mm1 Jarek Poplawski
2008-01-04 15:21                         ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-04 21:24                           ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-05  0:07                           ` 2.6.24-rc6-mm1 Jarek Poplawski
2008-01-05  8:01                             ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-05 10:13                               ` 2.6.24-rc6-mm1 Jarek Poplawski
2008-01-05 14:52                                 ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-05 22:10                                   ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-06  1:25                                     ` 2.6.24-rc6-mm1 Andrew Morton
2008-01-06  3:28                                       ` 2.6.24-rc6-mm1 FUJITA Tomonori
2008-01-06 10:41                                         ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-06 11:23                                           ` 2.6.24-rc6-mm1 FUJITA Tomonori
2008-01-06 11:35                                             ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-06 13:33                                               ` 2.6.24-rc6-mm1 FUJITA Tomonori
2008-01-06 20:03                                                 ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-07  6:16                                                   ` 2.6.24-rc6-mm1 FUJITA Tomonori
2008-01-08 15:59                                                     ` 2.6.24-rc6-mm1 Ingo Molnar
2008-01-08 23:57                                                       ` 2.6.24-rc6-mm1 FUJITA Tomonori
2008-01-09  0:27                                                         ` 2.6.24-rc6-mm1 Andrew Morton
2008-01-09  0:54                                                           ` 2.6.24-rc6-mm1 FUJITA Tomonori
2008-01-09  1:07                                                             ` 2.6.24-rc6-mm1 Andrew Morton
2008-01-09  9:04                                                         ` 2.6.24-rc6-mm1 Jarek Poplawski
2008-01-10  0:54                                                           ` 2.6.24-rc6-mm1 FUJITA Tomonori
2008-01-25 21:06                                                     ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-06  3:16                                     ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-06  8:27                                   ` 2.6.24-rc6-mm1 Jarek Poplawski
2008-01-06 10:30                                     ` 2.6.24-rc6-mm1 Torsten Kaiser
2008-01-06 14:52                                       ` 2.6.24-rc6-mm1 Jarek Poplawski
2007-12-30 21:24       ` 2.6.24-rc6-mm1 J. Bruce Fields
2007-12-30 21:35         ` 2.6.24-rc6-mm1 Torsten Kaiser
2007-12-31 13:17           ` 2.6.24-rc6-mm1 Torsten Kaiser
2007-12-23 22:54 ` 2.6.24-rc6-mm1: suspend broken on HP nx6325 due to cpufreq changes Rafael J. Wysocki
2007-12-23 22:50   ` Andrew Morton
2007-12-23 22:56     ` Dave Jones
2007-12-24 11:21     ` Takashi Iwai
2007-12-24 14:13       ` Rafael J. Wysocki
2007-12-25 21:51 ` 2.6.24-rc6-mm1 Andreas Mohr
2007-12-26  5:43 ` 2.6.24-rc6-mm1 - git-lblnet.patch and networking horkage Valdis.Kletnieks
2007-12-26  7:34   ` James Morris
2007-12-26  8:25     ` Valdis.Kletnieks
2007-12-26  8:52       ` James Morris
2007-12-26 14:16         ` James Morris
2007-12-26 22:46           ` Andrew Morton
2007-12-26 23:39             ` 2.6.24-rc6-mm1 - e1000 breakage James Morris
2007-12-26 16:44         ` 2.6.24-rc6-mm1 - git-lblnet.patch and networking horkage Valdis.Kletnieks
2007-12-26  8:37 ` 2.6.24-rc6-mm1 Dave Young
2007-12-26 12:29 ` 2.6.24-rc6-mm1: some section mismatches on sparc64 Mariusz Kozlowski
2007-12-27  3:05   ` David Miller
2007-12-28 23:22     ` Adrian Bunk
2007-12-29  8:14       ` David Miller
2007-12-29  8:27         ` David Miller
2007-12-29  8:48         ` Adrian Bunk
2007-12-29  8:54           ` David Miller
2007-12-29  9:06             ` Adrian Bunk
2007-12-29  9:18               ` David Miller
2007-12-29  9:53                 ` Adrian Bunk
2007-12-29  9:15             ` David Miller
2007-12-27  2:21 ` 2.6.24-rc6-mm1: __raw_spin_is_contended undefined Joseph Fannin
2007-12-27  5:21   ` Nick Piggin
2007-12-27  6:04 ` 2.6.24-rc6-mm1 - drivers/char/tpm/tpm_bios.c oddness? Valdis.Kletnieks
2007-12-27  8:49 ` 2.6.24-rc6-mm1 Kernel panics at different functions () Kamalesh Babulal
2007-12-27  9:54   ` Andrew Morton
2007-12-27 10:25     ` Kamalesh Babulal
2007-12-28  9:11     ` Kamalesh Babulal
2007-12-28 13:03       ` Dhaval Giani
2007-12-27  9:16 ` 2.6.24-rc6-mm1 - power_supply driver dmesg weirdness? Valdis.Kletnieks
2007-12-27 17:54 ` 2.6.24-rc6-mm1 - crash in tick_sched_timer/update_process_times Valdis.Kletnieks
2007-12-28  7:34   ` Andrew Morton
2007-12-29 16:02   ` Valdis.Kletnieks
2007-12-31 18:05 ` [PATCH -mm] crypto: scatterwalk.h needs sched.h Randy Dunlap
2007-12-31 22:31   ` Herbert Xu
2007-12-31 18:05 ` [PATCH -mm] driver core: build with SYSFS=n Randy Dunlap
2007-12-31 18:18 ` 2.6.24-rc6-mm1 (build problem: v4l / i2c) Randy Dunlap
2007-12-31 19:01   ` [v4l-dvb-maintainer] " Michael Krufky
2007-12-31 19:08     ` Michael Krufky
2007-12-31 18:18 ` 2.6.24-rc6-mm1 (build problem: gpio_keys) Randy Dunlap
2007-12-31 18:40   ` David Brownell
2007-12-31 19:10     ` [PATCH -mm] gpio: fix x86 build problem: gpio_keys Randy Dunlap
2008-01-01 15:32       ` Ingo Molnar
2007-12-31 18:19 ` 2.6.24-rc6-mm1 (build problem: gpio/W1) Randy Dunlap
2008-01-05 15:29   ` Evgeniy Polyakov
2008-01-05 16:16     ` Ville Syrjälä
2008-01-05 17:18       ` Randy Dunlap
2007-12-31 20:11 ` 2.6.24-rc6-mm1 (driver core/sysfs) Randy Dunlap
2008-01-12  1:05   ` Greg KH
2008-01-14 16:11     ` [patch] auto-qa Kconfig Ingo Molnar
2008-01-15 22:13       ` Pavel Machek
2008-01-06 10:03 ` 2.6.24-rc6-mm1: sparc64: undefined reference to `vmemmap_table' Mariusz Kozlowski
2008-01-06 10:15   ` Andrew Morton
2008-01-07  1:18     ` David Miller
2008-01-07 13:50 ` [PATCH -mm/x86] revert i386: handle an initrd in highmem (Was Re: 2.6.24-rc6-mm1) Dhaval Giani
2008-01-07 13:53   ` Thomas Gleixner
2008-01-07 14:56     ` Ingo Molnar
2008-01-07 15:19       ` Dhaval Giani
2008-01-07 16:22       ` Randy Dunlap
2008-01-07 16:32         ` Dhaval Giani
2008-01-07 16:50         ` Thomas Gleixner
2008-01-07 22:15           ` Randy Dunlap
     [not found] <9DtBq-2jD-3@gated-at.bofh.it>
     [not found] ` <476EAF98.6040004@yahoo.fr>
     [not found]   ` <20071223121410.0d572e03.akpm@linux-foundation.org>
2007-12-24  1:25     ` 2.6.24-rc6-mm1 Herbert Xu
2007-12-30 13:10       ` 2.6.24-rc6-mm1 Ingo Molnar
2008-01-02 10:31         ` 2.6.24-rc6-mm1 Nick Piggin
2008-01-02 11:01           ` 2.6.24-rc6-mm1 Peter Zijlstra
2008-01-02 11:12             ` 2.6.24-rc6-mm1 Nick Piggin
2008-01-02 11:24               ` 2.6.24-rc6-mm1 Peter Zijlstra
2008-01-02 12:19                 ` 2.6.24-rc6-mm1 Ingo Molnar
2008-01-02 13:26                   ` 2.6.24-rc6-mm1 Alan Cox
2008-01-02 16:18                     ` 2.6.24-rc6-mm1 Ingo Molnar
2008-01-02 22:49                       ` 2.6.24-rc6-mm1 Alan Cox
2008-01-02 11:08           ` 2.6.24-rc6-mm1 Ingo Molnar

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=64bb37e0801022102n54d85772p698055dd83b34d7c@mail.gmail.com \
    --to=just.for.lkml@googlemail.com \
    --cc=akpm@linux-foundation.org \
    --cc=bfields@fieldses.org \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-kernel@vger.kernel.org \
    --cc=neilb@suse.de \
    --cc=netdev@vger.kernel.org \
    --cc=tom@opengridcomputing.com \
    /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

all inboxes | Powered by JetHome®