Au1xxx sound registration and power management
PATCH 1/1 Au1xxx sound registration and power management
Hello,
here a patch to support device registration and power management for the au1xxx ALSA driver.
Ciao,
Rodolfo
Signature · 4 lines
GNU/Linux Solutions e-mail: [email protected] Linux Device Driver [email protected] Embedded Systems [email protected] UNIX programming phone: +39 349 2432127
arch/mips/au1000/common/platform.c +28 -0
@@ -88,6 +88,31 @@ static struct platform_device au1xxx_eth#endif #endif +#if defined(CONFIG_SND_AU1X00 ) +/* AC97 controller */ +static struct resource au1xxx_snd_resources[] = { + [0 ] = { + .name ="snd-base" , + .start =AC97C_BASE , + .end =AC97C_BASE +AC97_IOSIZE -1 , + .flags =IORESOURCE_MEM , + }, + [1 ] = { + .name ="snd-irq" , + .start =AU1000_AC97C_INT , + .end =AU1000_AC97C_INT , + .flags =IORESOURCE_IRQ , + }, +}; + +static struct platform_device au1xxx_snd_device = { + .name ="au1xxx-snd" , + .id =-1 , + .num_resources =ARRAY_SIZE (au1xxx_snd_resources), + .resource = au1xxx_snd_resources, +}; +#endif +/* OHCI (USB full speed host controller) */ static struct resource au1xxx_usb_ohci_resources[] = { [0 ] = {
@@ -376,6 +401,9 @@ #if defined(CONFIG_SOC_AU1000) || \ &au1xxx_eth1_device,#endif #endif +#if defined(CONFIG_SND_AU1X00 ) + &au1xxx_snd_device, +#endif &au1xxx_usb_ohci_device, &au1x00_pcmcia_device, #ifdef CONFIG_FB_AU1100
include/asm-mips/mach-au1x00/au1000.h +3 -0
@@ -1600,6 +1600,9 @@ #define SYS_CPUPLL 0xB190#define SYS_AUXPLL 0xB1900064/* AC97 Controller */ +#define AC97C_BASE AC97_PHYS_ADDR +#define AC97_IOSIZE 0x14 +#define AC97C_CONFIG 0xB0000000#define AC97C_RECV_SLOTS_BIT 13#define AC97C_RECV_SLOTS_MASK (0x3ff << AC97C_RECV_SLOTS_BIT)
sound/mips/au1x00.c +126 -43
250 lines not on this page · raw message
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Alsa-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/alsa-devel
At Thu, 20 Jul 2006 09:37:00 +0200,
Quoted 5 lines · Rodolfo Giometti
Hello,
here a patch to support device registration and power management for the au1xxx ALSA driver.
Thanks for the patch.
Would you mind to split this to several patches? Namely,
- addition of new resources in arch/mips/*
- move to platform_device
- addition of PM
(Since we have a separate ALSA-kernel tree from linux tree, it's easier for us to keep the changes in arch/ and sound/ separately.)
I'm afraid that snd_au1000_free() still releases the ac97 resource, which looks now like a static one. Is it intended behavior?
Also, au1000_ac97_config could be better in struct snd_au1000 rather than a static variable.
Takashi
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV