Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1414703

[PATCH 3/3] scsi: Use device_match_always()

From Thierry Reding <thierry.reding@gmail.com>
Newsgroups linux.kernel
Subject [PATCH 3/3] scsi: Use device_match_always()
Date 2016-06-06 09:40 +0200
Message-ID <rGXiG-1OJ-21@gated-at.bofh.it> (permalink)
References <rGXiG-1OJ-9@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Thierry Reding <treding@nvidia.com>

There is now a common implementation for a match function that will
always match, so the SCSI-specific implementation can be removed.

Signed-off-by: Thierry Reding <treding@nvidia.com>
---
 drivers/scsi/scsi_proc.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/drivers/scsi/scsi_proc.c b/drivers/scsi/scsi_proc.c
index 7a74b82e8973..4adcdc2caf27 100644
--- a/drivers/scsi/scsi_proc.c
+++ b/drivers/scsi/scsi_proc.c
@@ -371,15 +371,10 @@ static ssize_t proc_scsi_write(struct file *file, const char __user *buf,
 	return err;
 }
 
-static int always_match(struct device *dev, void *data)
-{
-	return 1;
-}
-
 static inline struct device *next_scsi_device(struct device *start)
 {
 	struct device *next = bus_find_device(&scsi_bus_type, start, NULL,
-					      always_match);
+					      device_match_always);
 	put_device(start);
 	return next;
 }
-- 
2.8.3

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

[PATCH 3/3] scsi: Use device_match_always() Thierry Reding <thierry.reding@gmail.com> - 2016-06-06 09:40 +0200

csiph-web