Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 561024aa authored by Alice Kuo's avatar Alice Kuo
Browse files

Fix regression for the frame duration conf missing

The patch fix the regression with
cd703c6e leaudio: Simplify stream configuration

The previous patch removed the frame duration setting that offload case would always get the 0 frame duration update. Add it back to update the correct value.

Bug: 231084798
Test: LE audio offload streaming
Change-Id: Iadcdd96612121dd7e19ddb7a80a0ac1e477ce058
Merged-In: Iadcdd96612121dd7e19ddb7a80a0ac1e477ce058
(cherry picked from commit 33bb0d7a)
parent 51ac59bb
Loading
Loading
Loading
Loading
+22 −0
Original line number Diff line number Diff line
@@ -921,6 +921,17 @@ class LeAudioGroupStateMachineImpl : public LeAudioGroupStateMachine {
                   *ase->codec_config.codec_frames_blocks_per_sdu);
      }

      if (stream_conf->sink_frame_duration_us == 0) {
        stream_conf->sink_frame_duration_us =
            ase->codec_config.GetFrameDurationUs();
      } else {
        ASSERT_LOG(stream_conf->sink_frame_duration_us ==
                       ase->codec_config.GetFrameDurationUs(),
                   "frame_duration_us: %d!=%d",
                   stream_conf->sink_frame_duration_us,
                   ase->codec_config.GetFrameDurationUs());
      }

      LOG_INFO(
          " Added Sink Stream Configuration. CIS Connection Handle: %d"
          ", Audio Channel Allocation: %d"
@@ -980,6 +991,17 @@ class LeAudioGroupStateMachineImpl : public LeAudioGroupStateMachine {
                   *ase->codec_config.codec_frames_blocks_per_sdu);
      }

      if (stream_conf->source_frame_duration_us == 0) {
        stream_conf->source_frame_duration_us =
            ase->codec_config.GetFrameDurationUs();
      } else {
        ASSERT_LOG(stream_conf->source_frame_duration_us ==
                       ase->codec_config.GetFrameDurationUs(),
                   "frame_duration_us: %d!=%d",
                   stream_conf->source_frame_duration_us,
                   ase->codec_config.GetFrameDurationUs());
      }

      LOG_INFO(
          " Added Source Stream Configuration. CIS Connection Handle: %d"
          ", Audio Channel Allocation: %d"