Two men who were seen "encouraging violence" when disorder broke out at a hotel housing asylum seekers have been jailed.