Date: Tue, 20 May 2003 01:54:46 -0700 From: Terry Lambert <tlambert2@mindspring.com> To: Daniel O'Connor <doconnor@gsoft.com.au> Cc: freebsd-hackers@freebsd.org Subject: Re: cvs commit: src/release/alpha dokern.sh drivers.conf Message-ID: <3EC9ED56.56E9B12@mindspring.com> References: <20030518005055.GG12759@sunbay.com> <200305192355.h4JNtx4e076037@khavrinen.lcs.mit.edu> <200305201733.43619.doconnor@gsoft.com.au>
next in thread | previous in thread | raw e-mail | index | archive | help
Daniel O'Connor wrote: > Currently I don't see a way of extracting PCI IDs from module source in a > standard way which means the lists would have to be maintained manually and > that would _suck_. Perhaps some standard struct array could be used, and if > it isn't present then you can't do a guess about whether to load the module > or not, so you just prompt the user. Add a seperate section for it. See the "--remove-section" and the "--add-section" and "--change-section" arguments to the "objcopy" program for how to maintain the lists seperate from the driver (even works with binary-only drivers for which you don't have source, so long as there's a defined structure that's a known type for the ID list sources, and has a NULL terminator on the list and/or uses a linker set type construct). You could even have a program that you "objcopy" the section from the module into, which could then spit out source code by printing out the ID table by direct reference to the table itself; tack your new IDs to the end of the ID list that gets spit out, recompile it, and drop it; or just link against the same "bfd" library "objcopy" links against, and make a small edit program ("vielf" or whatever). -- Terry
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3EC9ED56.56E9B12>