@@ -1349,14 +1350,15 @@
static int AtaMixerIoctl(u_int cmd, u_long arg)
{
int data;
+ unsigned long flags;
switch (cmd) {
case SOUND_MIXER_READ_SPEAKER:
if (is_falcon || MACH_IS_TT) {
int porta;
- cli();
+ spin_lock_irqsave(&dmasound.lock, flags);
sound_ym.rd_data_reg_sel = 14;
porta = sound_ym.rd_data_reg_sel;
- sti();
+ spin_unlock_irqrestore(&dmasound.lock, flags);
return IOCTL_OUT(arg, porta & 0x40 ? 0 : 100);
}
break;
@@ -1367,12 +1369,12 @@
if (is_falcon || MACH_IS_TT) {
int porta;
IOCTL_IN(arg, data);
- cli();
+ spin_lock_irqsave(&dmasound.lock, flags);
sound_ym.rd_data_reg_sel = 14;
porta = (sound_ym.rd_data_reg_sel & ~0x40) |
(data < 50 ? 0x40 : 0);
sound_ym.wd_data = porta;
- sti();
+ spin_unlock_irqrestore(&dmasound.lock, flags);
return IOCTL_OUT(arg, porta & 0x40 ? 0 : 100);
}
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/