Messages in this thread | | | Date | Wed, 20 Sep 2006 09:56:08 -0700 | From | "Randy.Dunlap" <> | Subject | Re: drivers/char/random.c exported interfaces |
| |
On Mon, 18 Sep 2006 09:27:59 -0400 Robin Getz wrote:
> It says in the comments in drivers/char/random.c that: > > * Exported interfaces ---- input > * ============================== > * > * The current exported interfaces for gathering environmental noise > * from the devices are: > * > * void add_input_randomness(unsigned int type, unsigned int code, > * unsigned int value); > * void add_interrupt_randomness(int irq); > * > * add_input_randomness() uses the input layer interrupt timing, as well as > * the event type information from the hardware. > * > [..snip..] > > If "add_input_randomness" is an "Exported interface" why is it not an > exported symbol? > > If I build drivers/input/input.ko, I get the error: > > ** Warning: "add_input_randomness" [drivers/input/input.ko] undefined!
Yep, confirmed (after disabling CONFIG_VT and CONFIG_USB_HID) (on 2.6.18).
On x86_64, I get both of these:
WARNING: "kobject_get_path" [drivers/input/input.ko] undefined! WARNING: "add_input_randomness" [drivers/input/input.ko] undefined!
With USB_HID enabled, I also get:
LD .tmp_vmlinux1 drivers/built-in.o: In function `hidinput_disconnect': (.text+0x10741e): undefined reference to `input_unregister_device' drivers/built-in.o: In function `hidinput_connect': (.text+0x107526): undefined reference to `input_allocate_device' drivers/built-in.o: In function `hidinput_connect': (.text+0x107547): undefined reference to `input_free_device' drivers/built-in.o: In function `hidinput_connect': (.text+0x1091a2): undefined reference to `input_register_device' drivers/built-in.o: In function `hidinput_connect': (.text+0x1091f2): undefined reference to `input_register_device' drivers/built-in.o: In function `hidinput_hid_event': (.text+0x10942f): undefined reference to `input_event' drivers/built-in.o: In function `hidinput_hid_event': (.text+0x1094bd): undefined reference to `input_event' drivers/built-in.o: In function `hidinput_hid_event': (.text+0x109507): undefined reference to `input_event' drivers/built-in.o: In function `hidinput_hid_event': (.text+0x109577): undefined reference to `input_event' drivers/built-in.o: In function `hidinput_hid_event': (.text+0x10959b): undefined reference to `input_event' drivers/built-in.o:(.text+0x1095dc): more undefined references to `input_event' follow
so using INPUT=m has a few problems.
ISTM that we should at least fix the first 2 (by EXPORTing them). or we don't allow INPUT=m.
You want to send a patch?
--- ~Randy - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |