I worked as a front desk clerk. We were not really supposed to accept tips, but the pay is crappy so I never refused one. It's not so much the tip that probably scored you the upgrade, but that you are the kind of person who thinks you should treat the front desk staff well, plus an upgrade was available.