From: Jan Dittmer <jdi@l4x.org>
To: Joe Jin <lkmaillist@gmail.com>
Cc: kernel <linux@idccenter.cn>, Nathan Scott <nathans@sgi.com>,
linux-kernel@vger.kernel.org
Subject: Re: XFS Bug null pointer dereference in xfs_free_ag_extent
Date: Tue, 01 Aug 2006 10:12:14 +0200 [thread overview]
Message-ID: <44CF0CDE.2080500@l4x.org> (raw)
In-Reply-To: <215036450607311849o43b1555br13ea2f3f20fb3b82@mail.gmail.com>
Joe Jin schrieb:
> From the information, I think it caused by (args.agbp == NULL).
> get rid of, we'll find the call trace should panic:
> xfs_free_extent
> |_ xfs_free_ag_extent => here args.agbp= NULL;
> |_ xfs_btree_init_cursor()
> |_ agf = XFS_BUF_TO_AGF(agbp); => (xfs_agf_t
> *)XFS_BUF_PTR(arbp)
> |_ (xfs_caddr_t)((agbp)->b_addr) : but
> here, agbp is NULL
> so it caused the oops.
> Non debug option, and the oops occured at xfs_btree_init_cursor().
>
Probably caused by this part of the diff from Nathan's earlier mail:
--- 8558226281c45a61d7a0bc056505246e705a372b
+++ 22af489d3f346c7bb4488cdcf1ee91e59e48ddf3
--- fs/xfs/xfs_alloc.c
+++ fs/xfs/xfs_alloc.c
@@ -1951,8 +1951,14 @@ xfs_alloc_fix_freelist(
* the restrictions correctly. Can happen for free calls
* on a completely full ag.
*/
- if (targs.agbno == NULLAGBLOCK)
+ if (targs.agbno == NULLAGBLOCK) {
+ if (!(flags & XFS_ALLOC_FLAG_FREEING)) {
+ xfs_trans_brelse(tp, agflbp);
+ args->agbp = NULL;
+ return 0;
+ }
break;
+ }
/*
* Put each allocated block on the list.
*/
Jan
next prev parent reply other threads:[~2006-08-01 8:12 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-20 6:59 XFS Bug null pointer dereference in xfs_free_ag_extent Jan Dittmer
2006-07-29 7:19 ` kernel
2006-07-29 7:49 ` Jan Dittmer
2006-07-29 8:10 ` kernel
2006-07-30 23:44 ` Nathan Scott
2006-07-31 1:30 ` kernel
2006-07-31 6:21 ` kernel
2006-07-31 6:55 ` Nathan Scott
2006-07-31 7:28 ` kernel
2006-07-31 8:41 ` Joe Jin
2006-07-31 9:53 ` Nathan Scott
2006-07-31 9:43 ` Nathan Scott
2006-07-31 10:04 ` kernel
[not found] ` <215036450607311849o43b1555br13ea2f3f20fb3b82@mail.gmail.com>
2006-08-01 8:12 ` Jan Dittmer [this message]
2006-08-02 1:26 ` Nathan Scott
2006-08-08 3:30 ` Nathan Scott
2006-07-31 6:58 ` Jan Dittmer
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=44CF0CDE.2080500@l4x.org \
--to=jdi@l4x.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@idccenter.cn \
--cc=lkmaillist@gmail.com \
--cc=nathans@sgi.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