-
Notifications
You must be signed in to change notification settings - Fork 318
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
audio: base_fw: do not use platform interface for vendor extensions #9103
audio: base_fw: do not use platform interface for vendor extensions #9103
Conversation
In commit 14c4e86 ("audio: base_fw: add platform layer to IPC4 hw_config data"), the platform specific code was moved to platform layer. This commit implements a lighter weight abstraction for the moved code. Instead of using the platform layer, the Intel specific vendor code is added directly in base_fw_intel.c and guarded by a Kconfig. All other IPC4 build targets will use an empty implementation. This avoids the need to add a platform definition for all IPC4 targets. The common implementation in base_fw.c is sufficient to cover all mandatory functionality required e.g. by the upstream SOF Linux driver's IPC4 implementation. The interfaces are renamed to refer to "vendor" instead of "platform", to avoid any confusion with the platform layer with the new implementation. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
For background, this is a follow-up agreed in #9060 (review) @lgirdwood more in line now? this requires addition of new build time conditionals (Kconfig in this PR) as we can't use the platform selection to choose the implemetnation, but given we only have two implementations, this is pretty light. If longterm, there are not going to be many build targets that need to variate this, this approach will be better. If we end up having customizations for majority of build targets, then (re)using platform layer would be better. @thesofproject/nxp please chime in, you are the first non-intel target this affects. |
Use tabs for indentation consistently. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
V2:
|
CI fails are caused by #9101 , rest are good. Waiting for reviews... |
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.
Looks good to me
In commit 14c4e86 ("audio: base_fw: add platform layer to IPC4 hw_config data"), the platform specific code was moved to platform layer.
This commit implements a lighter weight abstraction for the moved code. Instead of using the platform layer, the Intel specific vendor code is added directly in base_fw_intel.c and guarded by a Kconfig. All other IPC4 build targets will use an empty implementation.
This avoids the need to add a platform definition for all IPC4 targets. The common implementation in base_fw.c is sufficient to cover all mandatory functionality required e.g. by the upstream SOF Linux driver's IPC4 implementation.
The interfaces are renamed to refer to "vendor" instead of "platform", to avoid any confusion with the platform layer with the new implementation.