via_do_set_mode(9)
β¨ NAME β¨
via_do_set_mode β the one that sets your transfer mode data, bestie π
So this page is from the Kernel API Manual, section 9 β like, kernel-internals territory, iykyk. Pull up a chair π
β¨ SYNOPSIS β¨
void via_do_set_mode (struct ata_port *ap , struct ata_device *adev ,
int mode , int set_ast , int udma_type );
No cap, it returns void β it's giving "I do the work, I don't report back" energy π«Ά
β¨ ARGUMENTS β¨
apβ the ATA interface. your whole entire port, the main character here πadevβ the ATA device. the actual little guy we're configuring π¦modeβ the ATA mode being programmed. literally the vibe we're setting it to βset_astβ set this to program address setup. yes bestie, it's a flag, it does a thing πudma_typeβ the UDMA mode slash format of the registers. register-flavoured UDMA, okay?? π
β¨ DESCRIPTION β¨
Okay so here's the tea π β this function programs the VIA registers for DMA and PIO modes. It uses the ata timing support to compute those modes, so it's not out here freestyling the numbers, it's doing it properly. Slay β¨
β οΈ FIXME: hotplug is gonna require that we serialize multiple mode changes on the two channels. so like, yeah, that's a known thing that needs handling β noted, not solved, periodt π
β¨ SEE ALSO β¨
Go read these next, they're all in the kernel file ./drivers/ata/pata_via.c and they're lowkey iconic π
via_cable_detect(9)via_mode_filter(9)via_tf_load(9)via_config_fifo(9)via_init_one(9)via_reinit_one(9)
kisses, this page lives in ./drivers/ata and it's stamped October 2026 β via_do_set_mode(9) out πβ¨π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms