Page MenuHomeFreeBSD

sound examples: Simplify audio example
ClosedPublic

Authored by christos on Aug 15 2024, 3:04 PM.
Tags
None
Referenced Files
F103363828: D46307.id142402.diff
Sun, Nov 24, 1:59 AM
Unknown Object (File)
Sat, Nov 23, 1:26 AM
Unknown Object (File)
Fri, Nov 22, 6:16 PM
Unknown Object (File)
Fri, Nov 22, 12:54 PM
Unknown Object (File)
Thu, Nov 21, 12:56 AM
Unknown Object (File)
Wed, Nov 20, 9:04 AM
Unknown Object (File)
Wed, Nov 20, 7:37 AM
Unknown Object (File)
Wed, Nov 20, 4:38 AM
Subscribers

Details

Summary
  • Merge ossinit.h and basic.c.
  • Rename basic.c to audio.c.
  • Use err(3) instead of fprintf(3) + exit(3).
  • Some style(9) improvements.

Sponsored by: The FreeBSD Foundation
MFC after: 2 days

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 59032
Build 55919: arc lint + arc unit

Event Timeline

Add ossinit.h removal to ObsoleteFiles.inc.

Add basic.c rename to ObsoleteFiles.inc as well.

I suppose the original idea by @meka_tilda.center was to implement another example using mmap, at least there's code fragments for that. What's the plan regarding a mmap example?

I suppose the original idea by @meka_tilda.center was to implement another example using mmap, at least there's code fragments for that. What's the plan regarding a mmap example?

Here I simply re-arranged and cleaned up some parts. I think the mmap example should be added in a separate patch.

This revision is now accepted and ready to land.Aug 20 2024, 3:31 PM

I suppose the original idea by @meka_tilda.center was to implement another example using mmap, at least there's code fragments for that. What's the plan regarding a mmap example?

To be honest, at the time of writing those examples I didn't know much about FreeBSD audio. As a matter of fact, that was the reason I wrote them: I wanted to learn and write it down for others. So, thank you, Christos, for improving it. Where I hit the wall is mmap mode and kqueue example, because cuse (hence, virtual_oss) has kqueue handler, but kernel OSS doesn't. What I'm trying to say is that I wrote down in those examples as I learned, so no wonder there are traces of mmap support.

This revision was automatically updated to reflect the committed changes.