mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
nvme-fabrics: don't check for non-NULL module in nvmf_register_transport
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 <[email protected]>
Reviewed-by: Sagi Grimberg <[email protected]>
Reviewed-by: Johannes Thumshirn <[email protected]>
Signed-off-by: Keith Busch <[email protected]>
This commit is contained in:
parent
af27d9403f
commit
5a1e595333
1 changed files with 1 additions and 1 deletions
|
|
@ -493,7 +493,7 @@ EXPORT_SYMBOL_GPL(nvmf_should_reconnect);
|
|||
*/
|
||||
int nvmf_register_transport(struct nvmf_transport_ops *ops)
|
||||
{
|
||||
if (!ops->create_ctrl || !ops->module)
|
||||
if (!ops->create_ctrl)
|
||||
return -EINVAL;
|
||||
|
||||
down_write(&nvmf_transports_rwsem);
|
||||
|
|
|
|||
Loading…
Reference in a new issue