I too have had problems with my wifi forgetting passwords. For me, what appears to work (so far) is uninstalling ATT Hotspot. If you are not rooted, you can remove it from the market but you will still have the icon to reinstall it.
While this could be one of the most useful bloat apps, it must intercept / manage the wifi password configuration file and unfortunately it is known (Google for reviews) that it does not save passwords even though that is what the app is intended to do.
Once I uninstalled this all of my passwords could be saved and I did a reboot and all passwords were retained and auto connect worked as it should.