Tarmac Delay is a DOT enforced framework, so that if an aircraft gets to 3 hour delay on domestic, 4 hours on international flights, before taking off, passengers should be given the option to disembark (a different terms is used in the DOT's jargon set...) rather than being "held hostage". Airlines risk a fine unless they can document they gave passengers the option to leave at this point. A few exceptions apply, for example if it's not safe to disembark passengers. There is no compensation for delays, EC261 style, in a USA context, however this BA flight may have been eligible for EC261 as a European airline. Airlines should provide water / snack on tarmac delays but are not required to offload baggage. I have been the victim of this at DCA, where the offloading process at exactly 4 hours then meant that the crew were out of hours, the flight was cancelled, no compensation - whereas there was some evidence that we could have taken off at 4 hrs 30 mins if we maintained "ready" status. So I am not at all convinced this is good consumer protection overall.
But as you can see DOT is fairly strict in applying its rules if someone complains.