Re: [PATCH 2/2] dma:of: Use a mutex to protect the of_dma_list

From: Arnd Bergmann
Date: Fri Apr 19 2013 - 08:25:56 EST


On Friday 19 April 2013, Lars-Peter Clausen wrote:
> Well, It's not only about the of_dma struct, e.g. the of_dma's of_dma_data
> field usually points to some driver allocated data. If we do not block in
> of_dma_controller_free() this data might be freed while the controller is
> still in use.

Right, makes sense. This could of course be worked around using a destructor
in the of_dma struct, but your approach is much simpler.

Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/