How can I connect Surface pro with iMac 27"?

I have late 2009 iMac 27" and I ve been using it as external monitor for MBP (connect through Mini display port and its cable.).

And now I got Surface pro which has same mini display port, but it does not work at all. Anyone has any idea? Should I intall something on Surface to recognize iMac as display? or iMac's target display mode only works with Ones from Apple?