Skip to content

Conversation

@nordic-krch
Copy link
Contributor

Add module for managing multiple requests for setting MRAM operations without the latency. Module is using onoff manager.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is only application expected to call this API?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've split the init into 2 stages, first onoff manager is initialized and then nrfs. Requests that comes before nrfs is initialized will not get completion notification until nrfs is initialized.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd try to be consistent with gpd: use some namespacing, place it under soc/nrf54h/..., headers nrf/mram_latency.h, etc.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did not put it in nrf54h because of nrf92 and took the similar approach to dmm. I can move it to nrf54h however i see that it is already a bit unclear with regards to include files (only gdp has it's own include path). Maybe we should have soc/nordic/include/nrf path?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

an additional sync API may be useful for simplicity, dealing with onoff is cumbersome

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added mram_no_latency_sync_request() and mram_no_latency_sync_release()

Comment on lines 117 to 118
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is goto needed if no cleanup action is done>?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i was initially logging rv so wanted to have one place. Removed label and gotos now.

Add module for managing multiple requests for MRAM latency.

Signed-off-by: Krzysztof Chruściński <[email protected]>
Add test for MRAM latency.

Signed-off-by: Krzysztof Chruściński <[email protected]>
Copy link
Contributor

@kl-cruz kl-cruz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you open related PR in sdk-zephyr?

@nordic-krch
Copy link
Contributor Author

@masz-nordic @anangl can you take a look?

Comment on lines +21 to +22
/** @internal For test purposes only. */
extern struct onoff_manager mram_latency_mgr;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it's only for tests then why not place it in tests/boards/nrf/mram_latency/src/main.c?

@nashif nashif merged commit 20e28d2 into zephyrproject-rtos:main Nov 26, 2024
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

platform: nRF Nordic nRFx

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants