8000 Refactoring of Earlgrey GPIO driver by mazurek-michal · Pull Request #3710 · tock/tock · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Refactoring of Earlgrey GPIO driver #3710

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

Merged
merged 3 commits into from
Nov 22, 2023
Merged

Conversation

mazurek-michal
Copy link
Contributor
@mazurek-michal mazurek-michal commented Oct 13, 2023

Pull Request Overview

  • Add implementation of PadConfig
  • Replace padctl with PadConfig in lowrisc GPIO
  • Add trait for supporting board I/O layout configuration
  • Pinmux configuration for CW310 board

Depend on changes form: (Merged) #3707

Testing Strategy

Manual test using CW310 as DUT and Hyperdebug with opentitan tool
as test bench for generating stimulus.

TODO

  • rebase on top of master after merging PINMUX
  • Use auto-generated registers for lowrisc GPIO
  • GPIO input filtering support
  • GPIO wakeup/sleep feature

Documentation Updated

N/A

Formatting

  • Ran make prepush.

@github-actions github-actions bot added the WG-OpenTitan In the purview of the OpenTitan working group. label Oct 13, 2023
@mazurek-michal mazurek-michal force-pushed the pinmux_gpio_02 branch 3 times, most recently from b3928b2 to 6b42a4b Compare October 20, 2023 15:14
@bradjc
Copy link
Contributor
bradjc commented Oct 24, 2023

I think a rebase here would help with reviewing now that the register changes are merged.

This commit add new enum PadConfig used as representation
of association between pad and internal chip I/O.
This new enum implement GPIO::Configure interface
in order to provide necessary functionality for GPIO
such as floating state management and low power state.

Signed-off-by: Michał Mazurek <mazurekm@google.com>

lint of pinmux
pinmux pad fixes

Signed-off-by: Michał Mazurek <mazurekm@google.com>
@mazurek-michal mazurek-michal marked this pull request as ready for review October 25, 2023 15:22
@mazurek-michal
Copy link
Contributor Author
mazurek-michal commented Oct 25, 2023

@cfrantz @jrvanwhy @bradjc
Commits were rebased, a few things need to to be fixed but code is ready for first round of review.

jrvanwhy
jrvanwhy previously approved these changes Oct 25, 2023
* Replacing old pinmux reference with Pad and PadConfig.
* Improved handling of GPIO LowPower.
* Improved handling of GPIO floating state.

Signed-off-by: Michał Mazurek <mazurekm@google.com>
@mazurek-michal
Copy link
Contributor Author

Connected to OpenTitan task: lowRISC#28

jrvanwhy
jrvanwhy previously approved these changes Nov 15, 2023
Following commit introduce new trait that allow to configure
Pinmux during board initialization. The new interface allows to
configure Pinmux for specific board layout. When new board that
uses Ealgrey chip is added user should also implement this trait
to provide support for board specific I/O layout.

* Add new trait EarlGreyPinmuxConfig for passing baord I/O layout to chip drivers
* Add CW310 pinmux layout configuration, compatible with OpenTitan Hyperdebug
* Initialize GPIO port based on currently board I/O layout.

Signed-off-by: Michał Mazurek <mazurekm@google.com>
@mazurek-michal
Copy link
Contributor Author

@bradjc Could you check newest version ?

@bradjc bradjc added this pull request to the merge queue Nov 22, 2023
Merged via the queue into tock:master with commit 9d2ffac Nov 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
WG-OpenTitan In the purview of the OpenTitan working group.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0