Procedural Knowledge in Pretraining Drives Reasoning in Large Language Models