In chronological order, I think these are the Mario games that can fit into a single canon. The others would be alternate universes (part of another canon) or what-if scenarios. I'll list them in the order of which I think they occured.
-*Yoshi's Island
-Donkey Kong
-*DK Junior
-Mario Bros.
-Super Mario Bros/ *Lost levels (both part of the same conflict).
-Super Mario Bros. 2 (USA version)
-Super Mario Bros. 3
-Super Mario World.
-Super Mario 64.
-Luigi's Mansion
-Super Mario Sunshine.
-Super Mario Galaxy.
-*Super Mario Galaxy 2
* I feel that some of these may be contradictory to the other games. Yoshi's Island, for example, seems to suggest that Mario and Luigi are from Mushroom Land, while Donkey Kong and Mario Bros. seem to suggest that they're from the "Real World". Maybe they could have somehow wound up in the real world and then ended up coming back as adults, but I think that kinda overcomplicates things.
Donkey Kong Junior potrays Mario as the antagonist, which basically contradicts Mario's heroic and friendly personality. Maybe Mario had a good reason to do it, but again, I don't think it needs to be that complicated.
The Lost Levels (Japanese Super Mario Bros. 2) was so similar to Super Mario Bros. that I think they're actually the same story; one just has different levels and some slight graphical changes.
I think Super Mario Galaxy 2 is just a more light-hearted reimagination of the first Super Mario Galaxy. At the end of Super Mario Galaxy, Rosalina did that speech about the cycle of stars being reborn. Super Mario Galaxy 2, to me, is just that cycle. Maybe it will even lead to a canon split.