public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Jeremy Higdon <jeremy@sgi.com>
To: James Bottomley <James.Bottomley@steeleye.com>
Cc: Martin Hicks <mort@wildopensource.com>,
	SCSI Mailing List <linux-scsi@vger.kernel.org>
Subject: Re: Transport Attributes -- attempt#4
Date: Tue, 24 Feb 2004 23:08:47 -0800	[thread overview]
Message-ID: <20040225070847.GA504005@sgi.com> (raw)
In-Reply-To: <1077634979.1827.7.camel@mulgrave>

On Tue, Feb 24, 2004 at 09:02:56AM -0600, James Bottomley wrote:
> On Mon, 2004-02-23 at 23:58, Jeremy Higdon wrote:
> > James, was scsi/scsi_transport.h supposed to be patched also?
> > There is a new "size" member of the scsi_transport_template
> > structure, but no patch to the data structure itself.  Did you
> > replace attributes with size?
> 
> Well, not really.  The patch I provided is a sketch only of what I want
> done.  It compiles and works on the 53c700 which is where I tested it.
> 
> Really, I just want transport and core separated and transport
> attributes to be fixed (so there's some way of defining a transport
> private API for updating them).
> 
> Even with just offset and period as the transport attributes for SPI,
> that gives enough to move domain validation out of all the drivers into
> the SPI transport layer.

Okay, that's fine.

What I meant to say is that I get a compile error at the following
line in scsi_scan.c:

	sdev = kmalloc(sizeof(*sdev) + shost->transportt->size, GFP_ATOMIC);

In Martin's version of scsi_transport.h, there is no "size" member of
struct scsi_transport_template.

So I figured you must have left it out of your patch.  I also saw this
in your patch, which makes it look as though default_attr_values (mistakenly
called "attributes" by me above) was replaced by size:

 struct scsi_transport_template spi_transport_template = {
        .attrs = spi_transport_attrs,
        .class = &spi_transport_class,
-       .setup = &spi_alloc_transport_attrs,
-       .cleanup = &spi_destroy_transport_attrs,
-       .default_attr_values = &spi_transport_attr_defaults,
+       .setup = &spi_setup_transport_attrs,
+       .cleanup = NULL,
+       .size = sizeof(struct spi_transport_attrs) - sizeof(unsigned long),
 };

thanks

jeremy

  reply	other threads:[~2004-02-25  7:08 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-20 21:56 Transport Attributes -- attempt#4 Martin Hicks
2004-01-20 23:48 ` Patrick Mansfield
2004-02-24  0:17 ` James Bottomley
2004-02-24  5:58   ` Jeremy Higdon
2004-02-24 15:02     ` James Bottomley
2004-02-25  7:08       ` Jeremy Higdon [this message]
2004-02-25 16:42         ` James Bottomley
2004-03-04 16:14   ` Martin Hicks

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=20040225070847.GA504005@sgi.com \
    --to=jeremy@sgi.com \
    --cc=James.Bottomley@steeleye.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mort@wildopensource.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox