-
Notifications
You must be signed in to change notification settings - Fork 8.2k
[TOPIC-GPIO] gpio: Update mcux lpc driver to use new gpio api #19714
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
[TOPIC-GPIO] gpio: Update mcux lpc driver to use new gpio api #19714
Conversation
|
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. |
dfb55b3 to
2b868b2
Compare
mnkp
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with minor (but blocking) comments.
|
@agansari |
2b868b2 to
a3e9eb0
Compare
|
It looks like something went wrong during the rebase process. There are some commits in this PR which shouldn't be here. It will probably require some manual clean up. |
1eabe82 to
0da362b
Compare
@mnkp I rebased and moved the pin configuration to the test. |
0da362b to
08889c0
Compare
mnkp
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the update! Sorry, I overlooked two other minor issues. However, we should fix them to make sure the testcases can pass.
08889c0 to
b018f25
Compare
|
failing test is qemu base, not related to this pull |
|
It looks like this PR needs to be rebased after recent merges to |
b018f25 to
96bc17d
Compare
@mnkp rebase and shippable passed |
dts/bindings/gpio/nxp,lpc-gpio.yaml
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a license/copyright header
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will do
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@MaureenHelm kinetis does not have one... should i do anything about it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no
Updates the mcux lpc driver and all associated boards to use new device tree compatible gpio configuration flags. Implements new port get/set/clear/toggle functions recently added to the gpio api. ISR functions to be added later. Signed-off-by: Andrei Gansari <[email protected]>
96bc17d to
18a4ef8
Compare
NXP's LPC family of MCU's GPIOs parameters is udated. Boards LPC54xxx and LPC55xxx have updated values according pin and interrupt layout. Signed-off-by: Andrei Gansari <[email protected]>
Board is refactored to use DTS generated value, not use magic numbers. Signed-off-by: Andrei Gansari <[email protected]>
PINT device is enabled when SoC is booting up. Applies to LPC54xxx and LPC55xxx families. Signed-off-by: Andrei Gansari <[email protected]>
Use the latest commit available in hal_nxp repository. Signed-off-by: Andrei Gansari <[email protected]>
SoC initialization had an incorrect comment regarding system clock. Corrected from 48Mhz -> 96Mhz. Signed-off-by: Andrei Gansari <[email protected]>
Pull-up replaced by pull-down in particular test_gpio_port. Signed-off-by: Andrei Gansari <[email protected]>
LPC54114 to use D0 and D1 pinout. LPC55S69 to use A0 and A1 pinout. 2 pin test gpio_basic_api uses pins set up in boars' pinmux. Signed-off-by: Andrei Gansari <[email protected]>
LPC54114 to use D0 and D1 pinout. LPC55S69 to use A0 and A1 pinout. Pins enabled to be used as GPIO for 2 pin test gpio_basic_api. Signed-off-by: Andrei Gansari <[email protected]>
Add define that maps to IOCON register PULL-DOWN bit. Signed-off-by: Andrei Gansari <[email protected]>
Allocate all 8 PINT interrupts to ports 0 and 1, allocate 4 to each. Signed-off-by: Andrei Gansari <[email protected]>
LPC GPIO architecture uses multiple devices. GPIO input is routed via INPUTMUX to the PINT device which roots the interrupt to NVIC. Signed-off-by: Andrei Gansari <[email protected]>
18a4ef8 to
b5344b5
Compare
|
@MaureenHelm can you review this again? |
dts/bindings/gpio/nxp,lpc-gpio.yaml
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no
Updates the mcux lpc driver and LPC boards to use new device tree compatible gpio configuration flags. Implements new port get/set/clear/toggle and pin_interrupt_configure functions recently added to the gpio api.
Driver still supports port acces on some features. To be removed later.
Interrupts feature enabled in this pull in order to have a wider test array.
Ported from #16589, will be closed once this is merged.
Tested with:
On boards:
Tests in tests/drivers/ pass on lpc55s69 pass if run in debug mode.