-
Notifications
You must be signed in to change notification settings - Fork 8.4k
drivers: memc: Fix various APS6404 device driver issues #79513
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: memc: Fix various APS6404 device driver issues #79513
Conversation
6b6afaa to
8ac0290
Compare
|
@ioannis-karachalios Thanks for filing the PR, I was going to fix those things but apparently you’ve beat me to it😄. |
8ac0290 to
09cb552
Compare
@swift-tk, you're welcome. I am working on a new family of device that is going to support the MSPI driver and I came across these errors. |
|
@ioannis-karachalios Please note that you also have to fix the CI checks before a merge. |
09cb552 to
4da4fce
Compare
I am following as we are creating another device driver for memc. Same family, higher density. |
4da4fce to
b43f46c
Compare
|
"Please note that you also have to fix the CI checks before a merge." |
drivers/memc/memc_mspi_aps6404l.c
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.
Why are these ifdef's included of the enable is already there?
To save code space?
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.
When XIP is not supported by a specific hardware, CONFIG_MSPI_XIP=n is used to indicate that. This also means that xip_config may not be implemented, so calling it in device driver may result in error. Leaving it out of compile will not only save code space but also ensure the device driver is still functional without optional features.
Additionally, one can also choose to disable XIP even when it is supported.
Could you try rebase to latest main and try again with the CI. If that don't work, I will ask help in discord. |
b43f46c to
f19906e
Compare
|
swift-tk
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.
I did not notice the default 0 was gone.
This commit deals with fixing various issues that prevents the device from being built. In specific: 1. Fix default timing macro definitions to build with an MSPI controller, other than AMBIG. Add macro definition for MSPI_PORT. 2. Timing settings should be applied only when MSPI_TIMING is defined. Otherwise, the APS6404 initialization routine will fail with -EIO. 3. Similarly, use MSPI_XIP and MSPI_SCRAMBLE to apply XIP and SCRAMBLE device settings, respectively (optimization). 4. MEMC_INIT_PRIORITY is assigned higher priority than MSPI_INIT_PRIORITY which results in compiler error as APS6404 device initialization depends on its underlying MSPI bus controller. 5. The 'acquire' subroutine should be compiled when PM_DEVICE is used (suppress compiler warning). Signed-off-by: Ioannis Karachalios <[email protected]>
4d58cc9
f19906e to
4d58cc9
Compare
@swift-tk, I was under the impression that a zero value should be given if not defined, explicitly. Thanks for your support. |
|
@ioannis-karachalios , we are only merging PR that have a Zephyr Issue linked to it. If this is needed for the 4.0 release, then please add a Zephyr issue with details about the problem seen and link it to this PR. |
|
@mmahadevan108, I opened #81151 bug report incident linked to this PR. |
This commit deals with fixing various issues that prevents the APS6404 MSPI device from being built. In specific:
Fixes #81151