Linux Kernel - Data definition has no type or storage class -
i working on linux kernel 3.4, , have following code:
/* proximity sensor calibration values */ unsigned int als_kadc; export_symbol(als_kadc); static int __init parse_tag_als_calibration(const struct tag *tag) { als_kadc = tag->u.als_kadc.kadc; return 0; } __tagtable(atag_als, parse_tag_als_calibration);
but when build it, gives me following error:
warning: data definition has no type or storage class [enabled default]
yes, warning, forbidden warning, , being treated error. warning point following line in code:
export_symbol(als_kadc);
can me solve problem?
thank you.
ok. figured out problem: missing include module.h
so, added code file:
#include <linux/module.h>
this fixed problem, because export_symbol defined in header file.
Comments
Post a Comment