Re: [PATCH] drm/radeon/r600_cs: Fix possible int overflow in r600_packet3_check()

2024-09-30 Thread Alex Deucher
On Sun, Sep 29, 2024 at 8:08 PM Igor Artemiev wrote: > > It is possible, although unlikely, that an integer overflow will occur > when the result of radeon_get_ib_value() is shifted to the left. > > Avoid it by casting one of the operands to larger data type (u64). > > Found by Linux Verification

[PATCH] drm/radeon/r600_cs: Fix possible int overflow in r600_packet3_check()

2024-09-30 Thread Igor Artemiev
It is possible, although unlikely, that an integer overflow will occur when the result of radeon_get_ib_value() is shifted to the left. Avoid it by casting one of the operands to larger data type (u64). Found by Linux Verification Center (linuxtesting.org) with static analysis tool SVACE. Signe