Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 130730
b: refs/heads/master
c: 5c350d9
h: refs/heads/master
v: v3
  • Loading branch information
Linus Torvalds committed Feb 3, 2009
1 parent 723e88b commit 2f5313e
Show file tree
Hide file tree
Showing 28 changed files with 546 additions and 58 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b6018958a57f6621d6979c4384e42a3df636beed
refs/heads/master: 5c350d93ff4736086a1b08fef1d0b5e22138d2e0
63 changes: 63 additions & 0 deletions trunk/Documentation/block/queue-sysfs.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
Queue sysfs files
=================

This text file will detail the queue files that are located in the sysfs tree
for each block device. Note that stacked devices typically do not export
any settings, since their queue merely functions are a remapping target.
These files are the ones found in the /sys/block/xxx/queue/ directory.

Files denoted with a RO postfix are readonly and the RW postfix means
read-write.

hw_sector_size (RO)
-------------------
This is the hardware sector size of the device, in bytes.

max_hw_sectors_kb (RO)
----------------------
This is the maximum number of kilobytes supported in a single data transfer.

max_sectors_kb (RW)
-------------------
This is the maximum number of kilobytes that the block layer will allow
for a filesystem request. Must be smaller than or equal to the maximum
size allowed by the hardware.

nomerges (RW)
-------------
This enables the user to disable the lookup logic involved with IO merging
requests in the block layer. Merging may still occur through a direct
1-hit cache, since that comes for (almost) free. The IO scheduler will not
waste cycles doing tree/hash lookups for merges if nomerges is 1. Defaults
to 0, enabling all merges.

nr_requests (RW)
----------------
This controls how many requests may be allocated in the block layer for
read or write requests. Note that the total allocated number may be twice
this amount, since it applies only to reads or writes (not the accumulated
sum).

read_ahead_kb (RW)
------------------
Maximum number of kilobytes to read-ahead for filesystems on this block
device.

rq_affinity (RW)
----------------
If this option is enabled, the block layer will migrate request completions
to the CPU that originally submitted the request. For some workloads
this provides a significant reduction in CPU cycles due to caching effects.

scheduler (RW)
--------------
When read, this file will display the current and available IO schedulers
for this block device. The currently active IO scheduler will be enclosed
in [] brackets. Writing an IO scheduler name to this file will switch
control of this block device to that new IO scheduler. Note that writing
an IO scheduler name to this file will attempt to load that IO scheduler
module, if it isn't already present in the system.



Jens Axboe <jens.axboe@oracle.com>, February 2009
6 changes: 3 additions & 3 deletions trunk/block/blk-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ static void drive_stat_acct(struct request *rq, int new_io)
int rw = rq_data_dir(rq);
int cpu;

if (!blk_fs_request(rq) || !disk || !blk_queue_io_stat(disk->queue))
if (!blk_fs_request(rq) || !disk || !blk_do_io_stat(disk->queue))
return;

cpu = part_stat_lock();
Expand Down Expand Up @@ -1667,7 +1667,7 @@ static void blk_account_io_completion(struct request *req, unsigned int bytes)
{
struct gendisk *disk = req->rq_disk;

if (!disk || !blk_queue_io_stat(disk->queue))
if (!disk || !blk_do_io_stat(disk->queue))
return;

if (blk_fs_request(req)) {
Expand All @@ -1686,7 +1686,7 @@ static void blk_account_io_done(struct request *req)
{
struct gendisk *disk = req->rq_disk;

if (!disk || !blk_queue_io_stat(disk->queue))
if (!disk || !blk_do_io_stat(disk->queue))
return;

/*
Expand Down
8 changes: 8 additions & 0 deletions trunk/block/blk.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,12 @@ static inline int blk_cpu_to_group(int cpu)
#endif
}

static inline int blk_do_io_stat(struct request_queue *q)
{
if (q)
return blk_queue_io_stat(q);

return 0;
}

#endif
10 changes: 10 additions & 0 deletions trunk/drivers/ide/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,16 @@ config BLK_DEV_CS5535

It is safe to say Y to this question.

config BLK_DEV_CS5536
tristate "CS5536 chipset support"
depends on X86_32
select BLK_DEV_IDEDMA_PCI
help
This option enables support for the AMD CS5536
companion chip used with the Geode LX processor family.

If unsure, say N.

config BLK_DEV_HPT366
tristate "HPT36X/37X chipset support"
select BLK_DEV_IDEDMA_PCI
Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/ide/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ obj-$(CONFIG_BLK_DEV_CMD64X) += cmd64x.o
obj-$(CONFIG_BLK_DEV_CS5520) += cs5520.o
obj-$(CONFIG_BLK_DEV_CS5530) += cs5530.o
obj-$(CONFIG_BLK_DEV_CS5535) += cs5535.o
obj-$(CONFIG_BLK_DEV_CS5536) += cs5536.o
obj-$(CONFIG_BLK_DEV_SC1200) += sc1200.o
obj-$(CONFIG_BLK_DEV_CY82C693) += cy82c693.o
obj-$(CONFIG_BLK_DEV_DELKIN) += delkin_cb.o
Expand Down
Loading

0 comments on commit 2f5313e

Please sign in to comment.