aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/oxygen/oxygen_lib.c
diff options
context:
space:
mode:
authorClemens Ladisch <clemens@ladisch.de>2008-05-13 03:19:53 -0400
committerJaroslav Kysela <perex@perex.cz>2008-05-19 07:19:15 -0400
commitc13650079ba3bed1c0bdd9bf4a13274be7676ff6 (patch)
tree12e62edd8d57884b29dea1536f0731ba0303ede5 /sound/pci/oxygen/oxygen_lib.c
parentd023dc0aa25d6a4f7dd0d109179a2077d22a7ad2 (diff)
[ALSA] oxygen: add symbol for I/O space size
Remove another magic number - add a symbol for the size of the PCI I/O range. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Diffstat (limited to 'sound/pci/oxygen/oxygen_lib.c')
-rw-r--r--sound/pci/oxygen/oxygen_lib.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/pci/oxygen/oxygen_lib.c b/sound/pci/oxygen/oxygen_lib.c
index 6e3879527dcd..60bc15917349 100644
--- a/sound/pci/oxygen/oxygen_lib.c
+++ b/sound/pci/oxygen/oxygen_lib.c
@@ -173,7 +173,7 @@ static void oxygen_proc_read(struct snd_info_entry *entry,
173 int i, j; 173 int i, j;
174 174
175 snd_iprintf(buffer, "CMI8788\n\n"); 175 snd_iprintf(buffer, "CMI8788\n\n");
176 for (i = 0; i < 0x100; i += 0x10) { 176 for (i = 0; i < OXYGEN_IO_SIZE; i += 0x10) {
177 snd_iprintf(buffer, "%02x:", i); 177 snd_iprintf(buffer, "%02x:", i);
178 for (j = 0; j < 0x10; ++j) 178 for (j = 0; j < 0x10; ++j)
179 snd_iprintf(buffer, " %02x", oxygen_read8(chip, i + j)); 179 snd_iprintf(buffer, " %02x", oxygen_read8(chip, i + j));
@@ -455,7 +455,7 @@ int oxygen_pci_probe(struct pci_dev *pci, int index, char *id,
455 } 455 }
456 456
457 if (!(pci_resource_flags(pci, 0) & IORESOURCE_IO) || 457 if (!(pci_resource_flags(pci, 0) & IORESOURCE_IO) ||
458 pci_resource_len(pci, 0) < 0x100) { 458 pci_resource_len(pci, 0) < OXYGEN_IO_SIZE) {
459 snd_printk(KERN_ERR "invalid PCI I/O range\n"); 459 snd_printk(KERN_ERR "invalid PCI I/O range\n");
460 err = -ENXIO; 460 err = -ENXIO;
461 goto err_pci_regions; 461 goto err_pci_regions;