fwupd/plugins/udev
Richard Hughes ff704414f6 Use superclassed versions of FuDevice when calling udev_added() and usb_added()
The daemon creates a baseclass of either FuUsbDevice or FuUdevDevice when the
devices are added or coldplugged to match the quirk database and to find out
what plugin to run.

This is proxied to plugins, but they are given the GUsbDevice or GUdevDevice and
the FuDevice is just thrown away. Most plugins either use a FuUsbDevice or
superclassed version like FuNvmeDevice and so we re-create the FuDevice, re-probe
the hardware, re-query the quirk database and then return this to the daemon.

In some cases, plugins actually probe the hardware three times (!) by creating
a FuUsbDevice to get the quirks, so that the plugin knows what kind of
superclass to create, which then itself probes the hardware again.

Passing the temporary FuDevice to the plugins means that the simplest ones can
just fu_plugin_device_add() the passed in object, or create a superclass and
incorporate the actual GUsbDevice and all the GUIDs.

This breaks internal plugin API but speeds up startup substantially and deletes
a lot of code.
2018-09-04 08:22:39 -05:00
..
fuzzing Move the Option ROM parsing to the Udev plugin 2016-12-15 17:09:38 +00:00
tests Move the Option ROM parsing to the Udev plugin 2016-12-15 17:09:38 +00:00
fu-plugin-udev.c Use superclassed versions of FuDevice when calling udev_added() and usb_added() 2018-09-04 08:22:39 -05:00
fu-rom-tool.c Remove the unused Emacs indenting headers from all source files 2018-08-09 12:48:04 +01:00
fu-rom.c Remove the unused Emacs indenting headers from all source files 2018-08-09 12:48:04 +01:00
fu-rom.h Remove the unused Emacs indenting headers from all source files 2018-08-09 12:48:04 +01:00
fu-self-test.c Remove the unused Emacs indenting headers from all source files 2018-08-09 12:48:04 +01:00
fuzzing.md Move the Option ROM parsing to the Udev plugin 2016-12-15 17:09:38 +00:00
meson.build trivial: Move gudev to the core plugin deps 2018-08-26 19:38:58 +01:00
README.md Convert the providers to plugins to simplify code and for future features 2016-12-12 12:31:23 +00:00

UDev Support

Introduction

This plugin reads the version numbers of PCI devices. It cannot deploy firmware onto devices but is used to list devices with known firmware updates that may require booting into another operating system to apply.

This plugin is also able to read and parse the firmware of some PCI devices which allows some host state verification to be done.