Re: [PATCH v1 2/2] gpio: ds4520: Add ADI DS4520 Regulator Support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I think I understand what you are trying to say so far. I did not have too much
experience related to gpio. I will set pull_up register in .set_config
However, I did not understand where its parameters come from.
set_config(struct gpio_chip *chip, unsigned int offset,
	      unsigned long config)
It might be trivial question, but Where does config come from?

Others have to answer that one as I don't have that much experience either.

At the end, I should rewrite the code using regmap_gpio, right? So if I rewrite
code using regmap_gpio, how can I replace set_config(...)?

You'd have to add a .set_config to gpio_regmap_config and then in

gpio_regmap_register():
  gpio->set_config = config->set_config;

I don't think it makes sense to have a default implementation in gpio-regmap,
the variances between "simple" gpio controllers might be too broad.

-michael



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux