-
Notifications
You must be signed in to change notification settings - Fork 6.6k
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
Add the DT_MEMORY_ATTR_
defines
#60874
Closed
carlocaione
wants to merge
2
commits into
zephyrproject-rtos:main
from
carlocaione:dt_mem_attr_bindings
Closed
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
/* | ||
* Copyright (c) 2023 Carlo Caione <ccaione@baylibre.com> | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
#ifndef ZEPHYR_INCLUDE_DT_BINDINGS_MEM_ATTR_H_ | ||
#define ZEPHYR_INCLUDE_DT_BINDINGS_MEM_ATTR_H_ | ||
|
||
/* Ideally we'd generate this enum to match what's coming out of the YAML, | ||
* however, we dont have a good way to know how to name such an enum from the | ||
* generation point of view, so for now we just hand code the enum. This | ||
* enum is expected to match the order in the yaml (dts/bindings/base/zephyr,memory-attr.yaml) | ||
*/ | ||
|
||
enum dt_memory_attr { | ||
DT_MEMORY_ATTR_RAM, | ||
DT_MEMORY_ATTR_RAM_NOCACHE, | ||
DT_MEMORY_ATTR_FLASH, | ||
DT_MEMORY_ATTR_PPB, | ||
DT_MEMORY_ATTR_IO, | ||
DT_MEMORY_ATTR_EXTMEM, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. what is extmem suppose to mean? How does it differ from RAM? |
||
DT_MEMORY_ATTR_UNKNOWN, /* must be last */ | ||
}; | ||
|
||
#endif /* ZEPHYR_INCLUDE_DT_BINDINGS_MEM_ATTR_H_ */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
ppb? maybe add a comment, since I've got no clue what PPB is ;)
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.
@galak replying here also for the other comment.
Agree, naming and description is a big issue here. @manuargue will be taking care of that soon, see #60049 (review) and #60049 (comment) but I think we are forced to live with it for a little while, but cleaning up is already planned I swear :)