--- zzzz-none-000/linux-3.10.107/drivers/video/backlight/da9052_bl.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/drivers/video/backlight/da9052_bl.c 2021-02-04 17:41:59.000000000 +0000 @@ -125,8 +125,9 @@ props.type = BACKLIGHT_RAW; props.max_brightness = DA9052_MAX_BRIGHTNESS; - bl = backlight_device_register(pdev->name, wleds->da9052->dev, wleds, - &da9052_backlight_ops, &props); + bl = devm_backlight_device_register(&pdev->dev, pdev->name, + wleds->da9052->dev, wleds, + &da9052_backlight_ops, &props); if (IS_ERR(bl)) { dev_err(&pdev->dev, "Failed to register backlight\n"); return PTR_ERR(bl); @@ -147,12 +148,11 @@ wleds->brightness = 0; wleds->state = DA9052_WLEDS_OFF; da9052_adjust_wled_brightness(wleds); - backlight_device_unregister(bl); return 0; } -static struct platform_device_id da9052_wled_ids[] = { +static const struct platform_device_id da9052_wled_ids[] = { { .name = "da9052-wled1", .driver_data = DA9052_TYPE_WLED1, @@ -165,6 +165,7 @@ .name = "da9052-wled3", .driver_data = DA9052_TYPE_WLED3, }, + { }, }; static struct platform_driver da9052_wled_driver = { @@ -173,7 +174,6 @@ .id_table = da9052_wled_ids, .driver = { .name = "da9052-wled", - .owner = THIS_MODULE, }, };