wwh20610 at cmsu2.cmsu.edu
Sat Jun 25 23:39:24 PDT 2005
On Sun, 19 Jun 2005 18:35:09 -0400, Robert Connolly wrote:
> Hi. I tried to build the pseudo_random/frandom patch on
> linux-2.6.12.rc6-mm1, and while the patch applied cleanly there is an
> undefined refference to "class_simple_create" and
> The new kernel has removed drivers/base/class_simple.c and replaced it
> with linux/drivers/base/class.c.
> I had to modify three lines in drivers/char/frandom.c to get it to build:
> - static struct class_simple *frandom_class; + static struct class
> - frandom_class = class_simple_create(THIS_MODULE, "frandom"); +
> frandom_class = class_create(THIS_MODULE, "frandom");
> - class_simple_device_add(frandom_class, +
> I sent linux-2.6.12-pseudo_random-1.patch to patches@ so it can be tested
> in advance.. it should apply and work whenever the 2.6.12 kernel is
> BTW, if you are using linux-2.6.12-rc6-mm1, the pseudo_random patch needs
> to be applied before the rc6 and mm1 patches or else some parts won't
I attempted an application of the patch to linux-188.8.131.52 with 1 hunk failed out of 2 with random.c. I edited random.c by hand.
Ended up keeping:
static struct class_simple *frandom_class;
frandom_class = class_simple_create(THIS_MODULE, "frandom");
The kernel build didn't like class, class_create, and class_device_create.
More information about the hlfs-dev