Skip to content

Commit 11d745b

Browse files
JoeMattclaude
andcommitted
Address review: mask JERRYReadWord offset for aligned PIT register access
Co-Authored-By: Claude Opus 4.6 <[email protected]>
1 parent aaae872 commit 11d745b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/jerry.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,7 @@ uint16_t JERRYReadWord(uint32_t offset, uint32_t who/*=UNKNOWN*/)
437437
// F1003C R xxxxxxxx xxxxxxxx JPIT4 - timer 2 divider
438438
else if ((offset >= 0xF10036) && (offset <= 0xF1003D))
439439
{
440-
switch (offset)
440+
switch (offset & 0xFFFFFFFE)
441441
{
442442
case 0xF10036: return JERRYPIT1Prescaler;
443443
case 0xF10038: return JERRYPIT1Divider;

0 commit comments

Comments
 (0)