2016/8/3

implicit declaration of function 'strict_strtoul

3.x 的 driver code 拿到 4.x build 出現..
 error: implicit declaration of function 'strict_strtoul' [-Werror=implicit-function-declaration]


然後kernel source 竟然找不到 strict_strtoul

然後..http://dpdk.org/dev/patchwork/patch/1911/
strict_strtoul() was just a redefinition of kstrtoul() for a long
time. From kernel version of 3.18, strict_strtoul() will not be
defined at all. A compile time kernel version check is needed to
decide which function or macro can be used for a specific version
of kernel.

也就說..直接用 kstrtoul 就好了。

沒有留言:

張貼留言