[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-devel] [patch #6463] IGMP - Adding Random Delay
From: |
Ed Kerekes |
Subject: |
[lwip-devel] [patch #6463] IGMP - Adding Random Delay |
Date: |
Mon, 17 Mar 2008 01:37:19 +0000 |
User-agent: |
Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2.0.50727) |
Follow-up Comment #1, patch #6463 (project lwip):
Frederic,
For some reason your email asking me to file the bug report didn't get
delivered until AFTER you filed this report. I would have been happy to help
out - it looks like your plate is full!
1. I have no problem with moving the random call inside the igmp_start_timer
routine. In fact I now think it belongs there -that way the other call will
also benefit from the random delay.
2. As far as a "global" solution for a random number generator goes - I'm not
using the AUTOIP, DHCP, or PPP - so I didn't notice they used random. I think
I got too specific by adding the "max" parameter in my suggestion. How about
just a macro that would work exactly like the standard c rand() function.
(Same approach as MEMCPY()). Maybe call the macro RAND() or LWIP_RAND()? Then
just do the specifice scaling to max in the igmp_start_timer routine
(following the macro call). That way users would have the option to use the
same routine for tricks to save cycles.
Then (later, when there is time) the same macro could be used in those other
lwip places. Just a suggestion...
Ed
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/patch/?6463>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/