Skip to content

Commit

Permalink
cmds/kernel: fix condition for saving kernel's beginning address
Browse files Browse the repository at this point in the history
JIRA: RTOS-813
  • Loading branch information
lukileczo authored and agkaminski committed Jun 25, 2024
1 parent 7910fb6 commit 5bf3ca4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmds/kernel.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ static int cmd_kernel(int argc, char *argv[])
}

/* Save kernel's beginning address */
if (phdr.p_flags == (ELF_WORD)(PHF_R | PHF_X)) {
if ((phdr.p_flags & (ELF_WORD)PHF_X) != 0) {
kernelPAddr = entry->start;
}

Expand Down

0 comments on commit 5bf3ca4

Please sign in to comment.