rpms/kernel/devel linux-2.6-kill-blk_attempt_merge.patch, NONE, 1.1.2.1 kernel-2.6.spec, 1.1826.2.7, 1.1826.2.8
fedora-cvs-commits at redhat.com
fedora-cvs-commits at redhat.com
Mon Jan 9 16:23:54 UTC 2006
Author: davej
Update of /cvs/dist/rpms/kernel/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv11597
Modified Files:
Tag: private-fc5-test2-branch
kernel-2.6.spec
Added Files:
Tag: private-fc5-test2-branch
linux-2.6-kill-blk_attempt_merge.patch
Log Message:
kill blk_attempt_merge which should make things happy again in block layer.
linux-2.6-kill-blk_attempt_merge.patch:
block/ll_rw_blk.c | 24 ------------------------
drivers/ide/ide-cd.c | 10 ----------
include/linux/blkdev.h | 1 -
3 files changed, 35 deletions(-)
--- NEW FILE linux-2.6-kill-blk_attempt_merge.patch ---
On Fri, Jan 06 2006, Dave Jones wrote:
> Looks like some nice slab poison...
>
> Dave
>
> Oops: 0000 [#1]
> last sysfs file:
> /devices/pci0000:00/0000:00:1d.7/usb1/1-0:1.0/bAlternateSettingModules linked
> in: usb_storage ata_piix libata e1000 ohci1394 ieee1394 uhci_hcdsCPU: 0
> EIP: 0060:[<c01c312e>] Not tainted VLI
> EFLAGS: 00010002 (2.6.15-1.1819_FC5)
> EIP is at rb_next+0x9/0x22
> eax: 6b6b6b6b ebx: dfed01f8 ecx: c01bf65a edx: 6b6b6b6b
> esi: c1991e98 edi: 00000202 ebp: dfed403c esp: c03c1f14
> ds: 007b es: 007b ss: 0068
> Process swapper (pid: 0, threadinfo=c03c1000 task=c0327ba0)
> Stack: c01bf662 c01b5dfa dfed01f8 c01b85dc c040c284 00000004 c1991e98 c023c8ab
> c1991e98 00000000 c040c284 00000000 c023d3a4 000194d0 00000000 dfed403c
> c1991e98 c040c284 c1991e98 00000000 c0231f2d 000194d0 00000000 000194d0
> Call Trace:
> [<c01bf662>] cfq_latter_request+0x8/0x14 [<c01b5dfa>] elv_latter_request+07
> [<c01b85dc>] blk_attempt_remerge+0x1d/0x3c [<c023c8ab>] cdrom_start_read+0e
> [<c023d3a4>] ide_do_rw_cdrom+0xdd/0x14a [<c0231f2d>] start_request+0x1b1/01
> [<c023220f>] ide_do_request+0x2a0/0x2fb [<c023265e>] ide_intr+0xf3/0x11b
> [<c023c1a7>] cdrom_read_intr+0x0/0x2a1 [<c013632a>] handle_IRQ_event+0x23/c
> [<c01363cd>] __do_IRQ+0x7a/0xcd [<c01054d0>] do_IRQ+0x5c/0x77
> =======================
> [<c0103cea>] common_interrupt+0x1a/0x20 [<c0101120>] mwait_idle+0x1a/0x2e
> [<c01010a3>] cpu_idle+0x38/0x4d [<c0390635>] start_kernel+0x17a/0x17c
> Code: 85 c0 74 0b 8b 50 0c 85 d2 74 04 89 d0 eb f5 c3 8b 00 85 c0 74 0b 8b 50 0
The blk_attempt_remerge() is a bad interface to be honest, and it's hard
to get to work reliably because it's done too late. I think the best
option is just to kill it, this will cause problems with other io
schedulers as well.
I've merged this up for 2.6.16-rc inclusion, probably should go to
stabel as well.
---
[PATCH] Kill blk_attempt_remerge()
It's a bad interface, and it's always done too late. Remove it.
Signed-off-by: Jens Axboe <axboe at suse.de>
diff --git a/block/ll_rw_blk.c b/block/ll_rw_blk.c
index 8e13645..c130519 100644
--- a/block/ll_rw_blk.c
+++ b/block/ll_rw_blk.c
@@ -2748,30 +2748,6 @@ static inline int attempt_front_merge(re
return 0;
}
-/**
- * blk_attempt_remerge - attempt to remerge active head with next request
- * @q: The &request_queue_t belonging to the device
- * @rq: The head request (usually)
- *
- * Description:
- * For head-active devices, the queue can easily be unplugged so quickly
- * that proper merging is not done on the front request. This may hurt
- * performance greatly for some devices. The block layer cannot safely
- * do merging on that first request for these queues, but the driver can
- * call this function and make it happen any way. Only the driver knows
- * when it is safe to do so.
- **/
-void blk_attempt_remerge(request_queue_t *q, struct request *rq)
-{
- unsigned long flags;
-
- spin_lock_irqsave(q->queue_lock, flags);
- attempt_back_merge(q, rq);
- spin_unlock_irqrestore(q->queue_lock, flags);
-}
-
-EXPORT_SYMBOL(blk_attempt_remerge);
-
static void init_request_from_bio(struct request *req, struct bio *bio)
{
req->flags |= REQ_CMD;
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c
index d31117e..e4d55ad 100644
--- a/drivers/ide/ide-cd.c
+++ b/drivers/ide/ide-cd.c
@@ -1332,8 +1332,6 @@ static ide_startstop_t cdrom_start_read
if (cdrom_read_from_buffer(drive))
return ide_stopped;
- blk_attempt_remerge(drive->queue, rq);
-
/* Clear the local sector buffer. */
info->nsectors_buffered = 0;
@@ -1874,14 +1872,6 @@ static ide_startstop_t cdrom_start_write
return ide_stopped;
}
- /*
- * for dvd-ram and such media, it's a really big deal to get
- * big writes all the time. so scour the queue and attempt to
- * remerge requests, often the plugging will not have had time
- * to do this properly
- */
- blk_attempt_remerge(drive->queue, rq);
-
info->nsectors_buffered = 0;
/* use dma, if possible. we don't need to check more, since we
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 804cc4e..02a585f 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -595,7 +595,6 @@ extern void generic_make_request(struct
extern void blk_put_request(struct request *);
extern void __blk_put_request(request_queue_t *, struct request *);
extern void blk_end_sync_rq(struct request *rq, int error);
-extern void blk_attempt_remerge(request_queue_t *, struct request *);
extern struct request *blk_get_request(request_queue_t *, int, gfp_t);
extern void blk_insert_request(request_queue_t *, struct request *, int, void *);
extern void blk_requeue_request(request_queue_t *, struct request *);
Index: kernel-2.6.spec
===================================================================
RCS file: /cvs/dist/rpms/kernel/devel/kernel-2.6.spec,v
retrieving revision 1.1826.2.7
retrieving revision 1.1826.2.8
diff -u -r1.1826.2.7 -r1.1826.2.8
--- kernel-2.6.spec 9 Jan 2006 15:41:31 -0000 1.1826.2.7
+++ kernel-2.6.spec 9 Jan 2006 16:23:52 -0000 1.1826.2.8
@@ -369,6 +369,7 @@
Patch1830: linux-2.6-w1-hush-debug.patch
Patch1840: linux-2.6-x86-hp-reboot.patch
Patch1860: linux-2.6-posix-timers-sched_time-accumulation.patch
+Patch1870: linux-2.6-kill-blk_attempt_merge.patch
# Warn about usage of various obsolete functionality that may go away.
Patch1900: linux-2.6-obsolete-idescsi-warning.patch
@@ -883,6 +884,8 @@
%patch1840 -p1
# Fix posix-cpu-timers sched_time accumulation
%patch1860 -p1
+# kill blk_attempt_merge
+%patch1870 -p1
# Warn about obsolete functionality usage.
%patch1900 -p1
@@ -1414,6 +1417,7 @@
* Mon Jan 9 2006 Dave Jones <davej at redhat.com>
- Remove vm debug patch that triggers too easily right now.
(Needs fixing properly post test2).
+- kill blk_attempt_merge() which was horribly broken.
* Mon Jan 9 2006 David Woodhouse <dwmw2 at redhat.com>
- Fix some usblp problems, add ieee1284_id to sysfs
More information about the fedora-cvs-commits
mailing list