Opened 14 years ago

Closed 14 years ago

#8641 closed defect (fixed)

DVD playback broken by recent pulse audio disabling changes.

Reported by: danielk Owned by: JYA
Priority: minor Milestone: 0.24
Component: MythTV - Audio Output Version: Master Head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

The pulse audio disabling code calls myth_system with locks held so when myth system processes Qt events the first one that tries to process audio causes the application to deadlock.

backtrace attached

Attachments (5)

8641-backtrace.txt (10.8 KB) - added by danielk 14 years ago.
8641-v1.patch (1.4 KB) - added by danielk 14 years ago.
8641-v2.patch (11.8 KB) - added by danielk 14 years ago.
8641-v3.patch (18.0 KB) - added by danielk 14 years ago.
8641-v4.patch (7.2 KB) - added by danielk 14 years ago.
Here's what's left of the patch, mostly debugging stuff. May be useful in the future.

Download all attachments as: .zip

Change History (11)

Changed 14 years ago by danielk

Attachment: 8641-backtrace.txt added

comment:1 Changed 14 years ago by JYA

Did this occur prior to your r25257 changes? I haven't seen this behavior prior to it

comment:2 Changed 14 years ago by danielk

yes

comment:3 Changed 14 years ago by danielk

hmm, actually no. something different goes wrong. let me look into this a bit more.

Changed 14 years ago by danielk

Attachment: 8641-v1.patch added

comment:4 Changed 14 years ago by danielk

This patch by all rights should fix both problems, but it actually brings back the no video problem. :|

FYI For anyone experiencing either problem, removing pulseaudio & libpulse development packages when compiling makes both problems go away.

Changed 14 years ago by danielk

Attachment: 8641-v2.patch added

comment:5 Changed 14 years ago by danielk

8641-v2.patch should prevent myth_system from re-enabling mythui painting when it should be disabled and do so in a thread-safe manner and without breaking DVD playback.

This hasn't been tested much yet, it still contains lots of debugging, and it looks like it prevents the MythUI intro screen from working.

For the last bit I'll rework how this is used in tv_play.cpp, so draws are not disabled until we actually start playing the video but for now I just added a push in the ctor and a pop in the dtor for simplicity's sake.

Changed 14 years ago by danielk

Attachment: 8641-v3.patch added

comment:6 Changed 14 years ago by danielk

Resolution: fixed
Status: newclosed

(In [25319]) Fixes #8641.

This makes sure mythui painting is disabled before video playback starts and that myth_system can not cause mythui painting to be re-enabled.

Note: In order to make sure the video intro screen is still shown I moved some of the tv_play initialization so that the screen is drawn earlier.

Changed 14 years ago by danielk

Attachment: 8641-v4.patch added

Here's what's left of the patch, mostly debugging stuff. May be useful in the future.

Note: See TracTickets for help on using tickets.