Microsoft is to give away its Windows operating system to makers of smartphones and small tablets for consumers as it seeks to make more of an impact on those fast-growing markets and counter the massive success of Google's free Android platform.