Abhishek,
Take a look at my answer to a similar query:
http://e2e.ti.com/support/embedded/tirtos/f/355/t/355673.aspx
In my code, I used some Starterware functions to set the pin registers the way I wanted them.
In others it was easier to use the HWREG macro to set a register.
Hope this helps.
Gerry Belanger