GUI: Fix Tomato RAF theme for all builds. Compilation typo.
[tomato.git] / release / src-rt-6.x.4708 / linux / linux-2.6.36 / Documentation / w1 / masters / w1-gpio
blobaf5d3b4aa851501da0687d6414c0f070c574a7aa
1 Kernel driver w1-gpio
2 =====================
4 Author: Ville Syrjala <syrjala@sci.fi>
7 Description
8 -----------
10 GPIO 1-wire bus master driver. The driver uses the GPIO API to control the
11 wire and the GPIO pin can be specified using platform data.
14 Example (mach-at91)
15 -------------------
17 #include <linux/w1-gpio.h>
19 static struct w1_gpio_platform_data foo_w1_gpio_pdata = {
20         .pin            = AT91_PIN_PB20,
21         .is_open_drain  = 1,
24 static struct platform_device foo_w1_device = {
25         .name                   = "w1-gpio",
26         .id                     = -1,
27         .dev.platform_data      = &foo_w1_gpio_pdata,
30 ...
31         at91_set_GPIO_periph(foo_w1_gpio_pdata.pin, 1);
32         at91_set_multi_drive(foo_w1_gpio_pdata.pin, 1);
33         platform_device_register(&foo_w1_device);