Re: git: b7761f1f0830 - main - x86/busdma: Limit reserved pages if low nsegs
- In reply to: Bjoern A. Zeeb: "Re: git: b7761f1f0830 - main - x86/busdma: Limit reserved pages if low nsegs"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 22 Oct 2022 20:53:03 UTC
On 10/22/22 13:07, Bjoern A. Zeeb wrote: > On Sat, 22 Oct 2022, Colin Percival wrote: >> Since pages used for bouncing are typically non-consecutive, each >> bounced page will typically constitute a busdma segment; as such, we >> are unlikely to ever successfully use more pages than the nsegments >> limit. Limit the number of pages reserved to nsegments. > > This is an interesting observation. LinuxKPI desperately needs more > consecutive pages but can only ever use one segment. > > We do have observed cases of bouncing failing due to the LinuxKPI > constraints and what busdma provided. Similar issue with Firecracker -- its virtio block backend only supports a single data segment, so for now our virtio_blk driver is limited to 4 kB I/Os. I was considering adding code to virtio_blk to reserve a contiguous buffer and use it when busdma failed, but theoretically this could be done in busdma instead. -- Colin Percival Security Officer Emeritus, FreeBSD | The power to serve Founder, Tarsnap | www.tarsnap.com | Online backups for the truly paranoid