All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lokesh Vutla <lokeshvutla@ti.com>
To: u-boot@lists.denx.de
Subject: [RFC 2/2] Revert "dm: core: device: switch off power domain after device removal"
Date: Fri, 14 Feb 2020 09:50:54 +0530	[thread overview]
Message-ID: <914a0443-bdab-3b43-3534-9e5c5a6c65c9@ti.com> (raw)
In-Reply-To: <d85b9eb0-f44f-54ef-1333-649aae5e48fa@baylibre.com>



On 13/02/20 10:42 PM, Neil Armstrong wrote:
> Hi,
> 
> On 03/02/2020 14:59, Oliver Graute wrote:
>> The conga-imx8 board isn't booting without this revert. Can someone tell me
>> what I need to Do so that this revert is not necessary?

Can you give more details on where the failure is happening?(logs would really
help).

>>
>> This reverts commit 52edfed65de967a86983a55c51ba0727090efc43.
>> ---
>>  drivers/core/device-remove.c | 5 -----
>>  1 file changed, 5 deletions(-)
>>
>> diff --git a/drivers/core/device-remove.c b/drivers/core/device-remove.c
>> index 5c8dc4ad70..586fadee0a 100644
>> --- a/drivers/core/device-remove.c
>> +++ b/drivers/core/device-remove.c
>> @@ -16,7 +16,6 @@
>>  #include <dm/uclass.h>
>>  #include <dm/uclass-internal.h>
>>  #include <dm/util.h>
>> -#include <power-domain.h>
>>  
>>  int device_chld_unbind(struct udevice *dev, struct driver *drv)
>>  {
>> @@ -193,10 +192,6 @@ int device_remove(struct udevice *dev, uint flags)
>>  		}
>>  	}
>>  
>> -	if (!(drv->flags & DM_FLAG_DEFAULT_PD_CTRL_OFF) &&
>> -	    (dev != gd->cur_serial_dev))
>> -		dev_power_domain_off(dev);
>> -
>>  	if (flags_remove(flags, drv->flags)) {
>>  		device_free(dev);
>>  
>>
> 
> It also breaks amlogic boards with video, since we can't tell we want
> to keep the power domains up after boot, it cuts the power domains and
> thus defeats all the goal of u-boot video..
> The problem is DM_FLAG_DEFAULT_PD_CTRL_OFF disables auto power domain on
> aswell, reverting to manual power domain enable.

This doesn't mean U-boot must leave the all power-domains un handled before
jumping to kernel. Please use DM_FLAG_DEFAULT_PD_CTRL_OFF in you driver and
enable power_domain in your probe. Your case is exactly the reason why
DM_FLAG_DEFAULT_PD_CTRL_OFF is introduced.

Thanks and regards,
Lokesh

  reply	other threads:[~2020-02-14  4:20 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-03 13:59 [PATCH v2] imx: support for conga-QMX8 board Oliver Graute
2020-02-03 13:59 ` [RFC 1/2] hack to boot with 2020.01 Oliver Graute
2020-02-03 17:15   ` Simon Glass
2020-02-04 17:07   ` Tom Rini
2020-02-05  8:48     ` Oliver Graute
2020-02-03 13:59 ` [RFC 2/2] Revert "dm: core: device: switch off power domain after device removal" Oliver Graute
2020-02-13 17:12   ` Neil Armstrong
2020-02-14  4:20     ` Lokesh Vutla [this message]
2020-02-14  9:18       ` Oliver Graute
2020-02-14  9:30         ` Lokesh Vutla
2020-02-14 10:30           ` Oliver Graute
2020-02-14 10:01       ` Anatolij Gustschin
2020-02-14 10:14         ` Anatolij Gustschin
2020-02-14 10:22         ` Lokesh Vutla
2020-02-14 10:50         ` Oliver Graute
2020-02-17  8:55       ` Neil Armstrong
2020-02-17 13:17       ` Anatolij Gustschin
2020-02-17 13:05     ` Anatolij Gustschin
2020-02-17 13:37       ` Lokesh Vutla
2020-05-04  7:40 ` [PATCH v2] imx: support for conga-QMX8 board Stefano Babic
2020-05-04 14:25   ` Oliver Graute

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=914a0443-bdab-3b43-3534-9e5c5a6c65c9@ti.com \
    --to=lokeshvutla@ti.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.