mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-08 20:07:46 +09:00
audio: modify lanemask for tdmout
PD#149114: S420 V03 speaker no sound when playing 2-ch wav
S400 & S420 modify the lineout and speaker out on TDMC dataIO2.
This commit make the speaker output available
by the output lanemask setting:
"dai-tdm-lane-slot-mask-out = <0 0 1 0>;"
It masks the third lane as data output when playing two channel
PCM waves.
Change-Id: Id1627c06f24f3fb57cc645247ca8183f197656db
Signed-off-by: Shuai Li <shuai.li@amlogic.com>
This commit is contained in:
@@ -529,18 +529,12 @@ static int aml_tdm_set_lanes(struct aml_tdm *p_tdm,
|
||||
// set lanes mask acordingly
|
||||
lane_mask = setting->lane_mask_out;
|
||||
for (i = 0; i < 4; i++) {
|
||||
unsigned int ch = i * 2;
|
||||
|
||||
if (i < lanes)
|
||||
if (((1 << i) & lane_mask) && lanes--) {
|
||||
aml_tdm_set_channel_mask(p_tdm->actrl,
|
||||
stream, p_tdm->id, i, setting->tx_mask);
|
||||
|
||||
if ((1 << i) & lane_mask) {
|
||||
// each lane only L/R swap
|
||||
swap_val |= set_num++ << (ch++ * 4);
|
||||
swap_val |= set_num++ << (ch * 4);
|
||||
}
|
||||
}
|
||||
swap_val = 0x76543210;
|
||||
aml_tdm_set_lane_channel_swap(p_tdm->actrl,
|
||||
stream, p_tdm->id, swap_val);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user