2. Given the lengths of the four sides of a quadrilateral are $m$, $n$, $p$, and $q$, and they satisfy $m^{2}+n^{2}+p^{2}+q^{2}=2 m n+2 p q$. Then this quadrilateral is ( ).
(A) parallelogram
(B) quadrilateral with perpendicular diagonals
(C) parallelogram or quadrilateral with perpendicular diagonals
(D) quadrilateral with equal diagonals
2.C.

From the given, we have
$$
(m-n)^{2}+(p-q)^{2}=0 .
$$

Therefore, $m=n, p=q$.
If $m, n$ are one pair of opposite sides of a quadrilateral, then $p, q$ are its other pair of opposite sides, making this quadrilateral a parallelogram; if $m, n$ are one pair of adjacent sides of the quadrilateral, then $p, q$ are also one pair of adjacent sides, making this quadrilateral a quadrilateral with perpendicular diagonals.