MXC driver ported from 3.10.17