nvme-fabrics: don't check for non-NULL module in nvmf_register_transport
authorChristoph Hellwig <hch@lst.de>
Thu, 22 Feb 2018 15:24:08 +0000 (07:24 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 12 Apr 2018 10:31:07 +0000 (12:31 +0200)
commitab0ba11b94b5e4ce7fce6d3f18c9d47e065b8ef4
tree15eb2505ce07c62e47058b8f3d71246b95decd2b
parent2c624d6fede9a0c3f2ae66518ab0e9847b3bd4fe
nvme-fabrics: don't check for non-NULL module in nvmf_register_transport

commit 5a1e59533380a3fd04593e4ab2d4633ebf7745c1 upstream.

THIS_MODULE evaluates to NULL when used from code built into the kernel,
thus breaking built-in transport modules.  Remove the bogus check.

Fixes: 0de5cd36 ("nvme-fabrics: protect against module unload during create_ctrl")
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Keith Busch <keith.busch@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/nvme/host/fabrics.c