Replace DEVICE_NOOP with noop_(set|read)_resources

`.read_resources` and `.set_resources` are the only two device
operations that are considered mandatory. Other function pointers
can be left NULL. Having dedicated no-op implementations for the
two mandatory fields should stop the leaking of no-op pointers to
other fields.

Change-Id: I6469a7568dc24317c95e238749d878e798b0a362
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/40207
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Nico Huber
2020-04-05 14:05:24 +02:00
committed by Angel Pons
parent a461b694a6
commit 2f8ba69b0e
80 changed files with 150 additions and 150 deletions

View File

@ -127,8 +127,8 @@ static const char *root_dev_acpi_name(const struct device *dev)
* of a motherboard can override this if you want non-default behavior. * of a motherboard can override this if you want non-default behavior.
*/ */
struct device_operations default_dev_ops_root = { struct device_operations default_dev_ops_root = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.scan_bus = scan_static_bus, .scan_bus = scan_static_bus,
.reset_bus = root_dev_reset, .reset_bus = root_dev_reset,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)

View File

@ -127,8 +127,8 @@ static const char *crb_tpm_acpi_name(const struct device *dev)
} }
static struct device_operations __unused crb_ops = { static struct device_operations __unused crb_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_name = crb_tpm_acpi_name, .acpi_name = crb_tpm_acpi_name,
.acpi_fill_ssdt = crb_tpm_fill_ssdt, .acpi_fill_ssdt = crb_tpm_fill_ssdt,

View File

@ -55,8 +55,8 @@ static const char *adau7002_acpi_name(const struct device *dev)
#endif #endif
static struct device_operations adau7002_ops = { static struct device_operations adau7002_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_name = adau7002_acpi_name, .acpi_name = adau7002_acpi_name,
.acpi_fill_ssdt = adau7002_fill_ssdt, .acpi_fill_ssdt = adau7002_fill_ssdt,

View File

@ -68,8 +68,8 @@ static const char *generic_dev_acpi_name(const struct device *dev)
} }
static struct device_operations generic_dev_ops = { static struct device_operations generic_dev_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = generic_dev_acpi_name, .acpi_name = generic_dev_acpi_name,
.acpi_fill_ssdt = generic_dev_fill_ssdt_generator, .acpi_fill_ssdt = generic_dev_fill_ssdt_generator,
}; };

View File

@ -102,8 +102,8 @@ static const char *gpio_keys_acpi_name(const struct device *dev)
} }
static struct device_operations gpio_keys_ops = { static struct device_operations gpio_keys_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = gpio_keys_acpi_name, .acpi_name = gpio_keys_acpi_name,
.acpi_fill_ssdt = gpio_keys_fill_ssdt_generator, .acpi_fill_ssdt = gpio_keys_fill_ssdt_generator,
}; };

View File

@ -59,8 +59,8 @@ static const char *gpio_regulator_acpi_name(const struct device *dev)
} }
static struct device_operations gpio_regulator_ops = { static struct device_operations gpio_regulator_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = gpio_regulator_acpi_name, .acpi_name = gpio_regulator_acpi_name,
.acpi_fill_ssdt = gpio_regulator_fill_ssdt_generator, .acpi_fill_ssdt = gpio_regulator_fill_ssdt_generator,
}; };

View File

@ -95,7 +95,7 @@ static void ioapic_read_resources(struct device *dev)
static struct device_operations ioapic_operations = { static struct device_operations ioapic_operations = {
.read_resources = ioapic_read_resources, .read_resources = ioapic_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = ioapic_init, .init = ioapic_init,
}; };

View File

@ -70,8 +70,8 @@ static const char *max98357a_acpi_name(const struct device *dev)
#endif #endif
static struct device_operations max98357a_ops = { static struct device_operations max98357a_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_name = max98357a_acpi_name, .acpi_name = max98357a_acpi_name,
.acpi_fill_ssdt = max98357a_fill_ssdt, .acpi_fill_ssdt = max98357a_fill_ssdt,

View File

@ -78,8 +78,8 @@ static void adt7463_init(struct device *adt7463)
} }
static struct device_operations adt7463_operations = { static struct device_operations adt7463_operations = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = adt7463_init, .init = adt7463_init,
}; };

