Release 4.7 block/noop-iosched.c
/*
* elevator noop
*/
#include <linux/blkdev.h>
#include <linux/elevator.h>
#include <linux/bio.h>
#include <linux/module.h>
#include <linux/slab.h>
#include <linux/init.h>
struct noop_data {
struct list_head queue;
};
static void noop_merged_requests(struct request_queue *q, struct request *rq,
struct request *next)
{
list_del_init(&next->queuelist);
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
tejun heo | tejun heo | 17 | 58.62% | 1 | 25.00% |
andrew morton | andrew morton | 9 | 31.03% | 1 | 25.00% |
jens axboe | jens axboe | 2 | 6.90% | 1 | 25.00% |
pekka j enberg | pekka j enberg | 1 | 3.45% | 1 | 25.00% |
| Total | 29 | 100.00% | 4 | 100.00% |
static int noop_dispatch(struct request_queue *q, int force)
{
struct noop_data *nd = q->elevator->elevator_data;
struct request *rq;
rq = list_first_entry_or_null(&nd->queue, struct request, queuelist);
if (rq) {
list_del_init(&rq->queuelist);
elv_dispatch_sort(q, rq);
return 1;
}
return 0;
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
tejun heo | tejun heo | 52 | 72.22% | 1 | 12.50% |
jens axboe | jens axboe | 10 | 13.89% | 5 | 62.50% |
geliang tang | geliang tang | 7 | 9.72% | 1 | 12.50% |
andrew morton | andrew morton | 3 | 4.17% | 1 | 12.50% |
| Total | 72 | 100.00% | 8 | 100.00% |
static void noop_add_request(struct request_queue *q, struct request *rq)
{
struct noop_data *nd = q->elevator->elevator_data;
list_add_tail(&rq->queuelist, &nd->queue);
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
tejun heo | tejun heo | 37 | 92.50% | 1 | 33.33% |
jens axboe | jens axboe | 2 | 5.00% | 1 | 33.33% |
andrew morton | andrew morton | 1 | 2.50% | 1 | 33.33% |
| Total | 40 | 100.00% | 3 | 100.00% |
static struct request *
noop_former_request(struct request_queue *q, struct request *rq)
{
struct noop_data *nd = q->elevator->elevator_data;
if (rq->queuelist.prev == &nd->queue)
return NULL;
return list_prev_entry(rq, queuelist);
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
tejun heo | tejun heo | 50 | 94.34% | 1 | 33.33% |
jens axboe | jens axboe | 2 | 3.77% | 1 | 33.33% |
geliang tang | geliang tang | 1 | 1.89% | 1 | 33.33% |
| Total | 53 | 100.00% | 3 | 100.00% |
static struct request *
noop_latter_request(struct request_queue *q, struct request *rq)
{
struct noop_data *nd = q->elevator->elevator_data;
if (rq->queuelist.next == &nd->queue)
return NULL;
return list_next_entry(rq, queuelist);
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
tejun heo | tejun heo | 46 | 86.79% | 1 | 20.00% |
jens axboe | jens axboe | 3 | 5.66% | 2 | 40.00% |
andrew morton | andrew morton | 3 | 5.66% | 1 | 20.00% |
geliang tang | geliang tang | 1 | 1.89% | 1 | 20.00% |
| Total | 53 | 100.00% | 5 | 100.00% |
static int noop_init_queue(struct request_queue *q, struct elevator_type *e)
{
struct noop_data *nd;
struct elevator_queue *eq;
eq = elevator_alloc(q, e);
if (!eq)
return -ENOMEM;
nd = kmalloc_node(sizeof(*nd), GFP_KERNEL, q->node);
if (!nd) {
kobject_put(&eq->kobj);
return -ENOMEM;
}
eq->elevator_data = nd;
INIT_LIST_HEAD(&nd->queue);
spin_lock_irq(q->queue_lock);
q->elevator = eq;
spin_unlock_irq(q->queue_lock);
return 0;
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
ma jianpeng | ma jianpeng | 59 | 50.43% | 1 | 16.67% |
tejun heo | tejun heo | 47 | 40.17% | 2 | 33.33% |
jens axboe | jens axboe | 7 | 5.98% | 2 | 33.33% |
andrew morton | andrew morton | 4 | 3.42% | 1 | 16.67% |
| Total | 117 | 100.00% | 6 | 100.00% |
static void noop_exit_queue(struct elevator_queue *e)
{
struct noop_data *nd = e->elevator_data;
BUG_ON(!list_empty(&nd->queue));
kfree(nd);
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
tejun heo | tejun heo | 35 | 94.59% | 1 | 50.00% |
jens axboe | jens axboe | 2 | 5.41% | 1 | 50.00% |
| Total | 37 | 100.00% | 2 | 100.00% |
static struct elevator_type elevator_noop = {
.ops = {
.elevator_merge_req_fn = noop_merged_requests,
.elevator_dispatch_fn = noop_dispatch,
.elevator_add_req_fn = noop_add_request,
.elevator_former_req_fn = noop_former_request,
.elevator_latter_req_fn = noop_latter_request,
.elevator_init_fn = noop_init_queue,
.elevator_exit_fn = noop_exit_queue,
},
.elevator_name = "noop",
.elevator_owner = THIS_MODULE,
};
static int __init noop_init(void)
{
return elv_register(&elevator_noop);
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
jens axboe | jens axboe | 13 | 81.25% | 1 | 33.33% |
pekka j enberg | pekka j enberg | 2 | 12.50% | 1 | 33.33% |
tejun heo | tejun heo | 1 | 6.25% | 1 | 33.33% |
| Total | 16 | 100.00% | 3 | 100.00% |
static void __exit noop_exit(void)
{
elv_unregister(&elevator_noop);
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
jens axboe | jens axboe | 9 | 60.00% | 1 | 33.33% |
andrew morton | andrew morton | 4 | 26.67% | 1 | 33.33% |
pekka j enberg | pekka j enberg | 2 | 13.33% | 1 | 33.33% |
| Total | 15 | 100.00% | 3 | 100.00% |
module_init(noop_init);
module_exit(noop_exit);
MODULE_AUTHOR("Jens Axboe");
MODULE_LICENSE("GPL");
MODULE_DESCRIPTION("No-op IO scheduler");
Overall Contributors
| Person | Tokens | Prop | Commits | CommitProp |
tejun heo | tejun heo | 324 | 59.78% | 4 | 25.00% |
jens axboe | jens axboe | 89 | 16.42% | 8 | 50.00% |
ma jianpeng | ma jianpeng | 59 | 10.89% | 1 | 6.25% |
andrew morton | andrew morton | 56 | 10.33% | 1 | 6.25% |
geliang tang | geliang tang | 9 | 1.66% | 1 | 6.25% |
pekka j enberg | pekka j enberg | 5 | 0.92% | 1 | 6.25% |
| Total | 542 | 100.00% | 16 | 100.00% |
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.