Consider the given expression,
⇒am2+bm2+bn2+an2
⇒m(a+b)+n2(b+a)
⇒(a+b)(m+n)
Hence, this is the answer.