[Galaxy S 4 Themes and Apps] AngelBob:
[MENTION=334644]sorg[/MENTION]

I'm trying to disable HDCP on a Xperia Z running 4.4.2, I have no issues with your first & third patch

However you patch in setupCallback can not be done as the function is not the same.

TIA for any pointers you can give

.text:000084D0 ; cback::setupCallback(rtspApiMesg &)
.text:000084D0 EXPORT _ZN5cback13setupCallbackER11rtspApiMesg
.text:000084D0 _ZN5cback13setupCallbackER11rtspApiMesg ; DATA XREF: .data.rel.ro:`vtable for'cbacko
.text:000084D0
.text:000084D0 var_28 = -0x28
.text:000084D0 var_1C = -0x1C
.text:000084D0 var_18 = -0x18
.text:000084D0
.text:000084D0 PUSH.W {R0-R8,LR}
.text:000084D4 MOV R7, R0
.text:000084D6 ADD.W R0, R1, #0x10
.text:000084DA MOV R4, R1
.text:000084DC BLX _ZN7rtspWfd4dumpEv ; rtspWfd::dump(void)
.text:000084E0 BL _ZN14SessionManager8InstanceEv ; SessionManager::Instance(void)
.text:000084E4 MOV R6, R0
.text:000084E6 CBNZ R0, loc_84F4
.text:000084E8 LDR R3, [R0,#0x64]
.text:000084EA CBNZ R3, loc_84F4
.text:000084EC LDR R0, [R0,#0x38]
.text:000084EE CMP R0, #0
.text:000084F0 BEQ.W locret_8644
.text:000084F4
.text:000084F4 loc_84F4 ; CODE XREF: cback::setupCallback(rtspApiMesg &)+16j
.text:000084F4 ; cback::setupCallback(rtspApiMesg &)+1Aj
.text:000084F4 LDR.W R3, [R4,#0x300]
.text:000084F8 CMP R3, #0
.text:000084FA BNE.W locret_8644
.text:000084FE LDR R2, =(_ZN11RTSPSession11m_eplayModeE - 0x8506)
.text:00008500 LDR R5, [R7,#4]
.text:00008502 ADD R2, PC ; RTSPSession::m_eplayMode
.text:00008504 LDR R1, [R2]
.text:00008506 CMP R1, #1
.text:00008508 BNE loc_8528
.text:0000850A LDR R0, [R5,#0x1C]
.text:0000850C MOVS R1, #3
.text:0000850E LDR R2, [R0,#0x3C]
.text:00008510 LDR.W R5, [R2,#0x200]
.text:00008514 STR R1, [R5]
.text:00008516 STRB.W R3, [R4,#0xB4]
.text:0000851A STRB.W R3, [R4,#0xF4]
.text:0000851E STRB.W R3, [R4,#0x174]
.text:00008522 STRB.W R3, [R4,#0x134]
.text:00008526 B loc_8548
.text:00008528 ; ---------------------------------------------------------------------------
.text:00008528
.text:00008528 loc_8528 ; CODE XREF: cback::setupCallback(rtspApiMesg &)+38j
.text:00008528 CMP R1, #2
.text:0000852A BNE loc_8548
.text:0000852C LDR R0, [R5,#0x1C]
.text:0000852E MOVS R1, #4
.text:00008530 LDR R2, [R0,#0x3C]
.text:00008532 LDR.W R5, [R2,#0x200]
.text:00008536 STR R1, [R5,#4]
.text:00008538 STRB.W R3, [R4,#0x6A]
.text:0000853C STRB.W R3, [R4,#0xAA]
.text:00008540 STRB.W R3, [R4,#0x8A]
.text:00008544 STRB.W R3, [R4,#0x4A]
.text:00008548
.text:00008548 loc_8548 ; CODE XREF: cback::setupCallback(rtspApiMesg &)+56j
.text:00008548 ; cback::setupCallback(rtspApiMesg &)+5Aj
.text:00008548 LDR R3, [R7,#4]
.text:0000854A LDR R2, [R4,#8]
.text:0000854C LDR R0, [R3,#0x1C]
.text:0000854E LDR R5, [R0,#0x3C]
.text:00008550 LDR.W R1, [R5,#0x200]
.text:00008554 STRH R2, [R1,#0x32]
.text:00008556 LDR.W R3, [R5,#0x200]
.text:0000855A LDR R0, [R4,#0xC]
.text:0000855C STRH R0, [R3,#0x36]
.text:0000855E LDR.W R1, [R4,#0x204]
.text:00008562 CBZ R1, loc_856A
.text:00008564 LDR.W R2, [R5,#0x200]
.text:00008568 STRH R1, [R2,#0x34]
.text:0000856A
.text:0000856A loc_856A ; CODE XREF: cback::setupCallback(rtspApiMesg &)+92j
.text:0000856A LDR R3, [R7,#4]
.text:0000856C LDR.W R8, [R5,#0x200]
.text:00008570 LDR R0, [R3,#0x1C]
.text:00008572 LDR R0, [R0,#0x2C] ; cp
.text:00008574 BLX inet_addr
.text:00008578 STR.W R0, [R8,#0x3C]
.text:0000857C LDR R1, [R7,#4]
.text:0000857E LDR.W R0, [R5,#0x200]
.text:00008582 LDR R2, [R1,#0x1C]
.text:00008584 ADDS R0, #0x44
.text:00008586 LDR R1, [R2,#0x14]
.text:00008588 MOVS R2, #0x18
.text:0000858A BLX strlcpy
.text:0000858E LDR R0, [R6,#0x64]
.text:00008590 BL _ZNK6Device13getDeviceTypeEv ; Device::getDeviceType(void)
.text:00008594 CBZ R0, loc_85AC
.text:00008596 LDR R3, [R6,#0x64]
.text:00008598 LDR R0, [R3,#0x38]
.text:0000859A LDR.W R1, [R0,#0x200]
.text:0000859E CBZ R1, loc_85AC
.text:000085A0 LDR.W R8, [R5,#0x200]
.text:000085A4 BL getStreamingSurface
.text:000085A8 STR.W R0, [R8,#0x78]
.text:000085AC
.text:000085AC loc_85AC ; CODE XREF: cback::setupCallback(rtspApiMesg &)+C4j
.text:000085AC ; cback::setupCallback(rtspApiMesg &)+CEj
.text:000085AC LDR R2, [R7,#4]
.text:000085AE LDR R3, [R2,#0x1C]
.text:000085B0 LDR R0, [R3,#0x3C]
.text:000085B2 BL _ZN12MMCapability4dumpEv ; MMCapability::dump(void)
.text:000085B6 ; ---------------------------------------------------------------------------
.text:000085B6 ADD R1, SP, #0x28+var_18
.text:000085B8 MOVS R0, #0
.text:000085BA STR.W R0, [R1,#-4]!
.text:000085BE LDR R0, =(aEnforcelinkhdc - 0x85C4)
.text:000085C0 ADD R0, PC ; "EnforceLinkHDCP"
.text:000085C2 BLX getCfgItem
.text:000085C6 LDR R1, [SP,#0x28+var_1C]
.text:000085C8 CBZ R1, loc_85EE
.text:000085CA LDR R0, [R6,#0x64]
.text:000085CC BL _ZNK6Device13getDeviceTypeEv ; Device::getDeviceType(void)
.text:000085D0 CBNZ R0, loc_85EE
.text:000085D2 LDR R2, [R6,#0x64]
.text:000085D4 LDR R0, [R2,#0x38]
.text:000085D6 LDR.W R3, [R0,#0x200]
.text:000085DA LDRB.W R1, [R3,#0x2A]
.text:000085DE BL _ZN12MMCapability22isHDCPVersionSupportedEi ; MMCapability::isHDCPVersionSupported(int)
.text:000085E2 CBNZ R0, loc_861E
.text:000085E4 B loc_85EE
.text:000085E6 ; ---------------------------------------------------------------------------
.text:000085E6
.text:000085E6 loc_85E6 ; CODE XREF: cback::setupCallback(rtspApiMesg &)+15Ej
.text:000085E6 LDR.W R0, [R5,#0x200]
.text:000085EA LDRH R2, [R0,#0x2C]
.text:000085EC CBZ R2, loc_8630
.text:000085EE
.text:000085EE loc_85EE ; CODE XREF: cback::setupCallback(rtspApiMesg &)+F8j
.text:000085EE ; cback::setupCallback(rtspApiMesg &)+100j ...
.text:000085EE LDR R0, [R6,#0x64]
.text:000085F0 BL _ZNK6Device13getDeviceTypeEv ; Device::getDeviceType(void)
.text:000085F4 MOV R1, R0
.text:000085F6 MOV R0, R5
.text:000085F8 BL _ZN9MMAdaptor13createSessionEP12MMCapability10DeviceType ; MMAdaptor::createSession(MMCapability *,DeviceType)
.text:000085FC LDR R3, [R7,#4]
.text:000085FE LDR R1, [R3,#0x20]
.text:00008600 CBZ R1, loc_860C
.text:00008602 MOVS R0, #1
.text:00008604 STR.W R1, [R4,#0x22C]
.text:00008608 STRB.W R0, [R4,#0x238]
.text:0000860C
.text:0000860C loc_860C ; CODE XREF: cback::setupCallback(rtspApiMesg &)+130j
.text:0000860C LDR R2, [R7,#4]
.text:0000860E LDR R3, [R2,#0x24]
.text:00008610 CBZ R3, locret_8644
.text:00008612 MOVS R1, #1
.text:00008614 STR.W R3, [R4,#0x234]
.text:00008618 STRB.W R1, [R4,#0x238]
.text:0000861C B locret_8644
.text:0000861E ; ---------------------------------------------------------------------------
.text:0000861E
.text:0000861E loc_861E ; CODE XREF: cback::setupCallback(rtspApiMesg &)+112j
.text:0000861E LDR.W R1, [R5,#0x200]
.text:00008622 MOV R0, R5
.text:00008624 LDRB.W R1, [R1,#0x2A]
.text:00008628 BL _ZN12MMCapability22isHDCPVersionSupportedEi ; MMCapability::isHDCPVersionSupported(int)
.text:0000862C CMP R0, #0
.text:0000862E BNE loc_85E6
.text:00008630
.text:00008630 loc_8630 ; CODE XREF: cback::setupCallback(rtspApiMesg &)+11Cj
.text:00008630 MOVS R2, #0
.text:00008632 MOVS R0, #3
.text:00008634 STR R2, [SP,#0x28+var_28]
.text:00008636 MOVS R1, #1
.text:00008638 MOV R3, R2
.text:0000863A BL eventMMUpdate
.text:0000863E MOVS R0, #1
.text:00008640 STR.W R0, [R4,#0x300]
.text:00008644
.text:00008644 locret_8644 ; CODE XREF: cback::setupCallback(rtspApiMesg &)+20j
.text:00008644 ; cback::setupCallback(rtspApiMesg &)+2Aj ...
.text:00008644 POP.W {R0-R8,PC}
.text:00008644 ; End of function cback::setupCallback(rtspApiMesg &)

Here's the full IDA report: http://xzdr.cambercreak.com/libwfdsm.html