arch_arm: improve thumb support