Patch "nvme-fabrics: don't check for non-NULL module in nvmf_register_transport" has been added to the 4.15-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    nvme-fabrics: don't check for non-NULL module in nvmf_register_transport

to the 4.15-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     nvme-fabrics-don-t-check-for-non-null-module-in-nvmf_register_transport.patch
and it can be found in the queue-4.15 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From 5a1e59533380a3fd04593e4ab2d4633ebf7745c1 Mon Sep 17 00:00:00 2001
From: Christoph Hellwig <hch@xxxxxx>
Date: Thu, 22 Feb 2018 07:24:08 -0800
Subject: nvme-fabrics: don't check for non-NULL module in nvmf_register_transport

From: Christoph Hellwig <hch@xxxxxx>

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@xxxxxx>
Reviewed-by: Sagi Grimberg <sagi@xxxxxxxxxxx>
Reviewed-by: Johannes Thumshirn <jthumshirn@xxxxxxx>
Signed-off-by: Keith Busch <keith.busch@xxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

---
 drivers/nvme/host/fabrics.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/nvme/host/fabrics.c
+++ b/drivers/nvme/host/fabrics.c
@@ -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);


Patches currently in stable-queue which might be from hch@xxxxxx are

queue-4.15/nvme_fcloop-fix-abort-race-condition.patch
queue-4.15/blk-mq-avoid-to-map-cpu-into-stale-hw-queue.patch
queue-4.15/scsi-libsas-initialize-sas_phy-status-according-to-response-of-discover.patch
queue-4.15/nvme-fabrics-protect-against-module-unload-during-create_ctrl.patch
queue-4.15/nvme_fcloop-disassocate-local-port-structs.patch
queue-4.15/nvme-fabrics-don-t-check-for-non-null-module-in-nvmf_register_transport.patch
queue-4.15/scsi-libsas-fix-error-when-getting-phy-events.patch
queue-4.15/blk-mq-fix-race-between-updating-nr_hw_queues-and-switching-io-sched.patch
queue-4.15/scsi-libsas-fix-memory-leak-in-sas_smp_get_phy_events.patch
queue-4.15/scsi-libsas-use-dynamic-alloced-work-to-avoid-sas-event-lost.patch



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]