Gentoo Archives: gentoo-dev

From: Daniel Drake <dsd@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] Trouble with sys fs
Date: Fri, 09 Sep 2005 07:58:38
Message-Id: 4321401B.50106@gentoo.org
In Reply to: [gentoo-dev] Trouble with sys fs by Kormos Matej
1 Kormos Matej wrote:
2 > Hello!
3 > I am beginner with Gentoo and absolute rookie about writing drivers, but I
4 > am trying to write one.
5 > I hope I have choose the right mailing list for my questions :-)
6
7 You should try the kernel-newbies mailing list, or the linux kernel mailing list.
8
9 > I have encountered following error:
10 > I have a simple char driver. Everything is working like should be, I can
11 > compile functional driver, which after inserting into system appears in the
12 > sys file system.
13 > But when I add this lines in order to create my own attribute in directory
14 > of my module:
15 >
16 > #include <linux/sysfs.h>
17 > #include <linux/kobject.h>
18 >
19 > sysfs_create_file(&device->cdev.kobj,&pid_sfs);
20 >
21 > I can not insert module. Kernel says something like this:
22 > Error inserting module -1: unknown symbol sysfs_create_file
23
24 sysfs_create_file is only available to GPL modules. Is yours
25 MODULE_LICENSE("GPL")?
26
27 Daniel
28
29 --
30 gentoo-dev@g.o mailing list