aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2023-06-13ASoC: atmel: use use new trigger ordering methodKuninori Morimoto1-1/+1
ASoC is now supporting generic trigger ordering method. This patch switch to use it. Signed-off-by: Kuninori Morimoto <[email protected]> Reviewed-by: Claudiu Beznea <[email protected]> Tested-by: Claudiu Beznea <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: amd: use use new trigger ordering methodKuninori Morimoto2-11/+11
ASoC is now supporting generic trigger ordering method. This patch switch to use it. Signed-off-by: Kuninori Morimoto <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: add new trigger ordering methodKuninori Morimoto3-50/+90
Current ASoC is assuming that trigger starting order is Link -> Component -> DAI as default, and its reverse order for stopping. But some Driver / Card want to reorder it for some reasons. We have such flags, but is unbalance like below. struct snd_soc_component_driver :: start_dma_last struct snd_soc_dai_link :: stop_dma_first We want to have more flexible, and more generic method. This patch adds new snd_soc_trigger_order for start/stop at component / DAI-link. Signed-off-by: Kuninori Morimoto <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: Intel: sof_sdw: add dai_link_codec_ch_mapBard Liao3-0/+72
The captured data will be combined from each cpu DAI if the dai link has more than one cpu DAIs. We can set channel number indirectly by adding sdw_codec_ch_maps. Signed-off-by: Bard Liao <[email protected]> Reviewed-by: Péter Ujfalusi <[email protected]> Reviewed-by: Pierre-Louis Bossart <[email protected]> Reviewed-by: Ranjani Sridharan <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: add N cpus to M codecs dai link supportBard Liao3-5/+69
Currently, ASoC supports dailinks with the following mappings: 1 cpu DAI to N codec DAIs N cpu DAIs to N codec DAIs But the mapping between N cpu DAIs and M codec DAIs is not supported. The reason is that we didn't have a mechanism to map cpu and codec DAIs This patch suggests a new snd_soc_dai_link_codec_ch_map struct in struct snd_soc_dai_link{} which provides codec DAI to cpu DAI mapping information used to implement N cpu DAIs to M codec DAIs support. When a dailink contains two or more cpu DAIs, we should set channel number of cpus based on its channel mask. The new struct also provides channel mask information for each codec and we can construct the cpu channel mask by combining all codec channel masks which map to the cpu. The N:M mapping is however restricted to the N <= M case due to physical restrictions on a time-multiplexed bus such as I2S/TDM, AC97, SoundWire and HDaudio. Signed-off-by: Bard Liao <[email protected]> Reviewed-by: Péter Ujfalusi <[email protected]> Reviewed-by: Pierre-Louis Bossart <[email protected]> Reviewed-by: Ranjani Sridharan <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs35l30: Use maple tree register cacheMark Brown1-1/+1
The cs35l30 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs43130: Use maple tree register cacheMark Brown1-1/+1
The cs43130 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs42l83: Use maple tree register cacheMark Brown1-1/+1
The cs42l83 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs42l73: Use maple tree register cacheMark Brown1-1/+1
The cs42l73 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs42l42: Use maple tree register cacheMark Brown1-1/+1
The cs42l42 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs4234: Use maple tree register cacheMark Brown1-1/+1
The cs4234 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs35l35: Use maple tree register cacheMark Brown1-1/+1
The cs35l35 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs35l34: Use maple tree register cacheMark Brown1-1/+1
The cs35l34 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs35l33: Use maple tree register cacheMark Brown1-1/+1
The cs35l33 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: cs35l32: Use maple tree register cacheMark Brown1-1/+1
The cs35l32 can only support single register read and write operations so does not benefit from block writes. This means it gets no benefit from using the rbtree register cache over the maple tree register cache so convert it to use maple trees instead, it is more modern. Acked-by: David Rhodes <[email protected]> Signed-off-by: Mark Brown <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-13ASoC: tegra: Fix Master Volume ControlJon Hunter1-0/+3
Commit 3ed2b549b39f ("ALSA: pcm: fix wait_time calculations") corrected the PCM wait_time calculations and in doing so reduced the calculated wait_time. This exposed an issue with the Tegra Master Volume Control (MVC) device where the reduced wait_time caused the MVC to fail. For now fix this by setting the default wait_time for Tegra to be 500ms. Fixes: 3ed2b549b39f ("ALSA: pcm: fix wait_time calculations") Signed-off-by: Jon Hunter <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs: remove redundant dapm routesMark Brown12-492/+31
Merge series from Brent Lu <[email protected]>: This patch series remove redundant dapm routes declared in multiple machine drivers. These routes will be created by snd_soc_dapm_connect_dai_link_widgets() during soundcard initialization. Following is the kernel log from a KBL chromebook nocturne. dmic: [ 13.773455] avs_dmic avs_dmic: connected DAI link dmic-codec:Capture -> dmic-platform:DMIC Rx [ 13.773460] avs_dmic avs_dmic: connected DAI link dmic-codec:Capture -> dmic-platform:DMIC WoV Rx max98373: [ 14.079536] avs_max98373 avs_max98373.1: connected DAI link avs_max98373.1-platform:ssp0 Tx -> i2c-MX98373:00:Right HiFi Playback [ 14.079545] avs_max98373 avs_max98373.1: connected DAI link i2c-MX98373:00:Right HiFi Capture -> avs_max98373.1-platform:ssp0 Rx [ 14.079550] avs_max98373 avs_max98373.1: connected DAI link avs_max98373.1-platform:ssp0 Tx -> i2c-MX98373:01:Left HiFi Playback [ 14.079554] avs_max98373 avs_max98373.1: connected DAI link i2c-MX98373:01:Left HiFi Capture -> avs_max98373.1-platform:ssp0 Rx hdaudio: [ 14.094818] avs_hdaudio avs_hdaudio.2: connected DAI link hdaudioB0D2-platform:hdaudioB0D2-cpu0 Tx -> hdaudioB0D2:HDMI 0 Playback [ 14.094824] avs_hdaudio avs_hdaudio.2: connected DAI link hdaudioB0D2-platform:hdaudioB0D2-cpu1 Tx -> hdaudioB0D2:HDMI 1 Playback [ 14.094828] avs_hdaudio avs_hdaudio.2: connected DAI link hdaudioB0D2-platform:hdaudioB0D2-cpu2 Tx -> hdaudioB0D2:HDMI 2 Playback
2023-06-12ASoC: mediatek: mt8173: Fix error pathsMark Brown1-6/+7
Merge series from Ricardo Ribalda Delgado <[email protected]>: ASoC: mediatek: mt8173, presented a couple of error paths errors, lets fix them.
2023-06-12ASoC: audio-graph-card2-custom-sample.dtsi: remove DT warningKuninori Morimoto1-50/+101
Current audio-graph-card2-custom-sample.dtsi is missing address-cells / size-cells / reg. Thus it get too many DT warnings. This patch solved it. Signed-off-by: Kuninori Morimoto <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Switch two more i2c drivers back to use .probe()Uwe Kleine-König2-2/+2
The previous conversion back to .probe() applied in commit 9abcd24002bf ("ASoC: Switch i2c drivers back to use .probe()") was created based on v6.3. Since then two more drivers were added which need to be convert back in the same way before eventually .probe_new() can be dropped from struct i2c_driver. Signed-off-by: Uwe Kleine-König <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: dt-bindings: cirrus,cs35l45: drop unneeded quotesKrzysztof Kozlowski1-5/+5
Cleanup bindings dropping unneeded quotes. Once all these are fixed, checking for this can be enabled in yamllint. Signed-off-by: Krzysztof Kozlowski <[email protected]> Acked-by: Charles Keepax <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: mediatek: mt8173: Fix irq error pathRicardo Ribalda Delgado1-4/+5
After reordering the irq probe, the error path was not properly done. Lets fix it. Reported-by: Dan Carpenter <[email protected]> Cc: [email protected] Fixes: 4cbb264d4e91 ("ASoC: mediatek: mt8173: Enable IRQ when pdata is ready") Signed-off-by: Ricardo Ribalda Delgado <[email protected]> Reviewed-by: AngeloGioacchino Del Regno <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: mediatek: mt8173: Fix snd_soc_component_initialize error pathRicardo Ribalda Delgado1-2/+2
If the second component fails to initialize, cleanup the first on. Reported-by: Dan Carpenter <[email protected]> Cc: [email protected] Fixes: f1b5bf07365d ("ASoC: mt2701/mt8173: replace platform to component") Signed-off-by: Ricardo Ribalda Delgado <[email protected]> Reviewed-by: AngeloGioacchino Del Regno <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-ssm4567: remove redundant dapm routesBrent Lu1-54/+3
Four routes "Left Playback<-sspX Tx", "Right Playback<-sspX Tx", "sspX Rx<-Left Capture Sense", and "sspX Rx<-Right Capture Sense" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-rt5682: remove redundant dapm routesBrent Lu1-42/+3
Two routes "AIF1 Playback<-sspX Tx" and "sspX Rx<-AIF1 Capture" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-rt298: remove redundant dapm routesBrent Lu1-42/+3
Two routes "AIF1 Playback<-sspX Tx" and "sspX Rx<-AIF1 Capture" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-rt286: remove redundant dapm routesBrent Lu1-42/+3
Two routes "AIF1 Playback<-sspX Tx" and "sspX Rx<-AIF1 Capture" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-rt274: remove redundant dapm routesBrent Lu1-42/+3
Two routes "AIF1 Playback<-sspX Tx" and "sspX Rx<-AIF1 Capture" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-nau8825: remove redundant dapm routesBrent Lu1-42/+3
Two routes "Playback<-sspX Tx" and "sspX Rx<-Capture" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-max98927: remove redundant dapm routesBrent Lu1-42/+3
Two routes "Left HiFi Playback<-sspX Tx" and "Right HiFi Playback<-sspX Tx" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-max98373: remove redundant dapm routesBrent Lu1-42/+3
Two routes "Left HiFi Playback<-sspX Tx" and "Right HiFi Playback<-sspX Tx" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-max98357a: remove redundant dapm routesBrent Lu1-36/+3
The route "HiFi Playback<-sspX Tx" is created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-hdaudio: remove redundant dapm routesBrent Lu1-64/+1
Three routes "HDMI 0 Playback<-hdaudioB0D2-cpu0 Tx", "HDMI 1 Playback<-hdaudioB0D2-cpu1 Tx" and "HDMI 2 Playback<-hdaudioB0D2-cpu2 Tx" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-dmic: remove redundant dapm routesBrent Lu1-2/+0
Two routes "DMIC Rx<-Capture" and "DMIC WoV Rx<-Capture" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-12ASoC: Intel: avs-da7219: remove redundant dapm routesBrent Lu1-42/+3
Two routes "Playback<-sspX Tx" and "sspX Rx<-Capture" are created by snd_soc_dapm_connect_dai_link_widgets() automatically. Remove the duplicate routes. Signed-off-by: Brent Lu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-09Fix error check and cleanup for JH7110 TDMMark Brown1-12/+3
Merge series from Walker Chen <[email protected]>: Some minor issues were found during addtional testing and static analysis. The first patch fix the error check for the return value of devm_reset_control_array_get_exclusive(). The second patch drop some unused macros.
2023-06-09ASoC: dt-bindings: audio-graph-card: Expand 'widgets' documentationMarek Vasut1-1/+5
Document the encoding of 'widgets' property to avoid confusion. Signed-off-by: Marek Vasut <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-09ASoC: audio-graph-card2-custom-sample: add missing CPU:Codec = 1:N sampleKuninori Morimoto1-0/+26
It has CPU:Codec = 1:1 and N:N samples, but missing 1:N settings. This patch adds it. One note here is that because of registering timing, probing and CPU/Codec numbering are mismatching. Signed-off-by: Kuninori Morimoto <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-09ASoC: SOF: Add IPC3 Kernel InjectorCurtis Malainey5-0/+228
Add debugfs path to fake a malicious firmware message for fuzzing purposes. Skip IPC4 for initial integration Signed-off-by: Curtis Malainey <[email protected]> Reviewed-by: Ranjani Sridharan <[email protected]> Reviewed-by: Pierre-Louis Bossart <[email protected]> Reviewed-by: Péter Ujfalusi <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-09ASoC: SOF: Refactor rx function for fuzzingCurtis Malainey2-24/+41
Refactor the function so reading the data is done outside the work function so fuzzing can pass data directly into the work callbacks. Also expose the inner function outside the module so we can call it from the injector. Signed-off-by: Curtis Malainey <[email protected]> Reviewed-by: Ranjani Sridharan <[email protected]> Reviewed-by: Pierre-Louis Bossart <[email protected]> Reviewed-by: Péter Ujfalusi <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-09ASoC: mediatek: mt8192-mt6359: Go back to old headphone pin nameNícolas F. R. A. Prado1-1/+1
This reverts commit cbbc0ec6dea09c ("ASoC: mediatek: mt8192-mt6359: Remove " Jack" from Headphone pin name"). That commit removed the " Jack" suffix with the reasoning that it is automatically added to the name of the kcontrol created, which is true, but this name is also used to look for the DAPM widget that will be toggled when the jack status is updated. Since the widget is still called "Headphone Jack" the jack can't link to the widget and the following error is shown: mt8192_mt6359 sound: ASoC: DAPM unknown pin Headphone It is not possible to also rename the headphone DAPM widget because its name is used by a switch kcontrol, "Headphone Jack Switch", both to link to the headphone widget and to assemble its name. This switch's name is referenced in the upstream UCM file, so renaming it would break userspace. Since the original commit didn't bring any benefit, besides sparing a few CPU cycles, simply revert it. Signed-off-by: Nícolas F. R. A. Prado <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-09ASoC: starfive: Remove some unused macrosWalker Chen1-8/+0
These macros are unused and can be dropped. Signed-off-by: Walker Chen <[email protected]> Reviewed-by: Claudiu Beznea <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-09ASoC: starfive: Fix an error check in jh7110_tdm_clk_reset_get()Walker Chen1-4/+3
Fix the check for devm_reset_control_array_get_exclusive() return value. The devm_reset_control_array_get_exclusive() function may return NULL if it's an optional request. If optional is intended then NULL should not be treated as an error case, but as a special kind of success case. So here the IS_ERR() is used to check better. Signed-off-by: Walker Chen <[email protected]> Reviewed-by: Claudiu Beznea <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-08ASoC: mt8188-mt6359: CleanupsMark Brown1-42/+45
Merge series from AngeloGioacchino Del Regno <[email protected]>: This series performs some cleanups to the mt8188-mt6359 driver, including usage of bitfield macros, adding definitions of register fields and some others for readability and consistency.
2023-06-08ASoC: tegra: Simplify code around clk_get_rate() handlingChristophe JAILLET2-10/+8
clk_get_rate() returns an unsigned long, so there is no point in storing it in a long, and test for negative values. So, turn 'parent_rate' into an unsigned long, simplify the sanity check, the error message and the return value, in case of error (i.e. 0). Doing so also turns 'i' and 'valid_rates' into unsigned long, but it is fine and harmless. Signed-off-by: Christophe JAILLET <[email protected]> Link: https://lore.kernel.org/r/53f928290f08f50ff43031e17fe1d88443c2c441.1686202022.git.christophe.jaillet@wanadoo.fr Signed-off-by: Mark Brown <[email protected]>
2023-06-08ASoC: max98088: clean up some inconsistent indentingJiapeng Chong1-11/+11
No functional modification involved. sound/soc/codecs/max98088.c:316 m98088_eq_band() warn: inconsistent indenting. Reported-by: Abaci Robot <[email protected]> Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=5461 Signed-off-by: Jiapeng Chong <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-08ASoC: mediatek: mt8188-mt6359: Use bitfield macros for registersAngeloGioacchino Del Regno1-13/+19
Replace open coded instances of FIELD_GET() with it, move register definitions at the top of the file and also replace magic numbers with register definitions. While at it, also change a regmap_update_bits() call to regmap_write() because the top 29 bits of AUD_TOP_CFG (31:3) are reserved (unused). Signed-off-by: AngeloGioacchino Del Regno <[email protected]> Reviewed-by: Alexandre Mergnat <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-08ASoC: mediatek: mt8188-mt6359: Clean up log levelsAngeloGioacchino Del Regno1-11/+10
Change some dev_info prints to dev_err() and some to dev_dbg(), depending on the actual severity of them. Signed-off-by: AngeloGioacchino Del Regno <[email protected]> Reviewed-by: Alexandre Mergnat <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-08ASoC: mediatek: mt8188-mt6359: Cleanup return 0 disguised as return retAngeloGioacchino Del Regno1-8/+12
Change all instances of `return ret` to `return 0` at the end of functions where ret is always zero and also change functions mt8188_{hdmi,dptx}_codec_init to be consistent with how other functions are returning errors Signed-off-by: AngeloGioacchino Del Regno <[email protected]> Reviewed-by: Alexandre Mergnat <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
2023-06-08ASoC: mediatek: mt8188-mt6359: clean up a return in codec_initDan Carpenter1-1/+1
This code triggers a Smatch static checker warning and does sort of look like an error path. sound/soc/mediatek/mt8188/mt8188-mt6359.c:597 mt8188_max98390_codec_init() warn: missing error code? 'ret' However, returning 0 is intentional. Make that explicit. Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: AngeloGioacchino Del Regno <[email protected]> Reviewed-by: Alexandre Mergnat <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>