PM / devfreq: event: testing the wrong variable

There is a typo here so we test "edev" but we intended to test
"edev[i]".

Fixes: f262f28c14 ('PM / devfreq: event: Add devfreq_event class')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
Dan Carpenter 2015-02-10 13:35:47 +03:00 committed by Rafael J. Wysocki
parent 9835e58ab2
commit 04a695edca

View File

@ -327,8 +327,8 @@ static int exynos_ppmu_probe(struct platform_device *pdev)
for (i = 0; i < info->num_events; i++) { for (i = 0; i < info->num_events; i++) {
edev[i] = devm_devfreq_event_add_edev(&pdev->dev, &desc[i]); edev[i] = devm_devfreq_event_add_edev(&pdev->dev, &desc[i]);
if (IS_ERR(edev)) { if (IS_ERR(edev[i])) {
ret = PTR_ERR(edev); ret = PTR_ERR(edev[i]);
dev_err(&pdev->dev, dev_err(&pdev->dev,
"failed to add devfreq-event device\n"); "failed to add devfreq-event device\n");
goto err; goto err;