Combining research related work and dissertation topic en route to PhD
It sounds like it's time for you to have a chat with one or more possible advisors to start exploring possible research areas.  One of the most important roles a PhD advisor plays is helping the student find and define a research topic.

Looking in my crystal ball at your future, here's what I see: a very small chance of being able to kill two birds with one stone.  It could happen, if the stars all align in a very fortunate way; but please don't count on it.  For thesis research, you have to be free to follow your nose.  You can't afford to box yourself in.

You may want to consider a somewhat different approach from the self-funding idea, and apply for a teaching or research assistantship (and quit the job), or get your present company (or some other company) to pay at least your tuition, with an agreement that you will work for them for x years after graduating.