Heat a large stock pot or dutch oven over medium high heat. Add bacon and cook until brown and crispy, about 6-8 minutes. Transfer to a paper towel-lined plate; set aside. Reserve bacon grease in the pot.
Add garlic and onion, and cook, stirring frequently, until onions have become translucent, about 2-3 minutes. Stir in corn and thyme until fragrant, about 1-2 minutes.
Whisk in flour until lightly browned, about 1 minute. Gradually whisk in milk, and cook, whisking constantly, until slightly thickened, about 1-2 minutes. Stir in potatoes.
Bring to a boil; reduce heat and simmer until potatoes are tender, about 12-15 minutes. Stir in ham, salt and pepper, to taste. If the chowder is too thick, add more milk as needed until desired consistency is reached.
Serve immediately, garnished with bacon.