lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <170900202640.3669151.3772018788684563610.b4-ty@oracle.com>
Date: Mon, 26 Feb 2024 21:47:14 -0500
From: "Martin K. Petersen" <martin.petersen@...cle.com>
To: Sathya Prakash Veerichetty <sathya.prakash@...adcom.com>,
        Kashyap Desai <kashyap.desai@...adcom.com>,
        Sumit Saxena <sumit.saxena@...adcom.com>,
        Sreekanth Reddy <sreekanth.reddy@...adcom.com>,
        Arnd Bergmann <arnd@...nel.org>
Cc: "Martin K . Petersen" <martin.petersen@...cle.com>,
        Arnd Bergmann <arnd@...db.de>,
        Johannes Thumshirn <johannes.thumshirn@....com>,
        "James E.J. Bottomley" <jejb@...ux.ibm.com>,
        Ranjan Kumar <ranjan.kumar@...adcom.com>,
        Tomas Henzl <thenzl@...hat.com>,
        Harshit Mogalapalli <harshit.m.mogalapalli@...cle.com>,
        mpi3mr-linuxdrv.pdl@...adcom.com, linux-scsi@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] [v2] scsi: mpi3mr: reduce stack usage in mpi3mr_refresh_sas_ports()

On Tue, 23 Jan 2024 14:07:36 +0100, Arnd Bergmann wrote:

> Doubling the number of PHYs also doubled the stack usage of this function,
> exceeding the 32-bit limit of 1024 bytes:
> 
> drivers/scsi/mpi3mr/mpi3mr_transport.c: In function 'mpi3mr_refresh_sas_ports':
> drivers/scsi/mpi3mr/mpi3mr_transport.c:1818:1: error: the frame size of 1636 bytes is larger than 1024 bytes [-Werror=frame-larger-than=]
> 
> Since the sas_io_unit_pg0 structure is already allocated dynamically, use
> the same method here. The size of the allocation can be smaller based on the
> actual number of phys now, so use this as an upper bound.
> 
> [...]

Applied to 6.8/scsi-fixes, thanks!

[1/1] scsi: mpi3mr: reduce stack usage in mpi3mr_refresh_sas_ports()
      https://git.kernel.org/mkp/scsi/c/5cc2da0b60e5

-- 
Martin K. Petersen	Oracle Linux Engineering

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