Colombo: Umpires warned England batsman Kevin Pietersen twice for changing stance to attempt a switch hit during the second Test against Sri Lanka on Thursday.

The flamboyant Pietersen was spoken to by Bruce Oxenford and Asad Rauf after bowler Tillakaratne Dilshan had to stop twice in his run-up as the batsman turned around in his stance.

The laws of the game say that the switch hit -- a right-hander playing a shot with a left-hander's grip -- is legal but a batsman cannot change stance before the bowler has delivered the ball.

Match referee Javagal Srinath of India confirmed that Pietersen had been officially warned twice.

A third offence by him or any other England batsman will result in five penalty runs being awarded to Sri Lanka, Srinath said.

Pietersen was unbeaten on 106 at tea on the third day in Colombo as England, replying to Sri Lanka's first-innings score of 275, moved to 352-4.

The South African-born batsman had hit 12 boundaries and four sixes in his 20th Test century.

There was no immediate comment from the England camp on the incident.