NYT calls it for Markey. Pity that Morse lost but keeping Ed in the senate makes this a good night.
Unfortunately, this will certainly not be the last of Kennedy. I expect a run for governor or perhaps a primary against Warren, who does notoriously poorly in her home state.
She does poorly in general elections. Trying to primary her would be laughable after this result. If Kennedy wants to get back in the game, he should wait until a seat opens up, and even then he wouldn't necessarily win.
I doubt he'd win, but if anyone has the ego to try...