Add an API to list drivers grouped by device

Bug #1025323 reported by Didier Roche-Tolomelli
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ubuntu-drivers-common (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

In the nvidia case with nouveau or fglrx, the backend can know that we have such a device and so present those list of free drivers along the way.

We can imagine a detect.system_device_drivers() call which return a tuple
{'</dev/syspath>': {''nvidia-current': {'virtual': False},
                                   'nouveau': {'virtual': True, 'description': 'Nouveau driver for nvidia cards'},
'</dev/syspath2>": …}

Devices with only external modules will have all the virtual property to False.
Some device like nvidia or ATI which have kernel drivers if no external module is used will have one heuristically detected driver with the driver name and a full description.

Another API we can imagine is:

{'</dev/syspath>': {'model': 'GT218 [GeForce 8400 GS]',
                                   'modalias': 'pci:v000010DEd000010C3sv00sd01bc03sc00i00',
                                   'vendor': 'NVIDIA Corporation'
                                   'drivers': {'nvidia-current': {'free': False,
                                                                                      'from_distro': True
                                                                                      'type': 'package'},
                                                    'nouveau': {'description': 'Nouveau driver for nvidia cards',
                                                                         'type': virtual'},
                                                    }
                                     },
'<…other syspath>':…
}

This has the convenience to somewhat nest the system_driver_packages() call into this system_device_drivers() call.

Martin Pitt (pitti)
summary: - Add an API to list free drivers by kernel
+ Add an API to list drivers grouped by device
Martin Pitt (pitti)
Changed in ubuntu-drivers-common (Ubuntu):
status: New → In Progress
assignee: nobody → Martin Pitt (pitti)
Revision history for this message
Martin Pitt (pitti) wrote :
Changed in ubuntu-drivers-common (Ubuntu):
assignee: Martin Pitt (pitti) → nobody
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubuntu-drivers-common - 1:0.2.65

---------------
ubuntu-drivers-common (1:0.2.65) quantal; urgency=low

  * UbuntuDrivers/detect.py, system_driver_packages(): Add 'recommended' flag
    to the nvidia-* and fglrx-* packages, which usually provide more than one
    package for a particular device. (LP: #1025315)
  * UbuntuDrivers/detect.py, auto_install_filter(): Filter out non-recommended
    packages, to avoid installing multiple versions of the NVidia or FGLRX
    driver.
  * UbuntuDrivers/detect.py: Change return value of detect_plugin_packages()
    to a plugin_name → [package, ...] map, so that we retain the plugin names.
  * UbuntuDrivers/detect.py: Add system_device_drivers() API to get a
    by-device view of drivers, plus OS builtin free alternatives (such as
    Nouveau). Add it to README as well. (LP: #1025323)
  * ubuntu-drivers: Add "device" command to show by-device drivers as reported
    by system_device_drivers().
 -- Martin Pitt <email address hidden> Tue, 17 Jul 2012 15:48:44 +0200

Changed in ubuntu-drivers-common (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.