Edmund is a very complicated character, and he is certainly not a villain on par with Iago, for example. He is relentlessly ambitious, willing to do anything to get what he wants, and he must constantly struggle against the fact that he is illegitimate. It is clear from his soliloquy in Act I, Scene 2 that he plans not to allow his status to get in the way of what he feels his talents deserve:
Thou, nature, art my goddess; to thy law
My services are bound. Wherefore should I
Stand in the plague of custom, and permit
The curiosity of nations to deprive me,
For that I am some twelve or fourteen moonshines
Lag of a brother?
He is a relentless schemer, and his plot is responsible for the destruction of many of the characters in the play, but by the end, he shows signs of remorse. As he is dying, he tries to rescind his order to have Lear and Cordelia killed (too late, in Cordelia's case) and he confesses to Edgar that he knows that what he did was wrong, and that he knew Edgar intended no disloyalty to their father. From the ending, it could be argued that Edmund is not purely evil, but a man driven to commit evil deeds, in part, by the circumstances of his birth.
It should be noted, however, that a man who tried to transcend the circumstances of his birth in Shakespeare's time was viewed as upsetting the natural order of things. He would not have been viewed as sympathetically then as he might be now, in a society that makes few distinctions about legitimacy of birth. Indeed, it is his desire to upset the natural order that causes a great deal of suffering in the play.