mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-15 12:54:27 +00:00
ofw_firmware: Only match if there is no compatible
If there is a compatible string it likely means that the firmware needs
a dedicated driver (like on RPI*).
PR: 273087
Tested-by: Mark Millard <marklmi26-fbsd@yahoo.com>
Sponsored by: Beckhoff Automation GmbH & Co. KG
Fixes: fdfd3a90b6
("ofw: Add a ofw_firmware driver")
This commit is contained in:
parent
a953ac19db
commit
69f8cc60aa
|
@ -100,11 +100,14 @@ ofw_firmware_add_device(device_t dev, phandle_t node, u_int order,
|
|||
static int
|
||||
ofw_firmware_probe(device_t dev)
|
||||
{
|
||||
const char *name;
|
||||
const char *name, *compat;
|
||||
|
||||
name = ofw_bus_get_name(dev);
|
||||
if (name == NULL || strcmp(name, "firmware") != 0)
|
||||
return (ENXIO);
|
||||
compat = ofw_bus_get_compat(dev);
|
||||
if (compat != NULL)
|
||||
return (ENXIO);
|
||||
|
||||
device_set_desc(dev, "OFW Firmware Group");
|
||||
return (0);
|
||||
|
|
Loading…
Reference in a new issue