mirror of
https://git.proxmox.com/git/fwupd
synced 2025-08-09 13:40:00 +00:00
vli: Skip probing the Dell DA300 device
Although 2109:2820 and 2109:0820 is the generic reference firmware, firmware revision 3003 is specific to this device. Fixes https://github.com/fwupd/fwupd/issues/4305
This commit is contained in:
parent
2472b51b9e
commit
7ef94d7a31
@ -237,6 +237,8 @@ fu_device_internal_flag_to_string(FuDeviceInternalFlags flag)
|
|||||||
return "md-set-vendor";
|
return "md-set-vendor";
|
||||||
if (flag == FU_DEVICE_INTERNAL_FLAG_NO_LID_CLOSED)
|
if (flag == FU_DEVICE_INTERNAL_FLAG_NO_LID_CLOSED)
|
||||||
return "no-lid-closed";
|
return "no-lid-closed";
|
||||||
|
if (flag == FU_DEVICE_INTERNAL_FLAG_NO_PROBE)
|
||||||
|
return "no-probe";
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -297,6 +299,8 @@ fu_device_internal_flag_from_string(const gchar *flag)
|
|||||||
return FU_DEVICE_INTERNAL_FLAG_MD_SET_VENDOR;
|
return FU_DEVICE_INTERNAL_FLAG_MD_SET_VENDOR;
|
||||||
if (g_strcmp0(flag, "no-lid-closed") == 0)
|
if (g_strcmp0(flag, "no-lid-closed") == 0)
|
||||||
return FU_DEVICE_INTERNAL_FLAG_NO_LID_CLOSED;
|
return FU_DEVICE_INTERNAL_FLAG_NO_LID_CLOSED;
|
||||||
|
if (g_strcmp0(flag, "no-probe") == 0)
|
||||||
|
return FU_DEVICE_INTERNAL_FLAG_NO_PROBE;
|
||||||
return FU_DEVICE_INTERNAL_FLAG_UNKNOWN;
|
return FU_DEVICE_INTERNAL_FLAG_UNKNOWN;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4162,11 +4166,25 @@ fu_device_probe(FuDevice *self, GError **error)
|
|||||||
if (priv->done_probe)
|
if (priv->done_probe)
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
|
/* device self-assigned */
|
||||||
|
if (fu_device_has_internal_flag(self, FU_DEVICE_INTERNAL_FLAG_NO_PROBE)) {
|
||||||
|
g_set_error_literal(error, FWUPD_ERROR, FWUPD_ERROR_NOT_SUPPORTED, "not probing");
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
/* subclassed */
|
/* subclassed */
|
||||||
if (klass->probe != NULL) {
|
if (klass->probe != NULL) {
|
||||||
if (!klass->probe(self, error))
|
if (!klass->probe(self, error))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* vfunc skipped device */
|
||||||
|
if (fu_device_has_internal_flag(self, FU_DEVICE_INTERNAL_FLAG_NO_PROBE)) {
|
||||||
|
g_set_error_literal(error, FWUPD_ERROR, FWUPD_ERROR_NOT_SUPPORTED, "not probing");
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* success */
|
||||||
priv->done_probe = TRUE;
|
priv->done_probe = TRUE;
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
@ -4297,6 +4315,12 @@ fu_device_setup(FuDevice *self, GError **error)
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* vfunc skipped device */
|
||||||
|
if (fu_device_has_internal_flag(self, FU_DEVICE_INTERNAL_FLAG_NO_PROBE)) {
|
||||||
|
g_set_error_literal(error, FWUPD_ERROR, FWUPD_ERROR_NOT_SUPPORTED, "not probing");
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
/* run setup on the children too (unless done already) */
|
/* run setup on the children too (unless done already) */
|
||||||
children = fu_device_get_children(self);
|
children = fu_device_get_children(self);
|
||||||
for (guint i = 0; i < children->len; i++) {
|
for (guint i = 0; i < children->len; i++) {
|
||||||
|
@ -429,6 +429,15 @@ typedef guint64 FuDeviceInternalFlags;
|
|||||||
*/
|
*/
|
||||||
#define FU_DEVICE_INTERNAL_FLAG_NO_LID_CLOSED (1ull << 21)
|
#define FU_DEVICE_INTERNAL_FLAG_NO_LID_CLOSED (1ull << 21)
|
||||||
|
|
||||||
|
/**
|
||||||
|
* FU_DEVICE_INTERNAL_FLAG_NO_PROBE:
|
||||||
|
*
|
||||||
|
* Do not probe this device.
|
||||||
|
*
|
||||||
|
* Since: 1.7.6
|
||||||
|
*/
|
||||||
|
#define FU_DEVICE_INTERNAL_FLAG_NO_PROBE (1ull << 22)
|
||||||
|
|
||||||
/* accessors */
|
/* accessors */
|
||||||
gchar *
|
gchar *
|
||||||
fu_device_to_string(FuDevice *self);
|
fu_device_to_string(FuDevice *self);
|
||||||
|
@ -4,6 +4,7 @@ cargs = ['-DG_LOG_DOMAIN="FuPluginVliUsbhub"']
|
|||||||
install_data([
|
install_data([
|
||||||
'vli-pd.quirk',
|
'vli-pd.quirk',
|
||||||
'vli-usbhub.quirk',
|
'vli-usbhub.quirk',
|
||||||
|
'vli-usbhub-dell.quirk',
|
||||||
'vli-usbhub-lenovo.quirk',
|
'vli-usbhub-lenovo.quirk',
|
||||||
'vli-usbhub-hyper.quirk',
|
'vli-usbhub-hyper.quirk',
|
||||||
'vli-usbhub-bizlink.quirk',
|
'vli-usbhub-bizlink.quirk',
|
||||||
|
5
plugins/vli/vli-usbhub-dell.quirk
Normal file
5
plugins/vli/vli-usbhub-dell.quirk
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
# Dell DA300
|
||||||
|
[USB\VID_2109&PID_0820&REV_3003]
|
||||||
|
Flags = no-probe
|
||||||
|
[USB\VID_2109&PID_2820&REV_3003]
|
||||||
|
Flags = no-probe
|
Loading…
Reference in New Issue
Block a user