### Virtual Method

# FwupdPlugin Backend get_device_parent

#### Declaration [src]

    FuDevice*
    get_device_parent (
      FuBackend* self,
      FuDevice* device,
      const gchar* subsystem,
      GError** error
    )

#### Description [src]

Asks the backend to create the parent device (of the correct type) for a given device subsystem.

Available since: | 2.0.0

#### Parameters

`device` | `FuDevice`
| A `FuDevice`.
| The data is owned by the caller of the function.
`subsystem` | `const gchar*`
| An optional device subsystem, e.g. “usb:usb_device”
| The argument can be `NULL`.
| The data is owned by the caller of the function.
| The value is a NUL terminated UTF-8 string.
`error` | `GError **`
| The return location for a `GError*`, or `NULL`.

#### Return value

Returns: | `FuDevice`
| A `FuDevice` or `NULL` if not found or unimplemented.
| The caller of the function takes ownership of the data, and is responsible for freeing it.