[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241014074151.GA22419@lst.de>
Date: Mon, 14 Oct 2024 09:41:51 +0200
From: Christoph Hellwig <hch@....de>
To: Hannes Reinecke <hare@...e.de>
Cc: Ming Lei <ming.lei@...hat.com>,
Hamza Mahfooz <someguy@...ective-light.com>,
Christoph Hellwig <hch@....de>,
Dan Williams <dan.j.williams@...el.com>,
linux-block@...r.kernel.org, io-uring@...r.kernel.org,
linux-raid@...r.kernel.org, iommu@...ts.linux.dev,
linux-kernel@...r.kernel.org
Subject: Re: [Report] annoyed dma debug warning "cacheline tracking EEXIST,
overlapping mappings aren't supported"
On Mon, Oct 14, 2024 at 09:23:14AM +0200, Hannes Reinecke wrote:
>> 3) some storage utilities
>> - dm thin provisioning utility of thin_check
>> - `dt`(https://github.com/RobinTMiller/dt)
>>
>> I looks like same user buffer is used in more than 1 dio.
>>
>> 4) some self cooked test code which does same thing with 1)
>>
>> In storage stack, the buffer provider is far away from the actual DMA
>> controller operating code, which doesn't have the knowledge if
>> DMA_ATTR_SKIP_CPU_SYNC should be set.
>>
>> And suggestions for avoiding this noise?
>>
> Can you check if this is the NULL page? Operations like 'discard' will
> create bios with several bvecs all pointing to the same NULL page.
> That would be the most obvious culprit.
The only case I fully understand without looking into the details
is raid1, and that will obviously map the same data multiple times
because it writes it out multiple time. Now mapping a buffer
multiple times for a DMA_TO_DEVICE is relatively harmless in
practice as the data is transferred to the device, but it it
still breaks the dma buffer ownership model in the dma which is
really helpful to find bugs where people don't think about this
at all. Not sure if there is any good solution here.
Powered by blists - more mailing lists