Rules for buying a BMW:
No V8s
No M cars
No 4 cylinder turbos past 100k miles
No N54s
So what's left? Any straight 6 other than the N54. The older ones will need a bunch of refreshing but it's not too hard or expensive. N55 and B58, green light.
“No M cars”
But you bought the M car?