All of lore.kernel.org
 help / color / mirror / Atom feed
* SCSI BLIST_*, sdev_bflags, and scsi_device flags
@ 2006-02-09 19:55 Alan Stern
  2006-02-10  0:17 ` Patrick Mansfield
  2006-02-10 10:36 ` Christoph Hellwig
  0 siblings, 2 replies; 8+ messages in thread
From: Alan Stern @ 2006-02-09 19:55 UTC (permalink / raw)
  To: SCSI development list

A fair number of SCSI BLIST bits have duplicate entries in the scsi_device 
structure (in one instance the meaning is inverted):

BLIST_BORKEN			borken
BLIST_SINGLELUN			single_lun
BLIST_USE_10_BYTE_MS		use_10_for_ms
BLIST_MS_SKIP_PAGE_08		skip_ms_page_8
BLIST_MS_SKIP_PAGE_3F		skip_ms_page_3f
BLIST_MS_192_BYTES_FOR_3F	use_192_bytes_for_3f
BLIST_RETRY_HWERROR		retry_hwerror
BLIST_NOT_LOCKABLE		lockable
BLIST_NOSTARTONADD		no_start_on_add

There's no good reason for this duplication.  It's largely historical; at 
the time the device flags were added there was no way to alter the bflags 
value.  Now there is, since sdev_bflags is stored in the scsi_device.

Should we keep this duplication?  Should we remove the device bits and use
the sdev_bflags bitmasks instead?  I presume we don't want to remove the
BLIST entries because they are visible to userspace.  (Although probably
some of them are not used anywhere at all.)

What about things like BLIST_REPORTLUN2 and BLIST_NOREPORTLUN?  They don't
mean anything for scsi_devices, only for scsi_targets.  Nevertheless they
are part of the same BLIST entries.  Again, I don't see any way around
that without affecting userspace.

Alan Stern


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

end of thread, other threads:[~2006-02-10 18:08 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-02-09 19:55 SCSI BLIST_*, sdev_bflags, and scsi_device flags Alan Stern
2006-02-10  0:17 ` Patrick Mansfield
2006-02-10  3:00   ` Alan Stern
2006-02-10 18:08     ` Patrick Mansfield
2006-02-10 10:36 ` Christoph Hellwig
2006-02-10 15:27   ` Alan Stern
2006-02-10 15:30     ` Matthew Wilcox
2006-02-10 15:58       ` Alan Stern

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.