Commit 277ed0d5 authored by Pantelis Antoniou's avatar Pantelis Antoniou Committed by Greg Kroah-Hartman

w1-gpio: Pinctrl-fy

Enable pinctrl for w1-gpio.
Acked-by: default avatarTony Lindgren <tony@atomide.com>
Signed-off-by: default avatarPantelis Antoniou <panto@antoniou-consulting.com>
Signed-off-by: default avatarEvgeniy Polyakov <zbr@ioremap.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5f7e2228
......@@ -16,6 +16,8 @@
#include <linux/gpio.h>
#include <linux/of_platform.h>
#include <linux/of_gpio.h>
#include <linux/pinctrl/consumer.h>
#include <linux/err.h>
#include "../w1.h"
#include "../w1_int.h"
......@@ -85,8 +87,13 @@ static int __init w1_gpio_probe(struct platform_device *pdev)
{
struct w1_bus_master *master;
struct w1_gpio_platform_data *pdata;
struct pinctrl *pinctrl;
int err;
pinctrl = devm_pinctrl_get_select_default(&pdev->dev);
if (IS_ERR(pinctrl))
dev_warn(&pdev->dev, "unable to select pin group\n");
err = w1_gpio_probe_dt(pdev);
if (err < 0)
return err;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment