I believe that the American government made its mistake in being so strongly against Ho Chi Minh in the first place. Of course, this is easy to say in hindsight.
As can be seen in the thaw between China and the US in the early 1970s, it was not impossible for America to get along with communist countries. A communist country that had not been completely alienated by the US might well be somewhat friendly to the US, particularly as a way to keep the Soviets from being able to dominate it.
If the US had realized that Ho was strongly nationalistic in addition to being a communist, they would not have had to fear that Vietnam would be dominated by the Soviets or China. They could have then had a decent relationship with a communist Vietnam. This is what has ended up happening anyway. Surely it could have been achieved without all the horrors of a war.