12679f63fSMichael Ellerman#include <asm/ppc_asm.h> 22679f63fSMichael Ellerman 32679f63fSMichael Ellerman_GLOBAL(copy_tofrom_user_reference) 42679f63fSMichael Ellerman cmpdi r5,0 52679f63fSMichael Ellerman beq 4f 62679f63fSMichael Ellerman 72679f63fSMichael Ellerman mtctr r5 82679f63fSMichael Ellerman 92679f63fSMichael Ellerman1: lbz r6,0(r4) 102679f63fSMichael Ellerman2: stb r6,0(r3) 112679f63fSMichael Ellerman addi r3,r3,1 122679f63fSMichael Ellerman addi r4,r4,1 132679f63fSMichael Ellerman bdnz 1b 142679f63fSMichael Ellerman 152679f63fSMichael Ellerman3: mfctr r3 162679f63fSMichael Ellerman blr 172679f63fSMichael Ellerman 182679f63fSMichael Ellerman4: mr r3,r5 192679f63fSMichael Ellerman blr 202679f63fSMichael Ellerman 212679f63fSMichael Ellerman.section __ex_table,"a" 222679f63fSMichael Ellerman .llong 1b,3b 232679f63fSMichael Ellerman .llong 2b,3b 242679f63fSMichael Ellerman.text 25