From: Bjorn Helgaas <helgaas@kernel.org>
To: Logan Gunthorpe <logang@deltatee.com>
Cc: linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
Doug Meyer <dmeyer@gigaio.com>,
Kelvin Cao <Kelvin.Cao@microchip.com>
Subject: Re: [PATCH] PCI/switchtec: read all 64bits of part_event_bitmap
Date: Mon, 30 Sep 2019 17:37:46 -0500 [thread overview]
Message-ID: <20190930223746.GA216949@google.com> (raw)
In-Reply-To: <20190910195833.3891-1-logang@deltatee.com>
On Tue, Sep 10, 2019 at 01:58:33PM -0600, Logan Gunthorpe wrote:
> The part_event_bitmap register is 64 bits wide and should be read with
> ioread64 instead of the 32-bit ioread32.
>
> Reported-by: Doug Meyer <dmeyer@gigaio.com>
> Signed-off-by: Logan Gunthorpe <logang@deltatee.com>
> Cc: Bjorn Helgaas <bhelgaas@google.com>
> Cc: Kelvin Cao <Kelvin.Cao@microchip.com>
Applied to pci/switchtec for v5.5, thanks!
I added:
Fixes: 52eabba5bcdb ("switchtec: Add IOCTLs to the Switchtec driver")
Cc: stable@vger.kernel.org # v4.12+
Object if you don't want those.
> ---
> drivers/pci/switch/switchtec.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/pci/switch/switchtec.c b/drivers/pci/switch/switchtec.c
> index 8c94cd3fd1f2..465d6afd826e 100644
> --- a/drivers/pci/switch/switchtec.c
> +++ b/drivers/pci/switch/switchtec.c
> @@ -675,7 +675,7 @@ static int ioctl_event_summary(struct switchtec_dev *stdev,
> return -ENOMEM;
>
> s->global = ioread32(&stdev->mmio_sw_event->global_summary);
> - s->part_bitmap = ioread32(&stdev->mmio_sw_event->part_event_bitmap);
> + s->part_bitmap = ioread64(&stdev->mmio_sw_event->part_event_bitmap);
> s->local_part = ioread32(&stdev->mmio_part_cfg->part_event_summary);
>
> for (i = 0; i < stdev->partition_count; i++) {
> --
> 2.20.1
>
prev parent reply other threads:[~2019-09-30 22:37 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-10 19:58 Logan Gunthorpe
2019-09-30 22:37 ` Bjorn Helgaas [this message]
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=20190930223746.GA216949@google.com \
--to=helgaas@kernel.org \
--cc=Kelvin.Cao@microchip.com \
--cc=dmeyer@gigaio.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=logang@deltatee.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome