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

Bitfield with negative bit_position value #49

Closed
IridiumXOR opened this issue May 28, 2023 · 3 comments
Closed

Bitfield with negative bit_position value #49

IridiumXOR opened this issue May 28, 2023 · 3 comments

Comments

@IridiumXOR
Copy link

Hi,
generating the json profile for vmlinux-5.19.0-40-generic Ubuntu 22.04 stock kernel I have discovered that the tool produce a negative bit_position value for bitfields (example for field active_mode in struct Scsi_Host.
I think the problem come from this line:

vtypeField.FieldType["bit_position"] = maxPos - (field.BitOffset + (field.BitSize - 1))

Please can you fix it?

@Shiselster
Copy link

I tend to believe the issue stems from differences between DWARF Version 4 and DWARF Version 5, the latter probably not supported by dwarf2json yet?

@TamirVered
Copy link

Happens to me too (only on DWARF Version 5), any intention to fix it?

@Shiselster
Copy link

Issue seems to be fixed after commit 9673739!!

Great job @mkonshie!
Any plans to merge #58 back into master?

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

3 participants