[alsa-devel] EMU-1212m "no Audiodock - no firmware" patch

Takashi Iwai tiwai at suse.de
Thu Nov 22 18:17:25 CET 2012


At Thu, 22 Nov 2012 02:18:47 +0400,
oeai wrote:
> 
> Aloha!
> 
> i've been posting about my problem earlier, but i decided to DIY
> 
> the problem was that when going up from suspend the firmware for 
> additional card (that i don't have) was trying to load,
>   -but there's no card
> - sorry, i'm gonna check few more thousand times
> that caused my cpu to load insanely

Right now I fixed a few bugs regarding the firmware loading.
It should have been improved by that.  Take a look at my recent posts
  [PATCH 7/8] ALSA: emu10k1: cache emu1010 firmware
and
  [PATCH 8/8] ALSA: emu10k1: don't update firmware during suspend/resume


> so in the patch i've changed few more strings for debugging
> 
> but actually the one (but not the only) bug
> is here
> 
> *** 728,739 ****
> 
> !        if (reg & EMU_HANA_OPTION_DOCK_OFFLINE) {
> 
> --- 729,740 ----
> 
> !         if (reg & !EMU_HANA_OPTION_DOCK_OFFLINE) {
> 
> the thing is in the  "!"EMU_HANA_OPTION_DOCK_OFFLINE -> then the firmware should be loaded.
> 
> and to debug some errors if something i've put the one more else state so if no audiodock - it could continue to load config
> 
> *** 777,784 ****
>    			/* Unmute all. Default is muted after a firmware load */
>    			snd_emu1010_fpga_write(emu, EMU_HANA_UNMUTE, EMU_UNMUTE);
>    		}
>    	}
> ! 	snd_printk(KERN_INFO "emu1010: firmware thread stopping\n");
>    	return 0;
>    }
>    
> --- 778,790 ----
>    			/* Unmute all. Default is muted after a firmware load */
>    			snd_emu1010_fpga_write(emu, EMU_HANA_UNMUTE, EMU_UNMUTE);
>    		}
> + 		else if ((reg & 0x3f) == 0x15)
> + 		{
> + 			snd_printk(KERN_INFO "emu1212m: trying to load config emu_hana_fpga_config");
> + 			snd_emu1010_fpga_write(emu, EMU_HANA_FPGA_CONFIG,0x02);
> + 		}
>    	}
> ! 	snd_printk(KERN_INFO "emu1010: emu dock firmware thread stopping\n");
>    	return 0;
>    }
>    
> ***************
> 
> then i've commented the power_down for audiodock - it should be in other place, but as i'm 1212m user - it works for me - you know.
> 
> 
> *** 841,847 ****
>    	outl(0x0005a000, emu->port + HCFG);
>    
>    	/* Disable 48Volt power to Audio Dock */
> ! 	snd_emu1010_fpga_write(emu, EMU_HANA_DOCK_PWR, 0);
>    
>    	/* ID, should read & 0x7f = 0x55. (Bit 7 is the IRQ bit) */
>    	snd_emu1010_fpga_read(emu, EMU_HANA_ID, &reg);
> --- 847,853 ----
>    	outl(0x0005a000, emu->port + HCFG);
>    
>    	/* Disable 48Volt power to Audio Dock */
> ! 	/*snd_emu1010_fpga_write(emu, EMU_HANA_DOCK_PWR, 0);*/
>    
>    	/* ID, should read & 0x7f = 0x55. (Bit 7 is the IRQ bit) */
>    	snd_emu1010_fpga_read(emu, EMU_HANA_ID, &reg);
> ***************

Hmm.  It's because you have no dock?
What happens if you don't change this?


> and here i've changed that the emu_model was firstly enabled and then ecard - since i don't know what's the ecard i thought that it is a second module of my emu card.

This should be harmless.  ecard is set only to Emu APS card, and
exclusive with EMU 1x1x & co.

What are other essentially required changes?

Do both Emu1010b and Emu1212 have the same PCI SSID?  That sucks.
I see you set ca_cardbus_chip=1 in the card entry.  Is it mandatory?

Last but not least, please use "diff -up" for creating a patch in the
unified diff format.


thanks,

Takashi


More information about the Alsa-devel mailing list