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

[2.2.5] Replace P2ALIGN with P2ALIGN_TYPED and delete P2ALIGN. #16186

Merged

Commits on May 10, 2024

  1. Replace P2ALIGN with P2ALIGN_TYPED and delete P2ALIGN.

    In P2ALIGN, the result would be incorrect when align is unsigned
    integer and x is larger than max value of the type of align.
    In that case, -(align) would be a positive integer, which means
    high bits would be zero and finally stay zero after '&' when
    align is converted to a larger integer type.
    
    Reviewed-by: Brian Behlendorf <[email protected]>
    Reviewed-by: Youzhong Yang <[email protected]>
    Signed-off-by: Qiuhao Chen <[email protected]>
    Closes openzfs#15940
    chenqiuhao1997 authored and behlendorf committed May 10, 2024
    Configuration menu
    Copy the full SHA
    471fd42 View commit details
    Browse the repository at this point in the history