From: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
To: Hans Zhang <18255117159@163.com>
Cc: manivannan.sadhasivam@linaro.org, kw@linux.com,
kishon@kernel.org, arnd@arndb.de,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-pci@vger.kernel.org, inux-kernel@vger.kernel.org,
rockswang7@gmail.com
Subject: Re: [PATCH] misc: pci_endpoint_test: fixed pci_resource_len return value out of bounds.
Date: Thu, 19 Dec 2024 14:36:31 +0200 (EET) [thread overview]
Message-ID: <fcac2f00-3d68-a398-4d47-2858272849f8@linux.intel.com> (raw)
In-Reply-To: <ca7e3d52-c60d-ee19-ca6b-8fa5674197c2@163.com>
[-- Attachment #1: Type: text/plain, Size: 1418 bytes --]
On Thu, 19 Dec 2024, Hans Zhang wrote:
> On 12/18/24 10:00, Ilpo Järvinen wrote:
>
> > I'm not sure how out-of-bounds access would happen. On which line you see
> > that possibility?
> Please see #L291
> https://elixir.bootlin.com/linux/v6.13-rc3/source/drivers/misc/pci_endpoint_test.c#L291
Ah, so this was just a language confusion (understandable, we're not
perfect in expressing ourselves in English, me included).
So you didn't mean "out-of-bound access" at all but that the value is too
large to fit the int sized variable.
Could you please try to phrase it better so it's clear what you mean with
it. And it feels that said multiple times as there's also the 2G thing
mentioned elsewhere in the changelog. It would be nice if you could try to
avoid such duplication. So try to structure changelog so that you first
describe the problem and its impact. And the how the patch solves the
issue.
> > > If the bar size of the EP device exceeds
> >
> > BAR size
> >
> > > 4G, this bar_Size will be equal to 0.
> >
> > bar_size
> >
> > I think bar0 and bar1 information could simply be dropped since they're
> > unrelated. I think this would be enough information:
> >
> > With 8GB BAR2, running pcitest -b 2 fails with "TEST FAILED".
> >
>
> Do I need to add the patch version?
Yes, when you change the patch in anyway, please create a new version.
--
i.
next prev parent reply other threads:[~2024-12-19 12:36 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-17 12:12 [PATCH] misc: pci_endpoint_test: fixed pci_resource_len return value out of bounds Hans Zhang
2024-12-17 15:55 ` Niklas Cassel
2024-12-18 15:00 ` Ilpo Järvinen
2024-12-19 12:28 ` Hans Zhang
2024-12-19 12:36 ` Ilpo Järvinen [this message]
2024-12-20 3:09 ` Hans Zhang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fcac2f00-3d68-a398-4d47-2858272849f8@linux.intel.com \
--to=ilpo.jarvinen@linux.intel.com \
--cc=18255117159@163.com \
--cc=arnd@arndb.de \
--cc=gregkh@linuxfoundation.org \
--cc=inux-kernel@vger.kernel.org \
--cc=kishon@kernel.org \
--cc=kw@linux.com \
--cc=linux-pci@vger.kernel.org \
--cc=manivannan.sadhasivam@linaro.org \
--cc=rockswang7@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.