Roth IRA income limits

I have a Roth IRA and several sources of income and I came perilously close to the 2021 Roth IRA contribution upper income limit.  Based on my current forecast, I will exceed the limit for 2022 but I won't really know until around November when my year-end forecast will be mostly actual data.  Since I have already funded the Roth IRA for 2022, and I'm over 59 1/2, how will my contributions be treated if I end up exceeding the upper income limit.