Re: [v20 02/13] rtase: Implement the .ndo_open function
From: Markus Elfring
Date: Mon Jun 17 2024 - 06:08:47 EST
>> How do you think about to increase the application of scope-based resource management?
>> https://elixir.bootlin.com/linux/v6.10-rc3/source/include/linux/cleanup.h#L8
>
> Due to our tx and rx each having multiple queues that need to
> allocate descriptors, if any one of the queues fails to allocate,
> rtase_alloc_desc() will return an error. Therefore, using 'goto'
> here rather than directly returning seems to be reasonable.
Some goto chains can be replaced by further usage of advanced cleanup techniques,
can't they?
Regards,
Markus