linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ard Biesheuvel <ardb@kernel.org>
To: "Christian König" <ckoenig.leichtzumerken@gmail.com>
Cc: Peter Geis <pgwipeout@gmail.com>,
	Punit Agrawal <punitagrawal@gmail.com>,
	Robin Murphy <robin.murphy@arm.com>,
	Alexandru Elisei <alexandru.elisei@arm.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"open list:ARM/Rockchip SoC..."
	<linux-rockchip@lists.infradead.org>,
	arm-mail-list <linux-arm-kernel@lists.infradead.org>,
	Heiko Stuebner <heiko.stuebner@theobroma-systems.com>,
	Leonardo Bras <leobras.c@gmail.com>,
	Rob Herring <robh@kernel.org>, PCI <linux-pci@vger.kernel.org>
Subject: Re: [BUG] rockpro64: PCI BAR reassignment broken by commit 9d57e61bf723 ("of/pci: Add IORESOURCE_MEM_64 to resource flags for 64-bit memory addresses")
Date: Wed, 26 May 2021 16:15:01 +0200	[thread overview]
Message-ID: <CAMj1kXGBEuV=OUeCWUj5iUbFmko549uKCt5eHFM_j2KW-_FNdw@mail.gmail.com> (raw)
In-Reply-To: <9b99d520-e4b1-ae44-44eb-93c2e3d0c0cb@gmail.com>

On Wed, 26 May 2021 at 15:55, Christian König
<ckoenig.leichtzumerken@gmail.com> wrote:
>
> Hi Ard,
>
> Am 25.05.21 um 19:18 schrieb Ard Biesheuvel:
> > [SNIP]
> >>> I seriously doubt that this is what is going on here.
> >>>
> >>> lspci -x will give you the bare BAR values - I suspect that those are
> >>> probably fine.
> >> lspci -x
> >> 00:00.0 PCI bridge: Fuzhou Rockchip Electronics Co., Ltd Device 3566 (rev 01)
> >> 00: 87 1d 66 35 07 05 10 40 01 00 04 06 00 00 01 00
> >> 10: 00 00 00 00 00 00 00 00 00 01 ff 00 10 10 00 20
> >> 20: 00 10 00 10 01 00 f1 0f 00 00 00 00 00 00 00 00
> >> 30: 00 00 00 00 40 00 00 00 00 00 00 00 5f 01 02 00
> >>
> >> 01:00.0 VGA compatible controller: Advanced Micro Devices, Inc.
> >> [AMD/ATI] Turks PRO [Radeon HD 7570]
> >> 00: 02 10 5d 67 07 00 10 20 00 00 00 03 00 00 80 00
> >> 10: 0c 00 00 00 00 00 00 00
> > This is a 64-bit prefetchable BAR programmed with bus address 0x0
> >
> >> 04 00 00 10 00 00 00 00
> > This is a 64-bit non-prefetchable BAR programmed with bus address 0x1000_0000
> >
> > (https://en.wikipedia.org/wiki/PCI_configuration_space describes the
> > meaning of the low order BAR bits)
>
> Sorry for jumping into the middle of the discussion and to be honest I
> haven't fully read it.
>
> This looks a bit odd since on AMD VGA hardware the non-prefetchable BAR
> is usually only 32bit, not 64bit.
>
> But this hardware generation is rather old and I'm not sure what the BAR
> assignment for that generation was. I would need to dig up the register
> description in our archives as well.
>

I have another museum piece in my AMD Seattle:

02:00.0 VGA compatible controller: Advanced Micro Devices, Inc.
[AMD/ATI] Oland XT [Radeon HD 8670 / R7 250/350] (rev 81) (prog-if 00
[VGA controller])
  Subsystem: Dell Oland XT [Radeon HD 8670 / R7 250/350]
  Flags: bus master, fast devsel, latency 0, IRQ 255
  Memory at 100000000 (64-bit, prefetchable) [size=4G]
  Memory at 40000000 (64-bit, non-prefetchable) [size=256K]
  I/O ports at 1000 [disabled] [size=256]
  Expansion ROM at 40060000 [disabled] [size=128K]
  Capabilities: <access denied>
  Kernel modules: radeon, amdgpu

So AMD/ATI ASICs definitely exist that expose a 64-bit pref and a
64-bit non-pref BAR.

-- 
Ard.

  reply	other threads:[~2021-05-26 14:15 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-18  9:09 [BUG] rockpro64: PCI BAR reassignment broken by commit 9d57e61bf723 ("of/pci: Add IORESOURCE_MEM_64 to resource flags for 64-bit memory addresses") Alexandru Elisei
2021-05-19  6:28 ` Qu Wenruo
2021-05-19  7:05   ` Qu Wenruo
2021-05-19  9:20     ` Alexandru Elisei
2021-05-19 11:16       ` Qu Wenruo
2021-05-19 11:27 ` Robin Murphy
2021-05-19 13:17   ` Peter Geis
2021-05-23 11:03   ` Punit Agrawal
2021-05-23 12:10     ` Ard Biesheuvel
2021-05-25 13:42       ` Punit Agrawal
2021-05-25 13:54         ` Ard Biesheuvel
2021-05-25 15:34           ` Peter Geis
2021-05-25 15:54             ` Ard Biesheuvel
2021-05-25 16:23               ` Peter Geis
2021-05-25 16:44                 ` Ard Biesheuvel
2021-05-25 17:01                   ` Peter Geis
2021-05-25 17:18                     ` Ard Biesheuvel
2021-05-25 17:37                       ` Peter Geis
2021-05-26 13:55                       ` Christian König
2021-05-26 14:15                         ` Ard Biesheuvel [this message]
2021-05-25 17:25                     ` Robin Murphy
2021-05-25 17:34                       ` Peter Geis
2021-05-25 18:55                         ` Robin Murphy
2021-05-25 19:15               ` Bjorn Helgaas
2021-05-25 19:43                 ` Ard Biesheuvel
2021-05-25 20:03                   ` Peter Geis
2021-05-26 14:18                     ` Ard Biesheuvel
2021-05-25 16:59           ` Anand Moon
2021-05-25 17:14             ` Robin Murphy
2021-05-25 17:42               ` Peter Geis
2021-05-25 22:36           ` Punit Agrawal
2021-05-26 15:37           ` Rob Herring
2021-05-26 16:35             ` Ard Biesheuvel

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='CAMj1kXGBEuV=OUeCWUj5iUbFmko549uKCt5eHFM_j2KW-_FNdw@mail.gmail.com' \
    --to=ardb@kernel.org \
    --cc=alexandru.elisei@arm.com \
    --cc=ckoenig.leichtzumerken@gmail.com \
    --cc=heiko.stuebner@theobroma-systems.com \
    --cc=leobras.c@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=pgwipeout@gmail.com \
    --cc=punitagrawal@gmail.com \
    --cc=robh@kernel.org \
    --cc=robin.murphy@arm.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;
as well as URLs for NNTP newsgroup(s).