This paper proposes to deploy multiple reconfigurable intelligent surfaces (RISs) in device-to-device (D2D)-underlaid cellular systems. The uplink sum-rate of the system is maximized by jointly optimizing the transmit powers of the users, the pairing of the cellular users (CUs) and D2D links, the receive beamforming of the base station (BS), and the configuration of the RISs, subject to the power limits and quality-of-service (QoS) of the users. To address the non-convexity of this problem, we develop a new block coordinate descent (BCD) framework which decouples the D2D-CU pairing, power allocation and receive beamforming, from the configuration of the RISs. Specifically, we derive closed-form expressions for the power allocation and receive beamforming under any D2D-CU pairing, which facilitates interpreting the D2D-CU pairing as a bipartite graph matching solved using the Hungarian algorithm. We transform the configuration of the RISs into a quadratically constrained quadratic program (QCQP) with multiple quadratic constraints. A low-complexity algorithm, named Riemannian manifold-based alternating direction method of multipliers (RM-ADMM), is developed to decompose the QCQP into simpler QCQPs with a single constraint each, and solve them efficiently in a decentralized manner. Simulations show that the proposed algorithm can significantly improve the sum-rate of the D2D-underlaid system with a reduced complexity, as compared to its alternative based on semidefinite relaxation (SDR).