Date: Tue, 1 May 2007 13:31:33 +0000 (UTC) From: Marius Strobl <marius@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/sparc64/pci psycho.c psychoreg.h Message-ID: <200705011331.l41DVXMM073048@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
marius 2007-05-01 13:31:33 UTC FreeBSD src repository Modified files: (Branch: RELENG_6) sys/sparc64/pci psycho.c psychoreg.h Log: MFC: psycho.c 1.61; psychoreg.h 1.12 o Changes to psycho_attach(): [1] - Clear the PCI AFSR and status error bits as previous errors still might be indicated. - Set up the PCI control and diagnostic registers according to the capabilities, workarounds, etc of/for specific revisions of the supported bridges. This includes no longer setting Hummingbird-/ Sabre-specific bits in the PCI control register but preserving what the firmware has initialized them to like OpenSolaris does. Previously we were setting these bits according to the example in the Sabre documentation, which I doubt is appropriate for all Sabre based designs and especially not for Hummingbirds. This also includes not enabling bus parking unless the firmware tells us to. - Set the PCI latency timer register as this isn't always done by the firmware. o Remove a redundant argument from psycho_set_intr() and in this function check the return value of bus_setup_intr(). [2] o Let psycho_setup_intr() return ENOMEM instead of 0 when it can't allocate memory for the interrupt wrapper stub and EINVAL instead of 0 if it can't find the interrupt vector in the interrupt map. o Add a workaround for a bug of the Sabre-APB-combination where it doesn't drain DMA write data for devices behind additional PCI-PCI bridges underneath the APB PCI-PCI bridge. This workaround (do things necessary in order to achieve a manual drain when coherency is required) is currently implemented in psycho_setup_intr() and psycho_intr_stub() due to lack of a real BUS_GET_DMA_TAG() and psycho(4)-specific bus_dma_tag_create() and bus_dmamap_sync() methods, respectively, in RELENG_6 and therefore is only applied for interrupt handlers but not for polling(4) callbacks. [3] o Fix some minor style issues. Info from: OpenSolaris [1] Info from: Linux, OpenBSD, OpenSolaris [3] Suggested by: Coverity Prevent (CID 682) [2] Revision Changes Path 1.53.2.3 +189 -55 src/sys/sparc64/pci/psycho.c 1.9.2.2 +36 -9 src/sys/sparc64/pci/psychoreg.h
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200705011331.l41DVXMM073048>