svn commit: r291142 - in head/sys: arm/arm arm64/arm64 mips/mips powerpc/powerpc x86/x86

Mark Johnston markj at FreeBSD.org
Mon Nov 23 03:22:58 UTC 2015


On Sat, Nov 21, 2015 at 07:55:01PM +0000, Svatopluk Kraus wrote:
> Author: skra
> Date: Sat Nov 21 19:55:01 2015
> New Revision: 291142
> URL: https://svnweb.freebsd.org/changeset/base/291142
> 
> Log:
>   Fix BUS_DMA_MIN_ALLOC_COMP flag logic. When bus_dmamap_t map is being
>   created for bus_dma_tag_t tag, bounce pages should be allocated
>   only if needed.
>   
>   Before the fix, they were allocated always if BUS_DMA_COULD_BOUNCE flag
>   was set but BUS_DMA_MIN_ALLOC_COMP not. As bounce pages are never freed,
>   it could cause memory exhaustion when a lot of such tags together with
>   their maps were created.
>   
>   Note that there could be more maps in one tag by current design.
>   However BUS_DMA_MIN_ALLOC_COMP flag is tag's flag. It's set after
>   bounce pages are allocated. Thus, they are allocated only for first
>   tag's map which needs them.

This appears to cause a hang with one of the re(4) interfaces in my
workstation. I can use it to start an ssh session, but it quickly hits a
point where it stops transmitting or receiving packets, and I need to
reboot the system to recover. Interestingly, the other re(4) interface
in this system works fine, but it drives a different card:

working:
re0 at pci0:3:0:0: class=0x020000 card=0x85051043 chip=0x816810ec rev=0x09 hdr=0x00
vendor     = 'Realtek Semiconductor Co., Ltd.'
device     = 'RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller'
class      = network
subclass   = ethernet

non-working:
re1 at pci0:5:0:0: class=0x020000 card=0x816910ec chip=0x816910ec rev=0x10 hdr=0x00
vendor     = 'Realtek Semiconductor Co., Ltd.'
device     = 'RTL8169 PCI Gigabit Ethernet Controller'
class      = network
subclass   = ethernet


More information about the svn-src-all mailing list