Message ID | 1345996865-32082-12-git-send-email-Julia.Lawall@lip6.fr (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
diff --git a/arch/arm/mach-at91/gpio.c b/arch/arm/mach-at91/gpio.c index be42cf0..7760f35 100644 --- a/arch/arm/mach-at91/gpio.c +++ b/arch/arm/mach-at91/gpio.c @@ -956,19 +956,14 @@ static int __init at91_gpio_setup_clk(int idx) goto err; } - if (clk_prepare(at91_gpio->clock)) - goto clk_prep_err; - /* enable PIO controller's clock */ - if (clk_enable(at91_gpio->clock)) { + if (clk_prepare_enable(at91_gpio->clock)) { pr_err("at91_gpio.%d, failed to enable clock, ignoring.\n", idx); - goto clk_err; + goto clk_prep_err; } return 0; -clk_err: - clk_unprepare(at91_gpio->clock); clk_prep_err: clk_put(at91_gpio->clock); err: