We have this infrastructure in the kernel for doing asynchronous IO, which sits in fs/aio.c and fs/direct-io.c mainly. It works fine and it's pretty fast. From userspace you would link with -laio and use the functions there for hooking into the syscalls. However, it's only really async for direct uncached IO (files opened with O_DIRECT). This last little detail essentially means that it's largely useless to most people. Oracle uses it, and other databases may as well. But nobody uses aio on the desktop or elsewhere simply because it isn't a good fit when O_DIRECT is required - you then need aligned IO buffers and transfer sizes and you lose readahead. The alignment and size restrictions also make it difficult to convert existing apps to use libaio with O_DIRECT, since it requires more than just a straight forward conversion. It adds complexity.
Over the years, several alternative approaches to async IO have been proposed/developed. We've had several variants of uatom/syslet/fibril/threadlet type schemes, which all boil down to (just about) the same type of implementation - when a process is about to block inside the kernel, a cloned process/thread returns to userspace on behalf of the original process and informs it of the postponed work. The completed events can then later be retrieved through some sort of get_event/wait_event type interface, similar to how you reap completions with other types of async IO. Or the implementation provided a callback type scheme, similar to how eg a signal would be received in the process. This sort of setup performed acceptably, but suffered from the schizophrenic disorder of split personalities due to the change in personalities on return from the kernel. Various approaches to "fix" or alleviate this problem weren't particularly pretty.
Recently, Zach Brown started playing with something he calls acall. The user interface is pretty neat, and (like the above syslet etc like implementations), it allows for performing all system calls in an async nature. Zach took a more simplified approach for making it async in the kernel, by punting every operation to a thread in the kernel. This obviously works and means that the submission interface is very fast, which is of course a good thing. It also means that some operations are going to be performed by someone else than the process that requested the operation, which has implications for IO scheduling in the system. Advanced IO schedulers like CFQ tracks IOs on a per-process basis, and they then need the specific process context for both performance and accounting reasons. Last year I added a CLONE_IO flag for sharing the IO context across processes for situations like this, so this part is actually easily fixable by just using that clone flag for creation of the kernel worker thread. Obviously, doing a fork() like operation for every async system call isn't going to scale, so some sort of thread pooling must be put in place for speeding it up. Not sure what Zach has done there yet (I don't think a version with that feature has been released yet), but even with that in place there's still going to be identity fiddling when a thread is taking over work from a user space process. Apart from the overhead of juggling these threads, there's also going to be a substantial increase in context switch rates with this type of setup. And this last bit is mostly why I don't think the acall approach will end up performing acceptably for doing lots of IO, while it does seem to be quite nice for the more casual async system call requirements.
A third and final possibility also exists, and this is what I have been trying to beat into submission lately. Back in the very early 2.6 kernel days, Suparna Bhattacharya led an effort to add support for buffered IO to the normal fs/aio.c submission path. The patches sat in Andrews -mm tree for some time, before they eventually got dropped due to Andrew spending too much time massaging them into every -mm release. They work by replacing the lock_page() call done for waiting IO completion to a page with another helper function - I call it lock_page_async() in the current patches. If the page is still locked when this function is called, we return -EIOCBRETRY to the caller, informing him that he should retry this call later on. When a process in the kernel wants to wait for some type of event, a wait queue is supplied. When that event occurs, the other end does a wake up call on that wait queue. This last operation invokes a callback in the wait queue, which normally just does a wake_up_process() like call to wake the process blocked for this event. With the async page waiting, we simply provide our own wait queue in the process structure and the callback given from fs/aio.c then merely adds the completed event to the aio ringbuffer associated with the IO context for that IO and process.
This last approach means that we have to replace the lock_page() calls in the IO path with lock_page_async() and be able to handle an "error" return from that function. But apart from that, things generally just work. The original process is still the one that does the IO submission, thus we don't have to play tricks with identity thefts or pay the large context switch fee for each IO. We also get readahead. In other words, it works just like you expect buffered IO to work. Additionally, the existing libaio interface works for this as well. Currently my diffstat looks like this:
19 files changed, 445 insertions(+), 153 deletions(-)
for adding support for the infrastructure, buffered async reads, and buffered async writes for ext2 and ext3. That isn't bad, imho.
Initial performance testing looks encouraging. I'll be back with more numbers and details, as progress and time permits!
Intelligence View
⚡ tsecurity.de Intelligence
Buffered async IO
We have this infrastructure in the kernel for doing asynchronous IO, which sits in fs/aio.c and fs/direct-io.c mainly. It works fine and it's pretty fast. From…
Powered by tsecurity.de
tsecurity.de Hub
Security Briefing Gratis · 1-klik uitschrijven
Intelligence Digest gratis
Dagelijks het belangrijkste beveiligingsnieuws · kan op elk moment worden opgehaald
Community Rating & Social Proof
⭐ Lezersbeoordeling
–
Ø / 5.0
★★★★★
Nog geen recensies van lezers
Was dit artikel nuttig?
0
Powered by tsecurity.de
tsecurity.de Hub
Verwant Story Cluster & Sources (vector AI)
6 Cluster
Verwant Story Cluster & Sources (vector AI)
14 Bronnen
Black Friday PC deals: save on Acer, Dell, HP, and more — including gaming PCs
Latest from TechRadar 20 min. geleden
13 andere bronnen
CCaschys Blog43 min. geledenAmazon Visa: Vom 26. bis 30. November 2026 punket ihr mit der Kreditkarte doppelt – passend zum Black Friday PPC-WELT17 min. geledenBeliebter Akku-Laubbläser für unter 54 Euro im Black-Friday-Angebot bei Amazon PPC-WELT35 min. geledenAmazon Black Friday Woche am Mittwoch: Diese Technik-Angebote empfehlen wir PPC-WELT53 min. geledenGeballtes IT-Wissen jetzt mit 30 % Rabatt: PC-WELT Plus als Black-Friday-Hammer-Deal CCNET1 uur geledenSpoil Your Furry Friend With Our Favorite Pet Water Filter While It’s $50 Off This Black Friday PPC-WELT1 uur geledenNeues Microsoft Surface Laptop mit 13,8-Zoll-Display ist 630 Euro günstiger in der Black-Friday-Woche PPC-WELT1 uur geledenNeues Microsoft Surface Laptop mit 13,8-Zoll-Display ist 630 Euro günstiger in der Black-Friday-Woche GGolem.de1 uur geledenAnzeige: DJI-Smartphone-Gimbal zum neuen Black-Friday-Bestpreis unter 100 Euro bei Amazon TThe Mac Observer1 uur geledenDell 14 Plus with 32GB drops to $1,299.99 for Black Friday, $400 under Dell WWinFuture News1 uur geledenPreise fast halbiert: 4K-Laser-Beamer zum Black-Friday-Tiefpreis Nnetzwelt.de2 uur geledenSony Bravia OLED-Fernseher für unter 900 Euro: Kann dieses Black-Friday-Angebot wahr sein? MMacerkopf.de2 uur geledenBlack Friday: AirPods Pro 3 bei Amazon zum Bestpreis – jetzt für nur 179 Euro [Update] MMacerkopf.de1 uur geledenVodafone Black Friday: GigaZuhause CableMax 1000 nur 49,99 Euro + 250€ Cashback + kostenlose FRITZ!Box 6670
7 Bronnen
CVE-2026-99648 | Linux Kernel up to 6.18.63/7.3.4/7.4-rc1 VMA Management mm/vma vma_merge_existing_range information disclosure (Nessus ID 385860)
VulDB Updates 38 min. geleden
6 andere bronnen
VVulDB Updates1 uur geledenCVE-2026-98490 | Linux Kernel up to 6.12.111/6.18.54/7.2.8/7.3-rc4 openvswitch conntrack nf_ct_helper use after free (Nessus ID 385860) VVulDB Updates1 uur geledenCVE-2026-99661 | Linux Kernel up to 6.12.117/6.18.63/7.3.4/7.4-rc1 gup gup_fast_fallback integer overflow (Nessus ID 385860) VVulDB Updates2 uur geledenCVE-2026-72367 | Linux Kernel up to 6.18.39/7.1.4/7.2-rc1 iomap iomap_writeback_handle_eof io_size integer underflow (Nessus ID 385860) VVulDB Updates2 uur geledenCVE-2026-81015 | Linux Kernel up to 6.18.49/7.2.3 AMD PMC Driver pmc.c amd_pmc_probe memory corruption (Nessus ID 385860) VVulDB Updates2 uur geledenCVE-2026-89899 | Linux Kernel up to 6.12.109/6.18.50/7.2.4 cec cec_transmit_msg_fh race condition (Nessus ID 385860) VVulDB Updates2 uur geledenCVE-2026-98373 | Linux Kernel up to 6.12.111/6.18.54/7.2.8/7.3-rc4 hugetlb move_hugetlb_page_tables input validation (Nessus ID 385860)
6 Bronnen
CVE-2026-134644 | Webmin up to 2.670 minecraft minecraft-lib.pl path traversal (EUVD-2026-134897)
VulDB Updates 1 uur geleden
5 andere bronnen
VVulDB Updates1 uur geledenCVE-2026-134648 | Webmin up to 2.670 Autoreply sendmail/autoreply.pl subject/from/date/body injection (EUVD-2026-134893) VVulDB Updates1 uur geledenCVE-2026-134647 | Webmin up to 2.670 RPC web-lib-funcs.pl remote_eval cleartext transmission (EUVD-2026-134894) VVulDB Updates2 uur geledenCVE-2026-18379 | Red Hat Enterprise Linux yggdrasil-worker-package-manager path traversal (Nessus ID 385862) VVulDB Updates2 uur geledenCVE-2026-136430 | PyTorch Foundation 2.14.0 Model Package Loader path traversal (EUVD-2026-134452) VVulDB Updates2 uur geledenCVE-2026-51862 | eosphoros-ai DB-GPT 0.8.0 skill_upload agentic_data_api.py path traversal
6 Bronnen
Top 10 Best Email Security Solutions in 2026 [Ranked & Scored]
Cyber Security News 2 uur geleden
5 andere bronnen
CCyber Security News2 uur geledenTop 10 Best Cloud Email Security Solutions (Microsoft 365 & Google) in 2026 [Ranked & Scored] CCyber Security News2 uur geledenTop 10 Best Red Team & Adversary Emulation Services in 2026 [Ranked & Scored] CCyber Security News2 uur geledenTop 10 Best Managed Vulnerability Scanning Services in 2026 [Ranked & Scored] IIT Security News2 uur geledenTop 10 Best Penetration Testing as a Service (PTaaS) Platforms in 2026 [Ranked & Scored] IIT Security News2 uur geleden12 Account Takeover (ATO) Protection Solutions : The 2026 Buyer’s Verdict Guide
5 Bronnen
Hackers Exploit Unpatched Flaw in Defunct Idunno AntiCsrf Library
IT Security News 11 min. geleden
4 andere bronnen
SSecurityWeek39 min. geledenHackers Exploit Unpatched Flaw in Defunct Idunno AntiCsrf Library IIT Security News1 uur geledenIT Security News Hourly Summary 2026-11-25 09h : Exploited: Abandoned Idunno.AntiCsrf library opens legacy ASP.NET apps to RCE (CVE-2026-131914) and 14 more posts IIT Security News2 uur geledenExploited: Abandoned Idunno.AntiCsrf library opens legacy ASP.NET apps to RCE (CVE-2026-131914) HHelp Net Security2 uur geledenExploited: Abandoned Idunno.AntiCsrf library opens legacy ASP.NET apps to RCE (CVE-2026-131914)
4 Bronnen
Kundendaten betroffen: Datenleck bei Deichmann
Computer Bild - COMPUTER BILD 41 min. geleden
3 andere bronnen
Nnetzwelt.de1 uur geledenDatenleck bei Deichmann: Wer im Onlineshop bestellt hat, sollte jetzt auf diese Mails achten GGoogle Alert1 uur geledenCyberangriff auf Schuhhändler: Hacker erbeuten Kundendaten von Deichmann - Golem.de GGolem.de1 uur geledenCyberangriff auf Schuhhändler: Hacker erbeuten Kundendaten von Deichmann
Mehr aus dieser Kategorie
Blättern: Pfeiltasten [ ← ] [ → ] · Tasten j / k · mobil: Wischen
HAND-OFF
Auf Smartphone übergeben (ADVISORY)
Scannen Sie den QR-Code mit der Smartphone-Kamera für sofortigen mobilen Zugriff:
https://tsecurity.de/nl/3500978/unix-linux-servers/buffered-async-io/
💬 Communitydiscussie & reacties
Start de discussie in de Social Chat broadcaststream of dien hierboven een vakbijdrage in via het aanvulformulier.