On Mon, Nov 4, 2024 at 1:01 PM <Valentina.FernandezAlanis@xxxxxxxxxxxxx> wrote: > > On 03/11/2024 00:23, Jassi Brar wrote: > Regarding the EXPORT function, I understand that it’s also possible to > retrieve con_priv from mbox_chan in the client. However, I felt it would > be cleaner to export the function to obtain the channel ID directly, > rather than declaring the struct ipc_chan_info in a header file to make > it accessible to the client. > > If necessary, I can remove the function and instead expose struct > ipc_chan_info in linux/mailbox/mchp-ipc.h. > Yes please avoid EXPORT at any cost. They are only acceptable when no other means exist. > > > >> +static struct platform_driver mchp_ipc_driver = { > >> + .driver = { > >> + .name = "microchip_ipc", > >> + .of_match_table = mchp_ipc_of_match, > >> + }, > >> + .probe = mchp_ipc_probe, > > The driver could be built as a module, so please provide .remove() > > even if you never intend to unload it. > In this particular case, there is nothing specific to implement in the > .remove() function because all resources allocated in the .probe() > function are managed using devm_* OK.