If you really want to contribute to Mesa you should at least have some CC++ experience, if you don’t buy yourself a book and go for it. Knowledge of OpenGL would also obviously be useful The OpenGL SuperBible is generally the most recommended book on OpenGL. Some knowledge of git will also be a must when it comes time to submitting your patches.
Ok now that we have the basics covered. The first thing I would recommend doing is signing up to the mesa-dev mailing list. Being a member on this list gives you a good insight into how the project is run and you get to see the code as its developed. You will get to see the patches that the developers submit for review. Things might not make much sense at first but it will start to come together over time.