Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 16176
b: refs/heads/master
c: 28bcbdd
h: refs/heads/master
v: v3
  • Loading branch information
James Courtier-Dutton authored and Jaroslav Kysela committed Jan 3, 2006
1 parent ed8874c commit ad2a074
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 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: ccadc3e38b72629fdfd1290343fdb11813dfecc2
refs/heads/master: 28bcbdddaffcb2ccf08d06db7cecf047ec66057d
15 changes: 9 additions & 6 deletions trunk/sound/pci/emu10k1/io.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,15 +130,18 @@ int snd_emu10k1_spi_write(struct snd_emu10k1 * emu,
unsigned int reset, set;
unsigned int reg, tmp;
int n, result;
if (emu->card_capabilities->ca0108_chip) {
reg=0x3c; /* PTR20, reg 0x3c */
} else {
return 1; /* For other cards types the SPI register is currently unknown. */
if (emu->card_capabilities->ca0108_chip)
reg = 0x3c; /* PTR20, reg 0x3c */
else {
/* For other chip types the SPI register
* is currently unknown. */
return 1;
}
if (data > 0xffff) return 1; /* Only 16bit values allowed */
if (data > 0xffff) /* Only 16bit values allowed */
return 1;

tmp = snd_emu10k1_ptr20_read(emu, reg, 0);
reset = (tmp & ~0x3ffff) | 0x20000; /* Set xxx20000 */
reset = (tmp & ~0x3ffff) | 0x20000; /* Set xxx20000 */
set = reset | 0x10000; /* Set xxx1xxxx */
snd_emu10k1_ptr20_write(emu, reg, 0, reset | data);
tmp = snd_emu10k1_ptr20_read(emu, reg, 0); /* write post */
Expand Down

0 comments on commit ad2a074

Please sign in to comment.