On the host side, everthing involves USB hubs. When a status change indicates a newly connected device, the driver on the host side gets busy with enumeration.
The first thing the host does is to reset the port. This makes sure that the new device is connected and enabled and will respond on USB address 0. If nothing weird happens, we go to the next stage.
The host sends a SETUP packet asking for a device descriptor. This is done solely to determine the correct maximum packet size for the control endpoint. The host only cares about the first 8 bytes of the descriptor. If there is trouble with this, the host will retry up to 3 times
The host performs another reset. It may start all over asking for the device descriptor if it thinks it only got part of it the first time. It is now set up to be sure it is able to receive the whole thing. The reset is needed for some badly programmed devices that are confused by this.
Tom's Computer Info / tom@mmto.org