All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steffen Maier <maier@linux.vnet.ibm.com>
To: Hannes Reinecke <hare@suse.de>,
	"Martin K. Petersen" <martin.petersen@oracle.com>
Cc: Christoph Hellwig <hch@lst.de>, Ewan Milne <emilne@redhat.com>,
	linux-scsi@vger.kernel.org, James Bottomley <jbottomley@odin.com>
Subject: Re: [PATCH 0/2] scsi_transport_fc: LUN masking
Date: Thu, 12 Nov 2015 14:33:26 +0100	[thread overview]
Message-ID: <56449526.5090405@linux.vnet.ibm.com> (raw)
In-Reply-To: <1447238080-109942-1-git-send-email-hare@suse.de>

Hi Hannes,

On 11/11/2015 11:34 AM, Hannes Reinecke wrote:
> having been subjected to the pain of trying to bootstrap a really
> large machine with systemd I decided to implement LUN masking in

This is very interesting.

I also thought about initiator-based LUN masking a while ago.
While scsi_transport_fc would be sufficient to allow zfcp to get rid of 
its own implementation, I wonder why we wouldn't do it in the midlayer's 
scsi_scan.c. This would provide initiator-based LUN masking for any and 
all transports and LLDDs?

(I also thought about initiator-based zoning, and that would indeed be 
something for scsi_transport_fc because it is inherently transport 
specific.)

> scsi_transport_fc.
> The principle is simple: disallow the automated LUN scanning when
> discovering a rport, and create udev rules which selectively
> enable individual LUNs by echoing the relevant values in the 'scan'
> attribute of the SCSI host.

I imagined exactly the same existing user space interface.

Now we "only" need some user-friendly user space tooling, which provides 
transport specific user arguments automatically translated into the 
midlayer naming scheme, such as converting FC SAN addressing (HBA device 
bus-ID,WWPN,FCPLUN) into scsi_device names (Scsi_Host,0,scsi_id,scsi_lun),
and some persistency mechanism (such as managing udev rules).

> With that I'm able to boot an arbitrary large machine without
> running into any udev or systemd imposed timeout.
> To _disable_ LUN masking and restoring the original behaviour
> I've noticed that the 'scan' sysfs attribute is actually synchronous,
> ie the calling process will be blocked until the entire LUN scan
> is completed.
> So I've added another module parameter 'async_user_scan' to
> move the scanning onto the existing scan workqueue, and unblock
> the calling process.

Just curious: Which means would a user of async_user_scan have to sync 
against the completion?
Or is this only meant for user space--I currently cannot imagine--which 
does not care about the appearance of what was (newly) discovered?

>
> As usual, comments and reviews are welcome.
>
> Hannes Reinecke (2):
>    scsi_transport_fc: implement 'disable_target_scan' module parameter
>    scsi_transport_fc: Implement 'async_user_scan' module parameter
>
>   drivers/scsi/scsi_transport_fc.c | 47 +++++++++++++++++++++++++++++++++++++---
>   1 file changed, 44 insertions(+), 3 deletions(-)
>

-- 
Mit freundlichen Grüßen / Kind regards
Steffen Maier

Linux on z Systems Development

IBM Deutschland Research & Development GmbH
Vorsitzende des Aufsichtsrats: Martina Koederitz
Geschaeftsfuehrung: Dirk Wittkopp
Sitz der Gesellschaft: Boeblingen
Registergericht: Amtsgericht Stuttgart, HRB 243294

--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2015-11-12 13:33 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-11 10:34 [PATCH 0/2] scsi_transport_fc: LUN masking Hannes Reinecke
2015-11-11 10:34 ` [PATCH 1/2] scsi_transport_fc: implement 'disable_target_scan' module parameter Hannes Reinecke
2016-03-01  5:48   ` Seymour, Shane M
2015-11-11 10:34 ` [PATCH 2/2] scsi_transport_fc: Implement 'async_user_scan' " Hannes Reinecke
2015-11-12 13:33 ` Steffen Maier [this message]
2015-11-12 14:00   ` [PATCH 0/2] scsi_transport_fc: LUN masking Hannes Reinecke
2016-01-29 14:57 ` Hannes Reinecke
2016-01-29 14:59   ` Hannes Reinecke
2016-02-02  0:37   ` Martin K. Petersen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=56449526.5090405@linux.vnet.ibm.com \
    --to=maier@linux.vnet.ibm.com \
    --cc=emilne@redhat.com \
    --cc=hare@suse.de \
    --cc=hch@lst.de \
    --cc=jbottomley@odin.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.