OpenCloudOS-Kernel/drivers/lightnvm
Arnd Bergmann 1e3aeae4ea lightnvm: propagate device_add() error code
device_add() may fail, and all callers are supposed to check the
return value, but one new user in lightnvm doesn't:

drivers/lightnvm/sysfs.c: In function 'nvm_sysfs_register_dev':
drivers/lightnvm/sysfs.c:184:2: error: ignoring return value of 'device_add',
  declared with attribute warn_unused_result [-Werror=unused-result]

This changes the caller to propagate any error codes, which avoids
the warning.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 38c9e260b9f9 ("lightnvm: expose device geometry through sysfs")
Signed-off-by: Matias Bjørling <m@bjorling.me>
Signed-off-by: Jens Axboe <axboe@fb.com>
2016-09-21 07:57:32 -06:00
..
Kconfig lightnvm: NVM should depend on HAS_DMA 2016-09-21 07:56:10 -06:00
Makefile lightnvm: expose device geometry through sysfs 2016-09-21 07:57:31 -06:00
core.c lightnvm: expose device geometry through sysfs 2016-09-21 07:57:31 -06:00
gennvm.c lightnvm: fix lun offset calculation for mark blk 2016-07-07 08:51:52 -06:00
gennvm.h lightnvm: move target mgmt into media mgr 2016-07-07 08:51:52 -06:00
lightnvm.h lightnvm: propagate device_add() error code 2016-09-21 07:57:32 -06:00
rrpc.c block: get rid of bio_rw and READA 2016-07-20 17:37:01 -06:00
rrpc.h lightnvm: make rrpc_map_page call nvm_get_blk outside locks 2016-07-07 08:51:52 -06:00
sysblk.c lightnvm: Make functions not used by ouside static 2016-07-07 08:51:52 -06:00
sysfs.c lightnvm: propagate device_add() error code 2016-09-21 07:57:32 -06:00