lkml.org 
[lkml]   [2003]   [Sep]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectFix noop elevator request merging (in current 2.5 bk)
Hello!

This patch is required otherwise in case if elv_try_last_merge returns nonzero, we do not
initialise *req, and subsequent BUG_ON() in __make_request() will dies because req is NULL
(or is just uninitialised).
This stopped my UBD devices to work, that's how I noticed ;)

Bye,
Oleg

# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher.
# This patch includes the following deltas:
# ChangeSet 1.1228 -> 1.1229
# drivers/block/noop-iosched.c 1.2 -> 1.3
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 03/09/08 green@angband.namesys.com 1.1229
# Fix request merging in noop elevator, preventing a crash in __make_request()
# --------------------------------------------
#
diff -Nru a/drivers/block/noop-iosched.c b/drivers/block/noop-iosched.c
--- a/drivers/block/noop-iosched.c Mon Sep 8 19:25:35 2003
+++ b/drivers/block/noop-iosched.c Mon Sep 8 19:25:35 2003
@@ -24,8 +24,10 @@
struct request *__rq;
int ret;

- if ((ret = elv_try_last_merge(q, bio)))
+ if ((ret = elv_try_last_merge(q, bio))) {
+ *req = q->last_merge;
return ret;
+ }

while ((entry = entry->prev) != &q->queue_head) {
__rq = list_entry_rq(entry);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 13:48    [W:0.188 / U:0.164 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site