diff options
Diffstat (limited to 'sound/isa')
-rw-r--r-- | sound/isa/msnd/msnd_midi.c | 2 | ||||
-rw-r--r-- | sound/isa/sb/emu8000.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/sound/isa/msnd/msnd_midi.c b/sound/isa/msnd/msnd_midi.c index cb9aa4c4edd0..4be562b2cf21 100644 --- a/sound/isa/msnd/msnd_midi.c +++ b/sound/isa/msnd/msnd_midi.c | |||
@@ -162,7 +162,7 @@ int snd_msndmidi_new(struct snd_card *card, int device) | |||
162 | err = snd_rawmidi_new(card, "MSND-MIDI", device, 1, 1, &rmidi); | 162 | err = snd_rawmidi_new(card, "MSND-MIDI", device, 1, 1, &rmidi); |
163 | if (err < 0) | 163 | if (err < 0) |
164 | return err; | 164 | return err; |
165 | mpu = kcalloc(1, sizeof(*mpu), GFP_KERNEL); | 165 | mpu = kzalloc(sizeof(*mpu), GFP_KERNEL); |
166 | if (mpu == NULL) { | 166 | if (mpu == NULL) { |
167 | snd_device_free(card, rmidi); | 167 | snd_device_free(card, rmidi); |
168 | return -ENOMEM; | 168 | return -ENOMEM; |
diff --git a/sound/isa/sb/emu8000.c b/sound/isa/sb/emu8000.c index 96678d5d3834..751762f1c59a 100644 --- a/sound/isa/sb/emu8000.c +++ b/sound/isa/sb/emu8000.c | |||
@@ -393,8 +393,6 @@ size_dram(struct snd_emu8000 *emu) | |||
393 | 393 | ||
394 | while (size < EMU8000_MAX_DRAM) { | 394 | while (size < EMU8000_MAX_DRAM) { |
395 | 395 | ||
396 | size += 512 * 1024; /* increment 512kbytes */ | ||
397 | |||
398 | /* Write a unique data on the test address. | 396 | /* Write a unique data on the test address. |
399 | * if the address is out of range, the data is written on | 397 | * if the address is out of range, the data is written on |
400 | * 0x200000(=EMU8000_DRAM_OFFSET). Then the id word is | 398 | * 0x200000(=EMU8000_DRAM_OFFSET). Then the id word is |
@@ -414,7 +412,9 @@ size_dram(struct snd_emu8000 *emu) | |||
414 | /*snd_emu8000_read_wait(emu);*/ | 412 | /*snd_emu8000_read_wait(emu);*/ |
415 | EMU8000_SMLD_READ(emu); /* discard stale data */ | 413 | EMU8000_SMLD_READ(emu); /* discard stale data */ |
416 | if (EMU8000_SMLD_READ(emu) != UNIQUE_ID2) | 414 | if (EMU8000_SMLD_READ(emu) != UNIQUE_ID2) |
417 | break; /* we must have wrapped around */ | 415 | break; /* no memory at this address */ |
416 | |||
417 | size += 512 * 1024; /* increment 512kbytes */ | ||
418 | 418 | ||
419 | snd_emu8000_read_wait(emu); | 419 | snd_emu8000_read_wait(emu); |
420 | 420 | ||