I would echo what @Kevin Slater said. I understand that you meant no harm but if you had done this to me, I would be startled by it. Just as you have a personal life to protect, so does the companion. Even though you only disclosed that you knew his real name, if he is a bright and discerning companion, he logically is going to wonder what else you have researched. He may wonder if you have been watching or following him, if you are a stalker etc... Remember, at this point you are a stranger to him. If someone discloses to you that they know more about you than they wanted you to know, it can feel ominous. If he didn't have a normal nickname, then I agree with the others who recommend just asking the companion what he would like to be called. I would just chalk this up to a lesson learned for future encounters.