Lines Matching refs:sr
413 static void implementPatch(ScanResult sr, InputSection *isec, in implementPatch() argument
417 utohexstr(isec->getVA(sr.off)) + " in unpatched output."); in implementPatch()
430 if (sr.rel) { in implementPatch()
437 int64_t patchRelAddend = sr.rel->addend; in implementPatch()
439 if (isBL(sr.instr) || isBLX(sr.instr)) { in implementPatch()
443 uint64_t dstSymAddr = (sr.rel->expr == R_PLT_PC) ? sr.rel->sym->getPltVA() in implementPatch()
444 : sr.rel->sym->getVA(); in implementPatch()
447 psec = make<Patch657417Section>(isec, sr.off, sr.instr, destIsARM); in implementPatch()
455 Relocation{sr.rel->expr, patchRelType, 0, patchRelAddend, sr.rel->sym}); in implementPatch()
457 sr.rel->expr = R_PC; in implementPatch()
458 sr.rel->addend = -4; in implementPatch()
459 sr.rel->sym = psec->patchSym; in implementPatch()
465 psec = make<Patch657417Section>(isec, sr.off, sr.instr, isBLX(sr.instr)); in implementPatch()
467 if (isBcc(sr.instr)) in implementPatch()
469 else if (isB(sr.instr)) in implementPatch()
473 isec->addReloc(Relocation{R_PC, type, sr.off, -4, psec->patchSym}); in implementPatch()
504 ScanResult sr = scanCortexA8Errata657417(isec, off, limit); in patchInputSectionDescription() local
505 if (sr.off) in patchInputSectionDescription()
506 implementPatch(sr, isec, patches); in patchInputSectionDescription()