Skip to contentSkip to conversation

device_create_drvdata missing on older kernels

DISCUSSION Eliot Blennerhassett 3 participants 4 messages Jul 30, 2008

lore
Share & tools
lore
#0 lore raw

I could not compile current git. (Error on acore/init.c)

Adding this to adriver.h fixed it for me. I'm not sure if this is the correct general fix?

#ifndef CONFIG_SND_HAS_DEVICE_CREATE_DRVDATA
#define device_create_drvdata(c,d,m,p,s,n) device_create((c),(d),(m),(s),(n)) #endif

(My kernel 2.6.24-19-generic)

Signature · 3 lines
--
Eliot Blennerhassett
www.audioscience.com
#1 lore raw
Quoted 8 lines · Eliot Blennerhassett

I could not compile current git. (Error on acore/init.c)

Adding this to adriver.h fixed it for me. I'm not sure if this is the correct general fix?

#ifndef CONFIG_SND_HAS_DEVICE_CREATE_DRVDATA
#define device_create_drvdata(c,d,m,p,s,n) device_create((c),(d),(m),(s),(n)) #endif

It looks like a correct fix. Applied. Thanks.

Jaroslav

-----
Jaroslav Kysela <[email protected]>
Linux Kernel Sound Maintainer
ALSA Project, Red Hat, Inc.

#2 lore raw
In reply to Eliot Blennerhassett

At Wed, 30 Jul 2008 15:00:34 +1200,

Quoted 9 lines · Eliot Blennerhassett

I could not compile current git. (Error on acore/init.c)

Adding this to adriver.h fixed it for me. I'm not sure if this is the correct general fix?

#ifndef CONFIG_SND_HAS_DEVICE_CREATE_DRVDATA
#define device_create_drvdata(c,d,m,p,s,n) device_create((c),(d),(m),(s),(n)) #endif

It works right now for vanilla, but not for linux-next, unfortunately. device_create_drvdata() is gone again in the next kernel. Long live the function.

Could you check it's fixed on the snapshot tarball?
http://ftp.kernel.org/pub/linux/kernel/people/tiwai/snapshot/

Takashi