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

-Warray-bounds in drivers/scsi/aacraid/commsup.c #1851

Closed
nickdesaulniers opened this issue May 24, 2023 · 6 comments
Closed

-Warray-bounds in drivers/scsi/aacraid/commsup.c #1851

nickdesaulniers opened this issue May 24, 2023 · 6 comments
Labels
-Warray-bounds [BUG] linux A bug that should be fixed in the mainline kernel. [FIXED][LINUX] development cycle This bug was only present and fixed in a -next or -rc cycle [Reported-by] KernelCI Reported-by: kernelci.org bot <bot@kernelci.org>

Comments

@nickdesaulniers
Copy link
Member

https://lore.kernel.org/llvm/646dc00e.170a0220.7bf11.14f5@mx.google.com/T/#u

    3    drivers/scsi/aacraid/commsup.c:1786:15: error: array index 3 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1785:15: error: array index 2 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1784:15: error: array index 1 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1347:18: error: array index 4 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1346:18: error: array index 6 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1345:18: error: array index 1 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1330:19: error: array index 4 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1329:50: error: array index 5 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1329:19: error: array index 6 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1328:18: error: array index 1 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1288:21: error: array index 3 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
    3    drivers/scsi/aacraid/commsup.c:1166:17: error: array index 1 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]=
    2    drivers/scsi/aacraid/commsup.c:1286:20: error: array index 3 is past the end of the array (that has type 'u8[1]' (aka 'unsigned char[1]'), cast to '__le32 *' (aka 'unsigned int *')) [-Werror,-Warray-bounds]
@nickdesaulniers nickdesaulniers added -Warray-bounds [BUG] linux-next This is an issue only seen in linux-next [Reported-by] KernelCI Reported-by: kernelci.org bot <bot@kernelci.org> labels May 24, 2023
@nathanchance
Copy link
Member

@nathanchance nathanchance added the [PATCH] Exists There is a patch that fixes this issue label May 24, 2023
@GustavoARSilva
Copy link

It's time to fight this battle, once again. Brace yourselves!

nickdesaulniers added a commit to ClangBuiltLinux/continuous-integration2 that referenced this issue May 30, 2023
@GustavoARSilva
Copy link

nickdesaulniers added a commit to ClangBuiltLinux/continuous-integration2 that referenced this issue May 31, 2023
* add patches for ClangBuiltLinux/linux#1851

* ./generate.py next

* grab just last patch
@nathanchance nathanchance added [PATCH] Submitted A patch has been submitted for review and removed [PATCH] Exists There is a patch that fixes this issue labels Jun 30, 2023
@nathanchance
Copy link
Member

It looks like Arnd sent a patch for this and Martin has tentatively applied it for 6.5:

https://git.kernel.org/mkp/scsi/c/47699a2b63caaa0de4841d4402627c2fdf3452a6

@nathanchance nathanchance added [PATCH] Accepted A submitted patch has been accepted upstream and removed [PATCH] Submitted A patch has been submitted for review labels Jul 6, 2023
@nathanchance
Copy link
Member

The patch appears to be in James's tree, which means it should be going to Linus soon:

https://git.kernel.org/jejb/scsi/c/47699a2b63caaa0de4841d4402627c2fdf3452a6

@nathanchance
Copy link
Member

@nathanchance nathanchance added [BUG] linux A bug that should be fixed in the mainline kernel. [FIXED][LINUX] development cycle This bug was only present and fixed in a -next or -rc cycle and removed [PATCH] Accepted A submitted patch has been accepted upstream [BUG] linux-next This is an issue only seen in linux-next labels Jul 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
-Warray-bounds [BUG] linux A bug that should be fixed in the mainline kernel. [FIXED][LINUX] development cycle This bug was only present and fixed in a -next or -rc cycle [Reported-by] KernelCI Reported-by: kernelci.org bot <bot@kernelci.org>
Projects
None yet
Development

No branches or pull requests

3 participants