It's now working in both Windows 7 and Windows XP.
Previously I was building the BSP in Debug mode. I changed it to Release Mode.
I ensured that KITL is disabled in OS Design and disabled KITL in eboot also when the device boots.
In Windows XP, it gets connected just like that.
In Windows 7, Windows update detected the device and installed drivers for it. It didn't get connected the first time (or maybe I didn't wait for few more minutes). The second time also Windows update installed drivers and got connected. From then, its getting connected every time in 2 minutes. No installation of drivers after that.
I think, due to some timing issues, Active Sync is not getting connected in Debug mode.
As per the ARM A8 User Guide, the reason why KITL and Active Sync can't be together at the same time is,
The USB RNDIS KITL transport uses a dedicated set of routines to communicate with the kernel. It does not use the standard USB function or OTG stacks. It is critical that all USB drivers be disabled when USB RNDIS KITL is in use. The USB RNDIS KITL implementation automatically disables the standard USB drivers when KITL is active.
Thanks to Keshava and Valter for the continuous help!