There are several causes for this problem, pilot error, effects of high speed flight, incorrectly connected controls, and various coupling forces on the aircraft.
Pilot error is the most common cause of control reversal. In unusual attitudes it is not uncommon for the pilot to become disoriented and start feeding in incorrect control movements in order to regain level flight. This is particularily common when using helment mounted display systems, which introduce graphics that remain steady in the pilot's view, notably when using a particular form of attitude display known as an inside-out display.
Incorrectly connected controls is another common cause of this problem. It is a recurring problem after maintenance on aircraft, notably homebuilt designs that are being flown for the first time after some minor work. However it is not entirely uncommon on commercial aircraft, and has been the cause of several near-accidents.
Another version of the problem occurs when the amount of airflow over the wing becomes great enough that the force generated by the ailerons is enough to twist the wing itself. For instance when the aileron is defelected upwards in order to make that wing move down, the wing twists in the opposite direction. The net result is that the airflow is direct down instead of up, meaning that the wing moves upward, opposite of what was expected. This form of control reversal is often lumped in with a number of "high speed" effects as compressibility.
This problem was notorious on the Supermarine Spitfire. A series of upgrades to the wing structure helped eliviated the problem to some degree, but improvements in engine power typically offset it. This continued until a new internal design was introduced on the late-war Mark XIV version that cured it entirely.
Finally the Wright Brothers suffered yet another form of control reversal, one normally referred to as adverse yaw. In their pre-Flier gliders they continued to encounter a problem where the glider would start to turn one direction, then suddenly reverse direction and spin into the ground. They eventually cured the problem by adding a moving rudder system, now found on all aircraft.
The root cause of the problem was dynamic. Warping the wing did what was expected in terms of lift, thereby rolling the plane, but also had an unexpectedly large effect on drag. The result was that the upward-moving wing was dragged backwards, yawing the glider. If this yaw was violent enough the additional speed on the lower wing as it was driven forward would make it generate more lift, and reverse the direction of the roll.