Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bitmask in APS2Pattern.Instruction.flatten is too short #151

Open
dellard opened this issue Jan 26, 2018 · 0 comments
Open

Bitmask in APS2Pattern.Instruction.flatten is too short #151

dellard opened this issue Jan 26, 2018 · 0 comments
Assignees

Comments

@dellard
Copy link
Contributor

dellard commented Jan 26, 2018

The bitmask used to select the payload in Instruction.flatten is only 48 bits wide, instead of 56.

Some of the TDM instructions may use the top 8 bits of the payload, so they won't "flatten" correctly.

Apparently there no ordinary APS2 instructions that use those 8 bits (or those instructions are never flattened anywhere) because the mask has been incomplete for years and nobody noticed. (perhaps someone is using those 8 bits for scratch space and relying on the fact that they'll be scrubbed out later...)

I'm ambivalent about fixing this because it seems that this error only has an impact on the TDM version of the driver (and it's already fixed there). If we ever decide to unify the APS2 and APS2TDM drivers, however, this change might be necessary.

@dellard dellard self-assigned this Jan 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant