I've found that my Raspberry Pi2's HDMI port only works if there's something attached to it when the RPi initially boots. If it boots with nothing attached, and I later attach a monitor, nothing shows up on the monitor.
My application is headless, but occasionally I want to attach a monitor to do debugging, and in those cases having to reboot the RPi risks losing debugging information.
How do I configure the RPi to either keep the HDMI port "turned on" even when nothing's connected, or continuously poll the HDMI port and enable the driver when it finds something there?