View File

@ -33,8 +33,8 @@ static void at24rf08c_init(struct device *dev)
} }
static struct device_operations at24rf08c_operations = { static struct device_operations at24rf08c_operations = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = at24rf08c_init, .init = at24rf08c_init,
}; };

View File

@ -46,8 +46,8 @@ static void ck505_init(struct device *dev)
} }
static struct device_operations ck505_operations = { static struct device_operations ck505_operations = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = ck505_init, .init = ck505_init,
}; };

View File

@ -98,8 +98,8 @@ static const char *da7219_acpi_name(const struct device *dev)
#endif #endif
static struct device_operations da7219_ops = { static struct device_operations da7219_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_name = da7219_acpi_name, .acpi_name = da7219_acpi_name,
.acpi_fill_ssdt = da7219_fill_ssdt, .acpi_fill_ssdt = da7219_fill_ssdt,

View File

@ -180,8 +180,8 @@ static const char *i2c_generic_acpi_name(const struct device *dev)
#endif #endif
static struct device_operations i2c_generic_ops = { static struct device_operations i2c_generic_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_name = i2c_generic_acpi_name, .acpi_name = i2c_generic_acpi_name,
.acpi_fill_ssdt = i2c_generic_fill_ssdt_generator, .acpi_fill_ssdt = i2c_generic_fill_ssdt_generator,

View File

@ -37,8 +37,8 @@ static const char *i2c_hid_acpi_name(const struct device *dev)
#endif #endif
static struct device_operations i2c_hid_ops = { static struct device_operations i2c_hid_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_name = i2c_hid_acpi_name, .acpi_name = i2c_hid_acpi_name,
.acpi_fill_ssdt = i2c_hid_fill_ssdt_generator, .acpi_fill_ssdt = i2c_hid_fill_ssdt_generator,

View File

@ -205,8 +205,8 @@ static void lm96000_init(struct device *const dev)
} }
static struct device_operations lm96000_ops = { static struct device_operations lm96000_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = lm96000_init, .init = lm96000_init,
}; };

View File

@ -75,8 +75,8 @@ static const char *max98373_acpi_name(const struct device *dev)
} }
static struct device_operations max98373_ops = { static struct device_operations max98373_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = max98373_acpi_name, .acpi_name = max98373_acpi_name,
.acpi_fill_ssdt = max98373_fill_ssdt, .acpi_fill_ssdt = max98373_fill_ssdt,
}; };

View File

@ -71,8 +71,8 @@ static const char *max98927_acpi_name(const struct device *dev)
} }
static struct device_operations max98927_ops = { static struct device_operations max98927_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = max98927_acpi_name, .acpi_name = max98927_acpi_name,
.acpi_fill_ssdt = max98927_fill_ssdt, .acpi_fill_ssdt = max98927_fill_ssdt,
}; };

View File

@ -86,8 +86,8 @@ static const char *nau8825_acpi_name(const struct device *dev)
#endif #endif
static struct device_operations nau8825_ops = { static struct device_operations nau8825_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_name = nau8825_acpi_name, .acpi_name = nau8825_acpi_name,
.acpi_fill_ssdt = nau8825_fill_ssdt, .acpi_fill_ssdt = nau8825_fill_ssdt,

View File

@ -20,8 +20,8 @@ static void nct7802y_init(struct device *const dev)
} }
static struct device_operations nct7802y_ops = { static struct device_operations nct7802y_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = nct7802y_init, .init = nct7802y_init,
}; };

View File

@ -39,8 +39,8 @@ static void pca9538_init(struct device *dev)
} }
static struct device_operations pca9538_ops = { static struct device_operations pca9538_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = pca9538_init, .init = pca9538_init,
}; };

View File

@ -118,8 +118,8 @@ static void pcf8523_init(struct device *dev)
} }
static struct device_operations pcf8523c_ops = { static struct device_operations pcf8523c_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = pcf8523_init, .init = pcf8523_init,
.final = pcf8523_final .final = pcf8523_final
}; };

