Date: Tue, 19 Sep 2000 08:57:57 +0100 (BST) From: Doug Rabson <dfr@nlsystems.com> To: Warner Losh <imp@village.org> Cc: arch@freebsd.org Subject: Re: binary compat guidelines Message-ID: <Pine.BSF.4.21.0009190855270.86297-100000@salmon.nlsystems.com> In-Reply-To: <200009190544.XAA36298@harmony.village.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 18 Sep 2000, Warner Losh wrote: > > I'm wondering if we (the FreeBSD project) has guidelines for kernel > binary compatibility over time. What things are allowed? What things > are bogus? > > I've been following the rules. I've been focused on the card driver > <-> bus driver interface, so these are slanted. > o use kobj > o don't add args to functions called with kobj > o use only basic types in args. If pointers are used, they > aren't dereferenced by the driver directly. > o use ivars. icky but useful. > o OK to make calls to external functions, not all calls must > be brokered through kobj. These are convenience functions. > o no sizeof(struct foo) > o no offsetof > And some silly things I've done or cleaned up in the past: > o Don't have module symbol interdependencies > > Any others? Anything stupid I'm doing? This looks like a good set of rules for avoiding certain kinds of ABI change. For added longevity, you need to isolate yourself from the various kernel data structures which tend to change frequently. -- Doug Rabson Mail: dfr@nlsystems.com Nonlinear Systems Ltd. Phone: +44 20 8348 3944 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0009190855270.86297-100000>