backlight: pandora_bl: Drop unneeded ENOMEM error message

Core code already prints detailed information about failure of memory
allocation.

Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20240305-backlight-probe-v2-7-609b0cf24bde@linaro.org
Signed-off-by: Lee Jones <lee@kernel.org>
This commit is contained in:
Krzysztof Kozlowski 2024-03-05 09:12:02 +01:00 committed by Lee Jones
parent c9128ed7b9
commit b49c1caca5

View file

@ -114,10 +114,8 @@ static int pandora_backlight_probe(struct platform_device *pdev)
u8 r;
priv = devm_kmalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL);
if (!priv) {
dev_err(&pdev->dev, "failed to allocate driver private data\n");
if (!priv)
return -ENOMEM;
}
memset(&props, 0, sizeof(props));
props.max_brightness = MAX_USER_VALUE;