View File

@ -127,8 +127,8 @@ __weak int mb_adjust_cfg(struct ptn_3460_config *cfg_ptr)
} }
static struct device_operations ptn3460_ops = { static struct device_operations ptn3460_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = ptn3460_init, .init = ptn3460_init,
}; };

View File

@ -84,8 +84,8 @@ static const char *rt1011_acpi_name(const struct device *dev)
} }
static struct device_operations rt1011_ops = { static struct device_operations rt1011_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = rt1011_acpi_name, .acpi_name = rt1011_acpi_name,
.acpi_fill_ssdt = rt1011_fill_ssdt, .acpi_fill_ssdt = rt1011_fill_ssdt,
}; };

View File

@ -75,8 +75,8 @@ static const char *rt5663_acpi_name(const struct device *dev)
} }
static struct device_operations rt5663_ops = { static struct device_operations rt5663_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = rt5663_acpi_name, .acpi_name = rt5663_acpi_name,
.acpi_fill_ssdt = rt5663_fill_ssdt, .acpi_fill_ssdt = rt5663_fill_ssdt,
}; };

View File

@ -225,8 +225,8 @@ static void rtd2132_init(struct device *dev)
} }
static struct device_operations rtd2132_operations = { static struct device_operations rtd2132_operations = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = rtd2132_init, .init = rtd2132_init,
}; };

View File

@ -165,8 +165,8 @@ static void rx6110sa_init(struct device *dev)
} }
static struct device_operations rx6110sa_ops = { static struct device_operations rx6110sa_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = rx6110sa_init, .init = rx6110sa_init,
.final = rx6110sa_final .final = rx6110sa_final
}; };

View File

@ -79,8 +79,8 @@ static const char *i2c_sx9310_acpi_name(const struct device *dev)
} }
static struct device_operations i2c_sx9310_ops = { static struct device_operations i2c_sx9310_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = i2c_sx9310_acpi_name, .acpi_name = i2c_sx9310_acpi_name,
.acpi_fill_ssdt = i2c_sx9310_fill_ssdt, .acpi_fill_ssdt = i2c_sx9310_fill_ssdt,
}; };

View File

@ -62,8 +62,8 @@ static const char *i2c_tpm_acpi_name(const struct device *dev)
} }
static struct device_operations i2c_tpm_ops = { static struct device_operations i2c_tpm_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = i2c_tpm_acpi_name, .acpi_name = i2c_tpm_acpi_name,
.acpi_fill_ssdt = i2c_tpm_fill_ssdt, .acpi_fill_ssdt = i2c_tpm_fill_ssdt,
}; };

View File

@ -292,8 +292,8 @@ static void w83793_init(struct device *dev)
} }
static struct device_operations w83793_operations = { static struct device_operations w83793_operations = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = w83793_init, .init = w83793_init,
}; };

View File

@ -30,8 +30,8 @@ static void ish_fill_ssdt_generator(struct device *dev)
} }
static struct device_operations intel_ish_ops = { static struct device_operations intel_ish_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_fill_ssdt = ish_fill_ssdt_generator, .acpi_fill_ssdt = ish_fill_ssdt_generator,
}; };

View File

@ -68,8 +68,8 @@ static const char *camera_acpi_name(const struct device *dev)
} }
static struct device_operations camera_ops = { static struct device_operations camera_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = camera_acpi_name, .acpi_name = camera_acpi_name,
.acpi_fill_ssdt = camera_fill_ssdt, .acpi_fill_ssdt = camera_fill_ssdt,
}; };

View File

@ -190,8 +190,8 @@ static const char *spi_acpi_name(const struct device *dev)
} }
static struct device_operations spi_acpi_ops = { static struct device_operations spi_acpi_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_name = spi_acpi_name, .acpi_name = spi_acpi_name,
.acpi_fill_ssdt = spi_acpi_fill_ssdt_generator, .acpi_fill_ssdt = spi_acpi_fill_ssdt_generator,
}; };

View File

