On 5/30/19 2:17 AM, Andrew Lunn wrote:
>> @@ -423,18 +434,41 @@ static int dsa_tree_setup_switches(struct
>> dsa_switch_tree *dst)
>>
>> err = dsa_switch_setup(ds);
>> if (err)
>> -return err;
>> +goto setup_switch_err;
>
> Mino
> @@ -423,18 +434,41 @@ static int dsa_tree_setup_switches(struct
> dsa_switch_tree *dst)
>
> err = dsa_switch_setup(ds);
> if (err)
> - return err;
> + goto setup_switch_err;
Minor nit pick.
All the other labels you add are e
In case a call to dsa_tree_setup() fails, an attempt to cleanup is made
by calling dsa_tree_remove_switch(), which should take care of
removing/unregistering any resources previously allocated. This does not
happen because it is conditioned by dst->setup being true, which is set
only after _all_ se