A bound on the reduction number of a primary ideal