Instead of flying through London have you considered flying through Dublin and taking advantage of US pre-clearance at DUB?
I understand this is a non-starter if you actually wanted to visit London.
And not sure there is a BA or BA code share EDI-DUB flight. Though there might be an Aer Lingus one from which you can get some Avios points, maybe not tier points.