@ -70,8 +70,8 @@ static void usb_acpi_fill_ssdt_generator(struct device *dev)
} }
static struct device_operations usb_acpi_ops = { static struct device_operations usb_acpi_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.scan_bus = scan_static_bus, .scan_bus = scan_static_bus,
.acpi_fill_ssdt = usb_acpi_fill_ssdt_generator, .acpi_fill_ssdt = usb_acpi_fill_ssdt_generator,
}; };

View File

@ -122,7 +122,7 @@ static void ene932_init(struct device *dev)
static struct device_operations ops = { static struct device_operations ops = {
.init = ene932_init, .init = ene932_init,
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
}; };
static struct pnp_info pnp_dev_info[] = { static struct pnp_info pnp_dev_info[] = {

View File

@ -438,7 +438,7 @@ static void lpc_ec_read_resources(struct device *dev)
static struct device_operations ops = { static struct device_operations ops = {
.init = lpc_ec_init, .init = lpc_ec_init,
.read_resources = lpc_ec_read_resources, .read_resources = lpc_ec_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_name = google_chromeec_acpi_name, .acpi_name = google_chromeec_acpi_name,
.acpi_fill_ssdt = google_chromeec_fill_ssdt_generator, .acpi_fill_ssdt = google_chromeec_fill_ssdt_generator,

View File

@ -219,7 +219,7 @@ static const char *wilco_ec_acpi_name(const struct device *dev)
static struct device_operations ops = { static struct device_operations ops = {
.init = wilco_ec_init, .init = wilco_ec_init,
.read_resources = wilco_ec_read_resources, .read_resources = wilco_ec_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_fill_ssdt = wilco_ec_fill_ssdt_generator, .acpi_fill_ssdt = wilco_ec_fill_ssdt_generator,
.acpi_name = wilco_ec_acpi_name, .acpi_name = wilco_ec_acpi_name,
}; };

View File

@ -132,7 +132,7 @@ static void ene_kb3940q_init(struct device *dev)
static struct device_operations ops = { static struct device_operations ops = {
.init = ene_kb3940q_init, .init = ene_kb3940q_init,
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
}; };
static struct pnp_info pnp_dev_info[] = { static struct pnp_info pnp_dev_info[] = {

View File

@ -146,7 +146,7 @@ static void it8518_init(struct device *dev)
static struct device_operations ops = { static struct device_operations ops = {
.init = it8518_init, .init = it8518_init,
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
}; };
static struct pnp_info pnp_dev_info[] = { static struct pnp_info pnp_dev_info[] = {

View File

@ -35,7 +35,7 @@ static void it8518_init(struct device *dev)
static struct device_operations ops = { static struct device_operations ops = {
.init = it8518_init, .init = it8518_init,
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
}; };
static struct pnp_info pnp_dev_info[] = { static struct pnp_info pnp_dev_info[] = {

View File

@ -66,8 +66,8 @@ struct device_operations {
/** /**
* Standard device operations function pointers shims. * Standard device operations function pointers shims.
*/ */
static inline void device_noop(struct device *dev) {} static inline void noop_read_resources(struct device *dev) {}
#define DEVICE_NOOP device_noop static inline void noop_set_resources(struct device *dev) {}
struct bus { struct bus {

View File

@ -273,8 +273,8 @@ static void cpu_bus_scan(struct device *bus)
} }
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
.scan_bus = cpu_bus_scan, .scan_bus = cpu_bus_scan,
}; };

View File

@ -823,8 +823,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
.scan_bus = cpu_bus_scan, .scan_bus = cpu_bus_scan,
}; };

View File

@ -892,8 +892,8 @@ static void cpu_bus_init(struct device *dev)
} }
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
.scan_bus = cpu_bus_scan, .scan_bus = cpu_bus_scan,
}; };

View File

@ -919,8 +919,8 @@ static void cpu_bus_init(struct device *dev)
} }
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
.scan_bus = cpu_bus_scan, .scan_bus = cpu_bus_scan,
}; };

View File

@ -894,8 +894,8 @@ static void cpu_bus_init(struct device *dev)
} }
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
.scan_bus = cpu_bus_scan, .scan_bus = cpu_bus_scan,
}; };

