Mixing materials using textures in nodes
You only need one difuse shader and the rest is combining colors using the existing masks. 

The result of one RGB mix is concatenated to another RGB mix and those become the color for the shader.



(Click on the images to expand to full screen)

If you must use shaders then the masks are used in a similar way to concatenate the mixes one over the other.