[PATCHv2 56/60] bluetooth: Process source messages for BlueZ 5 cards

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2013-08-13 at 01:54 -0300, jprvita at gmail.com wrote:
> +        case PA_SOURCE_MESSAGE_GET_LATENCY: {
> +            pa_usec_t wi, ri;
> +
> +            if (u->read_smoother) {
> +                wi = pa_smoother_get(u->read_smoother, pa_rtclock_now());
> +                ri = pa_bytes_to_usec(u->read_index, &u->sample_spec);
> +
> +                *((pa_usec_t*) data) = (wi > ri ? wi - ri : 0) + u->source->thread_info.fixed_latency;

I don't know why didn't complain about this last time, but I think this
has the same issue as the sink latency calculation: fixed_latency is
supposed to be the maximum latency, but here we should report the
current real latency. Instead of adding fixed_latency here, we should
only add FIXED_LATENCY_RECORD_A2DP.

-- 
Tanu



[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux