If it`s an old bike the top of each pedal stem may be attached by a pin with a bolt, called a cotter pin.These pins may need tightening, but they also may need replacing if the inside flat edge become worn.Most modern mountain bikes do not use this cotter system to fasten the pedals.Examine the pedals and see if anything obviously seems in need of tightening up.
dennis uk, May 2012