Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 154535
b: refs/heads/master
c: 9ea5ca7
h: refs/heads/master
i:
  154533: 71b4ce2
  154531: 7cb1020
  154527: a745686
v: v3
  • Loading branch information
Jiri Slaby authored and Takashi Iwai committed Jun 29, 2009
1 parent 8e6b8b4 commit bbe6432
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 14 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: 580c9d373ce7ccfbc5227e985fca761f8f039af3
refs/heads/master: 9ea5ca75a2aebb7172094a7d77acf6ff7600cc56
16 changes: 3 additions & 13 deletions trunk/sound/oss/mpu401.c
Original file line number Diff line number Diff line change
Expand Up @@ -926,31 +926,21 @@ static struct midi_operations mpu401_midi_operations[MAX_MIDI_DEV];
static void mpu401_chk_version(int n, struct mpu_config *devc)
{
int tmp;
unsigned long flags;

devc->version = devc->revision = 0;

spin_lock_irqsave(&devc->lock,flags);
if ((tmp = mpu_cmd(n, 0xAC, 0)) < 0)
{
spin_unlock_irqrestore(&devc->lock,flags);
tmp = mpu_cmd(n, 0xAC, 0);
if (tmp < 0)
return;
}
if ((tmp & 0xf0) > 0x20) /* Why it's larger than 2.x ??? */
{
spin_unlock_irqrestore(&devc->lock,flags);
return;
}
devc->version = tmp;

if ((tmp = mpu_cmd(n, 0xAD, 0)) < 0)
{
if ((tmp = mpu_cmd(n, 0xAD, 0)) < 0) {
devc->version = 0;
spin_unlock_irqrestore(&devc->lock,flags);
return;
}
devc->revision = tmp;
spin_unlock_irqrestore(&devc->lock,flags);
}

int attach_mpu401(struct address_info *hw_config, struct module *owner)
Expand Down

0 comments on commit bbe6432

Please sign in to comment.