diff options
author | Trent Piepho <xyzzy@speakeasy.org> | 2007-08-18 21:54:49 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-10-09 21:06:00 -0400 |
commit | 19453bc18848e842a9743fcc40707e6fb19ae92b (patch) | |
tree | 84497c94e348de301a8cf9be7cb9e659bd19a54f /drivers/media/video/cx88/cx88-alsa.c | |
parent | 5a5b3b5d4fe3acdd9fb73162023422a9ee0e56f3 (diff) |
V4L/DVB (6068): cx88-alsa: Use pci_dev->revision
The revision is part of the pci_dev struct, so there is no need to read it in.
Stop storing the revision and latency in the chip struct, since they're never
used after being printed out when the driver loads.
linux/pci.h wasn't included. It was getting picked up something else,
probably cx88.h, but this file uses struct pci_dev so it should include pci.h.
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/cx88/cx88-alsa.c')
-rw-r--r-- | drivers/media/video/cx88/cx88-alsa.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/media/video/cx88/cx88-alsa.c b/drivers/media/video/cx88/cx88-alsa.c index 3e293da0f70b..8d19d33c8b32 100644 --- a/drivers/media/video/cx88/cx88-alsa.c +++ b/drivers/media/video/cx88/cx88-alsa.c | |||
@@ -28,6 +28,7 @@ | |||
28 | #include <linux/device.h> | 28 | #include <linux/device.h> |
29 | #include <linux/interrupt.h> | 29 | #include <linux/interrupt.h> |
30 | #include <linux/dma-mapping.h> | 30 | #include <linux/dma-mapping.h> |
31 | #include <linux/pci.h> | ||
31 | 32 | ||
32 | #include <asm/delay.h> | 33 | #include <asm/delay.h> |
33 | #include <sound/driver.h> | 34 | #include <sound/driver.h> |
@@ -60,7 +61,6 @@ struct cx88_audio_dev { | |||
60 | 61 | ||
61 | /* pci i/o */ | 62 | /* pci i/o */ |
62 | struct pci_dev *pci; | 63 | struct pci_dev *pci; |
63 | unsigned char pci_rev,pci_lat; | ||
64 | 64 | ||
65 | /* audio controls */ | 65 | /* audio controls */ |
66 | int irq; | 66 | int irq; |
@@ -667,6 +667,7 @@ static int __devinit snd_cx88_create(struct snd_card *card, | |||
667 | snd_cx88_card_t *chip; | 667 | snd_cx88_card_t *chip; |
668 | struct cx88_core *core; | 668 | struct cx88_core *core; |
669 | int err; | 669 | int err; |
670 | unsigned char pci_lat; | ||
670 | 671 | ||
671 | *rchip = NULL; | 672 | *rchip = NULL; |
672 | 673 | ||
@@ -711,13 +712,12 @@ static int __devinit snd_cx88_create(struct snd_card *card, | |||
711 | } | 712 | } |
712 | 713 | ||
713 | /* print pci info */ | 714 | /* print pci info */ |
714 | pci_read_config_byte(pci, PCI_CLASS_REVISION, &chip->pci_rev); | 715 | pci_read_config_byte(pci, PCI_LATENCY_TIMER, &pci_lat); |
715 | pci_read_config_byte(pci, PCI_LATENCY_TIMER, &chip->pci_lat); | ||
716 | 716 | ||
717 | dprintk(1,"ALSA %s/%i: found at %s, rev: %d, irq: %d, " | 717 | dprintk(1,"ALSA %s/%i: found at %s, rev: %d, irq: %d, " |
718 | "latency: %d, mmio: 0x%llx\n", core->name, devno, | 718 | "latency: %d, mmio: 0x%llx\n", core->name, devno, |
719 | pci_name(pci), chip->pci_rev, pci->irq, | 719 | pci_name(pci), pci->revision, pci->irq, |
720 | chip->pci_lat,(unsigned long long)pci_resource_start(pci,0)); | 720 | pci_lat, (unsigned long long)pci_resource_start(pci,0)); |
721 | 721 | ||
722 | chip->irq = pci->irq; | 722 | chip->irq = pci->irq; |
723 | synchronize_irq(chip->irq); | 723 | synchronize_irq(chip->irq); |