We have raptors around here so you learn sport mode and straight up.. I go straight up to dodge the attack, then up and home. You can usually fly higher than the birds are willing to go.
Most birds can't chase something that reverses and goes straight up, they need to dive or have speed...