Port-alpha archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: I did a test on a DEC AlphaStation 600 and the SCSI driver seems borked
>
> What’s happening is that the PCI front-end (sys/dev/pci/isp_pci.c) is converting the normal RQSTYPE_REQUEST request into RQSTYPE_A64 (“request, but using 64-bit DMA addressing”). It does this conditional on "sizeof (bus_addr_t) > 4”, which at first glance is correct, but it’s actually not. The NetBSD PCI infrastructure has two separate DMA “tags” (mapping back-ends), the standard DMA tag, and the 64-bit DMA tag. A device using the standard DMA tag does not need to use 64-bit DMA, and so this test that the PCI front-end is doing is incorrect; it doesn’t need to use 64-bit DMA at all.
>
> (In fact, on most NetBSD/alpha systems, 64-bit PCI DMA is not necessary because the max RAM in the system is within the DMA window that fits into 32 address bits; the only one that supports a large 64-bit DMA window are the Titan-class systems, such as the DS25.). But even those systems have an IOMMU that supports 32-bit PCI devices.
>
> In any case, this PCI front-end behavior would be fine except for the logic in sys/dev/ic/isp.c:isp_intr() does not properly handle the 64-bit flavor of the request. It has a normal-completion handler for it that implies it should be handled exactly like the garden-variety RQSTYPE_REQUEST:
>
I've been struggling with the ISP driver on Linux for a while,
(qla1280 as linux call it). The Linux driver
can be built as a "64-bit driver" by setting QLA_64BIT_PTR which is
by default if we have
CONFIG_ARCH_DMA_ADDR_T_64BIT. This is actually required for the driver
to work on some SGI/mips
systems. My issues with the driver turned out to be DAC support on
Alpha. The driver ran fine in 64-bit mode
with a 64-bit DMA_MASK enbeling the "monster window" on Alpha. This
worked fine on Rawhide based
Alphas such as the Alphaserver 4100, but does not work on tsunami
based Alphas, such as ES40.
At least when there is more than 2GB RAM available, if enabled, the
"monster window" is activated
on Alpha systems with more than 2GB RAM if the DMA_MASK is > 40 bits.
Anyways I ended up with
the conclusion that the Linux driver was fine, but there was issues
with PCI/DAC/DMA on certain Alphas
32-bit mode on the ISP driver worked on all combinations of ISP cards
(tested ISP1080, ISP1040revB and
ISP1040revC, ISP1020). When the driver was in 64-bit mode with full
64-bit DMA mask, certain combination
of cards and Alpha chipsets and installed RAM did not work, most
notably any ISP card with a 32-bit PCI
interface did not work on tsunami based Alphas that had more than 2GB
ram installed. At the time I was
working on this issue for Linux I looked at how NetBSD did things for
the card since my qlogic ISP1040 card
worked fine on NetBSD, but maybe NetBSD never activated the monster
window for DMA transfers?
Anyway, this was maybe a bit off topic but I wanted to share some of
my experiences with qlogic ISP cards
on Alpha, even though it's mostly on Linux.
Magnus
Home |
Main Index |
Thread Index |
Old Index