Repository navigation
Drivers: Intel: DMIC: Re-arrange DMIC DAI component data - #4299
Conversation
89c58bc to
b5d0394
Compare
b5d0394 to
a90f747
Compare
There was a problem hiding this comment.
@singalsu One downside is that this memory cannot be freed even if all dmic pipelines are stopped (unless we get dynamic module loading in the future). But this is ~100 bytes, so maybe something that can be optimized later.
lgirdwood
left a comment
There was a problem hiding this comment.
I also assume here there is no regression in stability ?
a90f747 to
657a453
Compare
657a453 to
c8d9fa1
Compare
@lgirdwood The two alloc() done in dmic_probe() are to SOF_MEM_ZONE_RUNTIME_SHARED. Is that sufficient? |
This patch collects the global DMIC driver parameters into single struct. The pointer global in every DMIC DAI instance points into the same data. All access from functions happens via the pointer that simplifies the next step to add NHLT binary data configuration for the driver. The previous dmic_prm[] is no more allocated dynamically since the single data structure is fixed size and not large. It simplifies the driver code that handles the multiple ownership. Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
Previously the gain ramp updates were executed in core 0 only even if rest of driver was executed in other core. It caused issues with driver state variables in cached memory. Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
This patch only removes some unnecessary line feeds for better readability. Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
c8d9fa1 to
c72d2c7
Compare
|
I've split the PR to 3 commits. The fist contains most of the changes. Previously I forgot to mention in commit text that dmic_work() runs on the same core as driver as result of 2nd commit (it was needed to make it work for cached data, now I think it could run on core 0 always but I think this makes more sense). 3rd commit is just cosmetic. |
This patch separates the component data to private and global
parts and cleans up the explicit un-cache code from previous
version.
Since the dmic_prm[] struct is fixed length it does not need to
be allocated dynamically. It simplifies a lot the parameters
handling and sharing.
Signed-off-by: Seppo Ingalsuo seppo.ingalsuo@linux.intel.com