JackOfAll wrote: 
> squeezelite 100% CPU. Related to using the audio clock for spdif out?
> 
> > 
Code:
--------------------
  >   > 
  > [44755.805477] BUG: scheduling while atomic: squeezelite/2725/0x00000003
  > [44755.882662] Modules linked in: rfcomm bnep hci_uart bluetooth brcmfmac 
brcmutil cfg80211 snd_usb_audio rfkill snd_hwdep snd_usbmidi_lib snd_rawmidi 
snd_seq_device uinput
  > [44756.063911] Backtrace: 
  > [44756.093110] [<8004aa1c>] (dump_backtrace+0x0/0x108) from [<80536cc0>] 
(dump_stack+0x18/0x1c)
  > [44756.194258]  r6:b6b60000 r5:81aca1c0 r4:00000000 r3:60000093
  > [44756.261976] [<80536ca8>] (dump_stack+0x0/0x1c) from [<805372d0>] 
(__schedule_bug+0x64/0x74)
  > [44756.362088] [<8053726c>] (__schedule_bug+0x0/0x74) from [<8053cda8>] 
(__schedule+0x7c/0x6c4)
  > [44756.463236]  r4:90809260 r3:00000000
  > [44756.505950] [<8053cd2c>] (__schedule+0x0/0x6c4) from [<8053d57c>] 
(schedule+0x80/0x84)
  > [44756.600855] [<8053d4fc>] (schedule+0x0/0x84) from [<8053e600>] 
(__mutex_lock_slowpath+0x180/0x1f0)
  > [44756.708256] [<8053e480>] (__mutex_lock_slowpath+0x0/0x1f0) from 
[<8053e698>] (mutex_lock+0x28/0x40)
  > [44756.816691]  r8:bf855200 r7:0000000e r6:806e2b54 r5:2ee00000 r4:806e6ac0
  > [44756.896910] [<8053e670>] (mutex_lock+0x0/0x40) from [<8006435c>] 
(clk_set_rate+0x3c/0x6c)
  > [44756.994928]  r4:806e2c44 r3:8005a6e8
  > [44757.037644] [<80064320>] (clk_set_rate+0x0/0x6c) from [<80064254>] 
(wand_set_spdif_clk_rate+0x5c/0xa0)
  > [44757.149204]  r5:00000010 r4:02ee0000
  > [44757.191923] [<800641f8>] (wand_set_spdif_clk_rate+0x0/0xa0) from 
[<80436050>] (mxc_spdif_trigger+0x1d0/0x5f0)
  > [44757.310773]  r7:0000000e r6:00000001 r5:00000004 r4:0002ee00
  > [44757.378491] [<80435e80>] (mxc_spdif_trigger+0x0/0x5f0) from [<8042a758>] 
(soc_pcm_trigger+0x50/0xf0)
  > [44757.487968]  r8:bf8536c0 r7:bf84c2a0 r6:00000001 r5:bf885400 r4:bf855200
  > [44757.566092] r3:80435e80
  > [44757.597355] [<8042a708>] (soc_pcm_trigger+0x0/0xf0) from [<80422400>] 
(snd_pcm_do_start+0x2c/0x38)
  > [44757.704751]  r8:806ffe68 r7:00000000 r6:00000003 r5:806ffe68 r4:bf855200
  > [44757.782876] r3:8042a708
  > [44757.814136] [<804223d4>] (snd_pcm_do_start+0x0/0x38) from [<80422124>] 
(snd_pcm_action_single+0x40/0x6c)
  > [44757.927787] [<804220e4>] (snd_pcm_action_single+0x0/0x6c) from 
[<80422350>] (snd_pcm_action_lock_irq+0x7c/0x9c)
  > [44758.048722]  r7:00000003 r6:bf85528c r5:bf85528c r4:bf855200
  > [44758.116443] [<804222d4>] (snd_pcm_action_lock_irq+0x0/0x9c) from 
[<80423640>] (snd_pcm_common_ioctl1+0x7d4/0xf70)
  > [44758.239466]  r8:2cb00c58 r7:ba52b320 r6:2cb00c58 r5:bf855200 r4:2cb00c58
  > [44758.317589] r3:00004142
  > [44758.348849] [<80422e6c>] (snd_pcm_common_ioctl1+0x0/0xf70) from 
[<80424614>] (snd_pcm_playback_ioctl1+0x3c0/0x434)
  > [44758.472919] [<80424254>] (snd_pcm_playback_ioctl1+0x0/0x434) from 
[<804246b8>] (snd_pcm_playback_ioctl+0x30/0x3c)
  > [44758.595936]  r8:bf87cc10 r7:00004142 r6:2cb00c58 r5:ba52b320 r4:00000000
  > [44758.676161] [<80424688>] (snd_pcm_playback_ioctl+0x0/0x3c) from 
[<8010c0b4>] (vfs_ioctl+0x28/0x44)
  > [44758.783563] [<8010c08c>] (vfs_ioctl+0x0/0x44) from [<8010cbd8>] 
(do_vfs_ioctl+0x4cc/0x520)
  > [44758.882632] [<8010c70c>] (do_vfs_ioctl+0x0/0x520) from [<8010cc80>] 
(sys_ioctl+0x54/0x80)
  > [44758.980659] [<8010cc2c>] (sys_ioctl+0x0/0x80) from [<80047220>] 
(ret_fast_syscall+0x0/0x30)
  > [44759.080762]  r8:800473a4 r7:00000036 r6:000247cc r5:42cb5000 r4:2cb00af0
  > 
--------------------
> > 

Have you seen this more than once???  I think the cause of the error
message is the fact that arch/arm/plat-mxc/clock.c uses a mutex to
protect the clock state in clk_set_rate, but if look at implementations
for clk_set_rate for other architectures it is a spinlock.  If we want
to be able to alter the underlying clock rate at the time of changing
the spdif clock then I think we need to be able to do it from within
wand_set_spdif_clk_rate. However this message is a warning which should
not prevent scheduling when the mutex is freed?  So if this is causing
100% cpu then there is something more significant happening?  What were
the circumstances?


------------------------------------------------------------------------
Triode's Profile: http://forums.slimdevices.com/member.php?userid=17
View this thread: http://forums.slimdevices.com/showthread.php?t=98544

_______________________________________________
unix mailing list
unix@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/unix

Reply via email to