[PATCH v10 2/7] i3c: master: use i3c_master_register only for main master

Parshuram Raju Thombare pthombar at cadence.com
Tue Dec 8 00:47:51 EST 2020


>This looks a bit confusing. Here you're rolling back detailss in
>i3c_primary_master_register() that were factored out in
>i3c_master_init(). If i3c_master_init() is successful, then you
>shouldn't be undoing its things openly in i3c_primary_master_register().
>Instead, there should be another function that does the reverse of
>i3c_master_init() here.

Every function do its cleanup in case of failures.
And if any failure occur after successful i3c_master_init(), we have
function i3c_master_bus_cleanup() which does the major cleanup.

Regards,
Parshuram Thombare



More information about the linux-i3c mailing list