
Dear Peter Barada,
In message 4D87D9B0.1080102@logicpd.com you wrote:
Can you please fix these, and resubmit?
Updated patch attached (Thunderbird munched tabs)...
Thanks.
Also, do you happen to have a test case that can be used show the problem in the existing code, and to test the patch?
No, I don't have a testcase off hand (IIRC hashtable size is dependent on size of u-boot and amount of RAM), from my original email:
I was able to verify both the problem and that your fix fixes it. Tested on "qong".
Added a Tested-by: Wolfgang Denk wd@denx.de
From: Peter Barada peter.barada@logicpd.com Date: Mon, 21 Mar 2011 19:01:57 -0500 Subject: [PATCH] Fix hashtable to properly handle deletion.
Use negative used value to mark deleted entry. Search keeps probing past deleted entries. Adding an entry uses first deleted entry when it hits end of probe chain.
Initially found that "ramdiskimage" and "preboot" collide modulus 347, causing "preboot" to be inserted at idx 190, "ramdiskimage" at idx 191. Previous to this fix when "preboot" is deleted, "ramdiskimage" is orphaned.
Signed-off-by: Peter Barada peter.barada@logicpd.com
diff --git a/lib/hashtable.c b/lib/hashtable.c index 9f069c0..fcdb53c 100644 --- a/lib/hashtable.c +++ b/lib/hashtable.c
Applied, thanks.
Best regards,
Wolfgang Denk