diff options
author | Geliang Tang <geliangtang@gmail.com> | 2019-04-24 19:48:29 +0300 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2019-04-24 19:56:27 +0300 |
commit | 792732d9852c0e4505aceff4631ea2168fd02480 (patch) | |
tree | 4dea3d30ac952c2a31d80fc4064ab724c13e5d5a /drivers/md/bcache/request.c | |
parent | 78d4eb8ad9e1d413449d1b7a060f50b6efa81ebd (diff) | |
download | linux-792732d9852c0e4505aceff4631ea2168fd02480.tar.xz |
bcache: use kmemdup_nul for CACHED_LABEL buffer
This patch uses kmemdup_nul to create a NUL-terminated string from
dc->sb.label. This is better than open coding it.
With this, we can move env[2] initialization into env[] array to make
code more elegant.
Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Signed-off-by: Coly Li <colyli@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/md/bcache/request.c')
0 files changed, 0 insertions, 0 deletions