2025-09-04 00:08 ftp://ftp.de.debian.org/debian/pool/main/t/tp-smapi/tp-smapi_0.45.orig.tar.gz cppcheck-options: --library=posix --library=gnu --library=bsd --inconclusive --enable=style,information --inline-suppr --template=daca2 --disable=missingInclude --suppress=unmatchedSuppression --check-library --debug-warnings --suppress=autoNoType --suppress=valueFlowBailout --suppress=bailoutUninitVar --suppress=symbolDatabaseWarning --suppress=normalCheckLevelConditionExpressions -D__GNUC__ --platform=unix64 -j4 platform: Linux-6.12.41+deb13-amd64-x86_64-with-glibc2.41 python: 3.13.5 client-version: 1.3.67 compiler: g++ (Debian 14.2.0-19) 14.2.0 cppcheck: head 2.18.0 head-info: e6e045f (2025-09-02 21:05:14 +0200) count: 6 73 elapsed-time: 0.0 0.2 head-timing-info: old-timing-info: head results: tp_smapi-0.45/thinkpad_ec.c:42:0: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] tp_smapi-0.45/thinkpad_ec.c:42:2: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] tp_smapi-0.45/hdaps.c:430:0: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] tp_smapi-0.45/hdaps.c:430:2: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] tp_smapi-0.45/tp_smapi.c:112:0: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] tp_smapi-0.45/tp_smapi.c:112:2: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] diff: 2.18.0 tp_smapi-0.45/hdaps.c:156:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_WARNING [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:204:33: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable HZ [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:235:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EIO [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:252:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_DEBUG [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:287:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EIO [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:310:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_WARNING [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:335:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_WARNING [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:362:5: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_ERR [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:404:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_WARNING [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:423:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_INFO [valueFlowBailoutIncompleteVar] head tp_smapi-0.45/hdaps.c:430:0: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] head tp_smapi-0.45/hdaps.c:430:2: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] 2.18.0 tp_smapi-0.45/hdaps.c:445:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable hdaps_users_mtx [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:493:43: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ENODATA [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:539:48: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable HZ [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:550:45: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable HZ [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:559:53: style: Parameter 'dev' can be declared as pointer to const. However it seems that 'hdaps_calibrate_store' is a callback function, if 'dev' is declared with const you might also need to cast function pointer(s). [constParameterCallback] tp_smapi-0.45/hdaps.c:695:28: note: You might need to cast the function pointer here tp_smapi-0.45/hdaps.c:559:53: note: Parameter 'dev' can be declared as pointer to const 2.18.0 tp_smapi-0.45/hdaps.c:560:35: style: Parameter 'attr' can be declared as pointer to const. However it seems that 'hdaps_calibrate_store' is a callback function, if 'attr' is declared with const you might also need to cast function pointer(s). [constParameterCallback] tp_smapi-0.45/hdaps.c:695:28: note: You might need to cast the function pointer here tp_smapi-0.45/hdaps.c:560:35: note: Parameter 'attr' can be declared as pointer to const 2.18.0 tp_smapi-0.45/hdaps.c:581:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EINVAL [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:600:46: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable HZ [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:620:9: warning: %u in format string (no. 1) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] 2.18.0 tp_smapi-0.45/hdaps.c:629:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EINVAL [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:645:9: warning: %u in format string (no. 1) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] 2.18.0 tp_smapi-0.45/hdaps.c:654:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EINVAL [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:664:22: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable THIS_MODULE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:676:14: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable hdaps_users_mtx [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:731:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_INFO [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:816:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ENOMEM [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/hdaps.c:901:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_INFO [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:114:28: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable thinkpad_ec_mutex [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:128:23: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable thinkpad_ec_mutex [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:140:6: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable thinkpad_ec_mutex [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:159:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_ERR [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:241:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EBUSY [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:278:30: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INITIAL_JIFFIES [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:315:15: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EBUSY [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:359:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ENODATA [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:388:22: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INITIAL_JIFFIES [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:408:21: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable INITIAL_JIFFIES [valueFlowBailoutIncompleteVar] head tp_smapi-0.45/thinkpad_ec.c:42:0: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] head tp_smapi-0.45/thinkpad_ec.c:42:2: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:462:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable ident [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:478:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_WARNING [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/thinkpad_ec.c:511:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_INFO [valueFlowBailoutIncompleteVar] head tp_smapi-0.45/tp_smapi.c:112:0: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] head tp_smapi-0.45/tp_smapi.c:112:2: error: failed to evaluate #if condition, undefined function-like macro invocation: KERNEL_VERSION( ... ) [preprocessorErrorDirective] 2.18.0 tp_smapi-0.45/tp_smapi.c:1151:10: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:1206:26: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PAGE_SIZE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:1221:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EINVAL [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:1247:32: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PM_EVENT_HIBERNATE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:1264:2: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_DEBUG [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:129:21: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable rtc_lock [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:1417:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_INFO [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:1491:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_INFO [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:172:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_DEBUG [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:280:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_NOTICE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:327:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_NOTICE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:350:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_NOTICE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:396:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_NOTICE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:416:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_NOTICE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:435:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_NOTICE [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:524:29: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:535:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:555:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:576:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:603:68: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable bat [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:665:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:690:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:713:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:775:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EINVAL [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:798:6: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] 2.18.0 tp_smapi-0.45/tp_smapi.c:819:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EINVAL [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:841:6: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] 2.18.0 tp_smapi-0.45/tp_smapi.c:866:3: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable KERN_ERR [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:894:11: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable EINVAL [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:914:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:936:34: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:943:34: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] 2.18.0 tp_smapi-0.45/tp_smapi.c:950:34: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TP_CONTROLLER_ROW_LEN [valueFlowBailoutIncompleteVar] DONE