James Carlson wrote: > Scott Aitchison writes: > >> Thanks for your help Garrett. That did it. I come from a Linux background, >> so I'm still learning all these little details. >> >> Is there an approved way of calculating checksums (UDP/TCP/IP) on Solaris? >> Or is it up to the module writers to make their own? >> > > There are at least three viable ways of doing this that don't involve > duplicating code: > > - integrate your driver into ON, so that you're shipping in the same > consolidation as this Consolidation Private interface; > > - negotiate with the owners of the interface (start with > networking-discuss) to have the stability level raised, perhaps > making it part of the DDI, so that you can use it without trouble; > or > > - get an ARC contract on the interface so that the underlying > interface can't be changed without coordinating with you. > > In Solaris (and indeed across Sun), we intentionally separate the > world into "public" and "private" interfaces. The former are > documented and can change only in certain documented ways. The latter > are undocumented and may change without warning. > > "Private" here doesn't mean "secret." It merely means "not > documented." > > We do this intentionally to avoid the sorts of versioning madness that > afflicts some other software systems. The underlying idea is simple: > every project must explain what parts they expect others to use (their > "exported interfaces") and what things they're using that are defined > by others (their "imported interfaces"), and the ARC connects these > up. You're not allowed to use things from other projects in ways that > are contrary to what that other project specified. > >
Actually, it sounds like this particular kind of functionality is useful enough that it should be part of the DDI. There are functions like this (for example CRC functionality required for calculating hashes used in many ethernet MAC chips, SHA1 that is used in various places, etc.) that should really be part of a common DDI. They could be kept in separate modules, so that they don't increase the size of kernel/unix. I'd like to see a fasttrack for this. I'm not prepared to start one up myself, as I don't need it (right now), though for the CRC-32 functionality I have duplicated code in my Ethernet drivers. -- Garrett D'Amore, Principal Software Engineer Tadpole Computer / Computing Technologies Division, General Dynamics C4 Systems http://www.tadpolecomputer.com/ Phone: 951 325-2134 Fax: 951 325-2191 _______________________________________________ opensolaris-code mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/opensolaris-code
