i3c_master_register(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ i3c_master_register ✨

okay so this is a page from the Kernel API Manual β€” yes the actual kernel, yes it's a whole vibe πŸ’… β€” and today's main character is i3c_master_register. it's the function that registers an I3C master. you're gonna love it, i promise 🫢


🌸 SYNOPSIS 🌸

int i3c_master_register (struct i3c_master_controller *master , struct
       device *parent , const struct i3c_master_controller_ops *ops , bool
       secondary );

like, four whole arguments. we stay fed πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • master β€” the master that's gonna be out here sending frames on the bus. it's giving "the one who does the talking" ✨
  • parent β€” the parent device, aka the thing that actually provides this I3C master controller. the mothership, if you will πŸ›Έ
  • ops β€” the master controller operations. all the little behaviors πŸ’–
  • secondary β€” set it to true if you're registering a secondary master. BUT heads up bestie: it will return -EOPNOTSUPP if you set it to true, because secondary masters are not yet supported. so like... don't 😭 (not us being early adopters fr fr)

πŸ¦‹ DESCRIPTION πŸ¦‹

so basically this function does everything for you. it's the ultimate "i got you" bestie. no cap, it takes care of all of this:

  • creates and initializes the I3C bus πŸŽ€
  • populates the bus with static I2C devs if parent->of_node is not NULL (read that conditional carefully bestie, it's doing a lot of work πŸ’…)
  • registers all I3C devices that the controller added during bus initialization ✨
  • registers the I2C adapter and all the I2C devices 🌈

literally a full glow-up routine for your bus. obsessed. πŸ”₯


πŸ‘‘ RETURN πŸ‘‘

0 in case of success β€” slay πŸŽ‰ β€” or a negative error code otherwise πŸ˜”


πŸ’œ SEE ALSO πŸ’œ

the kernel file ./drivers/i3c/master.c plus this whole extended friend group of functions. i'm listing every single one because we don't do "etc." around here πŸ™ˆ

i3c_bus_maintenance_lock(9), i3c_bus_maintenance_unlock(9), i3c_bus_normaluse_lock(9), i3c_bus_normaluse_unlock(9), i3c_master_queue_hotjoin(9), i3c_master_send_ccc_cmd_locked(9), i3c_master_get_free_addr(9), i3c_master_setaasa_locked(9), i3c_master_entdaa_locked(9), i3c_master_enec_disec_locked(9), i3c_master_disec_locked(9), i3c_master_enec_locked(9), i3c_master_defslvs_locked(9), i3c_master_reattach_i3c_dev_locked(9), i3c_master_has_wakeup_enabled_devs(9), i3c_master_dma_map_single(9), i3c_master_dma_unmap_single(9), i3c_master_set_info(9), i3c_master_bus_init(9), __i3c_master_add_i3c_dev_locked(9), i3c_master_add_i3c_dev_locked(9), i3c_master_do_daa_ext(9), i3c_master_do_daa(9), i3c_master_queue_ibi(9), i3c_generic_ibi_free_pool(9), i3c_generic_ibi_alloc_pool(9), i3c_generic_ibi_get_free_slot(9), i3c_generic_ibi_recycle_slot(9), i3c_master_unregister(9), i3c_dev_disable_ibi_locked(9), i3c_dev_enable_ibi_locked(9), i3c_dev_request_ibi_locked(9), i3c_dev_free_ibi_locked(9)


ok that's the whole page, go register something iconic πŸ§šβ€β™€οΈβœ¨

and that's a wrap, bestie β€” brought to you straight out of ./drivers/i3c, dated October 2026. see you in the next man page πŸ’–πŸŒΈπŸ’…

πŸ“¦ where this page comes from