Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

drivers: gpio: Make PCA9535 driver generic to support multiple PCA95xx devices #19262

Closed

Conversation

albertofloyd
Copy link
Collaborator

@albertofloyd albertofloyd commented Sep 19, 2019

PCA9535 and PCA9555 IO-expanders share most of functionality and registers, the intention of this change is to make existing driver generic for both devices. The alternative will be to add a new PCA9555 driver with mostly same functionality that existing one.

PCA9535 delta features are: programmable output drive strength, latchable inputs,
pull-up/pull-down resistors, maskable interrupts and drain or push-pull outputs. From these current gpio driver only uses the support for pull-up/pull-down. The new KConfig GPIO_PCAL95XX_PUD allows to disable this feature when PC9555A is used.

Note: Original driver is not tracked in code owners hence adding owners based on git log history.

Signed-off-by: Jose Alberto Meza [email protected]

@zephyrbot
Copy link
Collaborator

zephyrbot commented Sep 19, 2019

All checks are passing now.

Tip: The bot edits this comment instead of posting a new one, so you can check the comment's history to see earlier messages.

@nashif
Copy link
Member

nashif commented Sep 19, 2019

@albertofloyd we need to move this driver to the new GPIO API, see #18530

same for the XEC gpio driver (gpio_mchp_xec.c)

@albertofloyd
Copy link
Collaborator Author

@nashif can this additional KConfig been included in the porting process for this driver?

@franciscomunoz can you take a look into changes needed for gpio_xec?

…evices

Make original driver generic to support also PCA9555 device
PCA9535 and PCA9555 share most of functionality and registers
PCA9555 doesn't have programmable pull-up/down for the pins
A new KConfig option will allow to disable this feature

Signed-off-by: Jose Alberto Meza <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants