All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Russell King - ARM Linux <linux@arm.linux.org.uk>,
	Paul Gortmaker <paul.gortmaker@windriver.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	qemu-devel@nongnu.org, Arnd Bergmann <arnd.bergmann@linaro.org>
Subject: Re: [Qemu-devel] SCSI bus failures with qemu-arm in kernel 3.8+
Date: Mon, 12 Aug 2013 17:24:50 +0100	[thread overview]
Message-ID: <CAFEAcA94ygwRPSsfxs3DvOcTZbdafLiEHys94FG4aXUx+A1t=A@mail.gmail.com> (raw)
In-Reply-To: <52082EF8.10005@roeck-us.net>

On 12 August 2013 01:40, Guenter Roeck <linux@roeck-us.net> wrote:
> On 08/11/2013 03:04 PM, Russell King - ARM Linux wrote:
>> It could be that it's qemu's PCI routing is wrong - it's not the first
>> time that qemu has got something wrong.

QEMU 1.5 has had its Versatile PCI routing code rewritten to
correspond with the hardware (cross-tested versus Arnd Bergmann's
patchset
http://marc.info/?l=linux-arm-kernel&m=128707282403376&w=2
which was run on real versatilePB backplane hardware and
could handle a PCI SATA card). I believe it to be correct,
and I spent a fairly long time wading through the various bits
of documentation and testing those kernel patches on h/w.

(It also includes a back-compatibility fudge so that old
kernels which assumed the old broken QEMU behaviour will
continue to work; it does not attempt to fix up the problems
with kernels from commit 1bc39ac5d to present which don't
work properly on either QEMU or real hardware. A fixed
kernel can force-disable the fudge.)

http://git.qemu.org/?p=qemu.git;a=blob;f=hw/pci-host/versatile.c
has the current PCI code, which includes comments about what
the routing is (in particular tables at lines 321 and 340).

>> Unfortunately, the PCI routing is totally undocumented, and as I
>> understand
>> it, there's very few backplanes out there now that finding out their real
>> routing is virtually impossible.  I'm loathed to change it unless someone
>> can point to a definitive source of information on this.

The Versatile boards have TRMs on infocenter.arm.com; the
backplane's wiring is documented in the circuit diagrams
which were distributed on the CD which came with the board
(ie they are non-confidential information, just difficult
to lay your hands on). It's also possible to just test
the hardware, which is what Arnd and I did to confirm that
his patchset was OK.

If somebody would like to fix the kernel I am happy to
locate the PCI backplane and test everything (again).
I would suggest that producing some patches which work
with QEMU 1.5 or later would be a good start; then we
can test on h/w as confirmation before they are applied.

-- PMM

WARNING: multiple messages have this Message-ID (diff)
From: Peter Maydell <peter.maydell@linaro.org>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Russell King - ARM Linux <linux@arm.linux.org.uk>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	qemu-devel@nongnu.org,
	Paul Gortmaker <paul.gortmaker@windriver.com>,
	Arnd Bergmann <arnd.bergmann@linaro.org>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>
Subject: Re: [Qemu-devel] SCSI bus failures with qemu-arm in kernel 3.8+
Date: Mon, 12 Aug 2013 17:24:50 +0100	[thread overview]
Message-ID: <CAFEAcA94ygwRPSsfxs3DvOcTZbdafLiEHys94FG4aXUx+A1t=A@mail.gmail.com> (raw)
In-Reply-To: <52082EF8.10005@roeck-us.net>

On 12 August 2013 01:40, Guenter Roeck <linux@roeck-us.net> wrote:
> On 08/11/2013 03:04 PM, Russell King - ARM Linux wrote:
>> It could be that it's qemu's PCI routing is wrong - it's not the first
>> time that qemu has got something wrong.

QEMU 1.5 has had its Versatile PCI routing code rewritten to
correspond with the hardware (cross-tested versus Arnd Bergmann's
patchset
http://marc.info/?l=linux-arm-kernel&m=128707282403376&w=2
which was run on real versatilePB backplane hardware and
could handle a PCI SATA card). I believe it to be correct,
and I spent a fairly long time wading through the various bits
of documentation and testing those kernel patches on h/w.

(It also includes a back-compatibility fudge so that old
kernels which assumed the old broken QEMU behaviour will
continue to work; it does not attempt to fix up the problems
with kernels from commit 1bc39ac5d to present which don't
work properly on either QEMU or real hardware. A fixed
kernel can force-disable the fudge.)

http://git.qemu.org/?p=qemu.git;a=blob;f=hw/pci-host/versatile.c
has the current PCI code, which includes comments about what
the routing is (in particular tables at lines 321 and 340).

>> Unfortunately, the PCI routing is totally undocumented, and as I
>> understand
>> it, there's very few backplanes out there now that finding out their real
>> routing is virtually impossible.  I'm loathed to change it unless someone
>> can point to a definitive source of information on this.

The Versatile boards have TRMs on infocenter.arm.com; the
backplane's wiring is documented in the circuit diagrams
which were distributed on the CD which came with the board
(ie they are non-confidential information, just difficult
to lay your hands on). It's also possible to just test
the hardware, which is what Arnd and I did to confirm that
his patchset was OK.

If somebody would like to fix the kernel I am happy to
locate the PCI backplane and test everything (again).
I would suggest that producing some patches which work
with QEMU 1.5 or later would be a good start; then we
can test on h/w as confirmation before they are applied.

-- PMM

WARNING: multiple messages have this Message-ID (diff)
From: peter.maydell@linaro.org (Peter Maydell)
To: linux-arm-kernel@lists.infradead.org
Subject: [Qemu-devel] SCSI bus failures with qemu-arm in kernel 3.8+
Date: Mon, 12 Aug 2013 17:24:50 +0100	[thread overview]
Message-ID: <CAFEAcA94ygwRPSsfxs3DvOcTZbdafLiEHys94FG4aXUx+A1t=A@mail.gmail.com> (raw)
In-Reply-To: <52082EF8.10005@roeck-us.net>

On 12 August 2013 01:40, Guenter Roeck <linux@roeck-us.net> wrote:
> On 08/11/2013 03:04 PM, Russell King - ARM Linux wrote:
>> It could be that it's qemu's PCI routing is wrong - it's not the first
>> time that qemu has got something wrong.

QEMU 1.5 has had its Versatile PCI routing code rewritten to
correspond with the hardware (cross-tested versus Arnd Bergmann's
patchset
http://marc.info/?l=linux-arm-kernel&m=128707282403376&w=2
which was run on real versatilePB backplane hardware and
could handle a PCI SATA card). I believe it to be correct,
and I spent a fairly long time wading through the various bits
of documentation and testing those kernel patches on h/w.

(It also includes a back-compatibility fudge so that old
kernels which assumed the old broken QEMU behaviour will
continue to work; it does not attempt to fix up the problems
with kernels from commit 1bc39ac5d to present which don't
work properly on either QEMU or real hardware. A fixed
kernel can force-disable the fudge.)

http://git.qemu.org/?p=qemu.git;a=blob;f=hw/pci-host/versatile.c
has the current PCI code, which includes comments about what
the routing is (in particular tables at lines 321 and 340).

>> Unfortunately, the PCI routing is totally undocumented, and as I
>> understand
>> it, there's very few backplanes out there now that finding out their real
>> routing is virtually impossible.  I'm loathed to change it unless someone
>> can point to a definitive source of information on this.

The Versatile boards have TRMs on infocenter.arm.com; the
backplane's wiring is documented in the circuit diagrams
which were distributed on the CD which came with the board
(ie they are non-confidential information, just difficult
to lay your hands on). It's also possible to just test
the hardware, which is what Arnd and I did to confirm that
his patchset was OK.

If somebody would like to fix the kernel I am happy to
locate the PCI backplane and test everything (again).
I would suggest that producing some patches which work
with QEMU 1.5 or later would be a good start; then we
can test on h/w as confirmation before they are applied.

-- PMM

  reply	other threads:[~2013-08-12 16:25 UTC|newest]

