Ignore:
Timestamp:
Apr 9, 2006, 12:09:39 PM (19 years ago)
Author:
vladest
Message:

Latest ALSA patches
HDA patches
Patch for Intel from Rudy's
Fixes locks on NM256 chipsets
Fixes PM on Maestro3 chipsets

File:
1 edited

Legend:

Unmodified
Added
Removed
  • GPL/trunk/alsa-kernel/pci/intel8x0.c

    r70 r76  
    494494    { 0x10de, 0x00da, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE },    /* NFORCE3 */
    495495    { 0x10de, 0x00ea, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE },        /* CK8S */
     496    { 0x10de, 0x026b, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_NFORCE },        /* MCP51 */
    496497    { 0x1022, 0x746d, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL },     /* AMD8111 */
    497498    { 0x1022, 0x7445, PCI_ANY_ID, PCI_ANY_ID, 0, 0, DEVICE_INTEL },     /* AMD768 */
     
    834835    unsigned int status;
    835836    unsigned int i;
     837#ifdef TARGET_OS2
     838    int fOurIrq = FALSE;
     839#endif
    836840
    837841    status = igetdword(chip, chip->int_sta_reg);
     
    854858#endif
    855859        }
    856         return IRQ_RETVAL(status);
    857     }
     860        return IRQ_NONE/*RETVAL(status)*/;
     861    }
     862#ifdef TARGET_OS2
     863    fOurIrq = TRUE;
     864#endif
    858865
    859866    for (i = 0; i < chip->bdbars_count; i++) {
     
    865872    /* ack them */
    866873    iputdword(chip, chip->int_sta_reg, status & chip->int_sta_mask);
     874#ifdef TARGET_OS2
     875    if (fOurIrq) {
     876        //eoi_irq(irq);
     877    }
     878#endif //TARGET_OS2
    867879
    868880    return IRQ_HANDLED;
     
    11611173        runtime->hw.period_bytes_max = 64*1024;
    11621174    }
     1175#if 1 /* vladest */
    11631176    if ((err = snd_pcm_hw_constraint_integer(runtime, SNDRV_PCM_HW_PARAM_PERIODS)) < 0)
    11641177        return err;
     1178#endif
    11651179    runtime->private_data = ichdev;
    11661180    return 0;
     
    11751189    err = snd_intel8x0_pcm_open(substream, &chip->ichd[ICHD_PCMOUT]);
    11761190    if (err < 0)
     1191    {
     1192        printk("snd_intel8x0_pcm_open open error: %i\n", err);
    11771193        return err;
     1194    }
    11781195    if (chip->multi6) {
    11791196        runtime->hw.channels_max = 6;
     
    19882005                .name = "Fujitsu-Siemens D1522",        /* AD1981 */
    19892006                .type = AC97_TUNE_HP_ONLY
    1990         },
     2007        },
     2008        {
     2009            .subvendor = 0x8086,
     2010            .subdevice = 0x0104,
     2011            .name = "Intel D845GEBV2",              /* AD1981B */
     2012            .type = AC97_TUNE_HP_ONLY
     2013        },
    19912014        {
    19922015                .subvendor = 0x8086,
     
    23102333         */
    23112334        end_time = jiffies + HZ;
    2312         i = 0;
    23132335        do {
    2314             status = igetdword(chip, ICHREG(GLOB_STA)) & chip->codec_isr_bits;;
     2336            status = igetdword(chip, ICHREG(GLOB_STA)) &
     2337                chip->codec_isr_bits;
    23152338            if (status)
    23162339                break;
    23172340            mdelay(1);
    23182341            //do_delay(chip);
    2319             i++;
    2320         } while (i<100);/*(time_after_eq(end_time, jiffies));*/
     2342        } while (time_after_eq(end_time, jiffies));
    23212343
    23222344        if (! status) {
     
    24102432static int snd_intel8x0_chip_init(struct intel8x0 *chip, int probing)
    24112433{
    2412     unsigned int i;
     2434    unsigned int i, timeout;
    24132435    int err;
    24142436
     
    24282450    for (i = 0; i < chip->bdbars_count; i++)
    24292451        iputbyte(chip, ICH_REG_OFF_CR + chip->ichd[i].reg_offset, ICH_RESETREGS);
     2452    for (i = 0; i < chip->bdbars_count; i++) {
     2453        timeout = 100000;
     2454        while (--timeout != 0) {
     2455            if ((igetbyte(chip, ICH_REG_OFF_CR + chip->ichd[i].reg_offset) & ICH_RESETREGS) == 0)
     2456                break;
     2457        }
     2458        if (timeout == 0)
     2459            printk(KERN_ERR "intel8x0: reset of registers failed?\n");
     2460    }
    24302461    /* initialize Buffer Descriptor Lists */
    24312462    for (i = 0; i < chip->bdbars_count; i++)
     
    26062637    iputbyte(chip, port + ICH_REG_OFF_CR, ICH_RESETREGS);
    26072638    spin_unlock_irq(&chip->reg_lock);
    2608 
     2639#if 0
    26092640    t = stop_time.tv_sec - start_time.tv_sec;
    26102641    t *= 1000000;
    26112642    t += stop_time.tv_usec - start_time.tv_usec;
     2643#else
     2644    t = 50000; /* patch, suggested by r.ihle */
     2645#endif
    26122646    printk(KERN_INFO "%s: measured %lu usecs\n", __FUNCTION__, t);
    26132647    if (t == 0) {
Note: See TracChangeset for help on using the changeset viewer.