drivers/wifi/generic: Use pci_dev_* operations for device ops
WiFi devices supported by the generic WiFi driver are PCIe devices which need to be managed using the standard pci_dev_* operations to read, set and enable resources. This change updates the device_operations structure `wifi_generic_ops` to use the standard pci_dev_* operations for these devices. BUG=b:169802515 BRANCH=zork Change-Id: I8b306259e205ecb963c0563000bd96ec6b978b8b Signed-off-by: Furquan Shaikh <furquan@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/46028 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Rob Barnes <robbarnes@google.com> Reviewed-by: Duncan Laurie <dlaurie@chromium.org> Reviewed-by: Michael Niewöhner <foss@mniewoehner.de> Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
This commit is contained in:
parent
f52e4a03ec
commit
7cb103461a
|
@ -4,6 +4,7 @@
|
||||||
#include <acpi/acpigen.h>
|
#include <acpi/acpigen.h>
|
||||||
#include <console/console.h>
|
#include <console/console.h>
|
||||||
#include <device/device.h>
|
#include <device/device.h>
|
||||||
|
#include <device/pci.h>
|
||||||
#include <device/pci_def.h>
|
#include <device/pci_def.h>
|
||||||
#include <sar.h>
|
#include <sar.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
@ -236,9 +237,11 @@ static void wifi_generic_fill_ssdt_generator(const struct device *dev)
|
||||||
wifi_generic_fill_ssdt(dev, dev->chip_info);
|
wifi_generic_fill_ssdt(dev, dev->chip_info);
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct device_operations wifi_generic_ops = {
|
struct device_operations wifi_generic_ops = {
|
||||||
.read_resources = noop_read_resources,
|
.read_resources = pci_dev_read_resources,
|
||||||
.set_resources = noop_set_resources,
|
.set_resources = pci_dev_set_resources,
|
||||||
|
.enable_resources = pci_dev_enable_resources,
|
||||||
|
.ops_pci = &pci_dev_ops_pci,
|
||||||
.acpi_name = wifi_generic_acpi_name,
|
.acpi_name = wifi_generic_acpi_name,
|
||||||
.acpi_fill_ssdt = wifi_generic_fill_ssdt_generator,
|
.acpi_fill_ssdt = wifi_generic_fill_ssdt_generator,
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue