The HUGE misconception with ending the war in Iraq is Obama taking credit for ending said war. Facts are pesky things, especially when they prove a statement FALSE.
The U.S.–Iraq Status of Forces Agreement-official name: Agreement Between the United States of America and the Republic of Iraq On the Withdrawal of United States Forces from Iraq and the Organization of Their Activities during Their Temporary Presence in Iraq
All US troops had to be out of Iraq by December 31, 2011.
Ironically, even publications like the Huffington Post reluctantly gave Bush credit for ending the war, but now-a-days you will not hear them correct Obama when he claims HE ended the war; fact is, Obama even tried to engage the Iraqies into letting the US stay longer, to which they said no.
Bush Ended War in Iraq Here