Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 210376
b: refs/heads/master
c: 2c4e967
h: refs/heads/master
v: v3
  • Loading branch information
Arnd Bergmann authored and Dmitry Torokhov committed Aug 29, 2010
1 parent 2917e0e commit 4f131b7
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: d9f66c1a46163c7c83411058516a69da547262f8
refs/heads/master: 2c4e9671edfef534e9726366707d64e63d44e7e6
16 changes: 8 additions & 8 deletions trunk/drivers/char/vt_ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -533,11 +533,14 @@ int vt_ioctl(struct tty_struct *tty, struct file * file,
case KIOCSOUND:
if (!perm)
goto eperm;
/* FIXME: This is an old broken API but we need to keep it
supported and somehow separate the historic advertised
tick rate from any real one */
/*
* The use of PIT_TICK_RATE is historic, it used to be
* the platform-dependent CLOCK_TICK_RATE between 2.6.12
* and 2.6.36, which was a minor but unfortunate ABI
* change.
*/
if (arg)
arg = CLOCK_TICK_RATE / arg;
arg = PIT_TICK_RATE / arg;
kd_mksound(arg, 0);
break;

Expand All @@ -553,11 +556,8 @@ int vt_ioctl(struct tty_struct *tty, struct file * file,
*/
ticks = HZ * ((arg >> 16) & 0xffff) / 1000;
count = ticks ? (arg & 0xffff) : 0;
/* FIXME: This is an old broken API but we need to keep it
supported and somehow separate the historic advertised
tick rate from any real one */
if (count)
count = CLOCK_TICK_RATE / count;
count = PIT_TICK_RATE / count;
kd_mksound(count, ticks);
break;
}
Expand Down

0 comments on commit 4f131b7

Please sign in to comment.