Re: [PATCH v5 02/14] driver core: Add dma_cleanup callback in bus_type

2022-02-14 Thread Greg Kroah-Hartman
On Tue, Jan 04, 2022 at 09:56:32AM +0800, Lu Baolu wrote: > The bus_type structure defines dma_configure() callback for bus drivers > to configure DMA on the devices. This adds the paired dma_cleanup() > callback and calls it during driver unbinding so that bus drivers can do > some cleanup work.

Re: [PATCH v5 02/14] driver core: Add dma_cleanup callback in bus_type

2022-02-14 Thread Greg Kroah-Hartman
On Tue, Jan 04, 2022 at 02:08:36AM -0800, Christoph Hellwig wrote: > All these bus callouts still looks horrible and just create tons of > boilerplate code. I can't remember anymore what one vs. the other looks like. Having an explicit "opt-in" for a bus is good, in that no code breaks and only

Re: [PATCH v5 02/14] driver core: Add dma_cleanup callback in bus_type

2022-02-08 Thread Greg Kroah-Hartman
On Tue, Feb 08, 2022 at 01:55:29PM +0800, Lu Baolu wrote: > Hi Greg, > > On 1/4/22 9:04 PM, Greg Kroah-Hartman wrote: > > On Tue, Jan 04, 2022 at 08:39:11AM -0400, Jason Gunthorpe wrote: > > > On Tue, Jan 04, 2022 at 02:08:36AM -0800, Christoph Hellwig wrote: > > > > All these bus callouts still

Re: [PATCH v5 02/14] driver core: Add dma_cleanup callback in bus_type

2022-02-07 Thread Lu Baolu
Hi Greg, On 1/4/22 9:04 PM, Greg Kroah-Hartman wrote: On Tue, Jan 04, 2022 at 08:39:11AM -0400, Jason Gunthorpe wrote: On Tue, Jan 04, 2022 at 02:08:36AM -0800, Christoph Hellwig wrote: All these bus callouts still looks horrible and just create tons of boilerplate code. Yes, Lu - Greg

Re: [PATCH v5 02/14] driver core: Add dma_cleanup callback in bus_type

2022-01-04 Thread Greg Kroah-Hartman
On Tue, Jan 04, 2022 at 08:39:11AM -0400, Jason Gunthorpe wrote: > On Tue, Jan 04, 2022 at 02:08:36AM -0800, Christoph Hellwig wrote: > > All these bus callouts still looks horrible and just create tons of > > boilerplate code. > > Yes, Lu - Greg asked questions then didn't respond to their

Re: [PATCH v5 02/14] driver core: Add dma_cleanup callback in bus_type

2022-01-04 Thread Jason Gunthorpe via iommu
On Tue, Jan 04, 2022 at 02:08:36AM -0800, Christoph Hellwig wrote: > All these bus callouts still looks horrible and just create tons of > boilerplate code. Yes, Lu - Greg asked questions then didn't respond to their answers meaning he accepts them, you should stick with the v4 version. Jason

Re: [PATCH v5 02/14] driver core: Add dma_cleanup callback in bus_type

2022-01-04 Thread Christoph Hellwig
All these bus callouts still looks horrible and just create tons of boilerplate code. ___ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu

[PATCH v5 02/14] driver core: Add dma_cleanup callback in bus_type

2022-01-03 Thread Lu Baolu
The bus_type structure defines dma_configure() callback for bus drivers to configure DMA on the devices. This adds the paired dma_cleanup() callback and calls it during driver unbinding so that bus drivers can do some cleanup work. One use case for this paired DMA callbacks is for the bus driver