Pain pills, abused or not, are taken the world over for legitimate reasons, so not to worry so much. Kidney infection has nothing to do with your drug use. Alcohol is at the top of the list for goofing up the liver... pills are waaaay down from that. When the gall bladder is removed, THAT can create digestive troubles for some people, so you should Google proper after-care for that absent organ.
About the only thing those pain killers can do is create a little ulcer sometimes, mainly because pills of any kind, including aspirin, will create an overly acidic environment for the stomach lining. There are treatments for ulcers, your doc can look into it. But I think the gall bladder being taken out is probably the main reason you're uncomfortable.
You did more good for your body by cutting lose your bad habit than anything that might have developed as a result of any addiction. A few body pains, a sensitive tummy, and typical aging may be bothering you rather more these days, especially on account of you're not covering up the natural order of things anymore.
I'm not sure anyone can give you a straight answer to your question. There are far too many variables, including how much you took, the capacity of your liver to detoxify, how your liver was functioning at the time you started the drugs, your genes, and a lot of other things.
The good thing to keep in mind is that the liver is one of the few organs in the body to be able to take quite a beating and be able to regenerate a large portion of itself. The big thing is to be 'good' to your system/body now and don't backslide.