Skip to contentSkip to conversation

__devinit in sound/oss/es1371.c

PATCH New [email protected] 1 participant 1 message Nov 13, 2004 Sound

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 __devinit in sound/oss/es1371.c

It is forbidden to refer from __devinit to __init.
(Unless one argues that in the given situation hotplugging is actually impossible. Too ugly.)
However, es1371_probe() is __devinit and referred to __initdata initvol[] and to __init src_init().

sound/oss/es1371.c +2 -2
diff -uprN -X /linux/dontdiff a/sound/oss/es1371.c b/sound/oss/es1371.c
@@ -637,7 +637,7 @@ static void set_dac2_rate(struct es1371_
 
 /* --------------------------------------------------------------------- */
 
-static void __init src_init(struct es1371_state *s)
+static void __devinit src_init(struct es1371_state *s)
 {
         unsigned int i;
 
@@ -2754,7 +2754,7 @@ MODULE_LICENSE("GPL");
 static struct initvol {
 	int mixch;
 	int vol;
-} initvol[] __initdata = {
+} initvol[] __devinitdata = {
 	{ SOUND_MIXER_WRITE_LINE, 0x4040 },
 	{ SOUND_MIXER_WRITE_CD, 0x4040 },
 	{ MIXER_WRITE(SOUND_MIXER_VIDEO), 0x4040 },