As a point of comparison, Microsoft ships its OS across a variety of manufacturers and largely keeps it maintained across them (give or take some exceptions like enterprise environments & the like).
Even unlocked Android phones purchased independently of carriers have inconsistent lengths of support, so it doesn’t seem to be entirely a result of carriers, so…What happened here?
Do you happen to know of any brands that fall into category 2?
I just searched this up and saw that Google Pixel 6 and later phones will get updates for at least 5 years from when the device first became available on the Google Store in the US, including security, software, and may also include feature drops but I hope more people respond to your question with more brands and models.