Subject: Oops in IFB

From: Nicolas DICHTEL <[email-masked]>
Date: Thu, 20 Jul 2006 15:33:28 +0200

Hi,

When there is no memory left for creating all IFB devices (requesting
by user), a oops happens on the system.
Please find enclosed a patch to solve this.

Regards,
Nicolas

[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 <[email-masked]>
--- a/drivers/net/ifb.c	2006-07-20 15:16:31.923529050 +0200
+++ b/drivers/net/ifb.c	2006-07-20 15:17:36.370188249 +0200
@@ -271,6 +271,7 @@
 	for (i = 0; i < numifbs && !err; i++)
 		err = ifb_init_one(i); 
 	if (err) { 
+		i--;
 		while (--i >= 0)
 			ifb_free_one(i);
 	}