]> git.ipfire.org Git - people/ms/u-boot.git/commitdiff
Fix hash table deletion to prevent lost entries
authorPeter Barada <peter.barada@logicpd.com>
Mon, 21 Mar 2011 23:05:20 +0000 (19:05 -0400)
committerWolfgang Denk <wd@denx.de>
Tue, 22 Mar 2011 21:43:04 +0000 (22:43 +0100)
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>
Tested-by: Wolfgang Denk <wd@denx.de>

No differences found