Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8324aa91 authored by Jens Axboe's avatar Jens Axboe
Browse files

block: split tag and sysfs handling from blk-core.c



Seperates the tag and sysfs handling from ll_rw_blk.

Signed-off-by: default avatarJens Axboe <jens.axboe@oracle.com>
parent a168ee84
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -2,7 +2,8 @@
# Makefile for the kernel block layer
#

obj-$(CONFIG_BLOCK) := elevator.o blk-core.o ioctl.o genhd.o scsi_ioctl.o
obj-$(CONFIG_BLOCK) := elevator.o blk-core.o blk-tag.o blk-sysfs.o ioctl.o \
			genhd.o scsi_ioctl.o

obj-$(CONFIG_BLK_DEV_BSG)	+= bsg.o
obj-$(CONFIG_IOSCHED_NOOP)	+= noop-iosched.o
+10 −709

File changed.

Preview size limit exceeded, changes collapsed.

block/blk-sysfs.c

0 → 100644
+298 −0

File added.

Preview size limit exceeded, changes collapsed.

block/blk-tag.c

0 → 100644
+396 −0

File added.

Preview size limit exceeded, changes collapsed.

block/blk.h

0 → 100644
+29 −0
Original line number Diff line number Diff line
#ifndef BLK_INTERNAL_H
#define BLK_INTERNAL_H

extern struct kmem_cache *blk_requestq_cachep;
extern struct kobj_type blk_queue_ktype;

void __blk_queue_free_tags(struct request_queue *q);

void blk_queue_congestion_threshold(struct request_queue *q);

/*
 * Return the threshold (number of used requests) at which the queue is
 * considered to be congested.  It include a little hysteresis to keep the
 * context switch rate down.
 */
static inline int queue_congestion_on_threshold(struct request_queue *q)
{
	return q->nr_congestion_on;
}

/*
 * The threshold at which a queue is considered to be uncongested
 */
static inline int queue_congestion_off_threshold(struct request_queue *q)
{
	return q->nr_congestion_off;
}

#endif