Kidney Pain

hello,i am using antibiotics for my prostate infection, I took antibiotics for 30 days after that doctor prescribed me again those antibiotic for 45 days but after 2 month there was little bit discomfort in my prostate ,,,last night I had a unbearable pain in my left kidney after ultrasound doctor told me,,kidney ki nali mein kachra hy,nikal jaye,pani ziada piyoo and give me some painkillers now my question is are these the antibiotics that are hurting my kidney ? Taking antibiotics for longer period affects kidnysy? should I discontinue remaining antibiotics? or continue