Bertrand Competition for Inputs and Walrasian Outcomes