Thread overview: 104+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-11 15:54 SCSI bus failures with qemu-arm in kernel 3.8+ Guenter Roeck
2013-08-11 15:54 ` Guenter Roeck
2013-08-11 22:04 ` Russell King - ARM Linux
2013-08-11 22:04   ` Russell King - ARM Linux
2013-08-12  0:40   ` Guenter Roeck
2013-08-12  0:40     ` Guenter Roeck
2013-08-12  0:40     ` [Qemu-devel] " Guenter Roeck
2013-08-12 16:24     ` Peter Maydell [this message]
2013-08-12 16:24       ` Peter Maydell
2013-08-12 16:24       ` Peter Maydell
2013-08-12 16:45       ` Russell King - ARM Linux
2013-08-12 16:45         ` Russell King - ARM Linux
2013-08-12 16:45         ` Russell King - ARM Linux
2013-08-12 17:33         ` Peter Maydell
2013-08-12 17:33           ` Peter Maydell
2013-08-12 17:33           ` Peter Maydell
2013-08-12 20:06           ` Russell King - ARM Linux
2013-08-12 20:06             ` Russell King - ARM Linux
2013-08-12 20:06             ` Russell King - ARM Linux
2013-08-12 20:49             ` Peter Maydell
2013-08-12 20:49               ` Peter Maydell
2013-08-12 20:49               ` Peter Maydell
2013-08-12 21:21               ` Russell King - ARM Linux
2013-08-12 21:21                 ` Russell King - ARM Linux
2013-08-12 21:21                 ` Russell King - ARM Linux
2013-08-12 21:36                 ` Peter Maydell
2013-08-12 21:36                   ` Peter Maydell
2013-08-12 21:36                   ` Peter Maydell
2013-08-12 22:12                   ` Russell King - ARM Linux
2013-08-12 22:12                     ` Russell King - ARM Linux
2013-08-12 22:12                     ` Russell King - ARM Linux
2013-08-12 22:48                     ` Guenter Roeck
2013-08-12 22:48                       ` Guenter Roeck
2013-08-12 22:48                       ` Guenter Roeck
2013-08-12 23:04                     ` Guenter Roeck
2013-08-12 23:04                       ` Guenter Roeck
2013-08-12 23:04                       ` Guenter Roeck
2013-08-14 10:33                       ` Russell King - ARM Linux
2013-08-14 10:33                         ` Russell King - ARM Linux
2013-08-14 10:33                         ` Russell King - ARM Linux
2013-08-14 12:44                         ` Peter Maydell
2013-08-14 12:44                           ` Peter Maydell
2013-08-14 12:44                           ` Peter Maydell
2013-08-14 12:49                           ` Russell King - ARM Linux
2013-08-14 12:49                             ` Russell King - ARM Linux
2013-08-14 12:49                             ` Russell King - ARM Linux
2013-08-14 12:56                             ` Peter Maydell
2013-08-14 12:56                               ` Peter Maydell
2013-08-14 12:56                               ` Peter Maydell
2013-08-14 14:41                           ` Guenter Roeck
2013-08-14 14:41                             ` Guenter Roeck
2013-08-14 14:41                             ` Guenter Roeck
2013-08-14 15:26                             ` [Qemu-devel] memory reads and writes Herbei Dacian
2013-08-12 17:48         ` [Qemu-devel] SCSI bus failures with qemu-arm in kernel 3.8+ Peter Maydell
2013-08-12 17:48           ` Peter Maydell
2013-08-12 17:48           ` Peter Maydell
2013-08-13  8:37         ` Rob Landley
2013-08-13  8:37           ` Rob Landley
2013-08-13  8:37           ` Rob Landley
2013-08-13  9:12           ` Peter Maydell
2013-08-13  9:12             ` Peter Maydell
2013-08-13  9:12             ` Peter Maydell
2013-08-13 11:30           ` Russell King - ARM Linux
2013-08-13 11:30             ` Russell King - ARM Linux
2013-08-13 11:30             ` Russell King - ARM Linux
2013-08-13  3:40       ` Guenter Roeck
2013-08-13  3:40         ` Guenter Roeck
2013-08-13  3:40         ` Guenter Roeck
2013-08-15 16:45         ` Peter Maydell
2013-08-15 16:45           ` Peter Maydell
2013-08-15 16:45           ` Peter Maydell
2013-08-15 17:54           ` Guenter Roeck
2013-08-15 17:54             ` Guenter Roeck
2013-08-15 17:54             ` Guenter Roeck
2013-08-15 18:05             ` Peter Maydell
2013-08-15 18:05               ` Peter Maydell
2013-08-15 18:05               ` Peter Maydell
2013-08-15 18:39               ` Guenter Roeck
2013-08-15 18:39                 ` Guenter Roeck
2013-08-15 18:39                 ` Guenter Roeck
2013-08-15 20:50               ` Guenter Roeck
2013-08-15 20:50                 ` Guenter Roeck
2013-08-15 20:50                 ` Guenter Roeck
2013-08-15 21:49                 ` Peter Maydell
2013-08-15 21:49                   ` Peter Maydell
2013-08-15 21:49                   ` Peter Maydell
2013-08-15 22:18                   ` Guenter Roeck
2013-08-15 22:18                     ` Guenter Roeck
2013-08-15 22:18                     ` Guenter Roeck
2013-08-15 22:23                     ` Peter Maydell
2013-08-15 22:23                       ` Peter Maydell
2013-08-15 22:23                       ` Peter Maydell
2013-08-15 23:25                       ` Guenter Roeck
2013-08-15 23:25                         ` Guenter Roeck
2013-08-15 23:25                         ` Guenter Roeck
2013-08-19 15:26                       ` Guenter Roeck
2013-08-19 15:26                         ` Guenter Roeck
2013-08-19 15:26                         ` Guenter Roeck
2013-08-12 19:02     ` Paul Gortmaker
2013-08-12 19:02       ` Paul Gortmaker
2013-08-12 19:02       ` [Qemu-devel] " Paul Gortmaker
2013-08-12 20:58       ` Peter Maydell
2013-08-12 20:58         ` Peter Maydell
2013-08-12 20:58         ` [Qemu-devel] " Peter Maydell

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='CAFEAcA94ygwRPSsfxs3DvOcTZbdafLiEHys94FG4aXUx+A1t=A@mail.gmail.com' \
    --to=peter.maydell@linaro.org \
    --cc=arnd.bergmann@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=linux@roeck-us.net \
    --cc=paul.gortmaker@windriver.com \
    --cc=qemu-devel@nongnu.org \
    /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.