[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <yq1y0rx9odi.fsf@ca-mkp.ca.oracle.com>
Date: Tue, 05 Aug 2025 22:30:46 -0400
From: "Martin K. Petersen" <martin.petersen@...cle.com>
To: Francisco Gutierrez <frankramirez@...gle.com>
Cc: Jack Wang <jinpu.wang@...ud.ionos.com>,
"James E . J . Bottomley"
<James.Bottomley@...senPartnership.com>,
"Martin K . Petersen"
<martin.petersen@...cle.com>,
linux-scsi@...r.kernel.org, linux-kernel@...r.kernel.org,
Jerry.Wong@...rochip.com, vishakhavc@...gle.com
Subject: Re: [PATCH] scsi: pm80xx: Fix race condition caused by static
variables
Francisco,
> - for (; start < end; start++)
> - str += sprintf(str, "%08x ", *(temp+start));
> - count++;
> + for (; pm8001_ha->iop_log_start < pm8001_ha->iop_log_end; pm8001_ha->iop_log_start++)
> + str += sprintf(str, "%08x ", *(temp+pm8001_ha->iop_log_start));
> + pm8001_ha->iop_log_count++;
Since the start, end, and count variables are only used in this
function, what is the point of putting them in 'struct pm8001_hba_info'?
It makes the lines longer and harder to read...
--
Martin K. Petersen
Powered by blists - more mailing lists