Pinking is detonation, which means that fuel is spontaneously igniting in the chamber.
Normally the air fuel mixture should ignite at the spark from the plug and the flame should spread evenly through the chamber. When you are getting pinking it's because the fuel is igniting at the edges of the chamber before the flamehas spread to that part of the chamber. Its normally caused by hot spots in the chamber. Detonation occurs after the spark and engines can handle a certain amount of detonation. It is normally sensed by the knock sensor and the ECU will retard the ignition timing to eliminate it.
It is often confused with pre ignition which is when the fuel ignites in the chamber before the spark and is much more damaging to engines, normally even one incident of pre ignition will mean costly engine repairs.