In this letter, we present a two-phase distributed resource allocation algorithm for a Device-to- Device (D2D) network underlaying a cellular network. In the first phase, D2D pairs learn resource block (RB) of the cellular user equipment (CUEs) to be used, while playing an interference minimization game. Each D2D pairis ensured an interference below an upper limit, which is chosen as the criterion for admission control. In the next phase, power allocation for the device pairs allocated to each RB is carried out to maximize their sum rate while ensuring a minimum rate to the CUEs using a pricing scheme. We perform simulations to evaluate the performance of the proposed scheme.