xcan_set_error_state(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ xcan_set_error_state ✨ (kernel API manual, section 9)

okay so bestie, we're in the kernel API manual (section 9) and this little icon is called xcan_set_error_state β€” say it with me, it's giving "let me just quietly fix the vibe of this CAN device" πŸ’…


🌸 SYNOPSIS 🌸

void xcan_set_error_state (struct net_device *ndev , enum can_state
new_state , struct can_frame *cf );

like, it returns nothing (void) and it takes three things. that's it. that's the whole entrance exam πŸŽ€


πŸ’– ARGUMENTS πŸ’–

  • ndev β€” a pointer to the net_device structure. your actual device, your main character 🫢
  • new_state β€” the new CAN state to be set. it's an enum can_state, so like, pick a state, any state ✨
  • cf β€” the error frame to be populated, or NULL. yes queen, NULL is allowed, it's optional and we respect that πŸ™ˆ

πŸ¦‹ DESCRIPTION πŸ¦‹

so what does it actually do? it sets a new CAN error state for the device. while it's at it, it also updates the statistics and populates the error frame β€” but only if you actually gave it one (cf). no frame, no populating. simple as that πŸ’€


⭐ SEE ALSO ⭐

literally the whole friend group, no cap. if you're gonna hang out with xcan_set_error_state, you're gonna meet all of these:


and that's the whole page, bestie 🧚 no notes, ate and left no crumbs πŸ‘‘

k byeee, this one lives in ./drivers/net/can and it's dated October 2026 β€” so like, it's from the future, iconic behavior honestly πŸŒˆπŸ’œ
πŸ“¦ where this page comes from