Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 340110
b: refs/heads/master
c: ab66378
h: refs/heads/master
v: v3
  • Loading branch information
Tomasz Figa authored and Linus Walleij committed Oct 15, 2012
1 parent 374bcb2 commit c190c59
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a7a8241540c3168965588d313f46b14f79e86753
refs/heads/master: ab663789d69760d2735402f66501f20b60312a3d
13 changes: 13 additions & 0 deletions trunk/drivers/pinctrl/pinctrl-samsung.c
Original file line number Diff line number Diff line change
Expand Up @@ -794,6 +794,7 @@ static struct samsung_pin_ctrl *samsung_pinctrl_get_soc_data(
int id;
const struct of_device_id *match;
const struct device_node *node = pdev->dev.of_node;
struct device_node *np;
struct samsung_pin_ctrl *ctrl;
struct samsung_pin_bank *bank;
int i;
Expand All @@ -816,6 +817,18 @@ static struct samsung_pin_ctrl *samsung_pinctrl_get_soc_data(
}
}

for_each_child_of_node(node, np) {
if (!of_find_property(np, "gpio-controller", NULL))
continue;
bank = ctrl->pin_banks;
for (i = 0; i < ctrl->nr_banks; ++i, ++bank) {
if (!strcmp(bank->name, np->name)) {
bank->of_node = np;
break;
}
}
}

ctrl->base = pin_base;
pin_base += ctrl->nr_pins;

Expand Down
2 changes: 2 additions & 0 deletions trunk/drivers/pinctrl/pinctrl-samsung.h
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ struct samsung_pinctrl_drv_data;
* @eint_type: type of the external interrupt supported by the bank.
* @irq_base: starting controller local irq number of the bank.
* @name: name to be prefixed for each pin in this pin bank.
* @of_node: OF node of the bank.
*/
struct samsung_pin_bank {
u32 pctl_offset;
Expand All @@ -124,6 +125,7 @@ struct samsung_pin_bank {
enum eint_type eint_type;
u32 irq_base;
char *name;
struct device_node *of_node;
};

/**
Expand Down

0 comments on commit c190c59

Please sign in to comment.