[PATCH v4] ARM: s3c244x: Fix mess with gpio {set,get}_pull callbacks
Kukjin Kim
kgene.kim at samsung.com
Wed Dec 1 00:28:17 EST 2010
Lars-Peter Clausen wrote:
>
> > +static int s3c_gpio_setpull_1(struct s3c_gpio_chip *chip,
> > + unsigned int off, s3c_gpio_pull_t pull,
> > + s3c_gpio_pull_t updown)
> > {
> > void __iomem *reg = chip->base + 0x08;
> > u32 pup = __raw_readl(reg);
> >
> > - pup = __raw_readl(reg);
> > -
> > - if (pup == S3C_GPIO_PULL_UP)
> > + if (pup == updown)
> This should be pull == updown, otherwise looks fine to me
>
Yeah, I meant this.
> > pup &= ~(1 << off);
> > else if (pup == S3C_GPIO_PULL_NONE)
pull == S3C_GPIO_PULL_NONE?
> > pup |= (1 << off);
Thanks.
Best regards,
Kgene.
--
Kukjin Kim <kgene.kim at samsung.com>, Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.
More information about the linux-arm-kernel
mailing list