On Fri, Dec 04, 2009 at 10:59:49AM +0100, Egbert Eich wrote:
The idea is that the install script for the proprietary driver would either set the global NO_KMS_IN_INITRD sysconfig variable or blacklist exactly those PCI ids in /etc/kms/
.blacklist and rerun mkinitrd. BTW, in which sysconfig file should this variable be set? Apparently it's not added by any of your patches, only checked in setup-kms.sh.
I've been thinking about the blacklisting some more. It's very easy to get the system inconsistent when we have different sort of blacklistings.
modprobe supports blacklisting per driver (not per modalias or any wildcared variant thereof). If we are willing to scarifice per device ID blacklisting we should simply go with the blacklisting modprobe supports. If we also make sure that options listed in /etc/modprobe.d/* are copied to initrd for the drivers copied to it then
- The user can disable KMS (per driver) by adding the a line options <drivername> modeset=0 to /etc/modprobe.d/options - ATI (as an example) can simply ship a file containing the line blacklist radeon and dump it into /etc/modprobe.d/ to prevent loading the radeon driver. rerunning mkinitrd will generate a new initrd without the radeon module.
Makes perfectly sense to me. ATI can run mkinitrd in %postin.
If we want black listing or option listing based on PCI Ids we'd have to provide a script which scans the hardware and adds appropirate entries to /etc/modprobe.d/. It would have to be rerun every time the hardware changes.
Assuming that drivers themselves provide such a blacklist file, this script could be run in %postin of such a driver package.
Expanding modprobe to perform such a mapping might be possible but I don't want to go this route without soliciting for feedback on opensuse-kernel.
Understood.
One reason for the vendors of proprietary drivers prefering to write 'nomodeset' to menu.list instead directly could be that this kind of works on Fedora, Ubuntu and openSUSE. Until it gets overwritten again on openSUSE later by the next kernel update or similar. Not sure whether changes in menu.lst are safe on Fedora/Ubuntu. Could be.
nomodeset will prevent KMS from being activated it will not prevent the driver from being loaded. Two different things. I would think what I suggested above will also work universally and doesn't involve tedious line parsing in menu.lst.
I agree. So the approach for the proprietary drivers is to ship a modprobe.d file blacklisting the opensource DRm modules to prevent them being loaded and added to initrd. Best regards, Stefan Public Key available ------------------------------------------------------ Stefan Dirsch (Res. & Dev.) SUSE LINUX Products GmbH Tel: 0911-740 53 0 Maxfeldstraße 5 FAX: 0911-740 53 479 D-90409 Nürnberg http://www.suse.de Germany ----------------------------------------------------------------- SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) ----------------------------------------------------------------- -- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-factory+help@opensuse.org