From: Pawel O. <p.o...@sa...> - 2009-07-07 10:55:07
|
This bug caused the release function being called on the first uninitialized window, instead of starting with the last successfully initialized one. Reviewed-by: Marek Szyprowski <m.s...@sa...> Reviewed-by: Kyungmin Park <kyu...@sa...> Signed-off-by: Pawel Osciak <p.o...@sa...> diff --git a/drivers/video/s3c-fb.c b/drivers/video/s3c-fb.c index bb63c07..ff0b1a3 100644 --- a/drivers/video/s3c-fb.c +++ b/drivers/video/s3c-fb.c @@ -926,7 +926,7 @@ static int __devinit s3c_fb_probe(struct platform_device *pdev) ret = s3c_fb_probe_win(sfb, win, &sfb->windows[win]); if (ret < 0) { dev_err(dev, "failed to create window %d\n", win); - for (; win >= 0; win--) + for ( win = win - 1; win >= 0; win--) s3c_fb_release_win(sfb, sfb->windows[win]); goto err_ioremap; } |