Re: [PATCH v4 net RESEND] net/sonic: Fix some resource leaks in error handling paths

2021-01-05 Thread David Miller
From: Finn Thain Date: Sun, 03 Jan 2021 11:26:26 +1100 > From: Christophe JAILLET > > A call to dma_alloc_coherent() is wrapped by sonic_alloc_descriptors(). > > This is correctly freed in the remove function, but not in the error > handling path of the probe function. Fix this by adding the m

[PATCH v4 net RESEND] net/sonic: Fix some resource leaks in error handling paths

2021-01-02 Thread Finn Thain
From: Christophe JAILLET A call to dma_alloc_coherent() is wrapped by sonic_alloc_descriptors(). This is correctly freed in the remove function, but not in the error handling path of the probe function. Fix this by adding the missing dma_free_coherent() call. While at it, rename a label in orde