{"id":"CVE-2025-40224","summary":"hwmon: (cgbc-hwmon) Add missing NULL check after devm_kzalloc()","details":"In the Linux kernel, the following vulnerability has been resolved:\n\nhwmon: (cgbc-hwmon) Add missing NULL check after devm_kzalloc()\n\nThe driver allocates memory for sensor data using devm_kzalloc(), but\ndid not check if the allocation succeeded. In case of memory allocation\nfailure, dereferencing the NULL pointer would lead to a kernel crash.\n\nAdd a NULL pointer check and return -ENOMEM to handle allocation failure\nproperly.","modified":"2026-03-20T12:43:13.600525Z","published":"2025-12-04T15:31:16.193Z","database_specific":{"cna_assigner":"Linux","osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/40xxx/CVE-2025-40224.json"},"references":[{"type":"WEB","url":"https://git.kernel.org/stable/c/240b82b86a091c1aa49d951d4467425420a081a0"},{"type":"WEB","url":"https://git.kernel.org/stable/c/a09a5aa8bf258ddc99a22c30f17fe304b96b5350"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/40xxx/CVE-2025-40224.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-40224"},{"type":"PACKAGE","url":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","events":[{"introduced":"08ebc9def79fc0c4dbb6ecc39263006e3f98b750"},{"fixed":"240b82b86a091c1aa49d951d4467425420a081a0"},{"fixed":"a09a5aa8bf258ddc99a22c30f17fe304b96b5350"}]}],"database_specific":{"source":"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2025-40224.json"}},{"package":{"name":"Kernel","ecosystem":"Linux"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"6.15.0"},{"fixed":"6.17.6"}]}],"database_specific":{"source":"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2025-40224.json"}}],"schema_version":"1.7.5"}