public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: linux-ia64@vger.kernel.org
Subject: Re: [PATCH 3/4] SGI Altix cross partition functionality
Date: Sun, 11 Jul 2004 10:11:27 +0000	[thread overview]
Message-ID: <20040711101127.GB11249@infradead.org> (raw)
In-Reply-To: <20040617183638.GA3712@sgi.com>

On Wed, Jul 07, 2004 at 02:40:17PM -0500, Dean Nelson wrote:
> > +	memset((u8 *)&part->references + sizeof(part->references), 0,
> > 
> > cast to u8 * in memset? Ummm..
> 
> I'm not exactly sure what you're objecting to here. The cast is necessary for
> a correct result. The following two lines do not give the same result (the
> 'references' field is an atomic_t):

Actually I was misreading the code to see a simple case to (u8 *) of the
variable, but the actual code looks even more fishy now that I look in-depth
;-)

What about the readable variant:

memset(&part->nchannels, 0,
       sizeof(xpc_partition_t) - offsetoff(xpc_partition_t, nchannels));


      parent reply	other threads:[~2004-07-11 10:11 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-17 18:36 [PATCH 3/4] SGI Altix cross partition functionality Dean Nelson
2004-06-17 19:22 ` Christoph Hellwig
2004-06-17 19:42 ` Dean Nelson
2004-06-22 18:17 ` Dean Nelson
2004-06-22 18:26 ` Christoph Hellwig
2004-07-07 19:40 ` Dean Nelson
2004-07-11 10:11 ` Christoph Hellwig [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=20040711101127.GB11249@infradead.org \
    --to=hch@infradead.org \
    --cc=linux-ia64@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox