25 #include <linux/kernel.h>
28 #include <linux/module.h>
29 #include <linux/pci.h>
32 #define DRV_NAME "cs5535-mfd"
49 dev_err(&pdev->
dev,
"can't fetch device resource info\n");
66 dev_err(&pdev->
dev,
"can't fetch device resource info\n");
81 .resources = &cs5535_mfd_resources[
SMB_BAR],
85 .name =
"cs5535-gpio",
87 .resources = &cs5535_mfd_resources[
GPIO_BAR],
91 .name =
"cs5535-mfgpt",
93 .resources = &cs5535_mfd_resources[
MFGPT_BAR],
99 .resources = &cs5535_mfd_resources[
PMS_BAR],
101 .enable = cs5535_mfd_res_enable,
102 .disable = cs5535_mfd_res_disable,
106 .name =
"cs5535-acpi",
108 .resources = &cs5535_mfd_resources[
ACPI_BAR],
110 .enable = cs5535_mfd_res_enable,
111 .disable = cs5535_mfd_res_disable,
116 static void __devinit cs5535_clone_olpc_cells(
void)
118 const char *acpi_clones[] = {
"olpc-xo1-pm-acpi",
"olpc-xo1-sci-acpi" };
120 if (!machine_is_olpc())
126 static void cs5535_clone_olpc_cells(
void) { }
139 for (i = 0; i <
ARRAY_SIZE(cs5535_mfd_cells); i++) {
140 int bar = cs5535_mfd_cells[
i].
id;
141 struct resource *
r = &cs5535_mfd_resources[bar];
148 cs5535_mfd_cells[
i].
id = 0;
154 dev_err(&pdev->
dev,
"MFD add devices failed: %d\n", err);
157 cs5535_clone_olpc_cells();
182 static struct pci_driver cs5535_mfd_driver = {
184 .id_table = cs5535_mfd_pci_tbl,
185 .probe = cs5535_mfd_probe,