View File

@ -902,8 +902,8 @@ static void cpu_bus_init(struct device *dev)
} }
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
.scan_bus = cpu_bus_scan, .scan_bus = cpu_bus_scan,
}; };

View File

@ -1258,8 +1258,8 @@ static void cpu_bus_init(struct device *dev)
} }
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
.scan_bus = cpu_bus_scan, .scan_bus = cpu_bus_scan,
}; };

View File

@ -80,8 +80,8 @@ static void cpu_bus_init(struct device *dev)
} }
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
}; };

View File

@ -226,8 +226,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = mp_cpu_bus_init, .init = mp_cpu_bus_init,
}; };

View File

@ -482,8 +482,8 @@ static const struct pci_driver mc_driver_hsw __pci_driver = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = mp_cpu_bus_init, .init = mp_cpu_bus_init,
}; };

View File

@ -79,8 +79,8 @@ static void cpu_bus_init(struct device *dev)
} }
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpu_bus_init, .init = cpu_bus_init,
}; };

View File

@ -198,8 +198,8 @@ static const struct pci_driver mc_driver __pci_driver = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = mp_cpu_bus_init, .init = mp_cpu_bus_init,
}; };

View File

@ -253,8 +253,8 @@ static const struct pci_driver mc_driver_ard __pci_driver = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = mp_cpu_bus_init, .init = mp_cpu_bus_init,
}; };

View File

@ -182,8 +182,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = mp_cpu_bus_init, .init = mp_cpu_bus_init,
}; };

View File

@ -459,8 +459,8 @@ static const struct pci_driver mc_driver __pci_driver = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = mp_cpu_bus_init, .init = mp_cpu_bus_init,
}; };

View File

@ -177,8 +177,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = mp_cpu_bus_init, .init = mp_cpu_bus_init,
}; };

View File

@ -75,8 +75,8 @@ static struct pci_operations lops_pci = {
.set_subsystem = pci_dev_set_subsystem, .set_subsystem = pci_dev_set_subsystem,
}; };
static struct device_operations smbus_ops = { static struct device_operations smbus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.enable_resources = pci_dev_enable_resources, .enable_resources = pci_dev_enable_resources,
.init = sm_init, .init = sm_init,
.scan_bus = scan_smbus, .scan_bus = scan_smbus,

View File

@ -19,8 +19,8 @@ extern struct device_operations picasso_i2c_mmio_ops;
extern const char *i2c_acpi_name(const struct device *dev); extern const char *i2c_acpi_name(const struct device *dev);
struct device_operations cpu_bus_ops = { struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = picasso_init_cpus, .init = picasso_init_cpus,
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,
}; };

View File

@ -126,8 +126,8 @@ void i2c_soc_init(void)
struct device_operations picasso_i2c_mmio_ops = { struct device_operations picasso_i2c_mmio_ops = {
/* TODO(teravest): Move I2C resource info here. */ /* TODO(teravest): Move I2C resource info here. */
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.scan_bus = scan_smbus, .scan_bus = scan_smbus,
.acpi_name = i2c_acpi_name, .acpi_name = i2c_acpi_name,
.acpi_fill_ssdt = dw_i2c_acpi_fill_ssdt, .acpi_fill_ssdt = dw_i2c_acpi_fill_ssdt,

View File

@ -24,8 +24,8 @@ extern struct device_operations stoneyridge_i2c_mmio_ops;
extern const char *i2c_acpi_name(const struct device *dev); extern const char *i2c_acpi_name(const struct device *dev);
struct device_operations cpu_bus_ops = { struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = stoney_init_cpus, .init = stoney_init_cpus,
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,
}; };

View File

@ -110,8 +110,8 @@ void i2c_soc_init(void)
struct device_operations stoneyridge_i2c_mmio_ops = { struct device_operations stoneyridge_i2c_mmio_ops = {
/* TODO(teravest): Move I2C resource info here. */ /* TODO(teravest): Move I2C resource info here. */
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.scan_bus = scan_smbus, .scan_bus = scan_smbus,
.acpi_name = i2c_acpi_name, .acpi_name = i2c_acpi_name,
.acpi_fill_ssdt = dw_i2c_acpi_fill_ssdt, .acpi_fill_ssdt = dw_i2c_acpi_fill_ssdt,

View File

@ -381,7 +381,7 @@ static void soc_final(struct device *dev)
static struct device_operations soc_ops = { static struct device_operations soc_ops = {
.read_resources = soc_read_resources, .read_resources = soc_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = soc_init, .init = soc_init,
.final = soc_final, .final = soc_final,
}; };

View File

@ -219,8 +219,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = apollolake_init_cpus, .init = apollolake_init_cpus,
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,
}; };

View File

@ -21,8 +21,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = baytrail_init_cpus, .init = baytrail_init_cpus,
}; };

