From 631cfa7d9e49f58bfcda9e5a834abb08d1eb005b Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Mon, 15 Aug 2005 23:44:23 +0000 Subject: * cx88-alsa.c: - Some fixups. Still incomplete. * cx88-core.c: - New error message. - spaces replaced by tabs. Signed-off-by: Mauro Carvalho Chehab --- linux/drivers/media/video/cx88/cx88-alsa.c | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) (limited to 'linux/drivers/media/video/cx88/cx88-alsa.c') diff --git a/linux/drivers/media/video/cx88/cx88-alsa.c b/linux/drivers/media/video/cx88/cx88-alsa.c index 062ea54e3..d962856c6 100644 --- a/linux/drivers/media/video/cx88/cx88-alsa.c +++ b/linux/drivers/media/video/cx88/cx88-alsa.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-alsa.c,v 1.7 2005/08/15 01:49:36 mchehab Exp $ + * $Id: cx88-alsa.c,v 1.8 2005/08/15 23:44:23 mchehab Exp $ * * Support for audio capture * PCI function #1 of the cx2388x. @@ -641,11 +641,11 @@ static snd_kcontrol_new_t snd_cx88_capture_source = { ****************************************************************************/ /* - * PCI ID Table + * PCI ID Table - 14f1:8801 and 14f1:8811 means function 1: Audio + * Only boards with eeprom and byte 1 at eeprom=1 have it */ struct pci_device_id cx88_audio_pci_tbl[] = { - {0x14f1,0x8800,PCI_ANY_ID,PCI_ANY_ID,0,0,0}, {0x14f1,0x8801,PCI_ANY_ID,PCI_ANY_ID,0,0,0}, {0x14f1,0x8811,PCI_ANY_ID,PCI_ANY_ID,0,0,0}, {0, } @@ -731,6 +731,21 @@ static int __devinit snd_cx88_create(snd_card_t *card, struct pci_dev *pci, chip->irq = -1; spin_lock_init(&chip->reg_lock); +#if 0 + if ((err = pci_request_regions(pci, "CX88 audio")) < 0) { + kfree(chip); + pci_disable_device(pci); + return err; + } + chip->mmio = ioremap_nocache(pci_resource_start(pci, 0), + pci_resource_len(pci, 0)); + if (!chip->mmio) { + snd_bt87x_free(chip); + snd_printk(KERN_ERR "cannot remap io memory\n"); + return -ENOMEM; + } +#endif + core = cx88_core_get(chip->pci); if (NULL == core) { err = -EINVAL; @@ -739,7 +754,7 @@ static int __devinit snd_cx88_create(snd_card_t *card, struct pci_dev *pci, } chip->core = core; #if 1 /* Should be tested if it is wright */ - chip->dig_rate=32000; + chip->dig_rate=48000; #endif #if 1 /* From cx88-mpeg.c */ @@ -763,6 +778,7 @@ static int __devinit snd_cx88_create(snd_card_t *card, struct pci_dev *pci, } cx_set(MO_PCI_INTMSK, core->pci_irqmask); #endif + /* print pci info */ pci_read_config_byte(pci, PCI_CLASS_REVISION, &chip->pci_rev); pci_read_config_byte(pci, PCI_LATENCY_TIMER, &chip->pci_lat); -- cgit v1.2.3