]> git.baikalelectronics.ru Git - kernel.git/commit
block/mq-deadline: Improve the sysfs show and store macros
authorBart Van Assche <bvanassche@acm.org>
Fri, 18 Jun 2021 00:44:50 +0000 (17:44 -0700)
committerJens Axboe <axboe@kernel.dk>
Mon, 21 Jun 2021 21:03:40 +0000 (15:03 -0600)
commit13f1b1785115fe9378f110a723700d9cc44a10b8
treec46f71bb44d9ad64258542b106d0a74b127a3e2d
parent5de19a41211f3f93dbb4997da3bd7cd874775dde
block/mq-deadline: Improve the sysfs show and store macros

Define separate macros for integers and jiffies to improve readability.
Use sysfs_emit() and kstrtoint() instead of sprintf() and simple_strtol().
The former functions are the recommended functions.

Cc: Damien Le Moal <damien.lemoal@wdc.com>
Cc: Hannes Reinecke <hare@suse.de>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Ming Lei <ming.lei@redhat.com>
Cc: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Cc: Himanshu Madhani <himanshu.madhani@oracle.com>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Link: https://lore.kernel.org/r/20210618004456.7280-11-bvanassche@acm.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/mq-deadline.c