... and make sure this code goes near the beginning of the mod_rewrite code.
Ideally it will be located right after your RewriteRule(s) which block bad requests and it MUST be before any code with performs any internal rewrite on the request.
!^.*mredir=0.*$ is inefficient. The ^.* part causes multiple "back off and retry" trial matches slowing the server. The .*$ part wastes yet more processor cycles reading to the end. Use !mredir=0 instead.
The target URL (the root of mobile site) must end in a trailing slash.