Ensures that this value is not greater than the specified maximum.
this value if it's less than or equal to the maximum or the maximum otherwise.