Earlier this month, HTC's One M9 began receiving the Android 5.1 update on AT&T. It's taken a couple of weeks longer to make its way to T-Mobile, but 5.1 is now heading to the One M9 on that carrier as well.
The update bumps the software version up to 2.7.531.6, and weighs in at 833MB; unsurprisingly, you'll need to connect to Wi-Fi in order to download and install it.
T-Mobile's release notes for the update reveal that in addition to the standard benefits that Google has baked into Android 5.1, it also includes Android anti-theft protections, along with Google Wallet support.
However, it's not clear if the update includes any patches for the massive security flaw recently revealed in the Android OS. The vulnerability, which affects all versions of Android from 2.2 onwards, can let attackers take control of a device using innocent-looking multimedia content. Google was actually given a patch to block the exploit back in April, but the slow pace of Android updates means that around 950 million devices are still believed to be unprotected.
Source: T-Mobile via Android Central