That is actually the precise point I was making: socketed bayonet was useful, but was not the primary defense of infantry squares against cavalry. Primary defense was always firepower. In fact, in pike-and-shot formations, shot protected the pikes from cavalry, while pikes protected the shot...