[PATCH 5/7] block: simplify the check for the current elevator in elv_iosched_show

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Just compare the pointers instead of using the string based
elevator_match.

Signed-off-by: Christoph Hellwig <hch@xxxxxx>
---
 block/elevator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/block/elevator.c b/block/elevator.c
index 4fc0d2f539295..77c16c5ef04ff 100644
--- a/block/elevator.c
+++ b/block/elevator.c
@@ -786,7 +786,7 @@ ssize_t elv_iosched_show(struct request_queue *q, char *name)
 
 	spin_lock(&elv_list_lock);
 	list_for_each_entry(e, &elv_list, list) {
-		if (cur && elevator_match(cur, e->elevator_name, 0)) {
+		if (e == cur) {
 			len += sprintf(name+len, "[%s] ", cur->elevator_name);
 			continue;
 		}
-- 
2.30.2




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux