Subject: Re: struct buf's b_flags B_XXX
To: Bill Studenmund <wrstuden@netbsd.org>
From: Reinoud Zandijk <reinoud@netbsd.org>
List: tech-kern
Date: 02/15/2007 19:26:58
--bg08WKrSYDhXBjb5
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Dear Bill,
On Thu, Feb 15, 2007 at 09:35:46AM -0800, Bill Studenmund wrote:
> On Thu, Feb 15, 2007 at 05:06:55PM +0100, Reinoud Zandijk wrote:
> I do not object. While I have a suggestion, I think this change cleans
> things up in a very good way.
>
> I recommend something like B_DEVPRIVATE or B_DEVPRIVUSE, just to be
> clearer that it's for the device driver's use (as opposed to the buffer
> somehow is using a device). Since it seems the drivers end up making an
> internal define based on the main define (as opposed to the code directly
> using the main define), the length isn't that much of a concern.
i've thought about that too yes; problem is a bit that file systems might
also want to differentiate; so i ended up with the idea of a flag for
devices and a flag for file system use. Maybe we can one day get rid of the
negative b_lblkno's one day ;)
My naming scheme was
B_DEVUSE
B_FSUSE
B_LAYERUSE
but maybe a name like
B_DEVPRIVATE
B_FSPRIVATE
B_LAYERPRIVATE
would do better?
I'll commit then the b_DEVPRIVATE variant for i think thats more clear
indeed!
Thanks for the feedback :-)
Reinoud
--bg08WKrSYDhXBjb5
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (NetBSD)
iQEVAwUBRdSl6oKcNwBDyKpoAQJOugf/X2W9m+T5BBhDZi4MSsZaKuXl5+K0cfjd
m9C3nyq+cKcSBF0/7uNgTH64XtWEmvkJX/oOe0xZFXgEbUZSiZ7XAlOTq5IHOX48
PppYVnyw9VEG7IvRLIa1pBkkCdXF6K8/BkE/N0H43zntpJ4fMMnElx6Fvxd5Mf9g
qgJWQ4Q3y31Ngw4JluBzFfBiWjG5LcBepJm00m+hYhcZOZUtoYdLWOgcsfrZN2pT
/uyPjEnfsj3bqBB+3gGmOWViNqrDPTFEd2onwfg8kcfHYk0tQfoqv8yCT1dcJsiV
6NBrGNayR6C/MDBAzLslRNxHoTLkFJKjaZtbE5Ytmv0XbdeXRp9nMA==
=SCyy
-----END PGP SIGNATURE-----
--bg08WKrSYDhXBjb5--