[PATCH v1] pinctrl: intel: merrifield: Introduce OF device table

Subsystems: intel mid (mobile internet device) platform, pin control subsystem, pin controller - intel, the rest

STALE3255d

2 messages, 2 authors, 2017-09-21 · open the first message on its own page

[PATCH v1] pinctrl: intel: merrifield: Introduce OF device table

From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Date: 2017-08-28 13:43:30

On Intel Merrifield the pin control device is a separate IP block
without any PCI or ACPI ID assigned. We need some means to allow the
device be enumerated in ACPI environment (*).

To achieve this without allocation special ACPI ID, which is really long
and pretty much unachievable procedure, we just re-use special ACPI ID
and standard compatible string.

(*) ACPI is enabled via second bootloader, i.e. U-Boot,
    firmware is still left untouched and being SFI enabled.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 drivers/pinctrl/intel/pinctrl-merrifield.c | 7 +++++++
 1 file changed, 7 insertions(+)
diff --git a/drivers/pinctrl/intel/pinctrl-merrifield.c b/drivers/pinctrl/intel/pinctrl-merrifield.c
index 86c4b3fab7b0..46fe30702a79 100644
--- a/drivers/pinctrl/intel/pinctrl-merrifield.c
+++ b/drivers/pinctrl/intel/pinctrl-merrifield.c
@@ -931,10 +931,17 @@ static int mrfld_pinctrl_probe(struct platform_device *pdev)
 	return 0;
 }
 
+static const struct of_device_id mrfld_of_table[] = {
+	{ .compatible = "intel,merrifield-pinctrl" },
+	{ },
+};
+MODULE_DEVICE_TABLE(of, mrfld_of_table);
+
 static struct platform_driver mrfld_pinctrl_driver = {
 	.probe = mrfld_pinctrl_probe,
 	.driver = {
 		.name = "pinctrl-merrifield",
+		.of_match_table = mrfld_of_table,
 	},
 };
 
-- 
2.14.1

Re: [PATCH v1] pinctrl: intel: merrifield: Introduce OF device table

From: Linus Walleij <hidden>
Date: 2017-09-21 11:08:13

On Mon, Aug 28, 2017 at 3:42 PM, Andy Shevchenko
[off-list ref] wrote:
On Intel Merrifield the pin control device is a separate IP block
without any PCI or ACPI ID assigned. We need some means to allow the
device be enumerated in ACPI environment (*).

To achieve this without allocation special ACPI ID, which is really long
and pretty much unachievable procedure, we just re-use special ACPI ID
and standard compatible string.
Unfortunately device tree has some bureaucracy too :/
(*) ACPI is enabled via second bootloader, i.e. U-Boot,
    firmware is still left untouched and being SFI enabled.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
I'm fine with this, please just add the following file:
Documentation/devicetree/bindings/pinctrl/intel.txt

And kind of just list the compatible string in it, with
Cc: devicetree@vger.kernel.org

That is the procedure they have asked me to follow.

Then they need some week to have a chance to look at it.

Yours,
Linus Walleij
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help