All of lore.kernel.org
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: Christoph Hellwig <hch@lst.de>
Cc: Hannes Reinecke <hare@suse.de>, linux-scsi@vger.kernel.org
Subject: Re: [PATCHv2] libsas: Fixup transport protocol definition in sas_get_ata_info()
Date: Tue, 07 Apr 2015 08:59:23 -0700	[thread overview]
Message-ID: <1428422363.15207.45.camel@HansenPartnership.com> (raw)
In-Reply-To: <20150407154550.GA18837@lst.de>

On Tue, 2015-04-07 at 17:45 +0200, Christoph Hellwig wrote:
> On Tue, Apr 07, 2015 at 10:49:07AM +0200, Hannes Reinecke wrote:
> > 'tproto' specifies the transport protocol, not the device type.
> > So use the correct definitions here.
> > 
> > Signed-off-by: Hannes Reinecke <hare@suse.de>
> 
> This looks correct, but opens up questions:

I'm not entirely convinced it is.  I think the correct value might be
SAS_PROTOCOL_SATA | SAS_PROTOCOL_STP which is the same numeric value as
SAS_SATA_DEV.

STP is the SATA Tunnelling Protocol.  It's what you use to talk to an
expander with a directly attached SATA device on one of its ports.
SAS_PROTOCOL_SATA means talk directly to the device using SATA (not SAS
tunnelled SATA) and is only appropriate for a SATA device directly
attached to the SAS initiator.

This function is examining an expander phy, so the initiator will always
have to speak STP to it, regardless of what the actual value is.

James

>  - how did you find this?
>  - why didn't we notice earlier?
> 
> Also I wonder if we should move to more __bitwise types for these
> kinds of things..
> --
> 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
> 




      reply	other threads:[~2015-04-07 15:59 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-07  8:49 [PATCHv2] libsas: Fixup transport protocol definition in sas_get_ata_info() Hannes Reinecke
2015-04-07 15:45 ` Christoph Hellwig
2015-04-07 15:59   ` James Bottomley [this message]

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=1428422363.15207.45.camel@HansenPartnership.com \
    --to=james.bottomley@hansenpartnership.com \
    --cc=hare@suse.de \
    --cc=hch@lst.de \
    --cc=linux-scsi@vger.kernel.org \
    /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.