  We formulate a version of the Breuil--Mezard conjecture for quaternion
algebras, and show that it follows from the Breuil--Mezard conjecture for GL_2.
In the course of the proof we establish a mod p analogue of the
Jacquet--Langlands correspondence for representations of GL_2(k), k a finite
field of characteristic p.
