aboutsummaryrefslogtreecommitdiff
path: root/sys/amd64/include
diff options
context:
space:
mode:
authorYoshihiro Takahashi <nyan@FreeBSD.org>2005-05-28 13:40:27 +0000
committerYoshihiro Takahashi <nyan@FreeBSD.org>2005-05-28 13:40:27 +0000
commitf7965374d480700aefd71e8a8fd7fedf0185115c (patch)
treeb4c961108927bd3ebb21c9e9a0071fc4d5d5f326 /sys/amd64/include
parent7329f580c8c7e14fbec8bbba59a88b62d27d3405 (diff)
Notes
Diffstat (limited to 'sys/amd64/include')
-rw-r--r--sys/amd64/include/timerreg.h12
1 files changed, 5 insertions, 7 deletions
diff --git a/sys/amd64/include/timerreg.h b/sys/amd64/include/timerreg.h
index 34e59e07200d..0ab7d40510a7 100644
--- a/sys/amd64/include/timerreg.h
+++ b/sys/amd64/include/timerreg.h
@@ -54,13 +54,11 @@
#define timer_spkr_release() \
release_timer2()
-static __inline void
-spkr_set_pitch(u_int16_t pitch)
-{
-
- outb(TIMER_CNTR2, pitch & 0xff);
- outb(TIMER_CNTR2, pitch >> 8);
-}
+#define spkr_set_pitch(pitch) \
+ do { \
+ outb(TIMER_CNTR2, (pitch) & 0xff); \
+ outb(TIMER_CNTR2, (pitch) >> 8); \
+ } while(0)
#endif /* _KERNEL */