aboutsummaryrefslogtreecommitdiffstats
path: root/sound/oss
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2009-03-23 19:36:16 -0400
committerTakashi Iwai <tiwai@suse.de>2009-03-23 19:36:16 -0400
commit9fb5430c3d6e96a74fd4406dbe7608f36abb9987 (patch)
tree1c990d9f2f91f6daabbf2de957bea744dd2bcb71 /sound/oss
parent4c5ecb7e59662a76754efdd41c6ed4415e6e9840 (diff)
parente5bf48437370f3fc603e2dce12e8d3fb1a6a2457 (diff)
Merge branch 'topic/oss-fix' into for-linus
Diffstat (limited to 'sound/oss')
-rw-r--r--sound/oss/ad1848.c4
-rw-r--r--sound/oss/dmabuf.c2
-rw-r--r--sound/oss/pas2_card.c4
-rw-r--r--sound/oss/pss.c12
-rw-r--r--sound/oss/sequencer.c3
5 files changed, 11 insertions, 14 deletions
diff --git a/sound/oss/ad1848.c b/sound/oss/ad1848.c
index 7cf9913a47b2..d12bd98a37ba 100644
--- a/sound/oss/ad1848.c
+++ b/sound/oss/ad1848.c
@@ -280,7 +280,7 @@ static void wait_for_calibration(ad1848_info * devc)
280 while (timeout > 0 && (ad_read(devc, 11) & 0x20)) 280 while (timeout > 0 && (ad_read(devc, 11) & 0x20))
281 timeout--; 281 timeout--;
282 if (ad_read(devc, 11) & 0x20) 282 if (ad_read(devc, 11) & 0x20)
283 if ( (devc->model != MD_1845) || (devc->model != MD_1845_SSCAPE)) 283 if ((devc->model != MD_1845) && (devc->model != MD_1845_SSCAPE))
284 printk(KERN_WARNING "ad1848: Auto calibration timed out(3).\n"); 284 printk(KERN_WARNING "ad1848: Auto calibration timed out(3).\n");
285} 285}
286 286
@@ -2107,7 +2107,7 @@ int ad1848_control(int cmd, int arg)
2107 switch (cmd) 2107 switch (cmd)
2108 { 2108 {
2109 case AD1848_SET_XTAL: /* Change clock frequency of AD1845 (only ) */ 2109 case AD1848_SET_XTAL: /* Change clock frequency of AD1845 (only ) */
2110 if (devc->model != MD_1845 || devc->model != MD_1845_SSCAPE) 2110 if (devc->model != MD_1845 && devc->model != MD_1845_SSCAPE)
2111 return -EINVAL; 2111 return -EINVAL;
2112 spin_lock_irqsave(&devc->lock,flags); 2112 spin_lock_irqsave(&devc->lock,flags);
2113 ad_enter_MCE(devc); 2113 ad_enter_MCE(devc);
diff --git a/sound/oss/dmabuf.c b/sound/oss/dmabuf.c
index 1e90d769b62e..1bfcf7e88546 100644
--- a/sound/oss/dmabuf.c
+++ b/sound/oss/dmabuf.c
@@ -439,7 +439,7 @@ int DMAbuf_sync(int dev)
439 DMAbuf_launch_output(dev, dmap); 439 DMAbuf_launch_output(dev, dmap);
440 adev->dmap_out->flags |= DMA_SYNCING; 440 adev->dmap_out->flags |= DMA_SYNCING;
441 adev->dmap_out->underrun_count = 0; 441 adev->dmap_out->underrun_count = 0;
442 while (!signal_pending(current) && n++ <= adev->dmap_out->nbufs && 442 while (!signal_pending(current) && n++ < adev->dmap_out->nbufs &&
443 adev->dmap_out->qlen && adev->dmap_out->underrun_count == 0) { 443 adev->dmap_out->qlen && adev->dmap_out->underrun_count == 0) {
444 long t = dmabuf_timeout(dmap); 444 long t = dmabuf_timeout(dmap);
445 spin_unlock_irqrestore(&dmap->lock,flags); 445 spin_unlock_irqrestore(&dmap->lock,flags);
diff --git a/sound/oss/pas2_card.c b/sound/oss/pas2_card.c
index 25f3a22c52ee..7f377ec3486d 100644
--- a/sound/oss/pas2_card.c
+++ b/sound/oss/pas2_card.c
@@ -156,9 +156,7 @@ static int __init config_pas_hw(struct address_info *hw_config)
156 * 0x80 156 * 0x80
157 */ , 0xB88); 157 */ , 0xB88);
158 158
159 pas_write(0x80 159 pas_write(0x80 | (joystick ? 0x40 : 0), 0xF388);
160 | joystick?0x40:0
161 ,0xF388);
162 160
163 if (pas_irq < 0 || pas_irq > 15) 161 if (pas_irq < 0 || pas_irq > 15)
164 { 162 {
diff --git a/sound/oss/pss.c b/sound/oss/pss.c
index 16ed06950dc1..16517a5a1301 100644
--- a/sound/oss/pss.c
+++ b/sound/oss/pss.c
@@ -457,10 +457,9 @@ static void pss_mixer_reset(pss_confdata *devc)
457 } 457 }
458} 458}
459 459
460static int set_volume_mono(unsigned __user *p, int *aleft) 460static int set_volume_mono(unsigned __user *p, unsigned int *aleft)
461{ 461{
462 int left; 462 unsigned int left, volume;
463 unsigned volume;
464 if (get_user(volume, p)) 463 if (get_user(volume, p))
465 return -EFAULT; 464 return -EFAULT;
466 465
@@ -471,10 +470,11 @@ static int set_volume_mono(unsigned __user *p, int *aleft)
471 return 0; 470 return 0;
472} 471}
473 472
474static int set_volume_stereo(unsigned __user *p, int *aleft, int *aright) 473static int set_volume_stereo(unsigned __user *p,
474 unsigned int *aleft,
475 unsigned int *aright)
475{ 476{
476 int left, right; 477 unsigned int left, right, volume;
477 unsigned volume;
478 if (get_user(volume, p)) 478 if (get_user(volume, p))
479 return -EFAULT; 479 return -EFAULT;
480 480
diff --git a/sound/oss/sequencer.c b/sound/oss/sequencer.c
index 5c215f787ca9..c79874696bec 100644
--- a/sound/oss/sequencer.c
+++ b/sound/oss/sequencer.c
@@ -212,7 +212,6 @@ int sequencer_write(int dev, struct file *file, const char __user *buf, int coun
212{ 212{
213 unsigned char event_rec[EV_SZ], ev_code; 213 unsigned char event_rec[EV_SZ], ev_code;
214 int p = 0, c, ev_size; 214 int p = 0, c, ev_size;
215 int err;
216 int mode = translate_mode(file); 215 int mode = translate_mode(file);
217 216
218 dev = dev >> 4; 217 dev = dev >> 4;
@@ -285,7 +284,7 @@ int sequencer_write(int dev, struct file *file, const char __user *buf, int coun
285 { 284 {
286 if (!midi_opened[event_rec[2]]) 285 if (!midi_opened[event_rec[2]])
287 { 286 {
288 int mode; 287 int err, mode;
289 int dev = event_rec[2]; 288 int dev = event_rec[2];
290 289
291 if (dev >= max_mididev || midi_devs[dev]==NULL) 290 if (dev >= max_mididev || midi_devs[dev]==NULL)