target driver question
Chuck Tuffli
chuck_tuffli at agilent.com
Thu Jan 15 07:20:51 PST 2004
Justin -
Thanks for the response. See below
On Wed, Jan 14, 2004 at 09:37:29PM -0700, Justin T. Gibbs wrote:
> >
> > When this driver receives a CDB, it needs to save away some information
> > specific to that IO for later use in the CONT_TARGET_IO phase.
>
> Can you explain what type of data this is?
This is a fibre channel target driver. So the data consists of login
information about the initiator on the other side of the link, an
exchange ID (OX_ID), and a couple of chip resources specific to this
IO.
> The two other drivers that perform target mode in FreeBSD do not require
> any data other than the init_id and tag_id to be "round-tripped" through
Does the combo of init_id and tag_id uniquely identify an IO? If so, I
guess the driver could keep track of the IO specific data in a "table"
indexed by init_id/tag_id.
> the target emulator. I would rather not have the target emulator touch *any*
> of the private data or to see a SIM driver rely on anything other than the
> standard fields in the CTIO. If this is absolutely necessary, we can
> add a way to refer to the ATIO from the CTIO since the ATIO lifetime
> is the lifetime of the SCSI transaction being serviced.
I think I can live with this. The above is a little bit more work, but
not a big deal. Other layered driver code that I've worked on before
either had a concept of handles or provided a hook for private (device
dependent) data. When I saw the sim_priv structure, that is what I
expected it to be.
Again, thank you for your help!
---chuck
--
Chuck Tuffli <chuck_tuffli AT NO_SPAM agilent DOT com>
Agilent Technologies, Storage Area Networking
More information about the freebsd-scsi
mailing list