From: Arnaldo Carvalho de Melo <acme@mandriva.com>
To: Jens Axboe <axboe@suse.de>, Tejun Heo <htejun@gmail.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH][noop-iosched] don't reuse a freed request
Date: Mon, 31 Oct 2005 01:52:49 -0200 [thread overview]
Message-ID: <20051031035249.GE5632@mandriva.com> (raw)
In-Reply-To: <20051031025526.GD5632@mandriva.com>
Em Mon, Oct 31, 2005 at 12:55:26AM -0200, Arnaldo Carvalho de Melo escreveu:
> Em Mon, Oct 31, 2005 at 12:30:24AM -0200, Arnaldo Carvalho de Melo escreveu:
> > Hi,
> >
> > I'm getting the oops below when trying to use qemu with a kernel
> > built with just the noop iosched, I'm never had looked at this code before,
> > so I did a quick hack that seems enough for my case.
> >
> > Ah, this is with a fairly recent git tree (today), haven't checked
> > if it is present in 2.6.14.
>
> Further info: building with all the io schedulers and using 'elevator=cfq'
> in the kernel cmd line produces another oops, with or without my patch:
>
> hda:<1>Unable to handle kernel paging request at virtual address c554ef60
> printing eip:
> 01b14f7
> pde = 00015067
> pte = 0554e000
> ops: 0000 [#1]
> EBUG_PAGEALLOC
> odules linked in:
> PU: 0
> IP: 0060:[<c01b14f7>] Not tainted VLI
> FLAGS: 00000046 (2.6.14acme)
> IP is at __elv_add_request+0xe7/0x13f
Ok, some more info, hope it'll be useful: I narrowed it down to this part
of __elv_add_request:
case ELEVATOR_INSERT_SORT:
BUG_ON(!blk_fs_request(rq));
rq->flags |= REQ_SORTED;
q->elevator->ops->elevator_add_req_fn(q, rq);
if (q->last_merge == NULL && rq_mergeable(rq))
q->last_merge = rq;
break;
It seems it is not safe to touch the request (rq) after calling
elevator_add_req_fn, as the panic happens when rq_mergeable tries
to read rq->flags, or cfq_insert_request is doing something bad, well,
enough for my block layer wanderings :-)
Best Regards,
- Arnaldo
P.S. the last patches to touch this code are post 2.6.14
next prev parent reply other threads:[~2005-10-31 3:52 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-31 2:30 [PATCH][noop-iosched] don't reuse a freed request Arnaldo Carvalho de Melo
2005-10-31 2:55 ` Arnaldo Carvalho de Melo
2005-10-31 3:52 ` Arnaldo Carvalho de Melo [this message]
2005-10-31 7:40 ` Jens Axboe
2005-10-31 8:04 ` Tejun Heo
2005-10-31 8:23 ` Jens Axboe
2005-10-31 8:59 ` Tejun Heo
2005-10-31 9:11 ` Jens Axboe
2005-10-31 15:53 ` Linus Torvalds
2005-10-31 18:03 ` Jens Axboe
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=20051031035249.GE5632@mandriva.com \
--to=acme@mandriva.com \
--cc=axboe@suse.de \
--cc=htejun@gmail.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox