On 10/27/20 11:50 PM, Leon Romanovsky wrote: > Failure in srpt_refresh_port() for the second port will leave MAD > registered for the first one, however, the srpt_add_one() will be > marked as "failed" and SRPT will leak resources for that registered > but not used and released first port. > > Unregister the MAD agent for all ports in case of failure. Reviewed-by: Bart Van Assche <bvanassche@xxxxxxx>