On Thu, Nov 14, 2024 at 07:03:03PM -0800, Xiaosen He wrote: > signed integer overflow happened in the following multiplication, > ext_cyl*(end_head+1)*end_sector = 0x41040*(0xff+1)*0x3f = 0xffffc000, > the overflow was caught by UBSAN and caused crash to the system, > use unsigned int instead of signed int to avoid integer overflow. > > Signed-off-by: Xiaosen He <quic_xiaosenh@xxxxxxxxxxx> > Signed-off-by: Jian Zhou <quic_jianzhou@xxxxxxxxxxx> Reviewed-by: Aleksei Vetrov <vvvvvv@xxxxxxxxxx>