Btrfs: autodetect SSD devices

During mount, btrfs will check the queue nonrot flag
for all the devices found in the FS.  If they are all
non-rotating, SSD mode is enabled by default.

If the FS was mounted with -o nossd, the non-rotating
flag is ignored.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
This commit is contained in:
Chris Mason
2009-06-10 09:51:32 -04:00
parent 451d7585a8
commit c289811cc0
5 changed files with 24 additions and 0 deletions

View File

@ -107,6 +107,11 @@ struct btrfs_fs_devices {
int seeding;
int opened;
/* set when we find or add a device that doesn't have the
* nonrot flag set
*/
int rotating;
};
struct btrfs_bio_stripe {