View File

@ -24,8 +24,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = soc_init_cpus .init = soc_init_cpus
}; };

View File

@ -23,8 +23,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = &broadwell_init_cpus, .init = &broadwell_init_cpus,
}; };

View File

@ -184,8 +184,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,
}; };

View File

@ -124,7 +124,7 @@ static void read_resources(struct device *dev)
static const struct device_operations device_ops = { static const struct device_operations device_ops = {
.read_resources = read_resources, .read_resources = read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.ops_pci = &pci_dev_ops_pci, .ops_pci = &pci_dev_ops_pci,
}; };

View File

@ -42,8 +42,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = denverton_init_cpus, .init = denverton_init_cpus,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,

View File

@ -140,8 +140,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,
}; };

View File

@ -147,8 +147,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,
#endif #endif

View File

@ -95,8 +95,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,
#endif #endif

View File

@ -147,8 +147,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
.acpi_fill_ssdt = generate_cpu_entries, .acpi_fill_ssdt = generate_cpu_entries,
#endif #endif

View File

@ -31,8 +31,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = cpx_init_cpus, .init = cpx_init_cpus,
}; };

View File

@ -482,8 +482,8 @@ static struct device_operations pci_domain_ops = {
}; };
static struct device_operations cpu_bus_ops = { static struct device_operations cpu_bus_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = xeon_sp_init_cpus, .init = xeon_sp_init_cpus,
#if CONFIG(HAVE_ACPI_TABLES) #if CONFIG(HAVE_ACPI_TABLES)
/* defined in src/soc/intel/common/block/acpi/acpi.c */ /* defined in src/soc/intel/common/block/acpi/acpi.c */

View File

@ -42,8 +42,8 @@ static void soc_init(struct device *dev)
} }
static struct device_operations soc_ops = { static struct device_operations soc_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.enable_resources = soc_enable, .enable_resources = soc_enable,
.init = soc_init, .init = soc_init,
}; };

View File

@ -51,7 +51,7 @@ static void soc_read_resources(struct device *dev)
static struct device_operations soc_ops = { static struct device_operations soc_ops = {
.read_resources = soc_read_resources, .read_resources = soc_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
}; };
static void enable_tegra210_dev(struct device *dev) static void enable_tegra210_dev(struct device *dev)

View File

@ -24,8 +24,8 @@ static void soc_init(struct device *dev)
} }
static struct device_operations soc_ops = { static struct device_operations soc_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.init = soc_init, .init = soc_init,
}; };

View File

@ -112,8 +112,8 @@ static void cpu_init(struct device *dev)
} }
static struct device_operations cpu_ops = { static struct device_operations cpu_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.enable_resources = cpu_enable, .enable_resources = cpu_enable,
.init = cpu_init, .init = cpu_init,
}; };

View File

@ -142,8 +142,8 @@ static void cpu_init(struct device *dev)
} }
static struct device_operations cpu_ops = { static struct device_operations cpu_ops = {
.read_resources = DEVICE_NOOP, .read_resources = noop_read_resources,
.set_resources = DEVICE_NOOP, .set_resources = noop_set_resources,
.enable_resources = cpu_enable, .enable_resources = cpu_enable,
.init = cpu_init, .init = cpu_init,
}; };