Heat a Dutch oven or soup pot over medium heat. Add the olive oil and diced onion, celery, and carrots. Sauté, stirring frequently, for 6-7 minutes or until the onion starts to turn translucent.
Add the garlic and sauté for 1-2 minutes or until fragrant.
Stir in the cubed ham, potatoes, broth, and salt. Increase the heat to medium-high and bring to a simmer. Cook uncovered for 13-15 minutes or until the potatoes are fork-tender. Stir in the black pepper.
After the soup has simmered for about 5 minutes, get started on the roux. Melt the butter in a medium saucepan over medium heat. Whisk in the flour and cook for 1-2 minutes until the mixture starts to sizzle and get puffy.
Whisk the milk into the roux and cook for 4-5 minutes until it thickens to lightly coat the back of a spoon. Remove the pan from the heat and whisk in the shredded cheese until smooth. The cheese sauce will thicken even more after adding the cheese.
Pour the cheese roux into the soup. Stir well until smooth and cook for 3-4 minutes, until well combined and thickened. Season the soup to taste with salt and pepper, and enjoy it hot!