public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCHv2] hpsa: expose enclosures
@ 2017-02-23 10:55 Hannes Reinecke
  2017-03-07 15:05 ` Don Brace
  0 siblings, 1 reply; 4+ messages in thread
From: Hannes Reinecke @ 2017-02-23 10:55 UTC (permalink / raw)
  To: Martin K. Petersen
  Cc: Christoph Hellwig, James Bottomley, linux-scsi, Hannes Reinecke,
	Don Brace, Hannes Reinecke

Some servers have a built-in enclosure which will show up on the
same bus as the internal physical devices. This patch fixes the
driver to expose them.

Cc: Don Brace <don.brace@microsemi.com>
Signed-off-by: Hannes Reinecke <hare@suse.com>
---
 drivers/scsi/hpsa.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c
index 524a0c7..a77ed5a 100644
--- a/drivers/scsi/hpsa.c
+++ b/drivers/scsi/hpsa.c
@@ -4407,7 +4407,10 @@ static void hpsa_update_scsi_devices(struct ctlr_info *h)
 		 * Expose all devices except for physical devices that
 		 * are masked.
 		 */
-		if (MASKED_DEVICE(lunaddrbytes) && this_device->physical_device)
+		if (this_device->devtype == TYPE_ENCLOSURE)
+			this_device->expose_device = 1;
+		else if (MASKED_DEVICE(lunaddrbytes) &&
+			 this_device->physical_device)
 			this_device->expose_device = 0;
 		else
 			this_device->expose_device = 1;
-- 
1.8.5.6

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-03-07 23:19 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-23 10:55 [PATCHv2] hpsa: expose enclosures Hannes Reinecke
2017-03-07 15:05 ` Don Brace
2017-03-07 15:24   ` Hannes Reinecke
2017-03-07 16:33     ` Don Brace

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox