From: Nicolas Dichtel Date: Fri, 21 Jul 2006 21:56:02 +0000 (-0700) Subject: [IFB] After ifb_init_one() failed, i is increased. Decrease X-Git-Tag: v2.6.18-rc3~59^2~3 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=4a9c74e5830444c1c3235848e06402c1d2ece1ea;p=linux-2.6-omap-h63xx.git [IFB] After ifb_init_one() failed, i is increased. Decrease It before entering in the loop for freeing the other ifb devices. Signed-off-by: Nicolas Dichtel Acked-by: Jamal Hadi Salim Signed-off-by: David S. Miller --- diff --git a/drivers/net/ifb.c b/drivers/net/ifb.c index 3a42afab503..43e3f33ed5e 100644 --- a/drivers/net/ifb.c +++ b/drivers/net/ifb.c @@ -271,6 +271,7 @@ static int __init ifb_init_module(void) for (i = 0; i < numifbs && !err; i++) err = ifb_init_one(i); if (err) { + i--; while (--i >= 0) ifb_free_one(i); }