Alright, first of all, you cannot "sell your soul" to anyone. A soul isn't even yours to sell. That's like selling the president's daughter. Souls belong to the one that created them, whatever that is in your own belief. You cannot sell what does not belong to you. Your soul is YOU. And you belong to your creator. Unless your creator decides to sell you, you're not going anywhere. Make sense?
What we do is one of two things. We can dedicate ourselves, which is similar to dedicating yourself to the service of a King. It is a relationship of give and take, respect and honor, and generally is done with a deity.
Contracts do exist within ceremonial magick, it is necessary. Just like lawyers need their paperwork to make all agreements clear. Contracts are usually something simple--you give me this and I'll give you that. It's a one time deal. But when dealings are over and the ceremony has ended, many beings are extremely particular about the way a ceremonial magician says goodbye. A ritual of having the spirit depart in some way is often necessary, especially when you haven't worked with said spirit enough to form a more casual relationship. Formality is key to keeping them happy or at least you safe.
Secondly, what is a "devil"? There are thousands of infernal beings existent. If you are referring to a higher being of the Judeo-Christian mythology that is seen in a negative light, there is Sammael, Satan, and in recent times (Michael Ford for example) working with a "Lucifer" archetype. Then you can even go further and some work with the Sumerian Enki. So what "devil" do you speak of? Learn your facts first. Ask your boyfriend questions. If he just called to "the devil" then he could have contacted one of countless beings and that makes matters quite difficult.
What can occur, and what is more likely the case, is that your boyfriend practiced evocation using some grimoire (might be best to find out) to call on an infernal being. He was not experienced in magick practice, had no prior knowledge of strengthening his own spirit to be capable of handling the presence of a strong spirit, how to banish it, etc. and it decided to lash out at him for his stupidity. Such beings do not like their time wasted and some of them can be extremely aggressive, especially when the one practicing the ceremonial magick demonstrates ignorance or disrespect in any way.
What you need to do is find out the details of what he did. If he did something legitamate (and not something he saw on a tv show or read in a work of fiction) then you would need to find a REAL ceremonial magician to evoke that being once again the proper way and redress the situation. Or you can do the proper studying and do it yourself.
The other option is to go to the other side and evoke a celestial being to remove the influence and break any binds. The problem with that is that celestial beings are just as picky about the experience level of the practitioner and can be just as vindictive if not more so if the one that evokes them shows disrespect or hasn't done their homework in proper evocation.
Another possibility is that evocation has done harm to his health. You see, there are many reasons why evocation is considered "advanced" and only to be done when experienced. One of the main reasons this is the case, is not just because you're inviting a being you may not be capable of controlling directly in front of you, but also because you need to be mentally, emotionally, and spiritually prepared to handle such a venture. The possible damage that can be caused from jumping into advanced magick without the knowledge and strength can be quite noticeable and is not incapable of making someone show signs of severe depression or neurotic tendencies. Once this occurs, the person needs to back peddle and study the right way. Have him read the If they are too far gone to do so...well, that is why we all say magick can be dangerous.
I believe you should read this