Date: Fri, 28 Apr 2006 15:36:32 +1000 (EST) From: Ian Smith <smithi@nimnet.asn.au> To: freebsd-multimedia@freebsd.org Subject: /dev/speaker broken in 5.x? (fwd) Message-ID: <Pine.BSF.3.96.1060428152820.6949A-100000@gaia.nimnet.asn.au>
next in thread | raw e-mail | index | archive | help
If this is not an appropriate topic for -multimedia, can someone please at least suggest where it might be on topic? Is anyone able to confirm (or otherwise) the behaviour demonstrated below on a 5.x or 6.x system? Cheers, Ian ---------- Forwarded message ---------- Date: Mon, 24 Apr 2006 15:53:58 +1000 From: Ian Smith <smithi@nimnet.asn.au> To: freebsd-multimedia@freebsd.org Subject: /dev/speaker broken in 5.x? Hoping it's not disrespectful to mention /dev/speaker in -multimedia :) but I've long found it very handy on the laptop for low-overhead sharp little sounds indicating battery charge state changes, generated by apmd events as per the examples in apmd.conf. This always worked fine in 4.5, and as far as I can tell from CVS, is unchanged in 4-STABLE. Since installing 5.4, I get the following always repeatable symptoms when using the speaker device to play tunes, shown here as root but it's just the same when run as a (wheel) user: paqi# echo "T250L8CE-GE-C" > /dev/speaker # works fine the 1st time .. paqi# fstat | grep speaker # but leaves speaker open .. root csh 1919 4 /dev 72 crw-rw---- speaker w root fstat 1918 4 /dev 72 crw-rw---- speaker w root csh 1116 4 /dev 72 crw-rw---- speaker w paqi# echo "T250L8CE-GE-C" > /dev/speaker # no sound every 2nd time .. /dev/speaker: Device busy. paqi# fstat | grep speaker # but frees the device again, paqi# echo "T250L8CE-GE-C" > /dev/speaker # to work again next time .. So I'm trying to figure out what's changed from 4.5 to 5.4 at http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/i386/isa/Attic/spkr.c.diff?hideattic=0&r1=1.45%3ARELENG_4_5_0_RELEASE&tr1=1.1&r2=1.66.2.1%3ARELENG_5_4_0_RELEASE&tr2=1.69.2.1 Apart from fairly obvious changes for devfs and such, the addition of PC98 code and coding major functions as macros, I can't spot what might cause the device to be left open after playing a string, but assume there's some problem with spkrclose(), or it's not getting called at the end of the playstring (?), or maybe the fairly extensive looking updates to clock.c re TIMER2 have something to do with it .. it's way beyond me. FWIW, spkrtest(8) works fine (as long as the device was left in closed state, as above) to play one or multiple example tunes. I've searched the list and PRs as best I can, finding no mention of such a problem. There has been only one further (apparently purely cosmetic) change to spkr.c at 6-STABLE since 5.4. Does anyone have any ideas, or interest in this lowly 'legacy' function working properly again? Cheers, Ian _______________________________________________ freebsd-multimedia@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-multimedia To unsubscribe, send any mail to "freebsd-multimedia-unsubscribe@freebsd.org"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.96.1060428152820.6949A-100000>