Repository navigation
[Stable v1.7] backport for v1.7 final release. - #3914
Conversation
Define to use 38.4MHz MCLK for DSM, to align with other SSP ports. Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Add a full_sync attribute to ll_schedule domain. This is set to true, for a full synchronous dma_domain scheduler, which is not time dependent. By default, it is false. In full_sync case we use the ratio between the task period and the registrable task period to do the scheduling, not the task.start time. We do this because for the DMA_DOMAIN there are no guarantees for the accuracy of the period of the registrable task which drives the entire scheduling. An example is the mixer topology where we have 3 pipelines for playback scenario: - 1 pipeline for pcm1.0 (task 0); - 1 pipeline for pcm1.1 (task 1); - 1 pipeline for DAI (task 2). Task 2 is the registrable task and this is always scheduled. The other tasks (task 0 and task 1) are scheduled based on task->start. The problem is that, at some point, the DMA transfer from DAI is finished earlier than task->start for one of the task 0 or task 1 and this is not scheduled anymore. And, task 2 ends up depleting one of the source buffers, thus blocking the entire data flow. Fixes: thesofproject#3802 Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
Use the full_sync attribute from dma_domain to schedule tasks based on period ratio between the registrable task and the current one. Do not make it time dependent anymore. Fixes: thesofproject#3802 Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
cppcheck points out the uselessness of checking <0 checks on unsigned types Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
not sure how this happened but this check is pointless and also results in a double free, found by cppcheck Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
sch is global and local, rename local, found via cppcheck Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
cppcheck was being confused as we were passing in hw_param_ctx which has linking in the following order hw_param_ctx->data->hw_params. Cppcheck was being confused as it failed to realize that hw_params was a writeback method and to be honest the way it was written they way the structures were linked was hard to see as well. Lets do all the linking upfront so its easier to read. Cppcheck doesn't seem to complain about this method so lets use it. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
we should free before we clear the pointer found via cppcheck Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
if we aren't going to use the value, dont set it. Cppcheck complaint Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Reference Kconfig in zephyr module file which is evaluated by Zephyr directly. This will eliminate the need for including the SOF Kconfig directly. Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This section is generating warnings when build with Zephyr, so remove for now. Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This reverts commit f4c9c28. This is no longer needed as we removed local copy of rimage from zephyr/ext. Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Getting formatting warnings when building with Zephyr which prevents successful build in CI. Signed-off-by: Anas Nashif <anas.nashif@intel.com>
ternary isn't entirely clear what order happens on the left, add brackets to clarify. Cppcheck complaint Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Ret is unconditionally set later, so initialization is irrelevant. Cppcheck find. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
cppcheck complaint Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Cppcheck complaint Related to thesofproject#3843 Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
There is a bug in upstream cppcheck where dereferencing a pointer does not result in a type check in sizeof as far as cppcheck is concerned. This results in a false divide by sizeof(pointer) error. See https://trac.cppcheck.net/ticket/10179 Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
libc doesn't return a type, so it just no-ops silently on null, lets to the same having this error makes walk back patterns more annoying Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
The current version of the code effectively relies on the compiler to optimize out the loop, this both trusts the compiler, annoys cppcheck which also not being entirely clear to the reader. Solution is to use the compile switch to remove all relevant code. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Cppcheck check doesn't understand the relationship between trace section start and end so it is giving a false positive because it thinks they are two separate objects, not two pointers to the same region. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Cppcheck is complaining that we are running a 32bit int off the end. This shouldn't happen here in any arch. Looking at the math and comments, it looks like idx should be a 64 type or cast to a larger container before the bit shift. Therefore I am enforcing a strict type on it. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
minor cppcheck style violation Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
if its unused, then its uneeded Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Comment is incorrect. There are multiple cases when a config is pushed by userspace that will result in no callback. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
rename the last_tick to next_tick, which means the one already set to the timer, for more easy to understand. Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Do timer_domain refining as below: Use unified LL_TIMER_SET_OVERHEAD_TICKS=1000 which denote the max overhead that the timer_domain_set() will take, and remove the definition from each platforms. Don't add any overhead if no needed(e.g. if the start > current + overhead). This will help to schedule the task ASAP, and make the catching up (of the previous delay) possible. Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Refine and simplify the domain_set/clear() part: 1. Use UINT64_MAX to denote that the domain is not set. 2. For _domain_set(), set only when needed. e.g. the first task over all cores being added, or a task asking for earlier timer being added. The _domain_set() logic is refined as below: a. For first task, set domain according to the required start, else b. for one shot task, set domain if it is earlier, else c. for earlier periodic task, try to make it cadence-aligned with the existed task, else d. for later periodic task, simply cover it by the coming interrupt. 3. For _domain_clear() logic, simplify to call it when the last client is freed. Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
At interrupt handling & tasks_run(): run each pending task of the core, e.g. for period tasks: previously: update task->start based on last_tick(asynchronized), if the last_tick was delayed, the delay will be accumulated to the subsequent periods! new: update task->start based on last task->start, to try to make the task's running follow the pipeline requirement as more as possible. Add lock/unlock for domain accessing and updating while keep task can run simultaneously on multiple cores. Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Reschedule once interrupt is handled by all cores(clients) according to the earlist task of the list, and enable interrupt on cores that have tasks to run. Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
|
SOFCI TEST |
|
@dbaluta can you help to check if it is fine for NXP v1.7? |
Currently you can't play multiple simultaneous streams at the same time into mux. Fix this by copying the trigger and reset mechanism from audio mixer. Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
This commit adds description of mux/demux config structure and format. Signed-off-by: Bartosz Kokoszko <bartoszx.kokoszko@linux.intel.com>
|
@keyonjie I can do a run with your PR on Thursday. @iuliana-prodan @paulstelian97 @ViorelSuman if you guys have some spare cycles today can you give it a quick test? |
|
SOFCI TEST |
cujomalainey
left a comment
There was a problem hiding this comment.
from my view my patches are fine
|
@keyonjie I'm fine with these patches |
|
SOFCI TEST |
|
Double check the multiple stream on BYT |
|
@zrombel can you confirm if internal CI supports stable branches ? |
|
SOFCI TEST |
|
Try CI again, @iuliana-prodan please wait for this to merge first (to reduce conflicts). ASAP after CI passes. |
|
Jenkins showing docker rate limit and known issue on BDW. |
|
@lgirdwood is there a way to have access to codec unit tests? |
@zrombel can you help here ? Thanks ! |
|
@lgirdwood To run codec test QB applies code patch and provide codec library. Due to recent changes in codec code in master branch at this point branch stable-v1.7 is not aligned with master and patch can't be applied. For this PR i've turned of the codec build and testing. If it's necessary I can run manual codec tests on this PR and give feedback. This patch can be a problem when lot of changes will be introduced to codec regarding codec so maybe is't a good time to find better solution. |
|
@zrombel thanks, we may just have to ignore the codec PR for v1.7. |
cherry-picks all fixes I think needed, the mux/demux optimization is not here as it looks uncompleted yet (at least from the kernel side), not quite sure about NXP parts.