Answer :
The event that either M1 or M2 fails has probability
[tex]P(M_1\text{ fails or }M_2\text{ fails})=P(M_1\text{ fails})+P(M_2\text{ fails})-P(M_1\text{ and }M_2\text{ both fail})[/tex]
by the addition rule. Failure events are independent, so
[tex]P(M_1\text{ and }M_2\text{ both fail})=P(M_1\text{ fails})P(M_2\text{ fails})[/tex]
so that
[tex]P(M_1\text{ fails or }M_2\text{ fails})=p_1+p_2-p_1p_2[/tex]
Denote this probability by [tex]p[/tex]. Then [tex]X[/tex] follows a geometric distribution with this parameter [tex]p[/tex] and has density
[tex]P(X=x)=\begin{cases}(1-p)^{x-1}p&\text{for }x\ge1\\0&\text{otherwise}\end{cases}[/tex]
The expectation is [tex]\dfrac1p=\dfrac1{p_1+p_2-p_1p_2}[/tex].