undefined4 Set_ATE_IPG_Proc(int param_1,undefined4 param_2)
{
char cVar1;
uint uVar2;
uint uVar3;
int iVar4;
char *pcVar5;
uint uVar6;
uVar2 = simple_strtol(param_2,0,10);
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
*(uint *)(param_1 + 0x76a4c) = uVar2;
if (uVar2 == 0) {
if (RTDebugLevel < 3) {
return 1;
}
pcVar5 = "Set_ATE_IPG_Proc::IPG is disabled(IPG == 0).\n";
goto LAB_000a0398;
}
if (uVar2 - 1 < 0xff) {
if (cVar1 == '\0') {
*(undefined4 *)(*(int *)(param_1 + 0xdc) + 0x1300) = 0;
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
else {
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
if (cVar1 == '\0') {
*(undefined4 *)(*(int *)(param_1 + 0xdc) + 0x1304) = 0;
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
else {
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
if (cVar1 == '\0') {
*(undefined4 *)(*(int *)(param_1 + 0xdc) + 0x1308) = 0;
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
else {
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
uVar6 = uVar2;
if (cVar1 == '\0') {
*(undefined4 *)(*(int *)(param_1 + 0xdc) + 0x130c) = 0;
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
else {
LAB_000a0328:
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
}
else {
uVar3 = 0;
if (cVar1 == '\0') {
uVar3 = *(uint *)(*(int *)(param_1 + 0xdc) + 0x1104);
}
uVar6 = uVar2 % (uVar3 & 0xff);
iVar4 = uVar2 / (uVar3 & 0xff) << 8;
if (cVar1 == '\0') {
*(int *)(*(int *)(param_1 + 0xdc) + 0x1300) = iVar4;
}
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
if (cVar1 == '\0') {
*(int *)(*(int *)(param_1 + 0xdc) + 0x1304) = iVar4;
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
if (cVar1 == '\0') {
*(int *)(*(int *)(param_1 + 0xdc) + 0x1308) = iVar4;
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
}
if (cVar1 == '\0') {
*(int *)(*(int *)(param_1 + 0xdc) + 0x130c) = iVar4;
goto LAB_000a0328;
}
cVar1 = *(char *)(param_1 + 0xec) //possible issue identified - semgrep
}
if (cVar1 == '\0') {
*(uint *)(*(int *)(param_1 + 0xdc) + 0x1100) = uVar6 << 8 | uVar6;
}
if (2 < RTDebugLevel) {
printk("Set_ATE_IPG_Proc (IPG = %u)\n",*(undefined4 *)(param_1 + 0x76a4c));
}
if (RTDebugLevel < 3) {
return 1;
}
pcVar5 = "Ralink: Set_ATE_IPG_Proc Success\n";
LAB_000a0398:
printk(pcVar5);
return 1;
}