diff options
| author | Warner Losh <imp@FreeBSD.org> | 2021-11-03 21:55:32 +0000 |
|---|---|---|
| committer | Warner Losh <imp@FreeBSD.org> | 2021-11-03 22:03:51 +0000 |
| commit | 072d5b98c4318e20248a6fbea4a5ca7c96992cac (patch) | |
| tree | 9e77c1a90a9947a8527f260f98a79e7c93ea101f /sys/dev/syscons/syscons.c | |
| parent | 6b67753488cb506f05694c5f6d2e74cf53497c54 (diff) | |
Diffstat (limited to 'sys/dev/syscons/syscons.c')
| -rw-r--r-- | sys/dev/syscons/syscons.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/dev/syscons/syscons.c b/sys/dev/syscons/syscons.c index 6a389604d3ab..6c349668410d 100644 --- a/sys/dev/syscons/syscons.c +++ b/sys/dev/syscons/syscons.c @@ -4258,6 +4258,11 @@ sc_respond(scr_stat *scp, const u_char *p, int count, int wakeup) } } +/* + * pitch is the divisor for 1.193182MHz PIT clock. By dividing 1193172 / pitch, + * we convert it back to Hz. + * duration is in ticks of 1/hz. + */ void sc_bell(scr_stat *scp, int pitch, int duration) { @@ -4277,7 +4282,7 @@ sc_bell(scr_stat *scp, int pitch, int duration) } else if (duration != 0 && pitch != 0) { if (scp != scp->sc->cur_scp) pitch *= 2; - sysbeep(1193182 / pitch, duration); + sysbeep(1193182 / pitch, SBT_1S * duration / hz); } } |
