2010-09-17	Mark Nord - Patch to enable kUp-hold on PRS-505
		ebook.so version 1.4.00.23260 unpatched, commented originalcode
.text:0000C698
.text:0000C698 loc_C698                                
.text:0000C698                 MOV     R0, R5
.text:0000C69C                 LDR     R3, =0x430      ; kUp
.text:0000C6A0                 B       loc_C6D4
.text:0000C6A4 ; ---------------------------------------------------------------------------
.text:0000C6A4
.text:0000C6A4 loc_C6A4                                
.text:0000C6A4                 CMP     R4, #0          ; check if hold-event
.text:0000C6A8                 MOVNE   R0, R1	       ; MOV is done either way	
.text:0000C6AC                 LDRNE   R3, =0x434      ; kLast - r4<>0 hold event
.text:0000C6B0                 BNE     loc_C6D4
.text:0000C6B4                 MOV     R0, R1          ; MOV is done either way
.text:0000C6B8                 LDR     R3, =0x438      ; kNext
.text:0000C6BC                 B       loc_C6D4
.text:0000C6C0 ; ---------------------------------------------------------------------------
.text:0000C6C0
.text:0000C6C0 loc_C6C0                                
.text:0000C6C0                 CMP     R4, #0          ; check if hold-event
.text:0000C6C4                 MOVNE   R0, R1          ; MOV is done either way	
.text:0000C6C8                 LDRNE   R3, =0x43C      ; kFirst
.text:0000C6CC                 MOVEQ   R0, R1          ; MOV is done either way	
.text:0000C6D0                 LDREQ   R3, =0x440      ; kPrevious
.text:0000C6D4
.text:0000C6D4 loc_C6D4                                
.text:0000C6D4                 LDR     R1, [R10,R3]    ; char *
.text:0000C6D8                 BL      _sprintf
.text:0000C6DC                 LDMEQFD SP!, {R4,R5,R10,PC} ; exit-code equal to ret
.text:0000C6E0 ; ---------------------------------------------------------------------------
.text:0000C6E0
.text:0000C6E0 loc_C6E0  ; handles 0x02%d              
.text:0000C6E0                 MOV     R0, R5          ; char *
.text:0000C6E4                 LDR     R3, =0x444      ; Ox02%d
.text:0000C6E4                                         ;
.text:0000C6E8                 LDR     R1, [R10,R3]    ; char *
.text:0000C6EC                 LDR     R2, [R12,#0x80]
.text:0000C6F0                 BL      _sprintf
.text:0000C6F4
.text:0000C6F4 loc_C6F4                                
.text:0000C6F4                 CMP     R4, #0
.text:0000C6F8                 LDMEQFD SP!, {R4,R5,R10,PC}
.text:0000C6FC                 MOV     R0, R5          ; char *
.text:0000C700                 LDR     R3, =0x448      ; -hold
.text:0000C704                 LDR     R1, [R10,R3]    ; char *
.text:0000C708                 BL      _strcat
.text:0000C70C                 LDMFD   SP!, {R4,R5,R10,PC}
.text:0000C70C ; End of function SubcpuThreadBuildTag
.text:0000C70C
.text:0000C70C ; ---------------------------------------------------------------------------

		ebook.so version 1.4.00.23260 patched to enable kUp-hold, commented code
.text:0000C698 loc_C698                                
.text:0000C698                 MOV     R0, R5
.text:0000C69C                 LDR     R3, =0x430      ; kUp
.text:0000C6A0                 B       loc_C6D4
.text:0000C6A4 ; ---------------------------------------------------------------------------
.text:0000C6A4
.text:0000C6A4 loc_C6A4                                
.text:0000C6A4                 CMP     R4, #0          ; check if hold-event (R4 <>0)
.text:0000C6A8                 MOV     R0, R1          ; as done either way, do it just once
.text:0000C6AC                 LDRNE   R3, =0x434      ; kLast - r4<>0 hold event
.text:0000C6B0                 MOVNE   R4, #0          ; delete hold-flag and 
.text:0000C6B4                 BNE     loc_C6D4        ; rearrange jmp
.text:0000C6B8                 LDR     R3, =0x438      ; kNext
.text:0000C6BC                 B       loc_C6D4
.text:0000C6C0 ; ---------------------------------------------------------------------------
.text:0000C6C0
.text:0000C6C0 loc_C6C0                                
.text:0000C6C0                 CMP     R4, #0          ; check if hold-event
.text:0000C6C4                 MOV     R0, R1          ; as done either way, do it just once
.text:0000C6C8                 LDRNE   R3, =0x43C      ; kPrevious
.text:0000C6CC                 MOV     R4, #0          ; delete hold-flag
.text:0000C6D0                 LDREQ   R3, =0x440      ; kFirst
.text:0000C6D4
.text:0000C6D4 loc_C6D4                                
.text:0000C6D4                 LDR     R1, [R10,R3]    ; char *
.text:0000C6D8                 BL      _sprintf
.text:0000C6DC                 B       loc_C6F4        ; jmp to -hold branch of 0x02%d handler
.text:0000C6E0 ; ---------------------------------------------------------------------------
.text:0000C6E0
.text:0000C6E0 loc_C6E0  ; handles 0x02%d              
.text:0000C6E0                                         
.text:0000C6E0                 MOV     R0, R5          ; char *
.text:0000C6E4                 LDR     R3, =0x444      ; Ox02%d
.text:0000C6E8                 LDR     R1, [R10,R3]    ; char *
.text:0000C6EC                 LDR     R2, [R12,#0x80]
.text:0000C6F0                 BL      _sprintf
.text:0000C6F4
.text:0000C6F4 loc_C6F4                                
.text:0000C6F4                 CMP     R4, #0          ; check if hold-event
.text:0000C6F8                 LDMEQFD SP!, {R4,R5,R10,PC}  ; exit if R4 EQ 0
.text:0000C6FC                 MOV     R0, R5          ; char *
.text:0000C700                 LDR     R3, =0x448      ; -hold
.text:0000C704                 LDR     R1, [R10,R3]    ; char *
.text:0000C708                 BL      _strcat
.text:0000C70C                 LDMFD   SP!, {R4,R5,R10,PC}  ; exit-code equal to ret
.text:0000C70C ; End of function SubcpuThreadBuildTag
.text:0000C70C
.text:0000C70C ; ---------------------------------------------------------------------------

For ver. 1.1.0.1840 equivalent code starts .text:0000C690