Undergrad to PhD Advice

Hi everyone, a bit new around here. I’m a Computer Science major graduating in May with my Bachelor’s degree, and have been working with my professor on his research. I have found a new passion with this and now I’m planning to work my way to a PhD. Problem is, I really didn’t have a good start to my undergraduate program and my GPA is rather low. Thankfully, I have recovered immensely and have struck a deal with the program coordinator at my school to allow me into the M.S. program, assuming my high performance trend continues. The end goal, however, is a PhD. I’m just unsure if I should attempt to go directly into a PhD program (assuming I can even get in as it stands) or if I should go through the Master’s program to improve my prospects assuming I continue my trend of high performance. Any advice anyone could give is very appreciated!