Re: [PATCH V3] dm: core: Add late driver remove option

2021-01-07 Thread Simon Glass
Hi Marek, On Thu, 7 Jan 2021 at 05:42, Marek Vasut wrote: > > On 12/10/20 6:44 PM, Simon Glass wrote: > > [...] > > > Note also the semantics of what is going on here. The idea of the > > existing OS_PREPARE and ACTIVE_DMA flags is that the default for > > device_remove() is to

Re: [PATCH V3] dm: core: Add late driver remove option

2021-01-07 Thread Marek Vasut
On 12/10/20 6:44 PM, Simon Glass wrote: [...] Note also the semantics of what is going on here. The idea of the existing OS_PREPARE and ACTIVE_DMA flags is that the default for device_remove() is to remove everything, but if you provide a flag then it just removes those things. Your flag is

Re: [PATCH V3] dm: core: Add late driver remove option

2020-12-10 Thread Simon Glass
Hi Marek, On Sat, 5 Dec 2020 at 08:19, Marek Vasut wrote: > > On 11/18/20 3:37 PM, Simon Glass wrote: > > Hi, > > [...] > > diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c > index 1206e306db..f9091a3d41 100644 > --- a/arch/arm/lib/bootm.c > +++ b/arch/arm/lib/bootm.c

Re: [PATCH V3] dm: core: Add late driver remove option

2020-12-05 Thread Marek Vasut
On 11/18/20 3:37 PM, Simon Glass wrote: Hi, [...] diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c index 1206e306db..f9091a3d41 100644 --- a/arch/arm/lib/bootm.c +++ b/arch/arm/lib/bootm.c @@ -120,6 +120,7 @@ static void announce_and_cleanup(int fake) * of DMA operation or

Re: [PATCH V3] dm: core: Add late driver remove option

2020-11-23 Thread Tom Rini
On Sun, Nov 22, 2020 at 03:13:15AM +0100, Marek Vasut wrote: > On 11/22/20 12:07 AM, Simon Glass wrote: > [...] > > > > > > > That way we are describing the property of the device rather than > > > > > > what > > > > > > we want to do with it. > > > > > > > > > > The device is not critical or

Re: [PATCH V3] dm: core: Add late driver remove option

2020-11-21 Thread Sean Anderson
On 11/21/20 9:13 PM, Marek Vasut wrote: On 11/22/20 12:07 AM, Simon Glass wrote: [...] That way we are describing the property of the device rather than what we want to do with it. The device is not critical or vital, it just needs to be torn down late. What is it about the device that

Re: [PATCH V3] dm: core: Add late driver remove option

2020-11-21 Thread Marek Vasut
On 11/22/20 12:07 AM, Simon Glass wrote: [...] That way we are describing the property of the device rather than what we want to do with it. The device is not critical or vital, it just needs to be torn down late. What is it about the device that requires it to be torn down 'late'? I

Re: [PATCH V3] dm: core: Add late driver remove option

2020-11-21 Thread Simon Glass
Hi Tom, On Wed, 18 Nov 2020 at 08:53, Tom Rini wrote: > > On Wed, Nov 18, 2020 at 07:37:27AM -0700, Simon Glass wrote: > > Hi Marek, > > > > On Sun, 15 Nov 2020 at 06:19, Marek Vasut wrote: > > > > > > On 11/9/20 1:21 AM, Simon Glass wrote: > > > > Hi Marek, > > > > > > [...] > > > > > > >>

Re: [PATCH V3] dm: core: Add late driver remove option

2020-11-18 Thread Tom Rini
On Wed, Nov 18, 2020 at 07:37:27AM -0700, Simon Glass wrote: > Hi Marek, > > On Sun, 15 Nov 2020 at 06:19, Marek Vasut wrote: > > > > On 11/9/20 1:21 AM, Simon Glass wrote: > > > Hi Marek, > > > > [...] > > > > >> diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c > > >> index

Re: [PATCH V3] dm: core: Add late driver remove option

2020-11-18 Thread Simon Glass
Hi Marek, On Sun, 15 Nov 2020 at 06:19, Marek Vasut wrote: > > On 11/9/20 1:21 AM, Simon Glass wrote: > > Hi Marek, > > [...] > > >> diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c > >> index 1206e306db..f9091a3d41 100644 > >> --- a/arch/arm/lib/bootm.c > >> +++ b/arch/arm/lib/bootm.c >

Re: [PATCH V3] dm: core: Add late driver remove option

2020-11-15 Thread Marek Vasut
On 11/9/20 1:21 AM, Simon Glass wrote: Hi Marek, [...] diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c index 1206e306db..f9091a3d41 100644 --- a/arch/arm/lib/bootm.c +++ b/arch/arm/lib/bootm.c @@ -120,6 +120,7 @@ static void announce_and_cleanup(int fake) * of DMA

Re: [PATCH V3] dm: core: Add late driver remove option

2020-11-08 Thread Simon Glass
Hi Marek, On Sun, 8 Nov 2020 at 07:09, Marek Vasut wrote: > > Add another flag to the DM core which could be assigned to drivers and > which makes those drivers call their remove callbacks last, just before > booting OS and after all the other drivers finished with their remove > callbacks. This

[PATCH V3] dm: core: Add late driver remove option

2020-11-08 Thread Marek Vasut
Add another flag to the DM core which could be assigned to drivers and which makes those drivers call their remove callbacks last, just before booting OS and after all the other drivers finished with their remove callbacks. This is necessary for things like clock drivers, where the other drivers