During the first Elemental War, rips opened between the planes in numbers that have not been seen before or since. Think about the planar rips that we are currently dealing with in the Blackstone area, except on a much larger scale.
Through some of these tears, an area called the Void of Corruption was able to implant itself into the elemental planes. Now, there are a couple important distinctions that I want to make here.
First, the concept of void as we know it and the void of corruption are two different things. Void itself is literal nothingness. To say that something is void is to say that it is not there. For example, we might describe the inside of an empty bottle as a void. Definitionally, nothingness cannot do anything, for it does not exist. Void of corruption, though, clearly does exist, as it has proven able to taint the elemental planes. Thus, void as a concept and void of corruiption are two different things.
Second, magical void and void of corruption are two different things. Magical void is the power of the void that is used in formal magic casting to do such things as forge someone's spirit or destroy a formal magic. This type of void has useful purposes, and does not taint that which it comes into contact with, at least insofar as anyone has been able to observe. Void of corruption, on the other hand, is a malevolent force which taints everything that it comes into contact with.
The elemental plane most strongly affected by the void of corruption was the plane of chaos. This is why necromancy calls upon chaos. It is in fact not calling upon the power of chaos itself, but instead using chaos as a conduit to channel the power of the void of corruption. Now, it remains possible that certain necromantic spells do not channel the void of corruption, but we cannot accurately distinguish which ones those are at present.
Chaos was not the only plane affected by the void of corruption. Death and darkness were heavily affected as well. I am sure most adventurers have noticed that chaos, death, and shadow elementals tend to be hostile far more often than order, life, and light elementals are. This is because of the void of corruption seeping into their planes and driving the elementals living there insane.
Of the elemental planes, the most stable is time, followed by the physical planes, and then the immaterial planes. During the elemental war, the icon of time saw that if left unchecked, the void of corruption would seep through all the planes and destroy them. Thus, the icon of time enveloped the eight immaterial planes within time, which was strong enough to ward off further entry by the void of corruption.
As an aside, this actually makes me wonder if the breakdown of the time stream in the Blackstone area due to the activity of Temporal Morgis and the other incarnations of him has something to do with all the planar rips we have been seeing.
Moving on, the icon of time also created a force to battle corruption, a force of healing so powerful that it could actually heal corruption. The icon of time took a little bit of each one of the elements, mixed them all together, and channeled them through the physical plane of stone, or earth, which is solid and thus the most stable physical plane, in order to create what we today call earth magic. Earth magic exists for the purpose of battling the void of corruption.
I welcome any further questions on The First Elemental War.