net_sched: sfq: add optional RED on top of SFQ
[linux-2.6-microblaze.git] / include / net / red.h
index baab385..28068ec 100644 (file)
@@ -199,7 +199,8 @@ static inline void red_set_parms(struct red_parms *p,
        p->Scell_log    = Scell_log;
        p->Scell_max    = (255 << Scell_log);
 
-       memcpy(p->Stab, stab, sizeof(p->Stab));
+       if (stab)
+               memcpy(p->Stab, stab, sizeof(p->Stab));
 }
 
 static inline int red_is_idling(const struct red_vars *v)