diff options
Diffstat (limited to 'arch/powerpc/sysdev/cpm_common.c')
-rw-r--r-- | arch/powerpc/sysdev/cpm_common.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/powerpc/sysdev/cpm_common.c b/arch/powerpc/sysdev/cpm_common.c index 51bf749a4f3a..b74508175b67 100644 --- a/arch/powerpc/sysdev/cpm_common.c +++ b/arch/powerpc/sysdev/cpm_common.c | |||
@@ -190,8 +190,9 @@ static int cpm2_gpio32_dir_in(struct gpio_chip *gc, unsigned int gpio) | |||
190 | return 0; | 190 | return 0; |
191 | } | 191 | } |
192 | 192 | ||
193 | int cpm2_gpiochip_add32(struct device_node *np) | 193 | int cpm2_gpiochip_add32(struct device *dev) |
194 | { | 194 | { |
195 | struct device_node *np = dev->of_node; | ||
195 | struct cpm2_gpio32_chip *cpm2_gc; | 196 | struct cpm2_gpio32_chip *cpm2_gc; |
196 | struct of_mm_gpio_chip *mm_gc; | 197 | struct of_mm_gpio_chip *mm_gc; |
197 | struct gpio_chip *gc; | 198 | struct gpio_chip *gc; |
@@ -211,6 +212,8 @@ int cpm2_gpiochip_add32(struct device_node *np) | |||
211 | gc->direction_output = cpm2_gpio32_dir_out; | 212 | gc->direction_output = cpm2_gpio32_dir_out; |
212 | gc->get = cpm2_gpio32_get; | 213 | gc->get = cpm2_gpio32_get; |
213 | gc->set = cpm2_gpio32_set; | 214 | gc->set = cpm2_gpio32_set; |
215 | gc->parent = dev; | ||
216 | gc->owner = THIS_MODULE; | ||
214 | 217 | ||
215 | return of_mm_gpiochip_add_data(np, mm_gc, cpm2_gc); | 218 | return of_mm_gpiochip_add_data(np, mm_gc, cpm2_gc); |
216 | } | 219 | } |