Inline motor_* functions