All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Mason <chris.mason@oracle.com>
To: Johannes Hirte <johannes.hirte@fem.tu-ilmenau.de>
Cc: linux-btrfs@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [btrfs] kernel BUG at include/linux/spinlock.h:376!
Date: Thu, 14 Jan 2010 14:37:08 -0500	[thread overview]
Message-ID: <20100114193708.GD23810@think> (raw)
In-Reply-To: <201001072229.33976.johannes.hirte@fem.tu-ilmenau.de>

On Thu, Jan 07, 2010 at 10:29:32PM +0100, Johannes Hirte wrote:
> One of my btrfs filesystems gives the following bug message on access:
> 
> Jan  6 23:08:12 datengrab kernel: ------------[ cut here ]------------
> Jan  6 23:08:12 datengrab kernel: kernel BUG at include/linux/spinlock.h:376!
> Jan  6 23:08:12 datengrab kernel: invalid opcode: 0000 [#1] SMP
> Jan  6 23:08:12 datengrab kernel: last sysfs file: 
> /sys/devices/pci0000:00/0000:00:18.3/temp1_input
> Jan  6 23:08:12 datengrab kernel: CPU 1
> Jan  6 23:08:12 datengrab kernel: Pid: 2837, comm: btrfs-endio-wri Not tainted 
> 2.6.33-rc3-00033-g03b7675 #12 TYAN Tiger K8W Dual AMD Opteron, S2875/To Be 
> Filled
> By O.E.M.
> Jan  6 23:08:12 datengrab kernel: RIP: 0010:[<ffffffff8118f7ea>]  [<ffffffff8118f7ea>] 
> btrfs_assert_tree_locked+0x16/0x1c

Well, we really should have this tree block locked, but
btrfs_mark_extent_written is doing some special things.  Is the trace
always the same?

If so, please try this patch:

diff --git a/fs/btrfs/file.c b/fs/btrfs/file.c
index 3bfe9f0..1148aa0 100644
--- a/fs/btrfs/file.c
+++ b/fs/btrfs/file.c
@@ -572,6 +572,7 @@ again:
 	key.objectid = inode->i_ino;
 	key.type = BTRFS_EXTENT_DATA_KEY;
 	key.offset = split;
+	path->keep_locks = 1;
 
 	ret = btrfs_search_slot(trans, root, &key, path, -1, 1);
 	if (ret > 0 && path->slots[0] > 0)

  parent reply	other threads:[~2010-01-14 19:37 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-07 21:29 [btrfs] kernel BUG at include/linux/spinlock.h:376! Johannes Hirte
2010-01-14 15:36 ` Johannes Hirte
2010-01-14 19:37 ` Chris Mason [this message]
2010-01-23 20:23   ` Johannes Hirte
2010-01-25 15:17     ` Chris Mason

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=20100114193708.GD23810@think \
    --to=chris.mason@oracle.com \
    --cc=johannes.hirte@fem.tu-ilmenau.de \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.