Date: Thu, 05 Jul 2001 08:35:32 -0600 From: "Justin T. Gibbs" <gibbs@scsiguy.com> To: Joerg Wunsch <joerg_wunsch@uriah.heep.sax.de> Cc: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/sys bio.h Message-ID: <200107051435.f65EZWU60519@aslan.scsiguy.com> In-Reply-To: Your message of "Tue, 03 Jul 2001 23:33:21 %2B0200." <20010703233321.C3398@uriah.heep.sax.de>
next in thread | previous in thread | raw e-mail | index | archive | help
>I don't need a private structure (i would have malloced it then), just
>a few values in a private scalar variable/field (only a couple of
>values would have sufficed for me, but bde pointed out that something
>like the ATA driver might have use for more distinct values here).
Why not use a union in bio for any "private use space" we care to
put in it? This is what cam does:
typedef union {
void *ptr;
u_long field;
u_int8_t bytes[sizeof(void *) > sizeof(u_long)
? sizeof(void *) : sizeof(u_long)];
} ccb_priv_entry;
--
Justin
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200107051435.f65EZWU60519>
