The NetBSD Project

CVS log for src/sys/dev/audio.c

[BACK] Up to [cvs.netbsd.org] / src / sys / dev

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.243.10.1 / (download) - annotate - [select for diffs], Wed May 13 17:19:05 2009 UTC (7 weeks, 2 days ago) by jym
Branch: jym-xensuspend
Changes since 1.243: +5 -4 lines
Diff to previous 1.243 (colored) next main 1.244 (colored)

Sync with HEAD.

Commit is split, to avoid a "too many arguments" protocol error.

Revision 1.239.2.1 / (download) - annotate - [select for diffs], Mon May 4 08:12:32 2009 UTC (2 months ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.239: +56 -34 lines
Diff to previous 1.239 (colored) next main 1.240 (colored)

sync with head.

Revision 1.243.4.1 / (download) - annotate - [select for diffs], Tue Apr 28 07:35:13 2009 UTC (2 months ago) by skrll
Branch: nick-hppapmap
Changes since 1.243: +5 -4 lines
Diff to previous 1.243 (colored) next main 1.244 (colored)

Sync with HEAD.

Revision 1.244 / (download) - annotate - [select for diffs], Fri Apr 17 20:04:35 2009 UTC (2 months, 2 weeks ago) by dyoung
Branch: MAIN
CVS Tags: yamt-nfs-mp-base5, yamt-nfs-mp-base4, yamt-nfs-mp-base3, nick-hppapmap-base4, nick-hppapmap-base3, nick-hppapmap-base, jym-xensuspend-nbase, jym-xensuspend-base, HEAD
Changes since 1.243: +5 -4 lines
Diff to previous 1.243 (colored)

Detach audio(4) during shutdown.

Revision 1.243.8.9 / (download) - annotate - [select for diffs], Sat Dec 13 12:32:10 2008 UTC (6 months, 2 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243.8.8: +49 -5 lines
Diff to previous 1.243.8.8 (colored) to branchpoint 1.243 (colored) next main 1.244 (colored)

- Add a table listing hw_if methods, and which locks are held when called.
- Grab locks in a couple more places.

Revision 1.243.8.8 / (download) - annotate - [select for diffs], Fri Dec 12 12:47:02 2008 UTC (6 months, 3 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243.8.7: +4 -2 lines
Diff to previous 1.243.8.7 (colored) to branchpoint 1.243 (colored)

Acquire interrupt level lock for hw->close, on error.

Revision 1.243.8.7 / (download) - annotate - [select for diffs], Fri Dec 12 09:57:35 2008 UTC (6 months, 3 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243.8.6: +4 -4 lines
Diff to previous 1.243.8.6 (colored) to branchpoint 1.243 (colored)

audiommap() doesn't need a writer lock.

Revision 1.243.8.6 / (download) - annotate - [select for diffs], Thu Dec 11 19:49:29 2008 UTC (6 months, 3 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243.8.5: +5 -6 lines
Diff to previous 1.243.8.5 (colored) to branchpoint 1.243 (colored)

Checkpoint work in progress.

Revision 1.243.8.5 / (download) - annotate - [select for diffs], Tue Dec 9 12:22:41 2008 UTC (6 months, 3 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243.8.4: +4 -4 lines
Diff to previous 1.243.8.4 (colored) to branchpoint 1.243 (colored)

No need to run the softint at SOFTINT_SERIAL.

Revision 1.243.8.4 / (download) - annotate - [select for diffs], Mon Dec 8 13:12:22 2008 UTC (6 months, 3 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243.8.3: +20 -4 lines
Diff to previous 1.243.8.3 (colored) to branchpoint 1.243 (colored)

Allow hw->mappage to sleep.

Revision 1.243.8.3 / (download) - annotate - [select for diffs], Sun Dec 7 18:27:45 2008 UTC (6 months, 3 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243.8.2: +29 -16 lines
Diff to previous 1.243.8.2 (colored) to branchpoint 1.243 (colored)

Fix a panic and some comments.

Revision 1.243.8.2 / (download) - annotate - [select for diffs], Sun Dec 7 15:29:35 2008 UTC (6 months, 3 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243.8.1: +307 -269 lines
Diff to previous 1.243.8.1 (colored) to branchpoint 1.243 (colored)

- Serialize changes to filters and audio device settings while a read/write
  is in progress.
- Fix other concurrency issues.
- Convert to use kmem_alloc().
- Don't do evil NOWAIT allocations.
- Don't assume sc_intr_lock is a spinlock.
- Add a comment block about the locking.

Revision 1.243.8.1 / (download) - annotate - [select for diffs], Sun Dec 7 13:02:12 2008 UTC (6 months, 3 weeks ago) by ad
Branch: ad-audiomp2
Changes since 1.243: +395 -276 lines
Diff to previous 1.243 (colored)

Ressurect the ad-audiomp branch at request of matt@.

With this commit:

- core audio subsystem made MPSAFE
- eap, btsco drivers made MPSAFE

TODO:

- midi
- convert remaining drivers

Revision 1.234.6.6 / (download) - annotate - [select for diffs], Sun Jun 29 09:33:04 2008 UTC (12 months ago) by mjf
Branch: mjf-devfs2
Changes since 1.234.6.5: +8 -8 lines
Diff to previous 1.234.6.5 (colored) to branchpoint 1.234 (colored) next main 1.235 (colored)

Sync with HEAD.

Revision 1.239.4.1 / (download) - annotate - [select for diffs], Mon Jun 23 04:30:57 2008 UTC (12 months, 1 week ago) by wrstuden
Branch: wrstuden-revivesa
Changes since 1.239: +53 -32 lines
Diff to previous 1.239 (colored) next main 1.240 (colored)

Sync w/ -current. 34 merge conflicts to follow.

Revision 1.242.2.1 / (download) - annotate - [select for diffs], Wed Jun 18 16:33:03 2008 UTC (12 months, 2 weeks ago) by simonb
Branch: simonb-wapbl
Changes since 1.242: +9 -9 lines
Diff to previous 1.242 (colored) next main 1.243 (colored)

Sync with head.

Revision 1.238.2.3 / (download) - annotate - [select for diffs], Tue Jun 17 09:14:24 2008 UTC (12 months, 2 weeks ago) by yamt
Branch: yamt-pf42
Changes since 1.238.2.2: +10 -10 lines
Diff to previous 1.238.2.2 (colored) to branchpoint 1.238 (colored) next main 1.239 (colored)

sync with head.

Revision 1.243 / (download) - annotate - [select for diffs], Tue Jun 10 22:53:08 2008 UTC (12 months, 3 weeks ago) by cegger
Branch: MAIN
CVS Tags: yamt-pf42-base4, wrstuden-revivesa-base-4, wrstuden-revivesa-base-3, wrstuden-revivesa-base-2, wrstuden-revivesa-base-1, wrstuden-revivesa-base, simonb-wapbl-nbase, simonb-wapbl-base, nick-hppapmap-base2, netbsd-5-base, netbsd-5-0-RELEASE, netbsd-5-0-RC4, netbsd-5-0-RC3, netbsd-5-0-RC2, netbsd-5-0-RC1, netbsd-5-0, netbsd-5, mjf-devfs2-base, matt-mips64-base2, haad-nbase2, haad-dm-base2, haad-dm-base1, haad-dm-base, haad-dm, ad-audiomp2-base
Branch point for: nick-hppapmap, jym-xensuspend, ad-audiomp2
Changes since 1.242: +9 -9 lines
Diff to previous 1.242 (colored)

device_private(device_lookup()) -> device_lookup_private()
ok cube@

Revision 1.242 / (download) - annotate - [select for diffs], Sun Jun 8 18:18:33 2008 UTC (12 months, 3 weeks ago) by tsutsui
Branch: MAIN
Branch point for: simonb-wapbl
Changes since 1.241: +3 -3 lines
Diff to previous 1.241 (colored)

Use device_lookup_private() rather than using cd_devs[] directly to get softc.

XXX maybe we should change a type of cd_devs[] in struct cfdriver
    from (void *) to device_t.

Revision 1.234.6.5 / (download) - annotate - [select for diffs], Thu Jun 5 19:14:35 2008 UTC (12 months, 4 weeks ago) by mjf
Branch: mjf-devfs2
Changes since 1.234.6.4: +43 -22 lines
Diff to previous 1.234.6.4 (colored) to branchpoint 1.234 (colored)

Sync with HEAD.

Also fix build.

Revision 1.238.2.2 / (download) - annotate - [select for diffs], Wed Jun 4 02:05:09 2008 UTC (12 months, 4 weeks ago) by yamt
Branch: yamt-pf42
Changes since 1.238.2.1: +45 -24 lines
Diff to previous 1.238.2.1 (colored) to branchpoint 1.238 (colored)

sync with head

Revision 1.215.2.1.2.2 / (download) - annotate - [select for diffs], Tue Jun 3 20:47:19 2008 UTC (13 months ago) by skrll
Branch: wrstuden-fixsa
Changes since 1.215.2.1.2.1: +5 -4 lines
Diff to previous 1.215.2.1.2.1 (colored) next main 1.215.2.2 (colored)

Sync with netbsd-4.

Revision 1.241 / (download) - annotate - [select for diffs], Tue Jun 3 06:21:17 2008 UTC (13 months ago) by bjs
Branch: MAIN
CVS Tags: yamt-pf42-base3
Changes since 1.240: +13 -9 lines
Diff to previous 1.240 (colored)



 - Fix the conditions for POLLOUT to match those elsewhere

 - Refactor pause attribute handling so that it it's preserved
   appropriately and reset in audio_clear().

Now audio/jack-devel works with the native driver.

Revision 1.240 / (download) - annotate - [select for diffs], Tue Jun 3 02:16:18 2008 UTC (13 months ago) by jmcneill
Branch: MAIN
Changes since 1.239: +34 -17 lines
Diff to previous 1.239 (colored)

pmf: in audio_volume_up and audio_volume_down, honour the mixer control's
delta field rather than arbitrary '32' when stepping up or down master
volume.

Revision 1.234.6.4 / (download) - annotate - [select for diffs], Mon Jun 2 13:23:11 2008 UTC (13 months ago) by mjf
Branch: mjf-devfs2
Changes since 1.234.6.3: +8 -8 lines
Diff to previous 1.234.6.3 (colored) to branchpoint 1.234 (colored)

Sync with HEAD.

Revision 1.238.2.1 / (download) - annotate - [select for diffs], Sun May 18 12:33:30 2008 UTC (13 months, 2 weeks ago) by yamt
Branch: yamt-pf42
Changes since 1.238: +8 -8 lines
Diff to previous 1.238 (colored)

sync with head.

Revision 1.239 / (download) - annotate - [select for diffs], Thu Apr 24 15:35:27 2008 UTC (14 months, 1 week ago) by ad
Branch: MAIN
CVS Tags: yamt-pf42-base2, yamt-nfs-mp-base2, yamt-nfs-mp-base, hpcarm-cleanup-nbase
Branch point for: yamt-nfs-mp, wrstuden-revivesa
Changes since 1.238: +8 -8 lines
Diff to previous 1.238 (colored)

Network protocol interrupts can now block on locks, so merge the globals
proclist_mutex and proclist_lock into a single adaptive mutex (proc_lock).
Implications:

- Inspecting process state requires thread context, so signals can no longer
  be sent from a hardware interrupt handler. Signal activity must be
  deferred to a soft interrupt or kthread.

- As the proc state locking is simplified, it's now safe to take exit()
  and wait() out from under kernel_lock.

- The system spends less time at IPL_SCHED, and there is less lock activity.

Revision 1.234.6.3 / (download) - annotate - [select for diffs], Sun Apr 6 09:58:49 2008 UTC (14 months, 4 weeks ago) by mjf
Branch: mjf-devfs2
Changes since 1.234.6.2: +3 -3 lines
Diff to previous 1.234.6.2 (colored) to branchpoint 1.234 (colored)

- after some discussion with agc@ i agreed it would be a good idea to move
  device_unregister_* to device_deregister_* to be more like the pmf(9)
  functions, especially since a lot of the time the function calls are next
  to each other.

- add device_register_name() support for dk(4).

Revision 1.234.6.2 / (download) - annotate - [select for diffs], Sat Apr 5 23:33:20 2008 UTC (14 months, 4 weeks ago) by mjf
Branch: mjf-devfs2
Changes since 1.234.6.1: +16 -2 lines
Diff to previous 1.234.6.1 (colored) to branchpoint 1.234 (colored)

- add "file-system DEVFS" and "pseudo-device devfsctl" to conf/std seeing
  as these are always needed.

- convert many, many drivers over to the New Devfs World Order. For a
  list of device drivers yet to be converted see,
  http://www.netbsd.org/~mjf/devfs-todo.html.

- add a new device_unregister_all(device_t) function to remove all device
  names associated with a device_t, which saves us having to construct
  device names when the driver is detached.

- add a DEV_AUDIO type for devices.

Revision 1.234.6.1 / (download) - annotate - [select for diffs], Thu Apr 3 12:42:36 2008 UTC (15 months ago) by mjf
Branch: mjf-devfs2
Changes since 1.234: +49 -46 lines
Diff to previous 1.234 (colored)

Sync with HEAD.

Revision 1.238 / (download) - annotate - [select for diffs], Tue Apr 1 00:52:11 2008 UTC (15 months ago) by jmcneill
Branch: MAIN
CVS Tags: yamt-pf42-baseX, yamt-pf42-base
Branch point for: yamt-pf42
Changes since 1.237: +4 -4 lines
Diff to previous 1.237 (colored)

Fix audio_volume_toggle. How did this ever work for me? Thinkpad T61
mutes audio automatically when the mute key is pressed.

Revision 1.234.2.1 / (download) - annotate - [select for diffs], Mon Mar 24 07:15:11 2008 UTC (15 months, 1 week ago) by keiichi
Branch: keiichi-mipv6
Changes since 1.234: +47 -44 lines
Diff to previous 1.234 (colored) next main 1.235 (colored)

sync with head.

Revision 1.223.2.3 / (download) - annotate - [select for diffs], Sun Mar 23 02:04:34 2008 UTC (15 months, 1 week ago) by matt
Branch: matt-armv6
Changes since 1.223.2.2: +74 -46 lines
Diff to previous 1.223.2.2 (colored) to branchpoint 1.223 (colored) next main 1.224 (colored)

sync with HEAD

Revision 1.197.2.10 / (download) - annotate - [select for diffs], Mon Mar 17 09:14:36 2008 UTC (15 months, 2 weeks ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.9: +47 -44 lines
Diff to previous 1.197.2.9 (colored) to branchpoint 1.197 (colored) next main 1.198 (colored)

sync with head.

Revision 1.237 / (download) - annotate - [select for diffs], Wed Mar 12 18:02:21 2008 UTC (15 months, 3 weeks ago) by dyoung
Branch: MAIN
CVS Tags: yamt-lazymbuf-base15, yamt-lazymbuf-base14, matt-armv6-nbase, keiichi-mipv6-nbase, keiichi-mipv6-base, ad-socklock-base1
Changes since 1.236: +11 -11 lines
Diff to previous 1.236 (colored)

Use device_t and its accessors throughout.  Use aprint_*_dev().

Improve PMF-ability.

        Add a 'flags' argument to suspend/resume handlers and
        callers such as pmf_system_suspend().

        Define a flag, PMF_F_SELF, which indicates to PMF that a
        device is suspending/resuming itself.  Add helper routines,
        pmf_device_suspend_self(dev) and pmf_device_resume_self(dev),
        that call pmf_device_suspend(dev, PMF_F_SELF) and
        pmf_device_resume(dev, PMF_F_SELF), respectively.  Use
        PMF_F_SELF to suspend/resume self in ath(4), audio(4),
        rtw(4), and sip(4).

        In ath(4) and in rtw(4), replace the icky sc_enable/sc_disable
        callbacks, provided by the bus front-end, with
        self-suspension/resumption.  Also, clean up the bus
        front-ends.  Make sure that the interrupt handler is
        disestablished during suspension.  Get rid of driver-private
        flags (e.g., RTW_F_ENABLED, ath_softc->sc_invalid); use
        device_is_active()/device_has_power() calls, instead.

        In the network-class suspend handler, call if_stop(, 0)
        instead of if_stop(, 1), because the latter is superfluous
        (bus- and driver-suspension hooks will 'disable' the NIC),
        and it may cause recursion.

        In the network-class resume handler, prevent infinite
        recursion through if_init() by getting out early if we are
        self-suspending (PMF_F_SELF).

rtw(4) improvements:

        Destroy rtw(4) callouts when we detach it.  Make rtw at
        pci detachable.  Print some more information with the "rx
        frame too long" warning.

Remove activate() methods:

        Get rid of rtw_activate() and ath_activate().  The device
        activate() methods are not good for much these days.

Make ath at cardbus resume with crypto functions intact:

        Introduce a boolean device property, "pmf-powerdown".  If
        pmf-powerdown is present and false, it indicates that a
        bus back-end should not remove power from a device.

        Honor this property in cardbus_child_suspend().

        Set this property to 'false' in ath_attach(), since removing
        power from an ath at cardbus seems to lobotomize the WPA
        crypto engine.  XXX Should the pmf-powerdown property
        propagate toward the root of the device tree?

Miscellaneous ath(4) changes:

        Warn if ath(4) tries to write crypto keys to suspended
        hardware.

        Reduce differences between FreeBSD and NetBSD in ath(4)
        multicast filter setup.

        Make ath_printrxbuf() print an rx descriptor's status &
        key index, to help debug crypto errors.

        Shorten a staircase in ath_ioctl().  Don't check for
        ieee80211_ioctl() return code ERESTART, it never happens.

Revision 1.236 / (download) - annotate - [select for diffs], Tue Mar 4 18:23:44 2008 UTC (15 months, 4 weeks ago) by cube
Branch: MAIN
Changes since 1.235: +31 -33 lines
Diff to previous 1.235 (colored)

Split device_t and softc for audio(4), and other related cosmetic changes.

Revision 1.235 / (download) - annotate - [select for diffs], Sat Mar 1 14:16:50 2008 UTC (16 months ago) by rmind
Branch: MAIN
Changes since 1.234: +9 -4 lines
Diff to previous 1.234 (colored)

Welcome to 4.99.55:

- Add a lot of missing selinit() and seldestroy() calls.

- Merge selwakeup() and selnotify() calls into a single selnotify().

- Add an additional 'events' argument to selnotify() call.  It will
  indicate which event (POLL_IN, POLL_OUT, etc) happen.  If unknown,
  zero may be used.

Note: please pass appropriate value of 'events' where possible.
Proposed on: <tech-kern>

Revision 1.197.2.9 / (download) - annotate - [select for diffs], Wed Feb 27 08:36:31 2008 UTC (16 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.8: +26 -2 lines
Diff to previous 1.197.2.8 (colored) to branchpoint 1.197 (colored)

sync with head.

Revision 1.224.4.3 / (download) - annotate - [select for diffs], Mon Feb 18 21:05:31 2008 UTC (16 months, 2 weeks ago) by mjf
Branch: mjf-devfs
Changes since 1.224.4.2: +29 -4 lines
Diff to previous 1.224.4.2 (colored) to branchpoint 1.224 (colored) next main 1.225 (colored)

Sync with HEAD.

Revision 1.234 / (download) - annotate - [select for diffs], Wed Feb 13 18:31:51 2008 UTC (16 months, 2 weeks ago) by jmcneill
Branch: MAIN
CVS Tags: nick-net80211-sync-base, nick-net80211-sync, mjf-devfs-base, hpcarm-cleanup-base
Branch point for: mjf-devfs2, keiichi-mipv6
Changes since 1.233: +26 -2 lines
Diff to previous 1.233 (colored)

Disable audio idle timer. It was a fun experiment, but causes more issues
than it was worth.

Revision 1.197.2.8 / (download) - annotate - [select for diffs], Mon Feb 4 09:23:17 2008 UTC (16 months, 4 weeks ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.7: +5 -4 lines
Diff to previous 1.197.2.7 (colored) to branchpoint 1.197 (colored)

sync with head.

Revision 1.215.2.4 / (download) - annotate - [select for diffs], Sun Feb 3 19:08:41 2008 UTC (16 months, 4 weeks ago) by riz
Branch: netbsd-4
CVS Tags: wrstuden-fixsa-newbase, wrstuden-fixsa-base
Changes since 1.215.2.3: +5 -4 lines
Diff to previous 1.215.2.3 (colored) to branchpoint 1.215 (colored) next main 1.216 (colored)

Pull up following revision(s) (requested by gson in ticket #1054):
	sys/dev/audio.c: revision 1.233
Don't enter an infinite loop in audio_read() when the sc->sc_rustream
buffer is full.  Fixes kern/34659.

Revision 1.227.2.3 / (download) - annotate - [select for diffs], Wed Jan 23 19:27:32 2008 UTC (17 months, 1 week ago) by bouyer
Branch: bouyer-xeni386
Changes since 1.227.2.2: +3 -2 lines
Diff to previous 1.227.2.2 (colored) next main 1.228 (colored)

Sync with HEAD.

Revision 1.233 / (download) - annotate - [select for diffs], Wed Jan 23 14:14:55 2008 UTC (17 months, 1 week ago) by gson
Branch: MAIN
CVS Tags: bouyer-xeni386-nbase
Changes since 1.232: +5 -4 lines
Diff to previous 1.232 (colored)

Don't enter an infinite loop in audio_read() when the sc->sc_rustream
buffer is full.  Fixes kern/34659.

Revision 1.197.2.7 / (download) - annotate - [select for diffs], Mon Jan 21 09:42:22 2008 UTC (17 months, 1 week ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.6: +281 -37 lines
Diff to previous 1.197.2.6 (colored) to branchpoint 1.197 (colored)

sync with head

Revision 1.223.2.2 / (download) - annotate - [select for diffs], Wed Jan 9 01:52:09 2008 UTC (17 months, 3 weeks ago) by matt
Branch: matt-armv6
Changes since 1.223.2.1: +292 -46 lines
Diff to previous 1.223.2.1 (colored) to branchpoint 1.223 (colored)

sync with HEAD

Revision 1.227.2.2 / (download) - annotate - [select for diffs], Wed Jan 2 21:53:44 2008 UTC (18 months ago) by bouyer
Branch: bouyer-xeni386
CVS Tags: bouyer-xeni386-merge1
Changes since 1.227.2.1: +3 -1 lines
Diff to previous 1.227.2.1 (colored)

Sync with HEAD

Revision 1.224.4.2 / (download) - annotate - [select for diffs], Thu Dec 27 00:44:44 2007 UTC (18 months, 1 week ago) by mjf
Branch: mjf-devfs
Changes since 1.224.4.1: +281 -37 lines
Diff to previous 1.224.4.1 (colored) to branchpoint 1.224 (colored)

Sync with HEAD.

Revision 1.225.2.2 / (download) - annotate - [select for diffs], Wed Dec 26 21:39:19 2007 UTC (18 months, 1 week ago) by ad
Branch: vmlocking2
Changes since 1.225.2.1: +281 -37 lines
Diff to previous 1.225.2.1 (colored) to branchpoint 1.225 (colored) next main 1.226 (colored)

Sync with head.

Revision 1.232 / (download) - annotate - [select for diffs], Sun Dec 23 19:14:03 2007 UTC (18 months, 1 week ago) by jmcneill
Branch: MAIN
CVS Tags: vmlocking2-base3, matt-armv6-base, bouyer-xeni386-base
Changes since 1.231: +4 -2 lines
Diff to previous 1.231 (colored)

Deregister activity handler on detach.

Revision 1.231 / (download) - annotate - [select for diffs], Sat Dec 22 18:34:56 2007 UTC (18 months, 1 week ago) by christos
Branch: MAIN
Changes since 1.230: +3 -3 lines
Diff to previous 1.230 (colored)

Use M_NOWAIT in audio_stream_ctor; it can be called from a softintr context
through pmf_resume.

Revision 1.227.2.1 / (download) - annotate - [select for diffs], Thu Dec 13 21:55:19 2007 UTC (18 months, 2 weeks ago) by bouyer
Branch: bouyer-xeni386
Changes since 1.227: +18 -10 lines
Diff to previous 1.227 (colored)

Sync with HEAD

Revision 1.230 / (download) - annotate - [select for diffs], Thu Dec 13 14:40:36 2007 UTC (18 months, 3 weeks ago) by joerg
Branch: MAIN
Changes since 1.229: +11 -10 lines
Diff to previous 1.229 (colored)

Don't count poll(2) and select(2) as device activity. Don't activate the
device on write(2) if it is suspended and was not idle.

Revision 1.229 / (download) - annotate - [select for diffs], Thu Dec 13 14:02:53 2007 UTC (18 months, 3 weeks ago) by jmcneill
Branch: MAIN
Changes since 1.228: +8 -2 lines
Diff to previous 1.228 (colored)

When resuming the audio device, call audiosetinfo with the last known good
parameters. Fixes an issue with suspending the audio device while playback
is paused.

Revision 1.226.2.1 / (download) - annotate - [select for diffs], Tue Dec 11 15:22:25 2007 UTC (18 months, 3 weeks ago) by yamt
Branch: yamt-kmem
Changes since 1.226: +271 -36 lines
Diff to previous 1.226 (colored) next main 1.227 (colored)

sync with head.

Revision 1.228 / (download) - annotate - [select for diffs], Tue Dec 11 00:08:14 2007 UTC (18 months, 3 weeks ago) by martin
Branch: MAIN
CVS Tags: yamt-kmem-base3, yamt-kmem-base2, cube-autoconf-base, cube-autoconf
Changes since 1.227: +3 -2 lines
Diff to previous 1.227 (colored)

When collecting mixer values while suspending, initialize the number
of channels from the mixer device info. Fixes PR kern/37512.
OK: jmcneill

Revision 1.227 / (download) - annotate - [select for diffs], Sun Dec 9 20:27:51 2007 UTC (18 months, 3 weeks ago) by jmcneill
Branch: MAIN
Branch point for: bouyer-xeni386
Changes since 1.226: +270 -36 lines
Diff to previous 1.226 (colored)

Merge jmcneill-pm branch.

Revision 1.222.6.12 / (download) - annotate - [select for diffs], Sun Dec 9 19:37:39 2007 UTC (18 months, 3 weeks ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.222.6.11: +3 -3 lines
Diff to previous 1.222.6.11 (colored) to branchpoint 1.222 (colored) next main 1.223 (colored)

Sync with HEAD.

Revision 1.224.4.1 / (download) - annotate - [select for diffs], Sat Dec 8 18:19:16 2007 UTC (18 months, 3 weeks ago) by mjf
Branch: mjf-devfs
Changes since 1.224: +13 -11 lines
Diff to previous 1.224 (colored)

Sync with HEAD.

Revision 1.225.2.1 / (download) - annotate - [select for diffs], Sat Dec 8 17:57:14 2007 UTC (18 months, 3 weeks ago) by ad
Branch: vmlocking2
Changes since 1.225: +3 -3 lines
Diff to previous 1.225 (colored)

Sync with head.

Revision 1.222.6.11 / (download) - annotate - [select for diffs], Sat Dec 8 16:21:01 2007 UTC (18 months, 3 weeks ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.222.6.10: +16 -16 lines
Diff to previous 1.222.6.10 (colored) to branchpoint 1.222 (colored)

Rename pnp(9) -> pmf(9), as requested by many.

Revision 1.197.2.6 / (download) - annotate - [select for diffs], Fri Dec 7 17:29:14 2007 UTC (18 months, 3 weeks ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.5: +13 -11 lines
Diff to previous 1.197.2.5 (colored) to branchpoint 1.197 (colored)

sync with head

Revision 1.222.6.10 / (download) - annotate - [select for diffs], Thu Dec 6 14:20:47 2007 UTC (18 months, 4 weeks ago) by joerg
Branch: jmcneill-pm
Changes since 1.222.6.9: +18 -2 lines
Diff to previous 1.222.6.9 (colored) to branchpoint 1.222 (colored)

Readd lost splaudio around suspend/resume/volume management.

Revision 1.226 / (download) - annotate - [select for diffs], Wed Dec 5 17:19:47 2007 UTC (18 months, 4 weeks ago) by pooka
Branch: MAIN
CVS Tags: yamt-kmem-base, vmlocking2-base2, reinoud-bufcleanup-nbase, reinoud-bufcleanup-base, jmcneill-pm-base
Branch point for: yamt-kmem
Changes since 1.225: +3 -3 lines
Diff to previous 1.225 (colored)

Do not "return 1" from kqfilter for errors.  That value is passed
directly to the userland caller and results in a mysterious EPERM.
Instead, return EINVAL or something else sensible depending on the
case.

Revision 1.222.6.9 / (download) - annotate - [select for diffs], Sat Dec 1 05:13:25 2007 UTC (19 months ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.222.6.8: +12 -10 lines
Diff to previous 1.222.6.8 (colored) to branchpoint 1.222 (colored)

Sync with HEAD.

Revision 1.225 / (download) - annotate - [select for diffs], Sat Dec 1 05:11:08 2007 UTC (19 months ago) by jmcneill
Branch: MAIN
CVS Tags: vmlocking2-base1, vmlocking-nbase
Branch point for: vmlocking2
Changes since 1.224: +12 -10 lines
Diff to previous 1.224 (colored)

aprintify

Revision 1.223.2.1 / (download) - annotate - [select for diffs], Tue Nov 6 23:25:25 2007 UTC (19 months, 3 weeks ago) by matt
Branch: matt-armv6
CVS Tags: matt-armv6-prevmlocking
Changes since 1.223: +10 -9 lines
Diff to previous 1.223 (colored)

sync with HEAD

Revision 1.222.6.8 / (download) - annotate - [select for diffs], Tue Nov 6 14:27:11 2007 UTC (19 months, 3 weeks ago) by joerg
Branch: jmcneill-pm
Changes since 1.222.6.7: +151 -101 lines
Diff to previous 1.222.6.7 (colored) to branchpoint 1.222 (colored)

Refactor PNP API:
- Make suspend/resume directly a device functionality. It consists of
  three layers (class logic, device logic, bus logic), all of them being
  optional. This replaces D0/D3 transitions.
- device_is_active returns true if the device was not disabled and was
  not suspended (even partially), device_is_enabled returns true if the
  device was enabled.
- Change pnp_global_transition into pnp_system_suspend and
  pnp_system_resume. Before running any suspend/resume handlers, check
  that all currently attached devices support power management and bail
  out otherwise. The latter is not done for the shutdown/panic case.
- Make the former bus-specific generic network handlers a class handler.
- Make PNP message like volume up/down/toogle PNP events. Each device
  can register what events they are interested in and whether the handler
  should be global or not.
- Introduce device_active API for devices to mark themselve in use from
  either the system or the device. Use this to implement the idle handling
  for audio and input devices. This is intended to replace most ad-hoc
  watchdogs as well.
- Fix somes situations in which audio resume would lose mixer settings.
- Make USB host controllers better deal with suspend in the light of
  shared interrupts.
- Flush filesystem cache on suspend.
- Flush disk caches on suspend. Put ATA disks into standby on suspend as
  well.
- Adopt drivers to use the new PNP API.
- Fix a critical bug in the generic cardbus layer that made D0->D3
  break.
- Fix ral(4) to set if_stop.
- Convert cbb(4) to the new PNP API.
- Apply the PCI Express SCI fix on resume again.

Revision 1.197.2.5 / (download) - annotate - [select for diffs], Sat Oct 27 11:29:56 2007 UTC (20 months, 1 week ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.4: +10 -9 lines
Diff to previous 1.197.2.4 (colored) to branchpoint 1.197 (colored)

sync with head.

Revision 1.222.6.7 / (download) - annotate - [select for diffs], Fri Oct 26 15:44:08 2007 UTC (20 months, 1 week ago) by joerg
Branch: jmcneill-pm
Changes since 1.222.6.6: +10 -9 lines
Diff to previous 1.222.6.6 (colored) to branchpoint 1.222 (colored)

Sync with HEAD.

Follow the merge of pmap.c on i386 and amd64 and move
pmap_init_tmp_pgtbl into arch/x86/x86/pmap.c. Modify the ACPI wakeup
code to restore CR4 before jumping back into kernel space as the large
page option might cover that.

Revision 1.222.6.6 / (download) - annotate - [select for diffs], Sun Oct 21 19:10:28 2007 UTC (20 months, 1 week ago) by joerg
Branch: jmcneill-pm
Changes since 1.222.6.5: +3 -3 lines
Diff to previous 1.222.6.5 (colored) to branchpoint 1.222 (colored)

Fix compilation with DIAGNOSTIC.

Revision 1.222.6.5 / (download) - annotate - [select for diffs], Thu Oct 18 02:07:20 2007 UTC (20 months, 2 weeks ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.222.6.4: +110 -7 lines
Diff to previous 1.222.6.4 (colored) to branchpoint 1.222 (colored)

Improve PNP audio power management. Instead of starting an idle timer
to power down the audio device on last close, allow the pm policy to
power down the device while it's still open.

Since X mixers typically poll /dev/mixer with AUDIO_GET_INFO ioctls, we need
to avoid resetting the idle timer when these applications are running. As a
result, introduce audio_mixer_{capture,restore} in MI audio and use them in
its power handler. When an audio device is asleep, we simply return cached
values on AUDIO_GET_INFO ioctls. A nice side effect is that MI audio now
properly captures and restores mixer values across hw device suspend/resume.

XXX: I've added locking in pnp_power(), but I'm using mutex_owned() in
a way that mutex(9) claims I shouldn't be doing. Needs to be revisited.

Revision 1.223.4.1 / (download) - annotate - [select for diffs], Sun Oct 14 11:47:58 2007 UTC (20 months, 2 weeks ago) by yamt
Branch: yamt-x86pmap
Changes since 1.223: +10 -9 lines
Diff to previous 1.223 (colored) next main 1.224 (colored)

sync with head.

Revision 1.224 / (download) - annotate - [select for diffs], Mon Oct 8 16:18:02 2007 UTC (20 months, 3 weeks ago) by ad
Branch: MAIN
CVS Tags: yamt-x86pmap-base4, yamt-x86pmap-base3, vmlocking-base, jmcneill-base, bouyer-xenamd64-base2, bouyer-xenamd64-base, bouyer-xenamd64
Branch point for: mjf-devfs
Changes since 1.223: +10 -9 lines
Diff to previous 1.223 (colored)

Use the softint API.

Revision 1.222.6.4 / (download) - annotate - [select for diffs], Thu Sep 13 04:45:12 2007 UTC (21 months, 3 weeks ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.222.6.3: +5 -2 lines
Diff to previous 1.222.6.3 (colored) to branchpoint 1.222 (colored)

If outputs.master doesn't exist, fallback to inputs.dac as the next best
possible candidate.

Revision 1.222.6.3 / (download) - annotate - [select for diffs], Fri Sep 7 23:55:29 2007 UTC (21 months, 3 weeks ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.222.6.2: +2 -7 lines
Diff to previous 1.222.6.2 (colored) to branchpoint 1.222 (colored)

Remove azalia mixer hack that should never have been commited in the first
place.

Revision 1.197.2.4 / (download) - annotate - [select for diffs], Mon Sep 3 14:33:08 2007 UTC (22 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.3: +93 -72 lines
Diff to previous 1.197.2.3 (colored) to branchpoint 1.197 (colored)

sync with head.

Revision 1.215.2.1.2.1 / (download) - annotate - [select for diffs], Mon Sep 3 07:04:17 2007 UTC (22 months ago) by wrstuden
Branch: wrstuden-fixsa
Changes since 1.215.2.1: +35 -14 lines
Diff to previous 1.215.2.1 (colored)

Sync w/ NetBSD-4-RC_1

Revision 1.192.4.7 / (download) - annotate - [select for diffs], Sun Aug 26 19:08:02 2007 UTC (22 months, 1 week ago) by bouyer
Branch: netbsd-3
Changes since 1.192.4.6: +6 -4 lines
Diff to previous 1.192.4.6 (colored) to branchpoint 1.192 (colored) next main 1.193 (colored)

Pull up following revision(s) (requested by uwe in ticket #1831):
	sys/dev/audio.c: revision 1.223
au_setup_ports - don't hide ports->nports++ inside another expression,
especially if that other expression is the right hand side operand of
&& which is short-circuiting.  The effect was that audiorecord(1)
would always fail trying to set recording port with AUDIO_SETINFO.
Tested on wss@pnpbios.  It looks like this problem has been reported
as PR/35239, filed against port-hp700.

Revision 1.215.2.3 / (download) - annotate - [select for diffs], Fri Aug 24 20:23:09 2007 UTC (22 months, 1 week ago) by liamjfoy
Branch: netbsd-4
CVS Tags: wrstuden-fixsa-base-1, netbsd-4-0-RELEASE, netbsd-4-0-RC5, netbsd-4-0-RC4, netbsd-4-0-RC3, netbsd-4-0-RC2, netbsd-4-0-RC1, netbsd-4-0-1-RELEASE, netbsd-4-0, matt-nb4-arm-base, matt-nb4-arm
Changes since 1.215.2.2: +6 -4 lines
Diff to previous 1.215.2.2 (colored) to branchpoint 1.215 (colored)

Pull up following revision(s) (requested by uwe in ticket #835):
	sys/dev/audio.c: revision 1.223
au_setup_ports - don't hide ports->nports++ inside another expression,
especially if that other expression is the right hand side operand of
&& which is short-circuiting.  The effect was that audiorecord(1)
would always fail trying to set recording port with AUDIO_SETINFO.
Tested on wss@pnpbios.  It looks like this problem has been reported
as PR/35239, filed against port-hp700.

Revision 1.221.2.3 / (download) - annotate - [select for diffs], Mon Aug 20 18:36:36 2007 UTC (22 months, 2 weeks ago) by ad
Branch: vmlocking
Changes since 1.221.2.2: +6 -4 lines
Diff to previous 1.221.2.2 (colored) to branchpoint 1.221 (colored) next main 1.222 (colored)

Sync with HEAD.

Revision 1.222.6.2 / (download) - annotate - [select for diffs], Thu Aug 16 11:03:02 2007 UTC (22 months, 2 weeks ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.222.6.1: +6 -4 lines
Diff to previous 1.222.6.1 (colored) to branchpoint 1.222 (colored)

Sync with HEAD.

Revision 1.222.2.1 / (download) - annotate - [select for diffs], Wed Aug 15 13:48:11 2007 UTC (22 months, 2 weeks ago) by skrll
Branch: nick-csl-alignment
Changes since 1.222: +6 -4 lines
Diff to previous 1.222 (colored) next main 1.223 (colored)

Sync with HEAD.

Revision 1.223 / (download) - annotate - [select for diffs], Tue Aug 14 21:34:03 2007 UTC (22 months, 2 weeks ago) by uwe
Branch: MAIN
CVS Tags: yamt-x86pmap-base2, yamt-x86pmap-base, nick-csl-alignment-base5
Branch point for: yamt-x86pmap, matt-armv6
Changes since 1.222: +6 -4 lines
Diff to previous 1.222 (colored)

au_setup_ports - don't hide ports->nports++ inside another expression,
especially if that other expression is the right hand side operand of
&& which is short-circuiting.  The effect was that audiorecord(1)
would always fail trying to set recording port with AUDIO_SETINFO.

Tested on wss@pnpbios.  It looks like this problem has been reported
as PR/35239, filed against port-hp700.

Revision 1.222.6.1 / (download) - annotate - [select for diffs], Fri Aug 3 22:17:12 2007 UTC (23 months ago) by jmcneill
Branch: jmcneill-pm
Changes since 1.222: +99 -32 lines
Diff to previous 1.222 (colored)

Pull in power management changes from private branch.

Revision 1.221.2.2 / (download) - annotate - [select for diffs], Sun Jul 15 13:21:05 2007 UTC (23 months, 2 weeks ago) by ad
Branch: vmlocking
Changes since 1.221.2.1: +31 -12 lines
Diff to previous 1.221.2.1 (colored) to branchpoint 1.221 (colored)

Sync with head.

Revision 1.221.4.1 / (download) - annotate - [select for diffs], Wed Jul 11 20:04:56 2007 UTC (23 months, 3 weeks ago) by mjf
Branch: mjf-ufs-trans
Changes since 1.221: +31 -12 lines
Diff to previous 1.221 (colored) next main 1.222 (colored)

Sync with head.

Revision 1.221.2.1 / (download) - annotate - [select for diffs], Sun Jun 17 21:30:48 2007 UTC (2 years ago) by ad
Branch: vmlocking
Changes since 1.221: +10 -9 lines
Diff to previous 1.221 (colored)

- Increase the number of thread priorities from 128 to 256. How the space
  is set up is to be revisited.
- Implement soft interrupts as kernel threads. A generic implementation
  is provided, with hooks for fast-path MD code that can run the interrupt
  threads over the top of other threads executing in the kernel.
- Split vnode::v_flag into three fields, depending on how the flag is
  locked (by the interlock, by the vnode lock, by the file system).
- Miscellaneous locking fixes and improvements.

Revision 1.215.2.2 / (download) - annotate - [select for diffs], Tue Jun 12 10:11:08 2007 UTC (2 years ago) by liamjfoy
Branch: netbsd-4
Changes since 1.215.2.1: +31 -12 lines
Diff to previous 1.215.2.1 (colored) to branchpoint 1.215 (colored)

Pull up following revision(s) (requested by jmcneill in ticket #716):
	share/man/man4/audio.4: revision 1.66
	sys/compat/ossaudio/ossaudio.c: revision 1.56
	sys/sys/audioio.h: revision 1.32
	lib/libossaudio/ossaudio.c: revision 1.21
	sys/dev/audio.c: revision 1.222
Add a new ioctl AUDIO_GETBUFINFO. It works like AUDIO_GETINFO, but
doesn't obtain the ports, gain and balance related parameters.
Those generally require reading from the hardware and therefore are
much
more expensive to obtain. Modify OSS emulation to use the new ioctl
where possible.
This reduces CPU usage of mplayer during mp3 playback with my Thinkpad
from 20% to < 1% and from 50% to 20% during Xvid playback.
Review and comments from jmcneill@

Revision 1.222 / (download) - annotate - [select for diffs], Mon Jun 11 13:05:46 2007 UTC (2 years ago) by joerg
Branch: MAIN
CVS Tags: nick-csl-alignment-base, mjf-ufs-trans-base, matt-mips64-base, matt-mips64, hpcarm-cleanup
Branch point for: nick-csl-alignment, jmcneill-pm
Changes since 1.221: +31 -12 lines
Diff to previous 1.221 (colored)

Add a new ioctl AUDIO_GETBUFINFO. It works like AUDIO_GETINFO, but
doesn't obtain the ports, gain and balance related parameters.
Those generally require reading from the hardware and therefore are much
more expensive to obtain. Modify OSS emulation to use the new ioctl
where possible.

This reduces CPU usage of mplayer during mp3 playback with my Thinkpad
from 20% to < 1% and from 50% to 20% during Xvid playback.

Review and comments from jmcneill@

Revision 1.217.2.2 / (download) - annotate - [select for diffs], Mon Mar 12 05:53:02 2007 UTC (2 years, 3 months ago) by rmind
Branch: yamt-idlelwp
Changes since 1.217.2.1: +60 -60 lines
Diff to previous 1.217.2.1 (colored) next main 1.218 (colored)

Sync with HEAD.

Revision 1.215.2.1 / (download) - annotate - [select for diffs], Sat Mar 10 12:06:05 2007 UTC (2 years, 3 months ago) by bouyer
Branch: netbsd-4
Branch point for: wrstuden-fixsa
Changes since 1.215: +3 -3 lines
Diff to previous 1.215 (colored)

Pull up following revision(s) (requested by kent in ticket #499):
	sys/dev/audio.c: revision 1.221
return information about playing buffer, not recording bufer,
for AUDIO_WSEEK.
PR#35171

Revision 1.192.4.5.2.1 / (download) - annotate - [select for diffs], Sat Mar 10 11:50:54 2007 UTC (2 years, 3 months ago) by bouyer
Branch: netbsd-3-1
CVS Tags: netbsd-3-1-1-RELEASE
Changes since 1.192.4.5: +1 -1 lines
Diff to previous 1.192.4.5 (colored) next main 1.192.4.6 (colored)

Pull up following revision(s) (requested by kent in ticket #1678):
	sys/dev/audio.c: revision 1.221
return information about playing buffer, not recording bufer,
for AUDIO_WSEEK.
PR#35171

Revision 1.192.4.2.2.3 / (download) - annotate - [select for diffs], Sat Mar 10 11:50:05 2007 UTC (2 years, 3 months ago) by bouyer
Branch: netbsd-3-0
CVS Tags: netbsd-3-0-3-RELEASE
Changes since 1.192.4.2.2.2: +3 -3 lines
Diff to previous 1.192.4.2.2.2 (colored) to branchpoint 1.192.4.2 (colored) next main 1.192.4.3 (colored)

Pull up following revision(s) (requested by kent in ticket #1678):
	sys/dev/audio.c: revision 1.221
return information about playing buffer, not recording bufer,
for AUDIO_WSEEK.
PR#35171

Revision 1.192.4.6 / (download) - annotate - [select for diffs], Sat Mar 10 11:46:52 2007 UTC (2 years, 3 months ago) by bouyer
Branch: netbsd-3
Changes since 1.192.4.5: +1 -1 lines
Diff to previous 1.192.4.5 (colored) to branchpoint 1.192 (colored)

Pull up following revision(s) (requested by kent in ticket #1678):
	sys/dev/audio.c: revision 1.221
return information about playing buffer, not recording bufer,
for AUDIO_WSEEK.
PR#35171

Revision 1.221 / (download) - annotate - [select for diffs], Fri Mar 9 13:20:12 2007 UTC (2 years, 3 months ago) by kent
Branch: MAIN
CVS Tags: yamt-idlelwp-base8, thorpej-atomic-base, thorpej-atomic, reinoud-bufcleanup
Branch point for: vmlocking, mjf-ufs-trans
Changes since 1.220: +3 -3 lines
Diff to previous 1.220 (colored)

return information about playing buffer, not recording bufer,
for AUDIO_WSEEK.

PR#35171

Revision 1.220 / (download) - annotate - [select for diffs], Sun Mar 4 06:01:40 2007 UTC (2 years, 4 months ago) by christos
Branch: MAIN
Changes since 1.219: +7 -7 lines
Diff to previous 1.219 (colored)

Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.

Revision 1.219 / (download) - annotate - [select for diffs], Thu Mar 1 17:31:35 2007 UTC (2 years, 4 months ago) by thorpej
Branch: MAIN
Changes since 1.218: +54 -54 lines
Diff to previous 1.218 (colored)

TRUE -> true, FALSE -> false

Revision 1.217.2.1 / (download) - annotate - [select for diffs], Tue Feb 27 16:53:46 2007 UTC (2 years, 4 months ago) by yamt
Branch: yamt-idlelwp
Changes since 1.217: +5 -5 lines
Diff to previous 1.217 (colored)

- sync with head.
- move sched_changepri back to kern_synch.c as it doesn't know PPQ anymore.

Revision 1.218.2.1 / (download) - annotate - [select for diffs], Tue Feb 27 14:15:55 2007 UTC (2 years, 4 months ago) by ad
Branch: ad-audiomp
Changes since 1.218: +338 -148 lines
Diff to previous 1.218 (colored) next main 1.219 (colored)

Add MP locking for audio drivers.

Revision 1.197.2.3 / (download) - annotate - [select for diffs], Mon Feb 26 09:09:50 2007 UTC (2 years, 4 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.2: +66 -25 lines
Diff to previous 1.197.2.2 (colored) to branchpoint 1.197 (colored)

sync with head.

Revision 1.218 / (download) - annotate - [select for diffs], Wed Feb 21 22:59:58 2007 UTC (2 years, 4 months ago) by thorpej
Branch: MAIN
CVS Tags: ad-audiomp-base
Branch point for: ad-audiomp
Changes since 1.217: +5 -5 lines
Diff to previous 1.217 (colored)

Replace the Mach-derived boolean_t type with the C99 bool type.  A
future commit will replace use of TRUE and FALSE with true and false.

Revision 1.217 / (download) - annotate - [select for diffs], Thu Feb 15 18:12:05 2007 UTC (2 years, 4 months ago) by ad
Branch: MAIN
Branch point for: yamt-idlelwp
Changes since 1.216: +6 -9 lines
Diff to previous 1.216 (colored)

Defer wakeup() to the soft interrupt also.

Revision 1.216 / (download) - annotate - [select for diffs], Fri Feb 9 21:55:26 2007 UTC (2 years, 4 months ago) by ad
Branch: MAIN
CVS Tags: post-newlock2-merge
Changes since 1.215: +59 -15 lines
Diff to previous 1.215 (colored)

Merge newlock2 to head.

Revision 1.209.2.3 / (download) - annotate - [select for diffs], Sat Jan 27 00:24:52 2007 UTC (2 years, 5 months ago) by ad
Branch: newlock2
Changes since 1.209.2.2: +55 -22 lines
Diff to previous 1.209.2.2 (colored) to branchpoint 1.209 (colored) next main 1.210 (colored)

Don't call selnotify() or psignal() while above IPL_VM: defer them to a
soft interrupt.

Revision 1.209.2.2 / (download) - annotate - [select for diffs], Fri Jan 19 09:39:57 2007 UTC (2 years, 5 months ago) by ad
Branch: newlock2
Changes since 1.209.2.1: +16 -5 lines
Diff to previous 1.209.2.1 (colored) to branchpoint 1.209 (colored)

Acquire proclist_mutex before sending signals.

Revision 1.197.2.2 / (download) - annotate - [select for diffs], Sat Dec 30 20:47:49 2006 UTC (2 years, 6 months ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197.2.1: +49 -37 lines
Diff to previous 1.197.2.1 (colored) to branchpoint 1.197 (colored)

sync with head.

Revision 1.209.4.2 / (download) - annotate - [select for diffs], Sun Dec 10 07:16:52 2006 UTC (2 years, 6 months ago) by yamt
Branch: yamt-splraiseipl
Changes since 1.209.4.1: +44 -38 lines
Diff to previous 1.209.4.1 (colored) to branchpoint 1.209 (colored) next main 1.210 (colored)

sync with head.

Revision 1.209.2.1 / (download) - annotate - [select for diffs], Sat Nov 18 21:34:03 2006 UTC (2 years, 7 months ago) by ad
Branch: newlock2
Changes since 1.209: +44 -34 lines
Diff to previous 1.209 (colored)

Sync with head.

Revision 1.215 / (download) - annotate - [select for diffs], Thu Nov 16 01:32:44 2006 UTC (2 years, 7 months ago) by christos
Branch: MAIN
CVS Tags: yamt-splraiseipl-base5, yamt-splraiseipl-base4, yamt-splraiseipl-base3, newlock2-nbase, newlock2-base, netbsd-4-base
Branch point for: netbsd-4
Changes since 1.214: +16 -16 lines
Diff to previous 1.214 (colored)

__unused removal on arguments; approved by core.

Revision 1.214 / (download) - annotate - [select for diffs], Wed Nov 1 10:13:37 2006 UTC (2 years, 8 months ago) by cbiere
Branch: MAIN
Changes since 1.213: +6 -6 lines
Diff to previous 1.213 (colored)

Set oldpblksize and oldrblksize early enough so that zero-initialisation
isn't necessary. The GCC warning was not a false-positive, AFAICS.

Revision 1.213 / (download) - annotate - [select for diffs], Wed Nov 1 09:36:52 2006 UTC (2 years, 8 months ago) by xtraeme
Branch: MAIN
Changes since 1.212: +4 -2 lines
Diff to previous 1.212 (colored)

Initialize old[pr]blksize to 0 to avoid gcc warnings.

Revision 1.212 / (download) - annotate - [select for diffs], Wed Nov 1 06:39:19 2006 UTC (2 years, 8 months ago) by cbiere
Branch: MAIN
Changes since 1.211: +26 -22 lines
Diff to previous 1.211 (colored)

Fix for kern/17446. Restore the audio settings if an error occured.

Revision 1.209.4.1 / (download) - annotate - [select for diffs], Sun Oct 22 06:05:28 2006 UTC (2 years, 8 months ago) by yamt
Branch: yamt-splraiseipl
Changes since 1.209: +20 -16 lines
Diff to previous 1.209 (colored)

sync with head

Revision 1.211 / (download) - annotate - [select for diffs], Thu Oct 12 01:30:50 2006 UTC (2 years, 8 months ago) by christos
Branch: MAIN
CVS Tags: yamt-splraiseipl-base2
Changes since 1.210: +18 -15 lines
Diff to previous 1.210 (colored)

- sprinkle __unused on function decls.
- fix a couple of unused bugs
- no more -Wno-unused for i386

Revision 1.210 / (download) - annotate - [select for diffs], Sun Sep 24 03:53:08 2006 UTC (2 years, 9 months ago) by jmcneill
Branch: MAIN
Changes since 1.209: +4 -3 lines
Diff to previous 1.209 (colored)

Add "name" parameter to powerhook_establish, to aid debugging. No objections
on tech-kern@

Revision 1.199.4.1 / (download) - annotate - [select for diffs], Sat Sep 9 02:49:09 2006 UTC (2 years, 9 months ago) by rpaulo
Branch: rpaulo-netinet-merge-pcb
Changes since 1.199: +109 -18 lines
Diff to previous 1.199 (colored) next main 1.200 (colored)

sync with head

Revision 1.200.2.6 / (download) - annotate - [select for diffs], Sun Sep 3 15:23:55 2006 UTC (2 years, 10 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.200.2.5: +5 -5 lines
Diff to previous 1.200.2.5 (colored) to branchpoint 1.200 (colored) next main 1.201 (colored)

sync with head.

Revision 1.209 / (download) - annotate - [select for diffs], Sun Aug 27 23:54:50 2006 UTC (2 years, 10 months ago) by christos
Branch: MAIN
CVS Tags: yamt-splraiseipl-base, yamt-pdpolicy-base9, yamt-pdpolicy-base8, rpaulo-netinet-merge-pcb-base
Branch point for: yamt-splraiseipl, newlock2
Changes since 1.208: +5 -5 lines
Diff to previous 1.208 (colored)

add missing initializers.

Revision 1.200.2.5 / (download) - annotate - [select for diffs], Fri Aug 11 15:43:52 2006 UTC (2 years, 10 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.200.2.4: +4 -2 lines
Diff to previous 1.200.2.4 (colored) to branchpoint 1.200 (colored)

sync with head

Revision 1.206.4.1 / (download) - annotate - [select for diffs], Thu Jul 13 17:49:16 2006 UTC (2 years, 11 months ago) by gdamore
Branch: gdamore-uart
Changes since 1.206: +43 -2 lines
Diff to previous 1.206 (colored) next main 1.207 (colored)

Merge from HEAD.

Revision 1.208 / (download) - annotate - [select for diffs], Tue Jun 27 02:07:08 2006 UTC (3 years ago) by jmcneill
Branch: MAIN
CVS Tags: yamt-pdpolicy-base7, abandoned-netbsd-4-base, abandoned-netbsd-4
Changes since 1.207: +4 -2 lines
Diff to previous 1.207 (colored)

Protect audio_powerhook with '#if NAUDIO > 0'. PR kern/33832.

Revision 1.200.2.4 / (download) - annotate - [select for diffs], Mon Jun 26 12:50:37 2006 UTC (3 years ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.200.2.3: +41 -2 lines
Diff to previous 1.200.2.3 (colored) to branchpoint 1.200 (colored)

sync with head.

Revision 1.206.2.1 / (download) - annotate - [select for diffs], Thu Jun 22 03:39:48 2006 UTC (3 years ago) by chap
Branch: chap-midi
Changes since 1.206: +41 -2 lines
Diff to previous 1.206 (colored) next main 1.207 (colored)

Complete a sync sys/ with head.

Revision 1.197.2.1 / (download) - annotate - [select for diffs], Wed Jun 21 15:02:11 2006 UTC (3 years ago) by yamt
Branch: yamt-lazymbuf
Changes since 1.197: +148 -58 lines
Diff to previous 1.197 (colored)

sync with head.

Revision 1.207 / (download) - annotate - [select for diffs], Mon Jun 19 10:19:08 2006 UTC (3 years ago) by jmcneill
Branch: MAIN
CVS Tags: yamt-pdpolicy-base6, chap-midi-nbase, chap-midi-base
Changes since 1.206: +41 -2 lines
Diff to previous 1.206 (colored)

Halt input/output on soft suspend if currently running, and restore them
on soft resume.

Revision 1.199.6.2 / (download) - annotate - [select for diffs], Thu Jun 1 22:36:02 2006 UTC (3 years, 1 month ago) by kardel
Branch: simonb-timecounters
CVS Tags: simonb-timcounters-final
Changes since 1.199.6.1: +21 -13 lines
Diff to previous 1.199.6.1 (colored) next main 1.200 (colored)

Sync with head.

Revision 1.201.4.2 / (download) - annotate - [select for diffs], Wed May 24 15:50:07 2006 UTC (3 years, 1 month ago) by tron
Branch: peter-altq
Changes since 1.201.4.1: +46 -11 lines
Diff to previous 1.201.4.1 (colored) to branchpoint 1.201 (colored) next main 1.202 (colored)

Merge 2006-05-24 NetBSD-current into the "peter-altq" branch.

Revision 1.200.2.3 / (download) - annotate - [select for diffs], Wed May 24 10:57:36 2006 UTC (3 years, 1 month ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.200.2.2: +48 -13 lines
Diff to previous 1.200.2.2 (colored) to branchpoint 1.200 (colored)

sync with head.

Revision 1.206 / (download) - annotate - [select for diffs], Tue May 16 13:46:19 2006 UTC (3 years, 1 month ago) by kent
Branch: MAIN
CVS Tags: yamt-pdpolicy-base5, simonb-timecounters-base, gdamore-uart-base
Branch point for: gdamore-uart, chap-midi
Changes since 1.205: +15 -9 lines
Diff to previous 1.205 (colored)

If one or more playback filters are applied, minimize loading
size of the hardware buffer to improve accuracy of AUDIO_GETIOFFS.

Revision 1.192.4.5 / (download) - annotate - [select for diffs], Sat May 13 16:44:41 2006 UTC (3 years, 1 month ago) by tron
Branch: netbsd-3
CVS Tags: netbsd-3-1-RELEASE, netbsd-3-1-RC4, netbsd-3-1-RC3, netbsd-3-1-RC2, netbsd-3-1-RC1
Branch point for: netbsd-3-1
Changes since 1.192.4.4: +8 -6 lines
Diff to previous 1.192.4.4 (colored) to branchpoint 1.192 (colored)

Pull up following revision(s) (requested by kent in ticket #1317):
	sys/dev/audio.c: revision 1.205
Fixes a bug that audio_offset_t::samples for AUDIO_GETxOFFS has
incorrect value.  It also affects SNDCTL_DSP_GETOPTR of
ossaudio.
PR: kern/32405 by Stephane Witzman

Revision 1.201.2.2 / (download) - annotate - [select for diffs], Thu May 11 23:28:04 2006 UTC (3 years, 1 month ago) by elad
Branch: elad-kernelauth
Changes since 1.201.2.1: +37 -8 lines
Diff to previous 1.201.2.1 (colored) to branchpoint 1.201 (colored) next main 1.202 (colored)

sync with head

Revision 1.205 / (download) - annotate - [select for diffs], Wed May 10 01:56:21 2006 UTC (3 years, 1 month ago) by kent
Branch: MAIN
CVS Tags: elad-kernelauth-base
Changes since 1.204: +8 -6 lines
Diff to previous 1.204 (colored)

Fixes a bug that audio_offset_t::samples for AUDIO_GETxOFFS has
incorrect value.  It also affects SNDCTL_DSP_GETOPTR of
ossaudio.

PR: kern/32405 by Stephane Witzman

Revision 1.199.6.1 / (download) - annotate - [select for diffs], Sat Apr 22 11:38:45 2006 UTC (3 years, 2 months ago) by simonb
Branch: simonb-timecounters
Changes since 1.199: +48 -6 lines
Diff to previous 1.199 (colored)

Sync with head.

Revision 1.192.4.2.2.2 / (download) - annotate - [select for diffs], Wed Apr 19 21:01:00 2006 UTC (3 years, 2 months ago) by tron
Branch: netbsd-3-0
CVS Tags: netbsd-3-0-2-RELEASE, netbsd-3-0-1-RELEASE
Changes since 1.192.4.2.2.1: +15 -13 lines
Diff to previous 1.192.4.2.2.1 (colored) to branchpoint 1.192.4.2 (colored)

Pull up following revision(s) (requested by jmcneill in ticket #1281):
	sys/dev/audio_if.h: revision 1.61
	sys/dev/audiovar.h: revision 1.36
	sys/dev/audio.c: revision 1.204 via patch
Don't use simple_locks; we can't hold them while calling malloc and
friends.

Revision 1.192.4.4 / (download) - annotate - [select for diffs], Wed Apr 19 20:59:13 2006 UTC (3 years, 2 months ago) by tron
Branch: netbsd-3
Changes since 1.192.4.3: +15 -13 lines
Diff to previous 1.192.4.3 (colored) to branchpoint 1.192 (colored)

Pull up following revision(s) (requested by jmcneill in ticket #1281):
	sys/dev/audio_if.h: revision 1.61
	sys/dev/audiovar.h: revision 1.36
	sys/dev/audio.c: revision 1.204 via patch
Don't use simple_locks; we can't hold them while calling malloc and
friends.

Revision 1.204 / (download) - annotate - [select for diffs], Wed Apr 19 14:10:58 2006 UTC (3 years, 2 months ago) by jmcneill
Branch: MAIN
Changes since 1.203: +15 -13 lines
Diff to previous 1.203 (colored)

Don't use simple_locks; we can't hold them while calling malloc and
friends.

Revision 1.201.2.1 / (download) - annotate - [select for diffs], Wed Apr 19 03:24:23 2006 UTC (3 years, 2 months ago) by elad
Branch: elad-kernelauth
Changes since 1.201: +3 -3 lines
Diff to previous 1.201 (colored)

sync with head.

Revision 1.192.4.2.2.1 / (download) - annotate - [select for diffs], Tue Apr 18 21:15:07 2006 UTC (3 years, 2 months ago) by tron
Branch: netbsd-3-0
Changes since 1.192.4.2: +29 -4 lines
Diff to previous 1.192.4.2 (colored)

Pull up following revision(s) (requested by jmcneill in ticket #1277):
	sys/dev/audio_if.h: revision 1.60 via patch
	sys/dev/audiovar.h: revision 1.35 via patch
	sys/dev/audio.c: revision 1.203 via patch
Protect audio_write's filter graph from being modified in the
middle of a
write. Fixes the 'audioctl of death' problem (PR#32563).

Revision 1.192.4.3 / (download) - annotate - [select for diffs], Tue Apr 18 21:12:46 2006 UTC (3 years, 2 months ago) by tron
Branch: netbsd-3
Changes since 1.192.4.2: +29 -4 lines
Diff to previous 1.192.4.2 (colored) to branchpoint 1.192 (colored)

Pull up following revision(s) (requested by jmcneill in ticket #1277):
	sys/dev/audio_if.h: revision 1.60 via patch
	sys/dev/audiovar.h: revision 1.35 via patch
	sys/dev/audio.c: revision 1.203 via patch
Protect audio_write's filter graph from being modified in the
middle of a
write. Fixes the 'audioctl of death' problem (PR#32563).

Revision 1.203 / (download) - annotate - [select for diffs], Tue Apr 18 19:15:27 2006 UTC (3 years, 2 months ago) by jmcneill
Branch: MAIN
Changes since 1.202: +29 -4 lines
Diff to previous 1.202 (colored)

Protect audio_write's filter graph from being modified in the middle of a
write. Fixes the 'audioctl of death' problem (PR#32563).

Revision 1.200.2.2 / (download) - annotate - [select for diffs], Sat Apr 1 12:06:43 2006 UTC (3 years, 3 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.200.2.1: +3 -3 lines
Diff to previous 1.200.2.1 (colored) to branchpoint 1.200 (colored)

sync with head.

Revision 1.201.4.1 / (download) - annotate - [select for diffs], Fri Mar 31 09:45:17 2006 UTC (3 years, 3 months ago) by tron
Branch: peter-altq
Changes since 1.201: +3 -3 lines
Diff to previous 1.201 (colored)

Merge 2006-03-31 NetBSD-current into the "peter-altq" branch.

Revision 1.202 / (download) - annotate - [select for diffs], Tue Mar 28 17:38:29 2006 UTC (3 years, 3 months ago) by thorpej
Branch: MAIN
CVS Tags: yamt-pdpolicy-base4, yamt-pdpolicy-base3
Changes since 1.201: +3 -3 lines
Diff to previous 1.201 (colored)

Use device_unit().

Revision 1.200.2.1 / (download) - annotate - [select for diffs], Mon Mar 13 09:07:08 2006 UTC (3 years, 3 months ago) by yamt
Branch: yamt-pdpolicy
Changes since 1.200: +12 -2 lines
Diff to previous 1.200 (colored)

sync with head.

Revision 1.201 / (download) - annotate - [select for diffs], Tue Mar 7 15:17:47 2006 UTC (3 years, 3 months ago) by jmcneill
Branch: MAIN
CVS Tags: yamt-pdpolicy-base2, peter-altq-base
Branch point for: peter-altq, elad-kernelauth
Changes since 1.200: +12 -2 lines
Diff to previous 1.200 (colored)

Add a 'powerstate' callback to audio_hw_if, to allow hw drivers to power
themselves down when not in use.

Revision 1.199.2.1 / (download) - annotate - [select for diffs], Wed Mar 1 09:28:11 2006 UTC (3 years, 4 months ago) by yamt
Branch: yamt-uio_vmspace
Changes since 1.199: +8 -3 lines
Diff to previous 1.199 (colored) next main 1.200 (colored)

sync with head.

Revision 1.200 / (download) - annotate - [select for diffs], Sat Feb 25 11:32:51 2006 UTC (3 years, 4 months ago) by rpaulo
Branch: MAIN
CVS Tags: yamt-uio_vmspace-base5, yamt-pdpolicy-base
Branch point for: yamt-pdpolicy
Changes since 1.199: +8 -3 lines
Diff to previous 1.199 (colored)

In mixer_remove() it's better to check if lwp is not NULL before trying
to access a children node of it.

Fixes PR 32823, by Yours Truly. I guess I should read the code before
sending a PR.

Revision 1.199 / (download) - annotate - [select for diffs], Sat Dec 24 20:27:29 2005 UTC (3 years, 6 months ago) by perry
Branch: MAIN
Branch point for: yamt-uio_vmspace, simonb-timecounters, rpaulo-netinet-merge-pcb
Changes since 1.198: +10 -10 lines
Diff to previous 1.198 (colored)

Remove leading __ from __(const|inline|signed|volatile) -- it is obsolete.

Revision 1.198 / (download) - annotate - [select for diffs], Sun Dec 11 12:20:53 2005 UTC (3 years, 6 months ago) by christos
Branch: MAIN
Changes since 1.197: +39 -38 lines
Diff to previous 1.197 (colored)

merge ktrace-lwp.

Revision 1.180.2.10 / (download) - annotate - [select for diffs], Thu Nov 10 14:03:00 2005 UTC (3 years, 7 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.9: +21 -39 lines
Diff to previous 1.180.2.9 (colored) next main 1.181 (colored)

Sync with HEAD. Here we go again...

Revision 1.197 / (download) - annotate - [select for diffs], Tue Jun 21 14:01:11 2005 UTC (4 years ago) by ws
Branch: MAIN
CVS Tags: yamt-vop-base3, yamt-vop-base2, yamt-vop-base, yamt-vop, yamt-readahead-pervnode, yamt-readahead-perfile, yamt-readahead-base3, yamt-readahead-base2, yamt-readahead-base, yamt-readahead, thorpej-vnode-attr-base, thorpej-vnode-attr, ktrace-lwp-base
Branch point for: yamt-lazymbuf
Changes since 1.196: +8 -8 lines
Diff to previous 1.196 (colored)

PR-30566: Poll must not return <sys/errno.h> values.
Start with those places I can easily test.

Revision 1.155.4.7 / (download) - annotate - [select for diffs], Fri Jun 17 12:46:35 2005 UTC (4 years ago) by tron
Branch: netbsd-1-6
Changes since 1.155.4.6: +9 -19 lines
Diff to previous 1.155.4.6 (colored) to branchpoint 1.155 (colored) next main 1.156 (colored)

Pull up revision 1.196 via patch (requested by is in ticket #5793):
Make sure buffer sizes are initialized correctly even when the pause state
is explicitly set.
Without this, the machine would crash for some audio hardware that needs
to divide by the block size (e.g., cs4281.c/cs4280.c).

Revision 1.182.2.2 / (download) - annotate - [select for diffs], Sun Jun 12 21:28:27 2005 UTC (4 years ago) by tron
Branch: netbsd-2-0
CVS Tags: netbsd-2-0-3-RELEASE
Changes since 1.182.2.1: +9 -19 lines
Diff to previous 1.182.2.1 (colored) to branchpoint 1.182 (colored) next main 1.183 (colored)

Pull up revision 1.196 via patch (requested by is in ticket #1990):
Make sure buffer sizes are initialized correctly even when the pause state
is explicitly set.
Without this, the machine would crash for some audio hardware that needs
to divide by the block size (e.g., cs4281.c/cs4280.c).

Revision 1.182.2.1.2.2 / (download) - annotate - [select for diffs], Sun Jun 12 21:28:22 2005 UTC (4 years ago) by tron
Branch: netbsd-2
CVS Tags: netbsd-2-1-RELEASE, netbsd-2-1-RC6, netbsd-2-1-RC5, netbsd-2-1-RC4, netbsd-2-1-RC3, netbsd-2-1-RC2, netbsd-2-1-RC1, netbsd-2-1
Changes since 1.182.2.1.2.1: +9 -19 lines
Diff to previous 1.182.2.1.2.1 (colored) to branchpoint 1.182.2.1 (colored) next main 1.182.2.2 (colored)

Pull up revision 1.196 via patch (requested by is in ticket #1990):
Make sure buffer sizes are initialized correctly even when the pause state
is explicitly set.
Without this, the machine would crash for some audio hardware that needs
to divide by the block size (e.g., cs4281.c/cs4280.c).

Revision 1.192.4.2 / (download) - annotate - [select for diffs], Sat Jun 11 11:18:32 2005 UTC (4 years ago) by tron
Branch: netbsd-3
CVS Tags: netbsd-3-0-RELEASE, netbsd-3-0-RC6, netbsd-3-0-RC5, netbsd-3-0-RC4, netbsd-3-0-RC3, netbsd-3-0-RC2, netbsd-3-0-RC1
Branch point for: netbsd-3-0
Changes since 1.192.4.1: +7 -17 lines
Diff to previous 1.192.4.1 (colored) to branchpoint 1.192 (colored)

Pull up revision 1.196 (requested by is in ticket #445):
Make sure buffer sizes are initialized correctly even when the pause state
is explicitly set.
Without this, the machine would crash for some audio hardware that needs
to divide by the block size (e.g., cs4281.c/cs4280.c).

Revision 1.196 / (download) - annotate - [select for diffs], Sat Jun 11 08:14:19 2005 UTC (4 years ago) by is
Branch: MAIN
Changes since 1.195: +9 -19 lines
Diff to previous 1.195 (colored)

Make sure buffer sizes are initialized correctly even when the pause state
is explicitly set. Without this, the machine would crash in the audio interupt when the driver
needs to divide by the block size (e.g., cs4281.c/cs4280.c).
Idea for the fix by yamt.

Revision 1.195 / (download) - annotate - [select for diffs], Wed May 18 20:10:25 2005 UTC (4 years, 1 month ago) by augustss
Branch: MAIN
Changes since 1.194: +5 -4 lines
Diff to previous 1.194 (colored)

Allow the audio device to be opened for read resp. write by separate calls
to open().  Previously only one call to open() was allowed.
This change should allow some Linux derived programs to work unaltered.

XXX This isn't really possible to implement correctly in a simple way.
So this implementation is incorrect: It is not until device has been closed
by both the reader and writer that it is possible to open it at all again.

Revision 1.182.2.1.2.1 / (download) - annotate - [select for diffs], Wed May 11 21:21:36 2005 UTC (4 years, 1 month ago) by riz
Branch: netbsd-2
Changes since 1.182.2.1: +3 -3 lines
Diff to previous 1.182.2.1 (colored)

Apply a patch to fix audio recording buffer handling to fix PR#26706
by Chapman Flack.  (requested by kent in ticket #1414)

Revision 1.194 / (download) - annotate - [select for diffs], Wed May 4 01:57:23 2005 UTC (4 years, 2 months ago) by augustss
Branch: MAIN
Changes since 1.193: +4 -11 lines
Diff to previous 1.193 (colored)

When audioclose is called it's the last close of the device, so there
is no need to fiddle with resetting individual bits.  Just clear them.

Revision 1.187.2.4 / (download) - annotate - [select for diffs], Fri Apr 29 11:28:44 2005 UTC (4 years, 2 months ago) by kent
Branch: kent-audio2
Changes since 1.187.2.3: +137 -24 lines
Diff to previous 1.187.2.3 (colored) next main 1.188 (colored)

sync with -current

Revision 1.192.4.1 / (download) - annotate - [select for diffs], Mon Apr 25 14:49:46 2005 UTC (4 years, 2 months ago) by tron
Branch: netbsd-3
Changes since 1.192: +3 -5 lines
Diff to previous 1.192 (colored)

Pull up revision 1.193 (requested by jmcneill in ticket #200):
Enable full-duplex mode by default on drivers that support it if the
underlying audio device was opened read/write. This is consistent with
Linux OSS behaviour and fixes a bug with certain applications (including
Skype) that assume this behaviour.
Fixes PR# 30044.

Revision 1.193 / (download) - annotate - [select for diffs], Mon Apr 25 13:19:46 2005 UTC (4 years, 2 months ago) by jmcneill
Branch: MAIN
CVS Tags: kent-audio2-base
Changes since 1.192: +3 -5 lines
Diff to previous 1.192 (colored)

Enable full-duplex mode by default on drivers that support it if the
underlying audio device was opened read/write. This is consistent with
Linux OSS behaviour and fixes a bug with certain applications (including
Skype) that assume this behaviour.

Fixes PR# 30044.

Revision 1.155.4.6 / (download) - annotate - [select for diffs], Thu Apr 14 22:09:16 2005 UTC (4 years, 2 months ago) by tron
Branch: netbsd-1-6
Changes since 1.155.4.5: +3 -3 lines
Diff to previous 1.155.4.5 (colored) to branchpoint 1.155 (colored)

Apply patch (requested by kent in ticket #5744):
Correct audio recording buffer handling. Fixes PR kern/26706.

Revision 1.188.2.2 / (download) - annotate - [select for diffs], Sat Mar 19 08:33:53 2005 UTC (4 years, 3 months ago) by yamt
Branch: yamt-km
Changes since 1.188.2.1: +66 -14 lines
Diff to previous 1.188.2.1 (colored) to branchpoint 1.188 (colored) next main 1.189 (colored)

sync with head.  xen and whitespace.  xen part is not finished.

Revision 1.180.2.9 / (download) - annotate - [select for diffs], Tue Feb 15 21:33:12 2005 UTC (4 years, 4 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.8: +66 -14 lines
Diff to previous 1.180.2.8 (colored)

Sync with HEAD.

Revision 1.192 / (download) - annotate - [select for diffs], Sun Feb 13 23:53:20 2005 UTC (4 years, 4 months ago) by fredb
Branch: MAIN
CVS Tags: yamt-km-base4, yamt-km-base3, netbsd-3-base, matt-timespec
Branch point for: netbsd-3
Changes since 1.191: +53 -11 lines
Diff to previous 1.191 (colored)

For the "record.port", choose "record.source" over "inputs.source" if the
former exists.  Partial fix for PR kern/29178.

Revision 1.191 / (download) - annotate - [select for diffs], Sun Feb 13 23:50:22 2005 UTC (4 years, 4 months ago) by fredb
Branch: MAIN
Changes since 1.190: +12 -2 lines
Diff to previous 1.190 (colored)

Comment as to why we run through the devinfo list twice, in audioattach().

Revision 1.190 / (download) - annotate - [select for diffs], Sun Feb 13 17:05:15 2005 UTC (4 years, 4 months ago) by kent
Branch: MAIN
Changes since 1.189: +3 -3 lines
Diff to previous 1.189 (colored)

fix a typo in audiogetinfo().
No behaviour changes though the code was wrong.

Revision 1.187.2.3 / (download) - annotate - [select for diffs], Sun Feb 13 04:36:15 2005 UTC (4 years, 4 months ago) by kent
Branch: kent-audio2
Changes since 1.187.2.2: +36 -24 lines
Diff to previous 1.187.2.2 (colored)

* add AUDIO_PROP_PLAY and AUDIO_PROP_RECORD for internal use
  XXX: need to modify all of audio HW drivers.

* At the first open(), open the HW as play and record mode even if the open
flags contains either FREAD or FWRITE.

* remove AUMODE_READ and AUMODE_WRITE, and use FREAD and FWRITE instead.

Revision 1.188.2.1 / (download) - annotate - [select for diffs], Sat Feb 12 18:17:42 2005 UTC (4 years, 4 months ago) by yamt
Branch: yamt-km
Changes since 1.188: +39 -11 lines
Diff to previous 1.188 (colored)

sync with head.

Revision 1.187.2.2 / (download) - annotate - [select for diffs], Fri Feb 4 15:01:48 2005 UTC (4 years, 4 months ago) by kent
Branch: kent-audio2
Changes since 1.187.2.1: +40 -12 lines
Diff to previous 1.187.2.1 (colored)

sync with -current

Revision 1.187.2.1 / (download) - annotate - [select for diffs], Fri Feb 4 14:53:53 2005 UTC (4 years, 4 months ago) by kent
Branch: kent-audio2
Changes since 1.187: +131 -21 lines
Diff to previous 1.187 (colored)

add entiries for cloned fd

Revision 1.180.2.8 / (download) - annotate - [select for diffs], Fri Feb 4 11:45:09 2005 UTC (4 years, 4 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.7: +39 -11 lines
Diff to previous 1.180.2.7 (colored)

Sync with HEAD.

Revision 1.189 / (download) - annotate - [select for diffs], Sat Jan 29 18:16:49 2005 UTC (4 years, 5 months ago) by kent
Branch: MAIN
CVS Tags: yamt-km-base2
Changes since 1.188: +39 -11 lines
Diff to previous 1.188 (colored)

* audiosetinfo()
  call audio_clear() only when blocksizes are actually changed.
  This fixes a problem on some audio devices and applications which
use ossaudio and call SNDCTL_DSP_GETOSPACE repeatedly while playing.

* audiostartp()
  add some debug prints.

Revision 1.180.2.7 / (download) - annotate - [select for diffs], Mon Jan 24 08:35:18 2005 UTC (4 years, 5 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.6: +3 -3 lines
Diff to previous 1.180.2.6 (colored)

Sync with HEAD.

Revision 1.180.2.6 / (download) - annotate - [select for diffs], Mon Jan 17 19:30:38 2005 UTC (4 years, 5 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.5: +988 -796 lines
Diff to previous 1.180.2.5 (colored)

Sync with HEAD.

Revision 1.188 / (download) - annotate - [select for diffs], Mon Jan 17 14:13:19 2005 UTC (4 years, 5 months ago) by minoura
Branch: MAIN
CVS Tags: yamt-km-base
Branch point for: yamt-km
Changes since 1.187: +3 -3 lines
Diff to previous 1.187 (colored)

Fix panic when precision < 8.
From kent@.

Revision 1.187 / (download) - annotate - [select for diffs], Sat Jan 15 16:23:03 2005 UTC (4 years, 5 months ago) by kent
Branch: MAIN
Branch point for: kent-audio2
Changes since 1.186: +150 -105 lines
Diff to previous 1.186 (colored)

minor KNF

Revision 1.186 / (download) - annotate - [select for diffs], Sat Jan 15 04:57:18 2005 UTC (4 years, 5 months ago) by kent
Branch: MAIN
Changes since 1.185: +3 -3 lines
Diff to previous 1.185 (colored)

fix a typo in audiostartp().  This change fixes a problem introduced by
kent-audio1 merger with some audio hardware such as emuxki.

Revision 1.185 / (download) - annotate - [select for diffs], Mon Jan 10 22:01:37 2005 UTC (4 years, 5 months ago) by kent
Branch: MAIN
Changes since 1.184: +855 -708 lines
Diff to previous 1.184 (colored)

merge kent-audio1 branch, which introduces audio filter pipeline to the MI
audio framework


Summary of changes:

* struct audio_params
  - remove sw_code, factor, factor_denom, hw_sample_rate,
hw_encoding ,hw_precision, and hw_channels.  Conversion information
is conveyed by stream_filter_list_t.
  - change the type of sample_rate: u_long -> u_int
  - add `validbits,' which represents the valid data size in
precision bits.  It is required in order to distinguish 24/32bit
from 24/24bit or 32/32bit.

* audio_hw_if
 - add two parameters to set_params()
	stream_filter_list_t *pfil, stream_filter_list *rfil
   A HW driver should set filter recipes for requested formats
 - constify audio_params parameters of trigger_output() and
trigger_input().  They represent audio formats for the hardware.
 - make open() and close() optional
 - add int (AUMODE_PLAY or AUMODE_RECORD) and audio_params_t parameters
 to round_blocksize()

* sw_code is replaced with stream_filter_t.
  stream_filer_t converts audio data in an input buffer and writes
into another output buffer unlike sw_code, which converts data in
single buffer.
  converters in dev/auconv.c, dev/mulaw.c, dev/aurateconv.c,
dev/tc/bba.c, dev/ic/msm6258.c, and arch/arm/iomd/vidcaudio.c are
reimplemented as stream_filter_t

* MI audio
 - audiosetinfo() builds filter pipelines from stream_filter_list_t
filled by audio_hw_if::set_params()
 - audiosetinfo() returns with EINVAL if mmapped and set_params()
requests filters
 - audio_write(), audio_pint(), and audio_rint() invoke a filter
pipeline.
 - ioctl() for FIONREAD, AUDIO_WSEEK, AUDIO_GETIOFFS,
AUDIO_GETOOFFS, and audio_prinfo::{seek,samples} for
AUDIO_GETINFO handle values for a buffer nearest to userland.

* add `struct device *' parameter to ac97_attach()

* all of audio HW drivers follow audio_hw_if and ac97 changes

Revision 1.184.2.29 / (download) - annotate - [select for diffs], Sun Jan 9 09:23:21 2005 UTC (4 years, 5 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.28: +8 -8 lines
Diff to previous 1.184.2.28 (colored) to branchpoint 1.184 (colored) next main 1.185 (colored)

pass HW encoding to round_blocksize()

Revision 1.184.2.28 / (download) - annotate - [select for diffs], Sun Jan 9 08:42:45 2005 UTC (4 years, 5 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.27: +19 -14 lines
Diff to previous 1.184.2.27 (colored) to branchpoint 1.184 (colored)

audio_hw_if change
 * make open() and close() optional
 * add int (AUMODE_PLAY or AUMODE_RECORD) and audio_params_t parameters
 to round_blocksize()

Revision 1.184.2.27 / (download) - annotate - [select for diffs], Sat Jan 8 18:34:09 2005 UTC (4 years, 5 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.26: +12 -4 lines
Diff to previous 1.184.2.26 (colored) to branchpoint 1.184 (colored)

fix cyclic noise with uaudio(4)

Revision 1.184.2.26 / (download) - annotate - [select for diffs], Wed Jan 5 12:49:44 2005 UTC (4 years, 5 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.25: +8 -7 lines
Diff to previous 1.184.2.25 (colored) to branchpoint 1.184 (colored)

don't fill silence if audio_stream_t::inp is wrapped.

Revision 1.184.2.25 / (download) - annotate - [select for diffs], Mon Jan 3 16:40:26 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.24: +62 -2 lines
Diff to previous 1.184.2.24 (colored) to branchpoint 1.184 (colored)

* remove stream_filter_list_append and stream_filter_list_prepend
* add stream_filter_list_t::{append(), prepend(), set()}

Revision 1.184.2.24 / (download) - annotate - [select for diffs], Sun Jan 2 15:54:44 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.23: +206 -146 lines
Diff to previous 1.184.2.23 (colored) to branchpoint 1.184 (colored)

* audiosetinfo()
  rebuild filter pipeline only when audio_parameters is changed.

* audio_write()
  set uio_fetcher before calling fetch_to() every time because
  audio_pint() sets null_fetcher.

* introduce audio_stream::used, audio_stream_add_inp(), and
  audio_stream_add_outp()

* aurateconv
  fix infinite loop for up-sampling

Revision 1.184.2.23 / (download) - annotate - [select for diffs], Sat Jan 1 19:51:33 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.22: +26 -12 lines
Diff to previous 1.184.2.22 (colored) to branchpoint 1.184 (colored)

* fix a playing filter setup bug
* make this comple with AUDIO_DEBUG
* add some debug printf

Revision 1.184.2.22 / (download) - annotate - [select for diffs], Sat Jan 1 17:35:27 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.21: +13 -11 lines
Diff to previous 1.184.2.21 (colored) to branchpoint 1.184 (colored)

* unconstfy some parameters of trigger_output() and start_output() because
  const pointers are harmful to unifying playing routine and recording
  routine in a hardware driver.

* strem_filter_list_t::filters[0] represents the most hardware-side filter
  even for playing filter pipeline to access hardware encoding by
  filters[0].param.

Revision 1.184.2.21 / (download) - annotate - [select for diffs], Sat Jan 1 16:18:26 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.20: +29 -10 lines
Diff to previous 1.184.2.20 (colored) to branchpoint 1.184 (colored)

keeping track of number of bytes of played or recorded data in the encoding
in which the kernel provides to userland.

Revision 1.184.2.20 / (download) - annotate - [select for diffs], Sat Jan 1 13:29:29 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.19: +12 -4 lines
Diff to previous 1.184.2.19 (colored) to branchpoint 1.184 (colored)

* re-correct filt_audioread()
* make sure filters are not available if mmapped

Revision 1.184.2.19 / (download) - annotate - [select for diffs], Sat Jan 1 12:46:00 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.18: +8 -7 lines
Diff to previous 1.184.2.18 (colored) to branchpoint 1.184 (colored)

audio_prinfo::buffer_size and audio_offset should be values for
the buffer near to userland.

Revision 1.184.2.18 / (download) - annotate - [select for diffs], Sat Jan 1 11:30:27 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.17: +4 -4 lines
Diff to previous 1.184.2.17 (colored) to branchpoint 1.184 (colored)

pass hardware audio encoding to trigger_input()/trigger_output()

Revision 1.184.2.17 / (download) - annotate - [select for diffs], Sat Jan 1 11:28:26 2005 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.16: +130 -97 lines
Diff to previous 1.184.2.16 (colored) to branchpoint 1.184 (colored)

* remove audio_ringbuffer::used.
* usedlow and usedhigh represent watermarks for the buffer near to userland.
* fix incorrect implementation for kqueue filters

Revision 1.184.2.16 / (download) - annotate - [select for diffs], Thu Dec 30 16:02:26 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.15: +14 -4 lines
Diff to previous 1.184.2.15 (colored) to branchpoint 1.184 (colored)

normalize encoding by audio_check_params()

Revision 1.184.2.15 / (download) - annotate - [select for diffs], Wed Dec 29 19:55:16 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.14: +4 -4 lines
Diff to previous 1.184.2.14 (colored) to branchpoint 1.184 (colored)

correct usage of stream_filter_t::filters[].param

Revision 1.184.2.14 / (download) - annotate - [select for diffs], Wed Dec 29 18:17:38 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.13: +6 -2 lines
Diff to previous 1.184.2.13 (colored) to branchpoint 1.184 (colored)

* audio_stream_ctor()
 stream->end - stream->start should be multiple of the frame size

Revision 1.184.2.13 / (download) - annotate - [select for diffs], Wed Dec 29 15:02:28 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.12: +5 -4 lines
Diff to previous 1.184.2.12 (colored) to branchpoint 1.184 (colored)

add audio_params::validbits to distinguish 24bit data in 24bit container,
24bit data in 32bit container, 32bit data in 32bit container.

There is no userland API to specify audio_params::validbits, and
audio_params::validbits is always the same value as audio_params::precision
at this moment.

Revision 1.184.2.12 / (download) - annotate - [select for diffs], Wed Dec 29 13:54:05 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.11: +23 -23 lines
Diff to previous 1.184.2.11 (colored) to branchpoint 1.184 (colored)

change types of the followings:
  au_mixer_ports::isenum: u_char -> boolean_t
  au_mixer_ports::isdual: u_char -> boolean_t
  audio_softc::sc_blkset: u_char -> boolean_t
  audio_softc::sc_sil_start: u_char* -> uint8_t*
  audio_softc::sc_rbus: u_char -> boolean_t
  audio_softc::sc_pbus: u_char -> boolean_t
  audio_softc::sc_dying: u_char -> boolean_t

Revision 1.184.2.11 / (download) - annotate - [select for diffs], Wed Dec 29 13:41:57 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.10: +2 -25 lines
Diff to previous 1.184.2.10 (colored) to branchpoint 1.184 (colored)

remove old aurateconv stuff

Revision 1.184.2.10 / (download) - annotate - [select for diffs], Tue Dec 28 14:54:19 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.9: +11 -15 lines
Diff to previous 1.184.2.9 (colored) to branchpoint 1.184 (colored)

* add audio_stream_add()
* remove 4th parameter of stream_fetcher::fetch_to()
* add must-have variables to stream_filter.

Revision 1.184.2.9 / (download) - annotate - [select for diffs], Sun Dec 26 17:38:25 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.8: +185 -47 lines
Diff to previous 1.184.2.8 (colored) to branchpoint 1.184 (colored)

* stream_filter_t
  remove get_input_size() and get_output_size() for simplicity.
The MI audio decides buffer sizes.

* audio_softc
  has audio_stram_t instances instead of audio_stream_t pointers

* audiosetinfo()
  setup filter chains, and add some helper functions
  The variables, cleard and modechange, are represented as boolean_t.

* audio_rint()
  set null_fetcher so that every filter has non-null previous fetcher.

Revision 1.184.2.8 / (download) - annotate - [select for diffs], Sat Dec 25 17:19:42 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.7: +7 -7 lines
Diff to previous 1.184.2.7 (colored) to branchpoint 1.184 (colored)

correct audio_params parameter of audio_fill_silence()

Revision 1.184.2.7 / (download) - annotate - [select for diffs], Sat Dec 25 13:25:16 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.6: +13 -29 lines
Diff to previous 1.184.2.6 (colored) to branchpoint 1.184 (colored)

remove audio_params::sw_code, factor, factor_denom,
hw_sample_rate, hw_encoding, hw_precision, hw_channels.

Revision 1.184.2.6 / (download) - annotate - [select for diffs], Sat Dec 25 12:32:22 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.5: +76 -76 lines
Diff to previous 1.184.2.5 (colored) to branchpoint 1.184 (colored)

remove needless parentheses for return

Revision 1.184.2.5 / (download) - annotate - [select for diffs], Sat Dec 25 12:24:38 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.4: +96 -187 lines
Diff to previous 1.184.2.4 (colored) to branchpoint 1.184 (colored)

* audio_read()
  remove aurateconv/sw_code related code.  It simply copies data
from the last audio_stream_t instance.

* audio_ioctl()
  FIONREAD/AUDIO_WSEEK: return the available data size of the
last audio_stream_t

* audio_rint()
  apply filters here so that FIONREAD and AUDIO_WSEEK can return
correct value.

* audio_softc
  remove sc_input_fragment_length, sc_input_fragment,
sc_pconvbuffer_size, sc_pconvbuffer, sc_pconv,
sc_rconvbuffer_size, sc_rconfbuffer_begin, sc_rconvbuffer_end,
sc_rconvbuffer, sc_rconv.

* audio_if.h
 add audio_stream_get_used().

Revision 1.184.2.4 / (download) - annotate - [select for diffs], Sun Dec 12 12:48:10 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.3: +72 -149 lines
Diff to previous 1.184.2.3 (colored) to branchpoint 1.184 (colored)

- add audio_stream_get_space()
- stream_fetcher::fetch_to() returns an errno and # of written bytes
- audio_write() uses stream_filter pipeline

Revision 1.184.2.3 / (download) - annotate - [select for diffs], Sat Dec 11 16:30:11 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.2: +6 -2 lines
Diff to previous 1.184.2.2 (colored) to branchpoint 1.184 (colored)

add audio_stream_t pointers and stream_filter_t instances to audio_softc.

Revision 1.184.2.2 / (download) - annotate - [select for diffs], Fri Dec 10 07:25:56 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184.2.1: +27 -26 lines
Diff to previous 1.184.2.1 (colored) to branchpoint 1.184 (colored)

introduce two macros: SPECIFIED(x) and SPECIFIED_CH(x)
for readability.

Revision 1.184.2.1 / (download) - annotate - [select for diffs], Fri Dec 10 00:30:55 2004 UTC (4 years, 6 months ago) by kent
Branch: kent-audio1
Changes since 1.184: +117 -128 lines
Diff to previous 1.184 (colored)

* introduce audio_stream_t, and make audio_ringbuffer a subclass of
  audio_stream_t
* introduce stream_fetcher_t, stream_filter_t, stream_filter_factory_t,
  and stream_filter_list_t.
* Empty stream_filter_list_t instances are passed to audio_hw_if::set_params()

Non-essential changes:
 * represent buffers as uint8_t* instead of u_char*
 * make outp const
 * make the second parameter of audio_hw_if::start_output() const
 * make the second parameter of audio_hw_if::trigger_output() const
 * change types of audio_ringbuffer::{pause,copying,needfill,mmapped}:
   char -> boolean_t
 * change the type of audio_params::sample_rate: u_long -> u_int
   The sample rate is exposed to userland as u_int.
 * typedef audio_params_t

Revision 1.180.2.5 / (download) - annotate - [select for diffs], Tue Nov 2 07:51:19 2004 UTC (4 years, 8 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.4: +15 -15 lines
Diff to previous 1.180.2.4 (colored)

Sync with HEAD.

Revision 1.184 / (download) - annotate - [select for diffs], Fri Oct 29 12:57:16 2004 UTC (4 years, 8 months ago) by yamt
Branch: MAIN
CVS Tags: kent-audio1-beforemerge, kent-audio1-base
Branch point for: kent-audio1
Changes since 1.183: +15 -15 lines
Diff to previous 1.183 (colored)

constify audio_hw_if, midi_hw_if, and radio_hw_if.

Revision 1.180.2.4 / (download) - annotate - [select for diffs], Tue Sep 21 13:26:24 2004 UTC (4 years, 9 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.3: +39 -38 lines
Diff to previous 1.180.2.3 (colored)

Fix the sync with head I botched.

Revision 1.180.2.3 / (download) - annotate - [select for diffs], Sat Sep 18 14:44:27 2004 UTC (4 years, 9 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.2: +38 -39 lines
Diff to previous 1.180.2.2 (colored)

Sync with HEAD.

Revision 1.180.2.2 / (download) - annotate - [select for diffs], Tue Aug 3 10:44:53 2004 UTC (4 years, 11 months ago) by skrll
Branch: ktrace-lwp
Changes since 1.180.2.1: +255 -184 lines
Diff to previous 1.180.2.1 (colored)

Sync with HEAD

Revision 1.182.2.1 / (download) - annotate - [select for diffs], Fri Jul 23 23:05:50 2004 UTC (4 years, 11 months ago) by he
Branch: netbsd-2-0
CVS Tags: netbsd-2-base, netbsd-2-0-RELEASE, netbsd-2-0-RC5, netbsd-2-0-RC4, netbsd-2-0-RC3, netbsd-2-0-RC2, netbsd-2-0-RC1, netbsd-2-0-2-RELEASE, netbsd-2-0-1-RELEASE
Branch point for: netbsd-2
Changes since 1.182: +5 -3 lines
Diff to previous 1.182 (colored)

Pull up revision 1.183 (requested by mycroft in ticket #699):
  If we are short-circuiting audiostartp() because there is
  not enough data present, do an extra wakeup() on the write
  channel.  This happens when we change parameters during
  playback, at which point we flush the buffer and would
  stall.

Revision 1.183 / (download) - annotate - [select for diffs], Wed Jul 7 22:30:22 2004 UTC (4 years, 11 months ago) by mycroft
Branch: MAIN
Changes since 1.182: +5 -3 lines
Diff to previous 1.182 (colored)

If we're short-circuiting audiostartp() because there isn't enough data
present, do an extra wakeup() on the write channel.  This happens when we
change parameters during playback, at which point we flush the buffer, and
would stall.

Revision 1.182 / (download) - annotate - [select for diffs], Sat Jan 31 00:07:56 2004 UTC (5 years, 5 months ago) by fredb
Branch: MAIN
CVS Tags: netbsd-2-0-base
Branch point for: netbsd-2-0
Changes since 1.181: +149 -88 lines
Diff to previous 1.181 (colored)

Fix a couple of long-standing bugs in the volume control(s) part of the
audio device interface:

1) When attempting to match the appropriate mixer control, we weren't
checking the class label, but only the second level label, so for
devices that had both an "inputs.cd" and a "record.cd", for example,
we could never do the right thing except by chance. For this reason,
evidently, all the record masters were labeled (by the underlying
drivers) either "record.record" or "record.volume", to distinguish
from "outputs.master". We'll now accept "record.master", and document
that as the the new preferred way.

2) More importantly, the model was deficient. Selecting a port on many
chips completely disables most of the level controls, which doesn't play
nice with other applications which are trying to use the interface. Now,
selecting a port simply sets which mixer input control shall be changed,
setting state in the audio layer. In other words, the "mixerout" port
is really selected all the time, enabling the final stage mixer, and
setting "gain" sets the level of the appropriate input. It should be
possible for separate applications to each control the mic, dac, and cd
inputs at the same time using this interface, simply by reiterating their
port selections with each change, but applications that don't bother to
do that aren't any worse off than they were before.

The user is expected to set the master output with another application,
dedicated to that task. Though it is now meaningful to select "no port"
with the audio device interface, to manipulate the master output, there's
no particular reason for an audio device consumer to do that. (I added
the capability in order to restore the initial state of the audio device,
for testing purposes. It might also be useful to users of broken binary-
only applications.)

Observe that the mixer device interface (and so, "mixerctl") still
retains all capabilities, including the ability to set the actual input
port on the chip, overriding the level controls. No change is being made
to the mixer device interface. The mixer device simply presents all the
controls on the chip, with no attempt at abstraction, so there are no
bugs there.

The upshot is, that applications that have been trying to use the audio
device interface to change the volume, such as mplayer, now "just work".

I've tested these changes extensively with "eso" and "eap" since first
proposing them on tech-kern last January, and somewhat with "esm" and a
few others. This closes both PR kern/10221, and PR kern/17159.

Revision 1.181 / (download) - annotate - [select for diffs], Thu Oct 2 07:15:20 2003 UTC (5 years, 9 months ago) by mycroft
Branch: MAIN
Changes since 1.180: +105 -97 lines
Diff to previous 1.180 (colored)

A bit of cleanup:
* Separate the code to set the default parameters into a new function,
  audio_set_defaults().  Make it use audiosetinfo(), which properly initializes
  the block size and whatnot.  Use this in both audioattach() and the
  /dev/audio case of audio_open().
* Do not force a reinitialization when /dev/sound is opened.
* Do all of the block size sanity checks in auto_init_ringbuffer(), not in
  both audio_calc_blksize() and audiosetinfo().
* Fix a bug in audiosetinfo() that caused the block size to not be recalculated
  immediately if we set it to 0.
* For AUDIO_GET[IO]OFFS, modify the deltablks calculation so that it gives us
  the number of block boundaries crossed.

Revision 1.180.2.1 / (download) - annotate - [select for diffs], Wed Jul 2 15:25:58 2003 UTC (6 years ago) by darrenr
Branch: ktrace-lwp
Changes since 1.180: +39 -38 lines
Diff to previous 1.180 (colored)

Apply the aborted ktrace-lwp changes to a specific branch.  This is just for
others to review, I'm concerned that patch fuziness may have resulted in some
errant code being generated but I'll look at that later by comparing the diff
from the base to the branch with the file I attempt to apply to it.  This will,
at the very least, put the changes in a better context for others to review
them and attempt to tinker with removing passing of 'struct lwp' through
the kernel.

Revision 1.180 / (download) - annotate - [select for diffs], Sun Jun 29 22:29:56 2003 UTC (6 years ago) by fvdl
Branch: MAIN
Branch point for: ktrace-lwp
Changes since 1.179: +36 -37 lines
Diff to previous 1.179 (colored)

Back out the lwp/ktrace changes. They contained a lot of colateral damage,
and need to be examined and discussed more.

Revision 1.179 / (download) - annotate - [select for diffs], Sat Jun 28 14:21:29 2003 UTC (6 years ago) by darrenr
Branch: MAIN
Changes since 1.178: +39 -38 lines
Diff to previous 1.178 (colored)

Pass lwp pointers throughtout the kernel, as required, so that the lwpid can
be inserted into ktrace records.  The general change has been to replace
"struct proc *" with "struct lwp *" in various function prototypes, pass
the lwp through and use l_proc to get the process pointer when needed.

Bump the kernel rev up to 1.6V

Revision 1.155.4.5 / (download) - annotate - [select for diffs], Tue Jun 24 09:42:04 2003 UTC (6 years ago) by grant
Branch: netbsd-1-6
CVS Tags: netbsd-1-6-PATCH002-RELEASE, netbsd-1-6-PATCH002-RC4, netbsd-1-6-PATCH002-RC3, netbsd-1-6-PATCH002-RC2, netbsd-1-6-PATCH002-RC1, netbsd-1-6-PATCH002
Changes since 1.155.4.4: +3 -3 lines
Diff to previous 1.155.4.4 (colored) to branchpoint 1.155 (colored)

Pull up revision 1.161 (requested by nakayama in ticket #1332):

fix unitialized variable. from simonb. OI

Revision 1.178 / (download) - annotate - [select for diffs], Mon May 26 12:43:35 2003 UTC (6 years, 1 month ago) by augustss
Branch: MAIN
Changes since 1.177: +6 -2 lines
Diff to previous 1.177 (colored)

Add FIONREAD ioctl().

Revision 1.177 / (download) - annotate - [select for diffs], Sat May 3 18:11:08 2003 UTC (6 years, 2 months ago) by wiz
Branch: MAIN
Changes since 1.176: +4 -4 lines
Diff to previous 1.176 (colored)

DMA, not dma nor Dma.

Revision 1.176 / (download) - annotate - [select for diffs], Fri Apr 25 03:02:11 2003 UTC (6 years, 2 months ago) by gmcgarry
Branch: MAIN
Changes since 1.175: +7 -22 lines
Diff to previous 1.175 (colored)

Fix full-duplex mode (again).

 Back-out revision 1.170 and and 1.166.  Revision 1.170 fixes some problems
introduced in revision 1.166.  It isn't clear what problem revision 1.166
was attempting to address.  It seems bogus anyway, since we later check
the modes in audio_check_params().

Revision 1.175 / (download) - annotate - [select for diffs], Sun Apr 6 18:20:11 2003 UTC (6 years, 2 months ago) by wiz
Branch: MAIN
Changes since 1.174: +3 -3 lines
Diff to previous 1.174 (colored)

Respect the law: Use A-law and mu-law as spellings as far as easily possible.
Inspired by Igor Sobrado in PR 19680.

Revision 1.174 / (download) - annotate - [select for diffs], Mon Mar 31 18:47:58 2003 UTC (6 years, 3 months ago) by jdolecek
Branch: MAIN
Changes since 1.173: +8 -8 lines
Diff to previous 1.173 (colored)

sprinkle const qualifiers to const stuff

Revision 1.173 / (download) - annotate - [select for diffs], Fri Jan 31 02:15:57 2003 UTC (6 years, 5 months ago) by thorpej
Branch: MAIN
Changes since 1.172: +3 -3 lines
Diff to previous 1.172 (colored)

Use aprint_*().

Revision 1.135.2.16 / (download) - annotate - [select for diffs], Fri Jan 3 17:07:30 2003 UTC (6 years, 6 months ago) by thorpej
Branch: nathanw_sa
CVS Tags: nathanw_sa_end
Changes since 1.135.2.15: +4 -4 lines
Diff to previous 1.135.2.15 (colored) to branchpoint 1.135 (colored) next main 1.136 (colored)

Sync with HEAD.

Revision 1.172 / (download) - annotate - [select for diffs], Wed Jan 1 00:10:15 2003 UTC (6 years, 6 months ago) by thorpej
Branch: MAIN
CVS Tags: nathanw_sa_before_merge, nathanw_sa_base, fvdl_fs64_base
Changes since 1.171: +3 -3 lines
Diff to previous 1.171 (colored)

Use aprint_normal() in cfprint routines.

Revision 1.171 / (download) - annotate - [select for diffs], Tue Dec 31 00:33:10 2002 UTC (6 years, 6 months ago) by augustss
Branch: MAIN
Changes since 1.170: +3 -3 lines
Diff to previous 1.170 (colored)

Use correct values to compute record high water mark.  From kern/19614 by
Ron Roskens.

Revision 1.135.2.15 / (download) - annotate - [select for diffs], Sun Dec 29 20:49:14 2002 UTC (6 years, 6 months ago) by thorpej
Branch: nathanw_sa
Changes since 1.135.2.14: +10 -4 lines
Diff to previous 1.135.2.14 (colored) to branchpoint 1.135 (colored)

Sync with HEAD.

Revision 1.170 / (download) - annotate - [select for diffs], Fri Dec 20 18:30:01 2002 UTC (6 years, 6 months ago) by fredette
Branch: MAIN
Changes since 1.169: +10 -4 lines
Diff to previous 1.169 (colored)

If the user is providing a mode value in AUDIO_SETINFO, that value
cannot change the recording or playback mode of the device, it can
only change other mode-like values (like AUMODE_PLAY_ALL).  Be very
explicit about fixing up the user's mode value based on the mode of
the device.  Before, giving AUMODE_PLAY_ALL could cause AUMODE_PLAY
to become set on the device, and once AUMODE_PLAY_ALL was set it
was impossible to clear.

Revision 1.155.4.4 / (download) - annotate - [select for diffs], Wed Dec 11 18:12:03 2002 UTC (6 years, 6 months ago) by he
Branch: netbsd-1-6
CVS Tags: netbsd-1-6-PATCH001-RELEASE, netbsd-1-6-PATCH001-RC3, netbsd-1-6-PATCH001-RC2, netbsd-1-6-PATCH001-RC1, netbsd-1-6-PATCH001
Changes since 1.155.4.3: +11 -9 lines
Diff to previous 1.155.4.3 (colored) to branchpoint 1.155 (colored)

Pull up revision 1.168 (requested by kent in ticket #981):
  Fix LR reversal problem of play.balance vs. record.balance.
  Based on PR#18901.

Revision 1.135.2.14 / (download) - annotate - [select for diffs], Wed Dec 11 06:37:47 2002 UTC (6 years, 6 months ago) by thorpej
Branch: nathanw_sa
Changes since 1.135.2.13: +4 -4 lines
Diff to previous 1.135.2.13 (colored) to branchpoint 1.135 (colored)

Sync with HEAD.

Revision 1.169 / (download) - annotate - [select for diffs], Tue Nov 26 18:49:40 2002 UTC (6 years, 7 months ago) by christos
Branch: MAIN
CVS Tags: gmcgarry_ucred_base, gmcgarry_ucred, gmcgarry_ctxsw_base, gmcgarry_ctxsw
Changes since 1.168: +6 -6 lines
Diff to previous 1.168 (colored)

si_ -> sel_

Revision 1.135.2.13 / (download) - annotate - [select for diffs], Mon Nov 11 22:08:38 2002 UTC (6 years, 7 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.12: +146 -12 lines
Diff to previous 1.135.2.12 (colored) to branchpoint 1.135 (colored)

Catch up to -current

Revision 1.155.4.3 / (download) - annotate - [select for diffs], Sun Nov 10 07:42:08 2002 UTC (6 years, 7 months ago) by tron
Branch: netbsd-1-6
Changes since 1.155.4.2: +13 -2 lines
Diff to previous 1.155.4.2 (colored) to branchpoint 1.155 (colored)

Pull up revision 1.157 (requested by gson in ticket #972):
The logic in audio_poll() was incorrect in full duplex mode;
among other things, it behaved as if full-duplex audio devices
were always ready for writing.  Also commented the code in case.
This fixes PRs kern/11179 and kern/13829.

Revision 1.168 / (download) - annotate - [select for diffs], Fri Nov 8 05:02:07 2002 UTC (6 years, 7 months ago) by kent
Branch: MAIN
Changes since 1.167: +11 -9 lines
Diff to previous 1.167 (colored)

Fix LR contrary problem of play.balance and record.balance.  The
change is based on PR kern/18901 by SUNAKAWA Hirokatsu.

Revision 1.167 / (download) - annotate - [select for diffs], Wed Oct 23 09:12:58 2002 UTC (6 years, 8 months ago) by jdolecek
Branch: MAIN
CVS Tags: kqueue-aftermerge
Changes since 1.166: +127 -6 lines
Diff to previous 1.166 (colored)

merge kqueue branch into -current

kqueue provides a stateful and efficient event notification framework
currently supported events include socket, file, directory, fifo,
pipe, tty and device changes, and monitoring of processes and signals

kqueue is supported by all writable filesystems in NetBSD tree
(with exception of Coda) and all device drivers supporting poll(2)

based on work done by Jonathan Lemon for FreeBSD
initial NetBSD port done by Luke Mewburn and Jason Thorpe

Revision 1.135.2.12 / (download) - annotate - [select for diffs], Fri Oct 18 02:41:24 2002 UTC (6 years, 8 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.11: +3 -6 lines
Diff to previous 1.135.2.11 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.166 / (download) - annotate - [select for diffs], Wed Oct 16 21:07:08 2002 UTC (6 years, 8 months ago) by jdolecek
Branch: MAIN
CVS Tags: kqueue-beforemerge
Changes since 1.165: +14 -3 lines
Diff to previous 1.165 (colored)

for AUDIO_SETINFO, silently enforce same mode as the currently used one;
this value is supposed to be read-only for this ioctl

Revision 1.137.2.9 / (download) - annotate - [select for diffs], Thu Oct 10 18:38:17 2002 UTC (6 years, 8 months ago) by jdolecek
Branch: kqueue
Changes since 1.137.2.8: +19 -11 lines
Diff to previous 1.137.2.8 (colored) next main 1.138 (colored)

sync kqueue with -current; this includes merge of gehenna-devsw branch,
merge of i386 MP branch, and part of autoconf rototil work

Revision 1.137.2.8 / (download) - annotate - [select for diffs], Wed Oct 2 22:02:29 2002 UTC (6 years, 9 months ago) by jdolecek
Branch: kqueue
Changes since 1.137.2.7: +7 -7 lines
Diff to previous 1.137.2.7 (colored)

do not need the (void *) cast for kn_hook anymore

Revision 1.165 / (download) - annotate - [select for diffs], Wed Oct 2 16:33:28 2002 UTC (6 years, 9 months ago) by thorpej
Branch: MAIN
CVS Tags: kqueue-base
Changes since 1.164: +3 -3 lines
Diff to previous 1.164 (colored)

Add trailing ; to CFATTACH_DECL.

Revision 1.164 / (download) - annotate - [select for diffs], Mon Sep 30 21:19:38 2002 UTC (6 years, 9 months ago) by thorpej
Branch: MAIN
Changes since 1.163: +4 -6 lines
Diff to previous 1.163 (colored)

Use CFATTACH_DECL().

Revision 1.163 / (download) - annotate - [select for diffs], Fri Sep 27 20:37:28 2002 UTC (6 years, 9 months ago) by thorpej
Branch: MAIN
Changes since 1.162: +3 -3 lines
Diff to previous 1.162 (colored)

Declare all cfattach structures const.

Revision 1.162 / (download) - annotate - [select for diffs], Mon Sep 23 05:51:10 2002 UTC (6 years, 9 months ago) by simonb
Branch: MAIN
Changes since 1.161: +2 -3 lines
Diff to previous 1.161 (colored)

Remove breaks after returns, unreachable returns and returns after
returns(!).

Revision 1.161 / (download) - annotate - [select for diffs], Mon Sep 23 03:44:56 2002 UTC (6 years, 9 months ago) by christos
Branch: MAIN
Changes since 1.160: +3 -3 lines
Diff to previous 1.160 (colored)

fix unitialized variable. from simonb. OI

Revision 1.135.2.11 / (download) - annotate - [select for diffs], Tue Sep 17 21:19:15 2002 UTC (6 years, 9 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.10: +13 -3 lines
Diff to previous 1.135.2.10 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.160 / (download) - annotate - [select for diffs], Fri Sep 6 13:22:57 2002 UTC (6 years, 9 months ago) by gehenna
Branch: MAIN
Changes since 1.159: +15 -5 lines
Diff to previous 1.159 (colored)

Merge the gehenna-devsw branch into the trunk.

This merge changes the device switch tables from static array to
dynamically generated by config(8).

- All device switches is defined as a constant structure in device drivers.

- The new grammer ``device-major'' is introduced to ``files''.

	device-major <prefix> char <num> [block <num>] [<rules>]

- All device major numbers must be listed up in port dependent majors.<arch>
  by using this grammer.

- Added the new naming convention.
  The name of the device switch must be <prefix>_[bc]devsw for auto-generation
  of device switch tables.

- The backward compatibility of loading block/character device
  switch by LKM framework is broken. This is necessary to convert
  from block/character device major to device name in runtime and vice versa.

- The restriction to assign device major by LKM is completely removed.
  We don't need to reserve LKM entries for dynamic loading of device switch.

- In compile time, device major numbers list is packed into the kernel and
  the LKM framework will refer it to assign device major number dynamically.

Revision 1.137.2.7 / (download) - annotate - [select for diffs], Fri Sep 6 08:43:44 2002 UTC (6 years, 9 months ago) by jdolecek
Branch: kqueue
Changes since 1.137.2.6: +5 -6 lines
Diff to previous 1.137.2.6 (colored)

sync kqueue branch with HEAD

Revision 1.155.4.2 / (download) - annotate - [select for diffs], Tue Aug 27 09:46:17 2002 UTC (6 years, 10 months ago) by lukem
Branch: netbsd-1-6
CVS Tags: netbsd-1-6-RELEASE, netbsd-1-6-RC3, netbsd-1-6-RC2
Changes since 1.155.4.1: +4 -0 lines
Diff to previous 1.155.4.1 (colored) to branchpoint 1.155 (colored)

Pull up revision 1.156 (requested by gmcgarry in ticket #729):
When audio recording was paused or dropping samples, the "outp" of the
recording ring buffer could overrun the end of the buffer.  When
recording resumed, memory after the end of the buffer would be read,
sometimes causing a system crash.

Revision 1.135.2.10 / (download) - annotate - [select for diffs], Thu Aug 1 02:44:32 2002 UTC (6 years, 11 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.9: +5 -6 lines
Diff to previous 1.135.2.9 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.155.2.4 / (download) - annotate - [select for diffs], Mon Jul 15 10:35:07 2002 UTC (6 years, 11 months ago) by gehenna
Branch: gehenna-devsw
Changes since 1.155.2.3: +5 -6 lines
Diff to previous 1.155.2.3 (colored) to branchpoint 1.155 (colored) next main 1.156 (colored)

catch up with -current.

Revision 1.159 / (download) - annotate - [select for diffs], Wed Jul 10 02:25:49 2002 UTC (6 years, 11 months ago) by gson
Branch: MAIN
CVS Tags: gehenna-devsw-base
Changes since 1.158: +3 -4 lines
Diff to previous 1.158 (colored)

When a recording interrupt happened in the middle of audio_read(),
changes to cb->used by audio_rint() could be overwritten by audio_read().

Revision 1.155.4.1 / (download) - annotate - [select for diffs], Mon Jun 24 05:06:27 2002 UTC (7 years ago) by lukem
Branch: netbsd-1-6
CVS Tags: netbsd-1-6-RC1
Changes since 1.155: +4 -4 lines
Diff to previous 1.155 (colored)

Pull up revision 1.158 (requested by gmcgarry in ticket #351):
Back out revision 1.132.  This revision broke binary compatibility with
binaries which were working fine on NetBSD 1.5.  We defer this change
until a longer-term fix is found as explain in the commit message in
revision 1.132.
Further details can be found in PR17159.

Revision 1.137.2.6 / (download) - annotate - [select for diffs], Sun Jun 23 17:44:57 2002 UTC (7 years ago) by jdolecek
Branch: kqueue
Changes since 1.137.2.5: +207 -174 lines
Diff to previous 1.137.2.5 (colored)

catch up with -current on kqueue branch

Revision 1.158 / (download) - annotate - [select for diffs], Sun Jun 23 01:36:07 2002 UTC (7 years ago) by gmcgarry
Branch: MAIN
Changes since 1.157: +4 -4 lines
Diff to previous 1.157 (colored)

Back out revision 1.132.  This revision broke binary compatibility with
binaries which were working fine on NetBSD 1.5.  We defer this change
until a longer-term fix is found as explain in the commit message in
revision 1.132.

Further details can be found in PR17159.

Revision 1.155.2.3 / (download) - annotate - [select for diffs], Thu Jun 20 16:31:19 2002 UTC (7 years ago) by gehenna
Branch: gehenna-devsw
Changes since 1.155.2.2: +15 -4 lines
Diff to previous 1.155.2.2 (colored) to branchpoint 1.155 (colored)

catch up with -current.

Revision 1.135.2.9 / (download) - annotate - [select for diffs], Thu Jun 20 03:43:21 2002 UTC (7 years ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.8: +19 -4 lines
Diff to previous 1.135.2.8 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.157 / (download) - annotate - [select for diffs], Sun Jun 2 02:00:30 2002 UTC (7 years, 1 month ago) by gson
Branch: MAIN
Changes since 1.156: +15 -4 lines
Diff to previous 1.156 (colored)

The logic in audio_poll() was incorrect in full duplex mode;
among other things, it behaved as if full-duplex audio devices
were always ready for writing.  Also commented the code in case.
This fixes PRs kern/11179 and kern/13829.

Revision 1.155.2.2 / (download) - annotate - [select for diffs], Thu May 30 14:45:26 2002 UTC (7 years, 1 month ago) by gehenna
Branch: gehenna-devsw
Changes since 1.155.2.1: +6 -2 lines
Diff to previous 1.155.2.1 (colored) to branchpoint 1.155 (colored)

Catch up with -current.

Revision 1.156 / (download) - annotate - [select for diffs], Mon May 27 17:13:14 2002 UTC (7 years, 1 month ago) by gson
Branch: MAIN
Changes since 1.155: +6 -2 lines
Diff to previous 1.155 (colored)

When audio recording was paused or dropping samples, the "outp" of the
recording ring buffer could overrun the end of the buffer.  When
recording resumed, memory after the end of the buffer would be read,
sometimes causing a system crash.

Revision 1.155.2.1 / (download) - annotate - [select for diffs], Thu May 16 04:52:05 2002 UTC (7 years, 1 month ago) by gehenna
Branch: gehenna-devsw
Changes since 1.155: +15 -5 lines
Diff to previous 1.155 (colored)

Add the character device switch.
Replace the direct-access to devsw table with calling devsw API.

Revision 1.135.2.8 / (download) - annotate - [select for diffs], Mon Apr 1 07:44:59 2002 UTC (7 years, 3 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.7: +472 -214 lines
Diff to previous 1.135.2.7 (colored) to branchpoint 1.135 (colored)

Catch up to -current.
(CVS: It's not just a program. It's an adventure!)

Revision 1.155 / (download) - annotate - [select for diffs], Sat Mar 23 17:17:10 2002 UTC (7 years, 3 months ago) by kent
Branch: MAIN
CVS Tags: netbsd-1-6-base
Branch point for: netbsd-1-6, gehenna-devsw
Changes since 1.154: +143 -140 lines
Diff to previous 1.154 (colored)

whitespace and folding fix.

Revision 1.154 / (download) - annotate - [select for diffs], Thu Mar 21 05:22:24 2002 UTC (7 years, 3 months ago) by isaki
Branch: MAIN
CVS Tags: eeh-devprop-base, eeh-devprop
Changes since 1.153: +5 -3 lines
Diff to previous 1.153 (colored)

Fix previous commit.  modifying cc is only when factor_denom > 1.
reviewed by kent@netbsd.org

Revision 1.153 / (download) - annotate - [select for diffs], Sun Mar 17 03:20:40 2002 UTC (7 years, 3 months ago) by isaki
Branch: MAIN
Changes since 1.152: +4 -3 lines
Diff to previous 1.152 (colored)

Fix infinate loop in recoding on vs0.

Revision 1.137.2.5 / (download) - annotate - [select for diffs], Sat Mar 16 16:00:46 2002 UTC (7 years, 3 months ago) by jdolecek
Branch: kqueue
Changes since 1.137.2.4: +313 -73 lines
Diff to previous 1.137.2.4 (colored)

Catch up with -current.

Revision 1.152 / (download) - annotate - [select for diffs], Sat Mar 16 08:58:49 2002 UTC (7 years, 3 months ago) by isaki
Branch: MAIN
Changes since 1.151: +45 -34 lines
Diff to previous 1.151 (colored)

Add factor_denom, a denominator of factor,
in 'struct audio_param' for vs0 on x68k.

{hw,user}_bytes_per_sample is changed to {hw,user}_bits_per_sample
to handle 4bit/sampling.

Revision 1.151 / (download) - annotate - [select for diffs], Fri Mar 15 14:55:03 2002 UTC (7 years, 3 months ago) by kent
Branch: MAIN
Changes since 1.150: +4 -4 lines
Diff to previous 1.150 (colored)

audio.c: revert a part of previous change.
auconv.c: correct handling of size parameter.

Revision 1.150 / (download) - annotate - [select for diffs], Fri Mar 15 14:35:32 2002 UTC (7 years, 3 months ago) by kent
Branch: MAIN
Changes since 1.149: +8 -7 lines
Diff to previous 1.149 (colored)

Fix a bug of audio_read() in a case that params->factor is not 1.

Revision 1.149 / (download) - annotate - [select for diffs], Sat Mar 9 20:30:43 2002 UTC (7 years, 3 months ago) by kent
Branch: MAIN
CVS Tags: newlock-base, newlock
Changes since 1.148: +40 -2 lines
Diff to previous 1.148 (colored)

Move sampling rate conversion functions to aurateconv.c.
Introduce "aurateconv" attribute for audio devices.
Add aurateconv to uaudio and auich.
(due to kern/15845 and kern/15848)

Revision 1.148 / (download) - annotate - [select for diffs], Sat Mar 9 07:25:41 2002 UTC (7 years, 3 months ago) by toshii
Branch: MAIN
Changes since 1.147: +3 -3 lines
Diff to previous 1.147 (colored)

Fix splaudio/splx botch.

Revision 1.147 / (download) - annotate - [select for diffs], Fri Mar 8 02:30:54 2002 UTC (7 years, 3 months ago) by thorpej
Branch: MAIN
Changes since 1.146: +4 -4 lines
Diff to previous 1.146 (colored)

Fix printf format on LP64.

Revision 1.146 / (download) - annotate - [select for diffs], Thu Mar 7 14:37:02 2002 UTC (7 years, 3 months ago) by kent
Branch: MAIN
Changes since 1.145: +275 -73 lines
Diff to previous 1.145 (colored)

Sampling rate and mono-stereo conversion described in
http://mail-index.netbsd.org/tech-kern/2002/03/04/0005.html

auconv.c: Add conversion functions

audio.c: Sample alignment, calling conversion functions, etc.

audio_if.h: Add four hw_* members to "struct audio_params"

audiovar.h: Add conversion buffers, etc.

auich and uaudio: Add conversion request code to *_set_params().

Revision 1.135.2.7 / (download) - annotate - [select for diffs], Thu Feb 28 04:13:09 2002 UTC (7 years, 4 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.6: +6 -11 lines
Diff to previous 1.135.2.6 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.137.2.4 / (download) - annotate - [select for diffs], Mon Feb 11 20:09:36 2002 UTC (7 years, 4 months ago) by jdolecek
Branch: kqueue
Changes since 1.137.2.3: +6 -11 lines
Diff to previous 1.137.2.3 (colored)

Sync w/ -current.

Revision 1.145 / (download) - annotate - [select for diffs], Fri Jan 18 21:59:41 2002 UTC (7 years, 5 months ago) by jdolecek
Branch: MAIN
CVS Tags: ifpoll-base, ifpoll
Changes since 1.144: +6 -11 lines
Diff to previous 1.144 (colored)

drop completely superfluous PRINT() macro

Revision 1.137.2.3 / (download) - annotate - [select for diffs], Thu Jan 10 19:52:44 2002 UTC (7 years, 5 months ago) by thorpej
Branch: kqueue
Changes since 1.137.2.2: +144 -271 lines
Diff to previous 1.137.2.2 (colored)

Sync kqueue branch with -current.

Revision 1.135.2.6 / (download) - annotate - [select for diffs], Tue Jan 8 00:29:17 2002 UTC (7 years, 5 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.5: +3 -3 lines
Diff to previous 1.135.2.5 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.144 / (download) - annotate - [select for diffs], Sat Nov 17 05:31:27 2001 UTC (7 years, 7 months ago) by perry
Branch: MAIN
Changes since 1.143: +3 -3 lines
Diff to previous 1.143 (colored)

fix a trivial lint warning

Revision 1.135.2.5 / (download) - annotate - [select for diffs], Wed Nov 14 19:13:40 2001 UTC (7 years, 7 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.4: +4 -1 lines
Diff to previous 1.135.2.4 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.143 / (download) - annotate - [select for diffs], Tue Nov 13 05:32:49 2001 UTC (7 years, 7 months ago) by lukem
Branch: MAIN
Changes since 1.142: +4 -1 lines
Diff to previous 1.142 (colored)

add RCSIDs

Revision 1.135.2.4 / (download) - annotate - [select for diffs], Mon Oct 22 20:41:15 2001 UTC (7 years, 8 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.3: +5 -6 lines
Diff to previous 1.135.2.3 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.138.2.4 / (download) - annotate - [select for diffs], Thu Oct 11 00:02:00 2001 UTC (7 years, 8 months ago) by fvdl
Branch: thorpej-devvp
Changes since 1.138.2.3: +141 -270 lines
Diff to previous 1.138.2.3 (colored) to branchpoint 1.138 (colored) next main 1.139 (colored)

Catch up with -current. Fix some bogons in the sparc64 kbd/ms
attach code. cd18xx conversion provided by mrg.

Revision 1.135.2.3 / (download) - annotate - [select for diffs], Mon Oct 8 20:10:54 2001 UTC (7 years, 8 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.2: +139 -268 lines
Diff to previous 1.135.2.2 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.142 / (download) - annotate - [select for diffs], Wed Oct 3 20:48:41 2001 UTC (7 years, 9 months ago) by augustss
Branch: MAIN
CVS Tags: thorpej-mips-cache-base, thorpej-mips-cache, thorpej-devvp-base3
Changes since 1.141: +5 -6 lines
Diff to previous 1.141 (colored)

Fix pasto in type of dev_ioctl method.

Revision 1.141 / (download) - annotate - [select for diffs], Wed Oct 3 00:04:49 2001 UTC (7 years, 9 months ago) by augustss
Branch: MAIN
Changes since 1.140: +12 -4 lines
Diff to previous 1.140 (colored)

Add a new optional method, dev_ioctl, to the audio hardware driver interface.
It is called when an unrecognized ioctl() is performed on a device,
thus allowing ioctl()s that frob the hardware driver (like loading
microcode).

Revision 1.140 / (download) - annotate - [select for diffs], Tue Oct 2 23:31:54 2001 UTC (7 years, 9 months ago) by augustss
Branch: MAIN
Changes since 1.139: +128 -265 lines
Diff to previous 1.139 (colored)

ANSIfy.

Revision 1.138.2.3 / (download) - annotate - [select for diffs], Mon Oct 1 12:44:09 2001 UTC (7 years, 9 months ago) by fvdl
Branch: thorpej-devvp
Changes since 1.138.2.2: +2 -2 lines
Diff to previous 1.138.2.2 (colored) to branchpoint 1.138 (colored)

Catch up with -current.

Revision 1.138.2.2 / (download) - annotate - [select for diffs], Wed Sep 26 15:28:08 2001 UTC (7 years, 9 months ago) by fvdl
Branch: thorpej-devvp
Changes since 1.138.2.1: +35 -17 lines
Diff to previous 1.138.2.1 (colored) to branchpoint 1.138 (colored)

* add a VCLONED vnode flag that indicates a vnode representing a cloned
  device.
* rename REVOKEALL to REVOKEALIAS, and add a REVOKECLONE flag, to pass
  to VOP_REVOKE
* the revoke system call will revoke all aliases, as before, but not the
  clones
* vdevgone is called when detaching a device, so make it use REVOKECLONE
  to get rid of all clones as well
* clean up all uses of VOP_OPEN wrt. locking.
* add a few VOPS to spec_vnops that need to do something when it's a
  clone vnode (access and getattr)
* add a copy of the vnode vattr structure of the original 'master' vnode
  to the specinfo of a cloned vnode. could possibly redirect getattr to
  the 'master' vnode, but this has issues with revoke
* add a vdev_reassignvp function that disassociates a vnode from its
  original device, and reassociates it with the specified dev_t. to be
  used by cloning devices only, in case a new minor is allocated.
* change all direct references in drivers to v_devcookie and v_rdev
  to vdev_privdata(vp) and vdev_rdev(vp). for diagnostic purposes
  when debugging race conditions that still exist wrt. locking and
  revoking vnodes.
* make the locking state of a vnode consistent when passed to
  d_open and d_close (unlocked). locked would be better, but has
  some deadlock issues

Revision 1.135.2.2 / (download) - annotate - [select for diffs], Fri Sep 21 22:35:27 2001 UTC (7 years, 9 months ago) by nathanw
Branch: nathanw_sa
Changes since 1.135.2.1: +25 -17 lines
Diff to previous 1.135.2.1 (colored) to branchpoint 1.135 (colored)

Catch up to -current.

Revision 1.139 / (download) - annotate - [select for diffs], Sun Sep 16 16:34:36 2001 UTC (7 years, 9 months ago) by wiz
Branch: MAIN
CVS Tags: thorpej-devvp-base2
Changes since 1.138: +2 -2 lines
Diff to previous 1.138 (colored)

Spell 'occurred' with two 'r's.

Revision 1.137.2.2 / (download) - annotate - [select for diffs], Thu Sep 13 01:15:34 2001 UTC (7 years, 9 months ago) by thorpej
Branch: kqueue
Changes since 1.137.2.1: +24 -16 lines
Diff to previous 1.137.2.1 (colored)

Update the kqueue branch to HEAD.

Revision 1.137.2.1 / (download) - annotate - [select for diffs], Sat Sep 8 20:03:43 2001 UTC (7 years, 9 months ago) by thorpej
Branch: kqueue
Changes since 1.137: +124 -4 lines
Diff to previous 1.137 (colored)

Add kqueue support (someone who understands how the audio code
works should make sure I got this right).

Revision 1.138.2.1 / (download) - annotate - [select for diffs], Fri Sep 7 04:45:22 2001 UTC (7 years, 9 months ago) by thorpej
Branch: thorpej-devvp
Changes since 1.138: +45 -50 lines
Diff to previous 1.138 (colored)

Commit my "devvp" changes to the thorpej-devvp branch.  This
replaces the use of dev_t in most places with a struct vnode *.

This will form the basic infrastructure for real cloning device
support (besides being architecurally cleaner -- it'll be good
to get away from using numbers to represent objects).

Revision 1.138 / (download) - annotate - [select for diffs], Mon Sep 3 18:51:43 2001 UTC (7 years, 10 months ago) by is
Branch: MAIN
CVS Tags: thorpej-devvp-base, pre-chs-ubcperf, post-chs-ubcperf
Branch point for: thorpej-devvp
Changes since 1.137: +24 -16 lines
Diff to previous 1.137 (colored)

Allow 24 and 32bit linear audio.
Actually, the silence filler can do any multiple of 8 bits now, but I didn't
allow the parameter check to accept more than 32 bit to avoid confusion
of drivers that fail to check the parameters themselves thoroughly.
This should be changed later.

Revision 1.135.2.1 / (download) - annotate - [select for diffs], Thu Jun 21 20:01:13 2001 UTC (8 years ago) by nathanw
Branch: nathanw_sa
Changes since 1.135: +6 -3 lines
Diff to previous 1.135 (colored)

Catch up to -current.

Revision 1.137 / (download) - annotate - [select for diffs], Sun Jun 3 23:52:51 2001 UTC (8 years, 1 month ago) by jhawk
Branch: MAIN
Branch point for: kqueue
Changes since 1.136: +2 -2 lines
Diff to previous 1.136 (colored)

s/printf/DPRINTF/ for kern/13101.

Revision 1.136 / (download) - annotate - [select for diffs], Wed May 2 12:49:41 2001 UTC (8 years, 2 months ago) by minoura
Branch: MAIN
Changes since 1.135: +5 -2 lines
Diff to previous 1.135 (colored)

X68k built-in voice synthesizer supports 4bit ADPCM.

Revision 1.117.2.3 / (download) - annotate - [select for diffs], Sun Feb 11 19:15:14 2001 UTC (8 years, 4 months ago) by bouyer
Branch: thorpej_scsipi
Changes since 1.117.2.2: +3 -2 lines
Diff to previous 1.117.2.2 (colored) next main 1.118 (colored)

Sync with HEAD.

Revision 1.135 / (download) - annotate - [select for diffs], Thu Jan 25 15:25:34 2001 UTC (8 years, 5 months ago) by toshii
Branch: MAIN
CVS Tags: thorpej_scsipi_nbase, thorpej_scsipi_beforemerge, thorpej_scsipi_base
Branch point for: nathanw_sa
Changes since 1.134: +3 -1 lines
Diff to previous 1.134 (colored)

The previous revision was my fault.  audio_calcwater() needs to be
called at every open.
Thanks Witold J. Wnuk for pointing out this problem.

Revision 1.134 / (download) - annotate - [select for diffs], Mon Jan 22 08:37:54 2001 UTC (8 years, 5 months ago) by toshii
Branch: MAIN
Changes since 1.133: +1 -2 lines
Diff to previous 1.133 (colored)

Remove the line in audio_open which zeroes sc_[pr]r.blksize.
Because zeroing them causes zero division panic with devices which don't
support 8kHz mulaw, and the effect of this line was to force calling
audio_calcwater even when unnecessary.

Revision 1.117.2.2 / (download) - annotate - [select for diffs], Fri Jan 5 17:35:31 2001 UTC (8 years, 5 months ago) by bouyer
Branch: thorpej_scsipi
Changes since 1.117.2.1: +4 -3 lines
Diff to previous 1.117.2.1 (colored)

Sync with HEAD

Revision 1.133 / (download) - annotate - [select for diffs], Fri Dec 29 10:00:08 2000 UTC (8 years, 6 months ago) by augustss
Branch: MAIN
Changes since 1.132: +2 -1 lines
Diff to previous 1.132 (colored)

Add a field in mixer_devinfo_t that indicates the minimum delta to
change mixer value.  A value of 0 indicates that the driver doesn't
supply a delta.
The change is backwards compatible.

Revision 1.132 / (download) - annotate - [select for diffs], Mon Dec 25 00:01:39 2000 UTC (8 years, 6 months ago) by jmc
Branch: MAIN
Changes since 1.131: +3 -3 lines
Diff to previous 1.131 (colored)

Back out changes from 1.124 since the additions of *ports.master=-1 wasn't
documented as to why it was added in and it breaks the ability to set the
gain on playback. A longer term fix to set these correctly should be done but
none of the drivers today are doing this and not being able to set the playback
volume otherwise is a bit silly.

Revision 1.117.2.1 / (download) - annotate - [select for diffs], Mon Nov 20 11:39:45 2000 UTC (8 years, 7 months ago) by bouyer
Branch: thorpej_scsipi
Changes since 1.117: +86 -42 lines
Diff to previous 1.117 (colored)

Update thorpej_scsipi to -current as of a month ago
A i386 GENERIC kernel compiles without the siop, ahc and bha drivers
(will be updated later). i386 IDE/ATAPI and ncr work, as well as
sparc/esp_sbus. alpha should work as well (untested yet).
siop, ahc and bha will be updated once I've updated the branch to current
-current, as well as machine-dependant code.

Revision 1.125.4.2 / (download) - annotate - [select for diffs], Sat Jul 22 04:58:46 2000 UTC (8 years, 11 months ago) by simonb
Branch: netbsd-1-5
CVS Tags: netbsd-1-5-RELEASE, netbsd-1-5-PATCH003, netbsd-1-5-PATCH002, netbsd-1-5-PATCH001, netbsd-1-5-BETA2, netbsd-1-5-BETA, netbsd-1-5-ALPHA2
Changes since 1.125.4.1: +2 -2 lines
Diff to previous 1.125.4.1 (colored) to branchpoint 1.125 (colored) next main 1.126 (colored)

Pull up rev 1.131 from nathanw:
 More printf format munging for off_t: when printing as %lld, cast to
 long long.

Revision 1.131 / (download) - annotate - [select for diffs], Wed Jul 19 13:44:24 2000 UTC (8 years, 11 months ago) by nathanw
Branch: MAIN
Changes since 1.130: +2 -2 lines
Diff to previous 1.130 (colored)

More printf format munging for off_t: when printing as %lld, cast to long long.

Revision 1.130 / (download) - annotate - [select for diffs], Thu Jul 6 00:43:04 2000 UTC (9 years ago) by thorpej
Branch: MAIN
Changes since 1.129: +9 -12 lines
Diff to previous 1.129 (colored)

Use device_lookup().

Revision 1.125.4.1 / (download) - annotate - [select for diffs], Fri Jun 30 16:27:45 2000 UTC (9 years ago) by simonb
Branch: netbsd-1-5
Changes since 1.125: +10 -8 lines
Diff to previous 1.125 (colored)

Pull up mmap paddr_t/off_t changes from trunk.

Revision 1.129 / (download) - annotate - [select for diffs], Tue Jun 27 21:25:02 2000 UTC (9 years ago) by augustss
Branch: MAIN
Changes since 1.128: +2 -2 lines
Diff to previous 1.128 (colored)

Make it compile with AUDIO_DEBUG after the mmap API change.

Revision 1.128 / (download) - annotate - [select for diffs], Tue Jun 27 17:58:22 2000 UTC (9 years ago) by mrg
Branch: MAIN
Changes since 1.127: +1 -3 lines
Diff to previous 1.127 (colored)

remove include of <vm/vm.h>

Revision 1.127 / (download) - annotate - [select for diffs], Mon Jun 26 04:56:17 2000 UTC (9 years ago) by simonb
Branch: MAIN
Changes since 1.126: +9 -7 lines
Diff to previous 1.126 (colored)

Change the kernel mmap interface so that the offset to map is an
"off_t" and the return value is a "paddr_t" to allow mappings
at offsets past 2^31 bytes.  Somewhat inspired by FreeBSD, which
only changed the offset to a "vm_offset_t".

Includes updates for the i386, pc532 and sh3 mmmmap from Jason Thorpe.

Revision 1.126 / (download) - annotate - [select for diffs], Sun Jun 25 13:26:19 2000 UTC (9 years ago) by mrg
Branch: MAIN
Changes since 1.125: +1 -2 lines
Diff to previous 1.125 (colored)

remove some redundant <vm/vm_xxx.h> includes

Revision 1.125 / (download) - annotate - [select for diffs], Tue May 2 00:00:00 2000 UTC (9 years, 2 months ago) by augustss
Branch: MAIN
CVS Tags: netbsd-1-5-base, minoura-xpg4dl-base, minoura-xpg4dl
Branch point for: netbsd-1-5
Changes since 1.124: +15 -1 lines
Diff to previous 1.124 (colored)

Support recording conversions that change the sample size.  PR 10029, from Gregory McGarry.

Revision 1.124 / (download) - annotate - [select for diffs], Mon May 1 17:10:40 2000 UTC (9 years, 2 months ago) by augustss
Branch: MAIN
Changes since 1.123: +7 -3 lines
Diff to previous 1.123 (colored)

Add some more debug output.

Revision 1.123 / (download) - annotate - [select for diffs], Sun Mar 26 10:01:32 2000 UTC (9 years, 3 months ago) by augustss
Branch: MAIN
Changes since 1.122: +2 -2 lines
Diff to previous 1.122 (colored)

Avoid a pointless debug message.

Revision 1.122 / (download) - annotate - [select for diffs], Wed Mar 1 00:44:35 2000 UTC (9 years, 4 months ago) by augustss
Branch: MAIN
Changes since 1.121: +13 -13 lines
Diff to previous 1.121 (colored)

Change the cmd argument in {audio,mixer}_ioctl() to u_long.

Revision 1.117.6.1 / (download) - annotate - [select for diffs], Mon Dec 27 18:34:34 1999 UTC (9 years, 6 months ago) by wrstuden
Branch: wrstuden-devbsize
Changes since 1.117: +36 -6 lines
Diff to previous 1.117 (colored) next main 1.118 (colored)

Pull up to last week's -current.

Revision 1.121 / (download) - annotate - [select for diffs], Wed Dec 15 12:09:34 1999 UTC (9 years, 6 months ago) by kleink
Branch: MAIN
CVS Tags: wrstuden-devbsize-base, wrstuden-devbsize-19991221, chs-ubc2-newbase
Changes since 1.120: +19 -5 lines
Diff to previous 1.120 (colored)

Report all AUDIO_PROP_* properties when attaching an audio device.

Revision 1.113.6.1 / (download) - annotate - [select for diffs], Tue Nov 30 13:33:45 1999 UTC (9 years, 7 months ago) by itojun
Branch: kame
CVS Tags: kame_141_19991130
Changes since 1.113: +12 -6 lines
Diff to previous 1.113 (colored) next main 1.114 (colored)

bring in latest KAME (as of 19991130, KAME/NetBSD141) into kame branch
just for reference purposes.
This commit includes 1.4 -> 1.4.1 sync for kame branch.

The branch does not compile at all (due to the lack of ALTQ and some other
source code).  Please do not try to modify the branch, this is just for
referenre purposes.

synchronization to latest KAME will take place on HEAD branch soon.

Revision 1.120 / (download) - annotate - [select for diffs], Tue Nov 23 08:38:30 1999 UTC (9 years, 7 months ago) by augustss
Branch: MAIN
Changes since 1.119: +7 -1 lines
Diff to previous 1.119 (colored)

Avoid 0 blocksize.

Revision 1.117.4.1 / (download) - annotate - [select for diffs], Mon Nov 15 00:40:10 1999 UTC (9 years, 7 months ago) by fvdl
Branch: fvdl-softdep
Changes since 1.117: +12 -2 lines
Diff to previous 1.117 (colored) next main 1.118 (colored)

Sync with -current

Revision 1.119 / (download) - annotate - [select for diffs], Tue Nov 9 16:50:47 1999 UTC (9 years, 7 months ago) by augustss
Branch: MAIN
CVS Tags: fvdl-softdep-base
Changes since 1.118: +5 -2 lines
Diff to previous 1.118 (colored)

Make sure to call vdevgone() on all devices when deteching.

Revision 1.118 / (download) - annotate - [select for diffs], Mon Nov 1 18:06:36 1999 UTC (9 years, 8 months ago) by augustss
Branch: MAIN
CVS Tags: comdex-fall-1999-base, comdex-fall-1999
Changes since 1.117: +8 -1 lines
Diff to previous 1.117 (colored)

Be cautious about the blocksize returned by the hardware driver to
avoid division by 0.

Revision 1.117 / (download) - annotate - [select for diffs], Thu Sep 23 11:53:13 1999 UTC (9 years, 9 months ago) by kleink
Branch: MAIN
Branch point for: wrstuden-devbsize, thorpej_scsipi, fvdl-softdep
Changes since 1.116: +2 -2 lines
Diff to previous 1.116 (colored)

Minor output formatting buglet.

Revision 1.116 / (download) - annotate - [select for diffs], Thu Sep 9 10:24:39 1999 UTC (9 years, 9 months ago) by augustss
Branch: MAIN
Changes since 1.115: +235 -97 lines
Diff to previous 1.115 (colored)

Add support for detaching audio devices.

Revision 1.113.2.2 / (download) - annotate - [select for diffs], Tue Jun 22 14:18:41 1999 UTC (10 years ago) by perry
Branch: netbsd-1-4
CVS Tags: netbsd-1-4-PATCH003, netbsd-1-4-PATCH002, netbsd-1-4-PATCH001
Changes since 1.113.2.1: +3 -3 lines
Diff to previous 1.113.2.1 (colored) to branchpoint 1.113 (colored) next main 1.114 (colored)

pullup 1.113->1.114 (nathanw). We are now sync'ed to 1.115

Revision 1.113.4.1 / (download) - annotate - [select for diffs], Mon Jun 21 01:17:35 1999 UTC (10 years ago) by thorpej
Branch: chs-ubc2
Changes since 1.113: +12 -6 lines
Diff to previous 1.113 (colored) next main 1.114 (colored)

Sync w/ -current.

Revision 1.113.2.1 / (download) - annotate - [select for diffs], Fri Jun 18 17:07:27 1999 UTC (10 years ago) by perry
Branch: netbsd-1-4
Changes since 1.113: +10 -4 lines
Diff to previous 1.113 (colored)

pullup 1.114->1.115 (thorpej)

Revision 1.115 / (download) - annotate - [select for diffs], Mon Jun 7 19:24:38 1999 UTC (10 years ago) by thorpej
Branch: MAIN
CVS Tags: chs-ubc2-base
Changes since 1.114: +10 -4 lines
Diff to previous 1.114 (colored)

Don't clobber the error returned by uiomove() when starting the audio
output (in case we got a partial block).  Fixes PR #7722, from
Antti Kantee <pooka@iki.fi>.

Revision 1.114 / (download) - annotate - [select for diffs], Sun May 30 00:21:08 1999 UTC (10 years, 1 month ago) by nathanw
Branch: MAIN
Changes since 1.113: +3 -3 lines
Diff to previous 1.113 (colored)

Fix two small bugs:
(1) Fix sense of a strcmp() test so that the monitor subdevice of the
    mixer is properly identified.
(2) Use hw_if->set_port() instead of hw_if->get_port() when changinh
    the monitor level in audiosetinfo().

Fixes PR kern/7661.

Revision 1.113 / (download) - annotate - [select for diffs], Fri Feb 26 01:18:09 1999 UTC (10 years, 4 months ago) by nathanw
Branch: MAIN
CVS Tags: netbsd-1-4-base, netbsd-1-4-RELEASE, kame_14_19990705, kame_14_19990628
Branch point for: netbsd-1-4, kame, chs-ubc2
Changes since 1.112: +7 -7 lines
Diff to previous 1.112 (colored)

Make these compile on the alpha when AUDIO_DEBUG is defined.

Revision 1.112 / (download) - annotate - [select for diffs], Fri Feb 19 17:09:16 1999 UTC (10 years, 4 months ago) by mycroft
Branch: MAIN
Changes since 1.111: +6 -3 lines
Diff to previous 1.111 (colored)

Indicate whether the decive is full or half duplex at attach time.

Revision 1.111 / (download) - annotate - [select for diffs], Wed Feb 17 02:37:38 1999 UTC (10 years, 4 months ago) by mycroft
Branch: MAIN
Changes since 1.110: +18 -16 lines
Diff to previous 1.110 (colored)

Pass the direction to the allocm and round_buffersize methods.
Some drivers need this to properly allocate DMAable memory.

Revision 1.110 / (download) - annotate - [select for diffs], Sun Dec 27 23:25:32 1998 UTC (10 years, 6 months ago) by augustss
Branch: MAIN
Changes since 1.109: +5 -5 lines
Diff to previous 1.109 (colored)

Make sure recording is started before we return EWOULDBLOCK in a read().

Revision 1.109 / (download) - annotate - [select for diffs], Sun Dec 27 22:52:23 1998 UTC (10 years, 6 months ago) by augustss
Branch: MAIN
Changes since 1.108: +83 -52 lines
Diff to previous 1.108 (colored)

Fold lines to 80 chars.

Revision 1.108 / (download) - annotate - [select for diffs], Sun Dec 20 14:26:44 1998 UTC (10 years, 6 months ago) by drochner
Branch: MAIN
Changes since 1.107: +4 -4 lines
Diff to previous 1.107 (colored)

Make midi_attach_mi() and audioprint() available also if MIDIBUS
(but not necessarily MIDI) is defined.
Fixes PR port-i386/6615 (Krister Walfridsson <cato@ulysses.df.lth.se>).
(XXX this should probably go into a separate file to get rid of
the #ifdef mess)

Revision 1.107 / (download) - annotate - [select for diffs], Wed Nov 25 13:44:13 1998 UTC (10 years, 7 months ago) by mycroft
Branch: MAIN
CVS Tags: kenh-if-detach-base, kenh-if-detach
Changes since 1.106: +3 -1 lines
Diff to previous 1.106 (colored)

Do not permit a class to be recorded as a master or monitor port.

Revision 1.77.2.2 / (download) - annotate - [select for diffs], Mon Nov 23 03:12:57 1998 UTC (10 years, 7 months ago) by cgd
Branch: netbsd-1-3
CVS Tags: netbsd-1-3-PATCH003-CANDIDATE2, netbsd-1-3-PATCH003-CANDIDATE1, netbsd-1-3-PATCH003-CANDIDATE0, netbsd-1-3-PATCH003
Changes since 1.77.2.1: +2 -2 lines
Diff to previous 1.77.2.1 (colored) to branchpoint 1.77 (colored) next main 1.78 (colored)

Fix many real and potential security problems with character device
driver mmap routines that did not properly bounds check offsets.
See NetBSD security advisory NetBSD-SA1998-005 for details.  Done
as a patch because it's large, and a fair number of bits are different
in -current.  (mrg)

Revision 1.106 / (download) - annotate - [select for diffs], Thu Nov 19 15:38:25 1998 UTC (10 years, 7 months ago) by mrg
Branch: MAIN
Changes since 1.105: +2 -2 lines
Diff to previous 1.105 (colored)

fix problems in many d_mmap routines:
	- returned EOPNOTSUPP rather than -1.
	- no check for negative offset.
many of these fix potential security problems in these drivers.


XXX XXX XXX
the d_mmap cdev routine should be changed to have a prototype like:
	paddr_t (*d_mmap) __P((dev_t, off_t, int));

by someone!

Revision 1.105 / (download) - annotate - [select for diffs], Sun Sep 27 16:43:56 1998 UTC (10 years, 9 months ago) by christos
Branch: MAIN
CVS Tags: chs-ubc-base, chs-ubc
Changes since 1.104: +9 -1 lines
Diff to previous 1.104 (colored)

Make this compile again with no audio but with midi devices.

Revision 1.104 / (download) - annotate - [select for diffs], Tue Sep 1 07:27:06 1998 UTC (10 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.103: +4 -4 lines
Diff to previous 1.103 (colored)

Move some debugging output to more useful levels.

Revision 1.103 / (download) - annotate - [select for diffs], Fri Aug 28 12:07:41 1998 UTC (10 years, 10 months ago) by pk
Branch: MAIN
Changes since 1.102: +31 -25 lines
Diff to previous 1.102 (colored)

Slight optimization in audio_[pr]int().

Revision 1.102 / (download) - annotate - [select for diffs], Fri Aug 28 07:44:12 1998 UTC (10 years, 10 months ago) by augustss
Branch: MAIN
Changes since 1.101: +37 -32 lines
Diff to previous 1.101 (colored)

Handle the case of MIDI devices with no audio devices.

Revision 1.101 / (download) - annotate - [select for diffs], Tue Aug 18 18:17:17 1998 UTC (10 years, 10 months ago) by thorpej
Branch: MAIN
Changes since 1.100: +0 -3 lines
Diff to previous 1.100 (colored)

Back out previous.

Revision 1.100 / (download) - annotate - [select for diffs], Tue Aug 18 06:16:45 1998 UTC (10 years, 10 months ago) by thorpej
Branch: MAIN
Changes since 1.99: +4 -1 lines
Diff to previous 1.99 (colored)

Deal with somewhat bogus uninitialized warning in new egcs.  Behavior
is such that would inidicate that __attribute__((__noreturn__)) is not
being honored.

Revision 1.99 / (download) - annotate - [select for diffs], Mon Aug 17 21:16:11 1998 UTC (10 years, 10 months ago) by augustss
Branch: MAIN
Changes since 1.98: +17 -16 lines
Diff to previous 1.98 (colored)

* Redo the way the way the MIDI driver attaches to audio devices.
* Improve the midisyn layer a little.
* Add a driver for the Yamaha OPL[23] FM synths.
  The opl driver is not finished yet; it sounds pretty awful.

For some strange reason I cannot get any FM sound from my SB64 cards,
but a regular SB16 works fine.

Revision 1.98 / (download) - annotate - [select for diffs], Mon Aug 10 01:17:33 1998 UTC (10 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.97: +2 -2 lines
Diff to previous 1.97 (colored)

Oops.

Revision 1.97 / (download) - annotate - [select for diffs], Mon Aug 10 01:13:20 1998 UTC (10 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.96: +6 -6 lines
Diff to previous 1.96 (colored)

Call set_params if usemode changes.

Revision 1.96 / (download) - annotate - [select for diffs], Sun Aug 9 20:28:07 1998 UTC (10 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.95: +45 -28 lines
Diff to previous 1.95 (colored)

Add trigger_output and trigger_input entry points, which replace
init_{in,out}put and start_{in,out}put, and are only called once.

Revision 1.95 / (download) - annotate - [select for diffs], Sun Aug 9 07:25:58 1998 UTC (10 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.94: +13 -8 lines
Diff to previous 1.94 (colored)

Make sure output is thoroughly halted on close, and remember that we stopped
it.

Revision 1.94 / (download) - annotate - [select for diffs], Sun Aug 9 05:44:51 1998 UTC (10 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.93: +3 -2 lines
Diff to previous 1.93 (colored)

Mask off extra usemode bits.

Revision 1.93 / (download) - annotate - [select for diffs], Sun Aug 9 04:54:44 1998 UTC (10 years, 10 months ago) by mycroft
Branch: MAIN
Changes since 1.92: +3 -5 lines
Diff to previous 1.92 (colored)

Always copy back both the record and play parameters, in case the driver had
to change one behind our back.

Revision 1.89.2.2 / (download) - annotate - [select for diffs], Sat Aug 8 03:06:45 1998 UTC (10 years, 10 months ago) by eeh
Branch: eeh-paddr_t
Changes since 1.89.2.1: +2 -2 lines
Diff to previous 1.89.2.1 (colored) to branchpoint 1.89 (colored) next main 1.90 (colored)

Revert cdevsw mmap routines to return int.

Revision 1.89.2.1 / (download) - annotate - [select for diffs], Fri Aug 7 12:39:49 1998 UTC (10 years, 10 months ago) by drochner
Branch: eeh-paddr_t
Changes since 1.89: +2 -2 lines
Diff to previous 1.89 (colored)

make it compile in paddr_t world

Revision 1.92 / (download) - annotate - [select for diffs], Fri Aug 7 00:00:58 1998 UTC (10 years, 10 months ago) by augustss
Branch: MAIN
Changes since 1.91: +1 -9 lines
Diff to previous 1.91 (colored)

Add MIDI support.  The MIDI devices can be accessed as ``raw'' through
the /dev/rmidiN devices, or with a sequencer interface via /dev/music.
So far the only supported MIDI device is the MPU401 port on SoundBlaster
(and only on SB on isapnp, since we do not have locators with multiple
values yet).

Revision 1.91 / (download) - annotate - [select for diffs], Wed Aug 5 16:38:09 1998 UTC (10 years, 11 months ago) by augustss
Branch: MAIN
Changes since 1.90: +6 -5 lines
Diff to previous 1.90 (colored)

Clarify a comment.

Revision 1.90 / (download) - annotate - [select for diffs], Tue Aug 4 11:26:14 1998 UTC (10 years, 11 months ago) by augustss
Branch: MAIN
Changes since 1.89: +10 -9 lines
Diff to previous 1.89 (colored)

Allow option AUDIO_INTR_TIME even if the platform does not support
FP in the kernel.

Revision 1.89 / (download) - annotate - [select for diffs], Thu Jul 9 09:27:33 1998 UTC (10 years, 11 months ago) by mycroft
Branch: MAIN
CVS Tags: eeh-paddr_t-base
Branch point for: eeh-paddr_t
Changes since 1.88: +1 -3 lines
Diff to previous 1.88 (colored)

This doesn't need opt_compat_netbsd.h any more.

Revision 1.88 / (download) - annotate - [select for diffs], Thu Jul 9 02:45:45 1998 UTC (10 years, 11 months ago) by mycroft
Branch: MAIN
Changes since 1.87: +1 -3 lines
Diff to previous 1.87 (colored)

Don't #ifdef the encoding compatibility crud.  It's needed for source
compatibility with other systems and much third party software.

Revision 1.87 / (download) - annotate - [select for diffs], Sun Jul 5 08:49:41 1998 UTC (11 years ago) by jonathan
Branch: MAIN
Changes since 1.86: +3 -1 lines
Diff to previous 1.86 (colored)

* defopt COMPAT_{09,10,11,12,13} and COMPAT_NOMID.
TODO: revisit interaction between native compat and emul compat usage.

Revision 1.86 / (download) - annotate - [select for diffs], Mon May 18 18:27:43 1998 UTC (11 years, 1 month ago) by augustss
Branch: MAIN
Changes since 1.85: +5 -5 lines
Diff to previous 1.85 (colored)

Avoid spaces in tsleep() string.

Revision 1.85 / (download) - annotate - [select for diffs], Fri May 15 15:45:58 1998 UTC (11 years, 1 month ago) by augustss
Branch: MAIN
Changes since 1.84: +3 -1 lines
Diff to previous 1.84 (colored)

Be more verbose if attaching the audio device fails.

Revision 1.84 / (download) - annotate - [select for diffs], Tue Apr 28 23:19:20 1998 UTC (11 years, 2 months ago) by augustss
Branch: MAIN
Changes since 1.83: +4 -4 lines
Diff to previous 1.83 (colored)

Change debug printing a littel again.

Revision 1.83 / (download) - annotate - [select for diffs], Tue Apr 28 09:07:12 1998 UTC (11 years, 2 months ago) by augustss
Branch: MAIN
Changes since 1.82: +42 -92 lines
Diff to previous 1.82 (colored)

Add a few more debug messages and clean up debug printing a little.

Revision 1.82 / (download) - annotate - [select for diffs], Tue Mar 3 09:16:15 1998 UTC (11 years, 4 months ago) by augustss
Branch: MAIN
Changes since 1.81: +7 -6 lines
Diff to previous 1.81 (colored)

Avoid the name free so the MALLOCLOG option works again.
Fix some typos.

Revision 1.81 / (download) - annotate - [select for diffs], Mon Jan 12 08:44:08 1998 UTC (11 years, 5 months ago) by thorpej
Branch: MAIN
Changes since 1.80: +2 -4 lines
Diff to previous 1.80 (colored)

Adjust for config changes.

Revision 1.80 / (download) - annotate - [select for diffs], Wed Dec 3 01:01:19 1997 UTC (11 years, 7 months ago) by augustss
Branch: MAIN
Changes since 1.79: +20 -6 lines
Diff to previous 1.79 (colored)

Fix three problems spotted by mycroft:
- Closing the audio device should stop recording.
- Manipulating the pause function could accidentally start playing or recording.
- AUDIO_FLUSH could accidentally start playing or recording.

Revision 1.77.2.1 / (download) - annotate - [select for diffs], Wed Nov 5 02:46:55 1997 UTC (11 years, 8 months ago) by mellon
Branch: netbsd-1-3
CVS Tags: netbsd-1-3-RELEASE, netbsd-1-3-PATCH002, netbsd-1-3-PATCH001, netbsd-1-3-BETA
Changes since 1.77: +41 -15 lines
Diff to previous 1.77 (colored)

Pull rev 1.79 up from trunk (augustss)

Revision 1.79 / (download) - annotate - [select for diffs], Wed Oct 29 02:11:45 1997 UTC (11 years, 8 months ago) by augustss
Branch: MAIN
Changes since 1.78: +3 -3 lines
Diff to previous 1.78 (colored)

Fix slight glitch in last commit when AUDIO_DEBUG is on.

Revision 1.78 / (download) - annotate - [select for diffs], Wed Oct 29 02:00:20 1997 UTC (11 years, 8 months ago) by augustss
Branch: MAIN
Changes since 1.77: +39 -13 lines
Diff to previous 1.77 (colored)

Do audio attachment the right way. From Chris Demetriou.
(Maybe I'll get the hang of the configuration stuff one of these days. :-)

Revision 1.77 / (download) - annotate - [select for diffs], Sun Oct 19 07:41:56 1997 UTC (11 years, 8 months ago) by augustss
Branch: MAIN
CVS Tags: netbsd-1-3-base
Branch point for: netbsd-1-3
Changes since 1.76: +454 -41 lines
Diff to previous 1.76 (colored)

Make the audio API (almost) SunOS compatible.
The changes is to allow some limited mixer manipulation through
the audio device (instead of the mixer device).
This rendered 4 methods in audio_hw_if unused so garbage collect these.

Revision 1.76 / (download) - annotate - [select for diffs], Thu Oct 16 23:58:01 1997 UTC (11 years, 8 months ago) by is
Branch: MAIN
Changes since 1.75: +14 -1 lines
Diff to previous 1.75 (colored)

TMS320AV110 (mpeg layer 2 decoder chip) and ZBUS Melody board, which uses it.
No optionboards yet for Melody, only audio driver.
MPEG data types for audio.c

Revision 1.75 / (download) - annotate - [select for diffs], Thu Oct 16 16:41:18 1997 UTC (11 years, 8 months ago) by augustss
Branch: MAIN
Changes since 1.74: +7 -1 lines
Diff to previous 1.74 (colored)

Aignore interrupts if the device isn't open.

Revision 1.57.2.6 / (download) - annotate - [select for diffs], Wed Oct 15 05:35:48 1997 UTC (11 years, 8 months ago) by thorpej
Branch: marc-pcmcia
Changes since 1.57.2.5: +1 -3 lines
Diff to previous 1.57.2.5 (colored) to branchpoint 1.57 (colored) next main 1.58 (colored)

Update marc-pcmcia branch from trunk.

Revision 1.74 / (download) - annotate - [select for diffs], Tue Oct 14 18:43:42 1997 UTC (11 years, 8 months ago) by augustss
Branch: MAIN
CVS Tags: marc-pcmcia-base
Changes since 1.73: +1 -3 lines
Diff to previous 1.73 (colored)

Don't test for unused methods.

Revision 1.57.2.5 / (download) - annotate - [select for diffs], Tue Oct 14 10:22:04 1997 UTC (11 years, 8 months ago) by thorpej
Branch: marc-pcmcia
Changes since 1.57.2.4: +9 -8 lines
Diff to previous 1.57.2.4 (colored) to branchpoint 1.57 (colored)

Update marc-pcmcia branch from trunk.

Revision 1.73 / (download) - annotate - [select for diffs], Sat Oct 11 11:16:28 1997 UTC (11 years, 8 months ago) by mycroft
Branch: MAIN
Changes since 1.72: +3 -6 lines
Diff to previous 1.72 (colored)

GETPROPS does not indicate whether the device is currently in full-duplex
mode.  Reinstate GETFD to return this information.

Revision 1.72 / (download) - annotate - [select for diffs], Tue Oct 7 22:40:43 1997 UTC (11 years, 8 months ago) by augustss
Branch: MAIN
Changes since 1.71: +7 -3 lines
Diff to previous 1.71 (colored)

Sanity check hi/lo water mark settings better.

Revision 1.57.2.4 / (download) - annotate - [select for diffs], Sat Sep 6 18:49:43 1997 UTC (11 years, 9 months ago) by thorpej
Branch: marc-pcmcia
Changes since 1.57.2.3: +46 -34 lines
Diff to previous 1.57.2.3 (colored) to branchpoint 1.57 (colored)

Update marc-pcmcia branch from trunk.

Revision 1.71 / (download) - annotate - [select for diffs], Sat Sep 6 01:14:48 1997 UTC (11 years, 10 months ago) by augustss
Branch: MAIN
CVS Tags: thorpej-signal-base, thorpej-signal
Changes since 1.70: +46 -34 lines
Diff to previous 1.70 (colored)

Move around splaudio() to (hopefully) get rid of some rare race conditions.
Add a missing call to round_blocksize.
Add some MIDI stuff that will be used in the future.

Revision 1.57.2.3 / (download) - annotate - [select for diffs], Mon Sep 1 20:20:39 1997 UTC (11 years, 10 months ago) by thorpej
Branch: marc-pcmcia
Changes since 1.57.2.2: +7 -5 lines
Diff to previous 1.57.2.2 (colored) to branchpoint 1.57 (colored)

Update marc-pcmcia branch from trunk.

Revision 1.57.2.2 / (download) - annotate - [select for diffs], Wed Aug 27 23:29:43 1997 UTC (11 years, 10 months ago) by thorpej
Branch: marc-pcmcia
Changes since 1.57.2.1: +200 -137 lines
Diff to previous 1.57.2.1 (colored) to branchpoint 1.57 (