projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
060fd19
)
null_blk: use available 'dev' in nullb_device_power_store()
author
Jens Axboe
<axboe@kernel.dk>
Mon, 28 Aug 2017 21:06:31 +0000
(15:06 -0600)
committer
Jens Axboe
<axboe@kernel.dk>
Mon, 28 Aug 2017 21:06:31 +0000
(15:06 -0600)
We already have this pointer, no need to use to_nullb_device()
again.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/null_blk.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/block/null_blk.c
b/drivers/block/null_blk.c
index 3b5cabe374d29948e72ebea8c4b2211299e7956f..bd922868a8614fe6f1247f0b24e6cb94888810b9 100644
(file)
--- a/
drivers/block/null_blk.c
+++ b/
drivers/block/null_blk.c
@@
-375,7
+375,7
@@
static ssize_t nullb_device_power_store(struct config_item *item,
set_bit(NULLB_DEV_FL_CONFIGURED, &dev->flags);
dev->power = newp;
- } else if (
to_nullb_device(item)
->power && !newp) {
+ } else if (
dev
->power && !newp) {
mutex_lock(&lock);
dev->power = newp;
null_del_dev(dev->nullb);