--- zzzz-none-000/linux-3.10.107/drivers/hwmon/vt1211.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/drivers/hwmon/vt1211.c 2021-02-04 17:41:59.000000000 +0000 @@ -879,6 +879,9 @@ if (err) return err; + if (val > 255) + return -EINVAL; + data->vrm = val; return count; @@ -1152,10 +1155,8 @@ int i, err; data = devm_kzalloc(dev, sizeof(struct vt1211_data), GFP_KERNEL); - if (!data) { - dev_err(dev, "Out of memory\n"); + if (!data) return -ENOMEM; - } res = platform_get_resource(pdev, IORESOURCE_IO, 0); if (!devm_request_region(dev, res->start, resource_size(res), @@ -1232,7 +1233,6 @@ static struct platform_driver vt1211_driver = { .driver = { - .owner = THIS_MODULE, .name = DRVNAME, }, .probe = vt1211_probe,