ctucan_set_btr(9)
π ctucan_set_btr β like, the bit timing plug for CTU CAN FD π¦
okay so bestie, welcome to the kernel API manual β this is ctucan_set_btr(9), and honestly? it's giving "small function, big responsibility" energy. β¨ It sets the CAN bus bit timing in CTU CAN FD. That's the whole vibe. No cap.
πΈ SYNOPSIS πΈ
int ctucan_set_btr (struct net_device *ndev , struct can_bittiming *bt ,
bool nominal );
literally just three args and an int coming back at you. iconic.
π ARGUMENTS π
ndevβ pointer to thenet_devicestructure. your main character netdev, hi bestie π«Άbtβ pointer to the Bit timing structure. this is where the actual timing tea lives πnominalβtruemeans Nominal bit timing,falsemeans Data bit timing. pick your fighter, both are valid π
β RETURN β
0β OK! we slayed, everything worked π-EPERMβ returned if the controller is enabled. yep, that's a hard no from the hardware, sorry bestie π
no cap, that -EPERM is a real "not me trying to set timing on an already-running controller" moment. respect the gate.
π SEE ALSO π
okay this list is long but every single one of these is invited to the group chat, fr fr:
- the Kernel file
./drivers/net/can/ctucanfd/ctucanfd_base.c ctucan_state_to_str(9)ctucan_reset(9)ctucan_set_bittiming(9)ctucan_set_data_bittiming(9)ctucan_set_secondary_sample_point(9)ctucan_set_mode(9)ctucan_chip_start(9)ctucan_do_set_mode(9)ctucan_get_tx_status(9)ctucan_is_txt_buf_writable(9)ctucan_insert_frame(9)ctucan_give_txtb_cmd(9)ctucan_start_xmit(9)ctucan_read_rx_frame(9)ctucan_rx(9)ctucan_read_fault_state(9)ctucan_get_rec_tec(9)ctucan_err_interrupt(9)ctucan_rx_poll(9)ctucan_rotate_txb_prio(9)ctucan_tx_interrupt(9)ctucan_interrupt(9)ctucan_chip_stop(9)ctucan_open(9)ctucan_close(9)ctucan_get_berr_counter(9)
iykyk π
and that's the whole page bestie β brought to you by the source/version at ./drivers/net/can/ctucanfd, dated October 2026. go forth and set those bit timings π§ββοΈπ
π¦ 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