All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time
@ 2018-01-18  5:40 ` Siva Durga Prasad Paladugu
  2018-01-18  8:15   ` Jaehoon Chung
  0 siblings, 1 reply; 7+ messages in thread
From: Siva Durga Prasad Paladugu @ 2018-01-18  5:40 UTC (permalink / raw)
  To: u-boot

From: Vipul Kumar <vipul.kumar@xilinx.com>

By enabling CONFIG_SKIP_EARLY_MMC_INIT config, user can skip the MMC
initialization at the boot time. After getting the u-boot console,
user can select the device using mmc dev and can communicate with that.
This is useful where user don't want to perform mmc initialization
while booting and can do explicitly later as per choice.

Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
---
 common/board_r.c    | 4 ++--
 drivers/mmc/Kconfig | 7 +++++++
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/common/board_r.c b/common/board_r.c
index 2a9df6b..8727b93 100644
--- a/common/board_r.c
+++ b/common/board_r.c
@@ -421,7 +421,7 @@ static int initr_onenand(void)
 }
 #endif

-#ifdef CONFIG_MMC
+#if defined(CONFIG_MMC) && !defined(CONFIG_SKIP_EARLY_MMC_INIT)
 static int initr_mmc(void)
 {
        puts("MMC:   ");
@@ -768,7 +768,7 @@ static init_fnc_t init_sequence_r[] = {
 #ifdef CONFIG_CMD_ONENAND
        initr_onenand,
 #endif
-#ifdef CONFIG_MMC
+#if defined(CONFIG_MMC) && !defined(CONFIG_SKIP_EARLY_MMC_INIT)
        initr_mmc,
 #endif
        initr_env,
diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig
index ab0627a..05b1503 100644
--- a/drivers/mmc/Kconfig
+++ b/drivers/mmc/Kconfig
@@ -40,6 +40,13 @@ config SPL_DM_MMC

 if MMC

+config SKIP_EARLY_MMC_INIT
+       bool "Skip the MMC initialization at boot time"
+       help
+         Skip the MMC initialization at the boot time. After getting the u-boot
+         console, user need to set mmc device and after setting the mmc dev, user
+         can communicate with that device.
+
 config ARM_PL180_MMCI
        bool "ARM AMBA Multimedia Card Interface and compatible support"
        depends on DM_MMC && OF_CONTROL
--
2.7.4

This email and any attachments are intended for the sole use of the named recipient(s) and contain(s) confidential information that may be proprietary, privileged or copyrighted under applicable law. If you are not the intended recipient, do not read, copy, or forward this email message or any attachments. Delete this email message and any attachments immediately.

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time
  2018-01-18  5:40 ` [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time Siva Durga Prasad Paladugu
@ 2018-01-18  8:15   ` Jaehoon Chung
  2018-01-22 11:03     ` Siva Durga Prasad Paladugu
  0 siblings, 1 reply; 7+ messages in thread
From: Jaehoon Chung @ 2018-01-18  8:15 UTC (permalink / raw)
  To: u-boot

On 01/18/2018 02:40 PM, Siva Durga Prasad Paladugu wrote:
> From: Vipul Kumar <vipul.kumar@xilinx.com>
> 
> By enabling CONFIG_SKIP_EARLY_MMC_INIT config, user can skip the MMC
> initialization at the boot time. After getting the u-boot console,
> user can select the device using mmc dev and can communicate with that.
> This is useful where user don't want to perform mmc initialization
> while booting and can do explicitly later as per choice.

Is there any use-case? What benefit can user have with this config?
According to commit-msg, user will choose the mmc device later.
Is it same with initializing at booting time?

> 
> Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
> Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
> ---
>  common/board_r.c    | 4 ++--
>  drivers/mmc/Kconfig | 7 +++++++
>  2 files changed, 9 insertions(+), 2 deletions(-)
> 
> diff --git a/common/board_r.c b/common/board_r.c
> index 2a9df6b..8727b93 100644
> --- a/common/board_r.c
> +++ b/common/board_r.c
> @@ -421,7 +421,7 @@ static int initr_onenand(void)
>  }
>  #endif
> 
> -#ifdef CONFIG_MMC
> +#if defined(CONFIG_MMC) && !defined(CONFIG_SKIP_EARLY_MMC_INIT)
>  static int initr_mmc(void)
>  {
>         puts("MMC:   ");
> @@ -768,7 +768,7 @@ static init_fnc_t init_sequence_r[] = {
>  #ifdef CONFIG_CMD_ONENAND
>         initr_onenand,
>  #endif
> -#ifdef CONFIG_MMC
> +#if defined(CONFIG_MMC) && !defined(CONFIG_SKIP_EARLY_MMC_INIT)
>         initr_mmc,
>  #endif
>         initr_env,
> diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig
> index ab0627a..05b1503 100644
> --- a/drivers/mmc/Kconfig
> +++ b/drivers/mmc/Kconfig
> @@ -40,6 +40,13 @@ config SPL_DM_MMC
> 
>  if MMC
> 
> +config SKIP_EARLY_MMC_INIT
> +       bool "Skip the MMC initialization at boot time"
> +       help
> +         Skip the MMC initialization at the boot time. After getting the u-boot
> +         console, user need to set mmc device and after setting the mmc dev, user
> +         can communicate with that device.
> +
>  config ARM_PL180_MMCI
>         bool "ARM AMBA Multimedia Card Interface and compatible support"
>         depends on DM_MMC && OF_CONTROL
> --
> 2.7.4
> 
> This email and any attachments are intended for the sole use of the named recipient(s) and contain(s) confidential information that may be proprietary, privileged or copyrighted under applicable law. If you are not the intended recipient, do not read, copy, or forward this email message or any attachments. Delete this email message and any attachments immediately.
> 
> 
> 

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time
  2018-01-18  8:15   ` Jaehoon Chung
@ 2018-01-22 11:03     ` Siva Durga Prasad Paladugu
  2018-01-23  1:52       ` Jaehoon Chung
  0 siblings, 1 reply; 7+ messages in thread
From: Siva Durga Prasad Paladugu @ 2018-01-22 11:03 UTC (permalink / raw)
  To: u-boot

Hi Jaehoon,

> -----Original Message-----
> From: Jaehoon Chung [mailto:jh80.chung at samsung.com]
> Sent: Thursday, January 18, 2018 1:46 PM
> To: Siva Durga Prasad Paladugu <sivadur@xilinx.com>; u-
> boot at lists.denx.de
> Cc: Vipul Kumar <vipulk@xilinx.com>; Vipul Kumar <vipulk@xilinx.com>;
> Siva Durga Prasad Paladugu <sivadur@xilinx.com>
> Subject: Re: [RFC PATCH] mmc: Skipping the MMC initialization at the boot
> time
> 
> On 01/18/2018 02:40 PM, Siva Durga Prasad Paladugu wrote:
> > From: Vipul Kumar <vipul.kumar@xilinx.com>
> >
> > By enabling CONFIG_SKIP_EARLY_MMC_INIT config, user can skip the
> MMC
> > initialization at the boot time. After getting the u-boot console,
> > user can select the device using mmc dev and can communicate with that.
> > This is useful where user don't want to perform mmc initialization
> > while booting and can do explicitly later as per choice.
> 
> Is there any use-case? What benefit can user have with this config?
> According to commit-msg, user will choose the mmc device later.
> Is it same with initializing at booting time?
Yes, there may be case, where we have both controllers enabled but user would like to
Communicate with only one at u-boot and this selection also depends on environment
Or something which will be updated from external world then in this case, user will initialize
Later as per his wish. This may save bootime as it initializes only the required one and choice of 
which one to initialize

Thanks,
Siva

> 
> >
> > Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
> > Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
> > ---
> >  common/board_r.c    | 4 ++--
> >  drivers/mmc/Kconfig | 7 +++++++
> >  2 files changed, 9 insertions(+), 2 deletions(-)
> >
> > diff --git a/common/board_r.c b/common/board_r.c index
> > 2a9df6b..8727b93 100644
> > --- a/common/board_r.c
> > +++ b/common/board_r.c
> > @@ -421,7 +421,7 @@ static int initr_onenand(void)  }  #endif
> >
> > -#ifdef CONFIG_MMC
> > +#if defined(CONFIG_MMC) &&
> !defined(CONFIG_SKIP_EARLY_MMC_INIT)
> >  static int initr_mmc(void)
> >  {
> >         puts("MMC:   ");
> > @@ -768,7 +768,7 @@ static init_fnc_t init_sequence_r[] = {  #ifdef
> > CONFIG_CMD_ONENAND
> >         initr_onenand,
> >  #endif
> > -#ifdef CONFIG_MMC
> > +#if defined(CONFIG_MMC) &&
> !defined(CONFIG_SKIP_EARLY_MMC_INIT)
> >         initr_mmc,
> >  #endif
> >         initr_env,
> > diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig index
> > ab0627a..05b1503 100644
> > --- a/drivers/mmc/Kconfig
> > +++ b/drivers/mmc/Kconfig
> > @@ -40,6 +40,13 @@ config SPL_DM_MMC
> >
> >  if MMC
> >
> > +config SKIP_EARLY_MMC_INIT
> > +       bool "Skip the MMC initialization at boot time"
> > +       help
> > +         Skip the MMC initialization at the boot time. After getting the u-
> boot
> > +         console, user need to set mmc device and after setting the mmc
> dev, user
> > +         can communicate with that device.
> > +
> >  config ARM_PL180_MMCI
> >         bool "ARM AMBA Multimedia Card Interface and compatible
> support"
> >         depends on DM_MMC && OF_CONTROL
> > --
> > 2.7.4
> >
> > This email and any attachments are intended for the sole use of the
> named recipient(s) and contain(s) confidential information that may be
> proprietary, privileged or copyrighted under applicable law. If you are not
> the intended recipient, do not read, copy, or forward this email message or
> any attachments. Delete this email message and any attachments
> immediately.
> >
> >
> >

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time
  2018-01-22 11:03     ` Siva Durga Prasad Paladugu
@ 2018-01-23  1:52       ` Jaehoon Chung
  2018-01-23  9:29         ` Siva Durga Prasad Paladugu
  0 siblings, 1 reply; 7+ messages in thread
From: Jaehoon Chung @ 2018-01-23  1:52 UTC (permalink / raw)
  To: u-boot

Hi Siva,

On 01/22/2018 08:03 PM, Siva Durga Prasad Paladugu wrote:
> Hi Jaehoon,
> 
>> -----Original Message-----
>> From: Jaehoon Chung [mailto:jh80.chung at samsung.com]
>> Sent: Thursday, January 18, 2018 1:46 PM
>> To: Siva Durga Prasad Paladugu <sivadur@xilinx.com>; u-
>> boot at lists.denx.de
>> Cc: Vipul Kumar <vipulk@xilinx.com>; Vipul Kumar <vipulk@xilinx.com>;
>> Siva Durga Prasad Paladugu <sivadur@xilinx.com>
>> Subject: Re: [RFC PATCH] mmc: Skipping the MMC initialization at the boot
>> time
>>
>> On 01/18/2018 02:40 PM, Siva Durga Prasad Paladugu wrote:
>>> From: Vipul Kumar <vipul.kumar@xilinx.com>
>>>
>>> By enabling CONFIG_SKIP_EARLY_MMC_INIT config, user can skip the
>> MMC
>>> initialization at the boot time. After getting the u-boot console,
>>> user can select the device using mmc dev and can communicate with that.
>>> This is useful where user don't want to perform mmc initialization
>>> while booting and can do explicitly later as per choice.
>>
>> Is there any use-case? What benefit can user have with this config?
>> According to commit-msg, user will choose the mmc device later.
>> Is it same with initializing at booting time?
> Yes, there may be case, where we have both controllers enabled but user would like to
> Communicate with only one at u-boot and this selection also depends on environment
> Or something which will be updated from external world then in this case, user will initialize
> Later as per his wish. This may save bootime as it initializes only the required one and choice of 
> which one to initialize

Then did you check how much time can save? 
If user want to save the booting time, will not enter to uboot console?
Well..I didn't agree about saving the booting time.

If you need to add this config, could you explain in more detail.
And how many board do enable this config in ./configs/ ?

Best Regards,
Jaehoon Chung

> 
> Thanks,
> Siva
> 
>>
>>>
>>> Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
>>> Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
>>> ---
>>>  common/board_r.c    | 4 ++--
>>>  drivers/mmc/Kconfig | 7 +++++++
>>>  2 files changed, 9 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/common/board_r.c b/common/board_r.c index
>>> 2a9df6b..8727b93 100644
>>> --- a/common/board_r.c
>>> +++ b/common/board_r.c
>>> @@ -421,7 +421,7 @@ static int initr_onenand(void)  }  #endif
>>>
>>> -#ifdef CONFIG_MMC
>>> +#if defined(CONFIG_MMC) &&
>> !defined(CONFIG_SKIP_EARLY_MMC_INIT)
>>>  static int initr_mmc(void)
>>>  {
>>>         puts("MMC:   ");
>>> @@ -768,7 +768,7 @@ static init_fnc_t init_sequence_r[] = {  #ifdef
>>> CONFIG_CMD_ONENAND
>>>         initr_onenand,
>>>  #endif
>>> -#ifdef CONFIG_MMC
>>> +#if defined(CONFIG_MMC) &&
>> !defined(CONFIG_SKIP_EARLY_MMC_INIT)
>>>         initr_mmc,
>>>  #endif
>>>         initr_env,
>>> diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig index
>>> ab0627a..05b1503 100644
>>> --- a/drivers/mmc/Kconfig
>>> +++ b/drivers/mmc/Kconfig
>>> @@ -40,6 +40,13 @@ config SPL_DM_MMC
>>>
>>>  if MMC
>>>
>>> +config SKIP_EARLY_MMC_INIT
>>> +       bool "Skip the MMC initialization at boot time"
>>> +       help
>>> +         Skip the MMC initialization at the boot time. After getting the u-
>> boot
>>> +         console, user need to set mmc device and after setting the mmc
>> dev, user
>>> +         can communicate with that device.
>>> +
>>>  config ARM_PL180_MMCI
>>>         bool "ARM AMBA Multimedia Card Interface and compatible
>> support"
>>>         depends on DM_MMC && OF_CONTROL
>>> --
>>> 2.7.4
>>>
>>> This email and any attachments are intended for the sole use of the
>> named recipient(s) and contain(s) confidential information that may be
>> proprietary, privileged or copyrighted under applicable law. If you are not
>> the intended recipient, do not read, copy, or forward this email message or
>> any attachments. Delete this email message and any attachments
>> immediately.
>>>
>>>
>>>
> 

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time
  2018-01-23  1:52       ` Jaehoon Chung
@ 2018-01-23  9:29         ` Siva Durga Prasad Paladugu
  2018-01-23  9:57           ` Michal Simek
  2018-01-23 10:02           ` Jaehoon Chung
  0 siblings, 2 replies; 7+ messages in thread
From: Siva Durga Prasad Paladugu @ 2018-01-23  9:29 UTC (permalink / raw)
  To: u-boot

Hi Jaehoon,

> -----Original Message-----
> From: Jaehoon Chung [mailto:jh80.chung at samsung.com]
> Sent: Tuesday, January 23, 2018 7:23 AM
> To: Siva Durga Prasad Paladugu <sivadur@xilinx.com>; u-
> boot at lists.denx.de
> Cc: Vipul Kumar <vipulk@xilinx.com>
> Subject: Re: [RFC PATCH] mmc: Skipping the MMC initialization at the boot
> time
> 
> Hi Siva,
> 
> On 01/22/2018 08:03 PM, Siva Durga Prasad Paladugu wrote:
> > Hi Jaehoon,
> >
> >> -----Original Message-----
> >> From: Jaehoon Chung [mailto:jh80.chung at samsung.com]
> >> Sent: Thursday, January 18, 2018 1:46 PM
> >> To: Siva Durga Prasad Paladugu <sivadur@xilinx.com>; u-
> >> boot at lists.denx.de
> >> Cc: Vipul Kumar <vipulk@xilinx.com>; Vipul Kumar <vipulk@xilinx.com>;
> >> Siva Durga Prasad Paladugu <sivadur@xilinx.com>
> >> Subject: Re: [RFC PATCH] mmc: Skipping the MMC initialization at the
> >> boot time
> >>
> >> On 01/18/2018 02:40 PM, Siva Durga Prasad Paladugu wrote:
> >>> From: Vipul Kumar <vipul.kumar@xilinx.com>
> >>>
> >>> By enabling CONFIG_SKIP_EARLY_MMC_INIT config, user can skip the
> >> MMC
> >>> initialization at the boot time. After getting the u-boot console,
> >>> user can select the device using mmc dev and can communicate with
> that.
> >>> This is useful where user don't want to perform mmc initialization
> >>> while booting and can do explicitly later as per choice.
> >>
> >> Is there any use-case? What benefit can user have with this config?
> >> According to commit-msg, user will choose the mmc device later.
> >> Is it same with initializing at booting time?
> > Yes, there may be case, where we have both controllers enabled but
> > user would like to Communicate with only one at u-boot and this
> > selection also depends on environment Or something which will be
> > updated from external world then in this case, user will initialize
> > Later as per his wish. This may save bootime as it initializes only
> > the required one and choice of which one to initialize
> 
> Then did you check how much time can save?
I didn’t measured, but it will definitely decrease eventhough it can be minimal.
> If user want to save the booting time, will not enter to uboot console?
Yes, user doesn’t need to enter u-boot console, he can simply execute boot command as per environment
and that env may contain corresponding/required mmc init only.

> Well..I didn't agree about saving the booting time.
> 
> If you need to add this config, could you explain in more detail.
> And how many board do enable this config in ./configs/ ?

I see it as an option, anyone can enable if they see value for them or
need boot time improvement.
For me, it's just one config in configs/ as of now.

Thanks,
Siva

> 
> Best Regards,
> Jaehoon Chung
> 
> >
> > Thanks,
> > Siva
> >
> >>
> >>>
> >>> Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
> >>> Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
> >>> ---
> >>>  common/board_r.c    | 4 ++--
> >>>  drivers/mmc/Kconfig | 7 +++++++
> >>>  2 files changed, 9 insertions(+), 2 deletions(-)
> >>>
> >>> diff --git a/common/board_r.c b/common/board_r.c index
> >>> 2a9df6b..8727b93 100644
> >>> --- a/common/board_r.c
> >>> +++ b/common/board_r.c
> >>> @@ -421,7 +421,7 @@ static int initr_onenand(void)  }  #endif
> >>>
> >>> -#ifdef CONFIG_MMC
> >>> +#if defined(CONFIG_MMC) &&
> >> !defined(CONFIG_SKIP_EARLY_MMC_INIT)
> >>>  static int initr_mmc(void)
> >>>  {
> >>>         puts("MMC:   ");
> >>> @@ -768,7 +768,7 @@ static init_fnc_t init_sequence_r[] = {  #ifdef
> >>> CONFIG_CMD_ONENAND
> >>>         initr_onenand,
> >>>  #endif
> >>> -#ifdef CONFIG_MMC
> >>> +#if defined(CONFIG_MMC) &&
> >> !defined(CONFIG_SKIP_EARLY_MMC_INIT)
> >>>         initr_mmc,
> >>>  #endif
> >>>         initr_env,
> >>> diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig index
> >>> ab0627a..05b1503 100644
> >>> --- a/drivers/mmc/Kconfig
> >>> +++ b/drivers/mmc/Kconfig
> >>> @@ -40,6 +40,13 @@ config SPL_DM_MMC
> >>>
> >>>  if MMC
> >>>
> >>> +config SKIP_EARLY_MMC_INIT
> >>> +       bool "Skip the MMC initialization at boot time"
> >>> +       help
> >>> +         Skip the MMC initialization at the boot time. After
> >>> +getting the u-
> >> boot
> >>> +         console, user need to set mmc device and after setting the
> >>> + mmc
> >> dev, user
> >>> +         can communicate with that device.
> >>> +
> >>>  config ARM_PL180_MMCI
> >>>         bool "ARM AMBA Multimedia Card Interface and compatible
> >> support"
> >>>         depends on DM_MMC && OF_CONTROL
> >>> --
> >>> 2.7.4
> >>>
> >>> This email and any attachments are intended for the sole use of the
> >> named recipient(s) and contain(s) confidential information that may
> >> be proprietary, privileged or copyrighted under applicable law. If
> >> you are not the intended recipient, do not read, copy, or forward
> >> this email message or any attachments. Delete this email message and
> >> any attachments immediately.
> >>>
> >>>
> >>>
> >

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time
  2018-01-23  9:29         ` Siva Durga Prasad Paladugu
@ 2018-01-23  9:57           ` Michal Simek
  2018-01-23 10:02           ` Jaehoon Chung
  1 sibling, 0 replies; 7+ messages in thread
From: Michal Simek @ 2018-01-23  9:57 UTC (permalink / raw)
  To: u-boot


Hi Jaehoon,

On 23.1.2018 10:29, Siva Durga Prasad Paladugu wrote:
> Hi Jaehoon,
> 
>> -----Original Message-----
>> From: Jaehoon Chung [mailto:jh80.chung at samsung.com]
>> Sent: Tuesday, January 23, 2018 7:23 AM
>> To: Siva Durga Prasad Paladugu <sivadur@xilinx.com>; u-
>> boot at lists.denx.de
>> Cc: Vipul Kumar <vipulk@xilinx.com>
>> Subject: Re: [RFC PATCH] mmc: Skipping the MMC initialization at the boot
>> time
>>
>> Hi Siva,
>>
>> On 01/22/2018 08:03 PM, Siva Durga Prasad Paladugu wrote:
>>> Hi Jaehoon,
>>>
>>>> -----Original Message-----
>>>> From: Jaehoon Chung [mailto:jh80.chung at samsung.com]
>>>> Sent: Thursday, January 18, 2018 1:46 PM
>>>> To: Siva Durga Prasad Paladugu <sivadur@xilinx.com>; u-
>>>> boot at lists.denx.de
>>>> Cc: Vipul Kumar <vipulk@xilinx.com>; Vipul Kumar <vipulk@xilinx.com>;
>>>> Siva Durga Prasad Paladugu <sivadur@xilinx.com>
>>>> Subject: Re: [RFC PATCH] mmc: Skipping the MMC initialization at the
>>>> boot time
>>>>
>>>> On 01/18/2018 02:40 PM, Siva Durga Prasad Paladugu wrote:
>>>>> From: Vipul Kumar <vipul.kumar@xilinx.com>
>>>>>
>>>>> By enabling CONFIG_SKIP_EARLY_MMC_INIT config, user can skip the
>>>> MMC
>>>>> initialization at the boot time. After getting the u-boot console,
>>>>> user can select the device using mmc dev and can communicate with
>> that.
>>>>> This is useful where user don't want to perform mmc initialization
>>>>> while booting and can do explicitly later as per choice.
>>>>
>>>> Is there any use-case? What benefit can user have with this config?
>>>> According to commit-msg, user will choose the mmc device later.
>>>> Is it same with initializing at booting time?
>>> Yes, there may be case, where we have both controllers enabled but
>>> user would like to Communicate with only one at u-boot and this
>>> selection also depends on environment Or something which will be
>>> updated from external world then in this case, user will initialize
>>> Later as per his wish. This may save bootime as it initializes only
>>> the required one and choice of which one to initialize
>>
>> Then did you check how much time can save?
> I didn’t measured, but it will definitely decrease eventhough it can be minimal.
>> If user want to save the booting time, will not enter to uboot console?
> Yes, user doesn’t need to enter u-boot console, he can simply execute boot command as per environment
> and that env may contain corresponding/required mmc init only.
> 
>> Well..I didn't agree about saving the booting time.
>>
>> If you need to add this config, could you explain in more detail.
>> And how many board do enable this config in ./configs/ ?
> 
> I see it as an option, anyone can enable if they see value for them or
> need boot time improvement.
> For me, it's just one config in configs/ as of now.

Let me also come to this discussion. Another usage of this would be with
broken HW or incorrect SW configurations.

Right now initialization at boot time is what u-boot is using for long
time for "old" subsystems.
For others this is done based on request. qspi - sf probe, usb - usb
start, scsi - scsi start and maybe others.

And this "feature" (I am not saying it is done properly) is just adding
option to initialize it based on request as is done for others
subsystems which we use today.
Based on current u-boot behavior for some subsystems I think it is
reasonable to defer mmc probe as is done for qspi, usb, scsi and almost
doesn't matter what's the reason for doing that (Incorrect HW,
configuration, time, etc).

Thanks,
Michal



-- 
Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel - Xilinx Microblaze
Maintainer of Linux kernel - Xilinx Zynq ARM and ZynqMP ARM64 SoCs
U-Boot custodian - Xilinx Microblaze/Zynq/ZynqMP SoCs


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180123/9289613f/attachment.sig>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time
  2018-01-23  9:29         ` Siva Durga Prasad Paladugu
  2018-01-23  9:57           ` Michal Simek
@ 2018-01-23 10:02           ` Jaehoon Chung
  1 sibling, 0 replies; 7+ messages in thread
From: Jaehoon Chung @ 2018-01-23 10:02 UTC (permalink / raw)
  To: u-boot

Hi Siva,

On 01/23/2018 06:29 PM, Siva Durga Prasad Paladugu wrote:
> Hi Jaehoon,
> 
>> -----Original Message-----
>> From: Jaehoon Chung [mailto:jh80.chung at samsung.com]
>> Sent: Tuesday, January 23, 2018 7:23 AM
>> To: Siva Durga Prasad Paladugu <sivadur@xilinx.com>; u-
>> boot at lists.denx.de
>> Cc: Vipul Kumar <vipulk@xilinx.com>
>> Subject: Re: [RFC PATCH] mmc: Skipping the MMC initialization at the boot
>> time
>>
>> Hi Siva,
>>
>> On 01/22/2018 08:03 PM, Siva Durga Prasad Paladugu wrote:
>>> Hi Jaehoon,
>>>
>>>> -----Original Message-----
>>>> From: Jaehoon Chung [mailto:jh80.chung at samsung.com]
>>>> Sent: Thursday, January 18, 2018 1:46 PM
>>>> To: Siva Durga Prasad Paladugu <sivadur@xilinx.com>; u-
>>>> boot at lists.denx.de
>>>> Cc: Vipul Kumar <vipulk@xilinx.com>; Vipul Kumar <vipulk@xilinx.com>;
>>>> Siva Durga Prasad Paladugu <sivadur@xilinx.com>
>>>> Subject: Re: [RFC PATCH] mmc: Skipping the MMC initialization at the
>>>> boot time
>>>>
>>>> On 01/18/2018 02:40 PM, Siva Durga Prasad Paladugu wrote:
>>>>> From: Vipul Kumar <vipul.kumar@xilinx.com>
>>>>>
>>>>> By enabling CONFIG_SKIP_EARLY_MMC_INIT config, user can skip the
>>>> MMC
>>>>> initialization at the boot time. After getting the u-boot console,
>>>>> user can select the device using mmc dev and can communicate with
>> that.
>>>>> This is useful where user don't want to perform mmc initialization
>>>>> while booting and can do explicitly later as per choice.
>>>>
>>>> Is there any use-case? What benefit can user have with this config?
>>>> According to commit-msg, user will choose the mmc device later.
>>>> Is it same with initializing at booting time?
>>> Yes, there may be case, where we have both controllers enabled but
>>> user would like to Communicate with only one at u-boot and this
>>> selection also depends on environment Or something which will be
>>> updated from external world then in this case, user will initialize
>>> Later as per his wish. This may save bootime as it initializes only
>>> the required one and choice of which one to initialize
>>
>> Then did you check how much time can save?
> I didn’t measured, but it will definitely decrease eventhough it can be minimal.
>> If user want to save the booting time, will not enter to uboot console?
> Yes, user doesn’t need to enter u-boot console, he can simply execute boot command as per environment
> and that env may contain corresponding/required mmc init only.
> 
>> Well..I didn't agree about saving the booting time.
>>
>> If you need to add this config, could you explain in more detail.
>> And how many board do enable this config in ./configs/ ?
> 
> I see it as an option, anyone can enable if they see value for them or
> need boot time improvement.
> For me, it's just one config in configs/ as of now.

I understood what you really want. :) Well, can i keep this RFC patch for considering more?
In future, will need to apply this patch..then i will request to you the patch, not RFC. :)

Best Regards,
Jaehoon Chung

> 
> Thanks,
> Siva
> 
>>
>> Best Regards,
>> Jaehoon Chung
>>
>>>
>>> Thanks,
>>> Siva
>>>
>>>>
>>>>>
>>>>> Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
>>>>> Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
>>>>> ---
>>>>>  common/board_r.c    | 4 ++--
>>>>>  drivers/mmc/Kconfig | 7 +++++++
>>>>>  2 files changed, 9 insertions(+), 2 deletions(-)
>>>>>
>>>>> diff --git a/common/board_r.c b/common/board_r.c index
>>>>> 2a9df6b..8727b93 100644
>>>>> --- a/common/board_r.c
>>>>> +++ b/common/board_r.c
>>>>> @@ -421,7 +421,7 @@ static int initr_onenand(void)  }  #endif
>>>>>
>>>>> -#ifdef CONFIG_MMC
>>>>> +#if defined(CONFIG_MMC) &&
>>>> !defined(CONFIG_SKIP_EARLY_MMC_INIT)
>>>>>  static int initr_mmc(void)
>>>>>  {
>>>>>         puts("MMC:   ");
>>>>> @@ -768,7 +768,7 @@ static init_fnc_t init_sequence_r[] = {  #ifdef
>>>>> CONFIG_CMD_ONENAND
>>>>>         initr_onenand,
>>>>>  #endif
>>>>> -#ifdef CONFIG_MMC
>>>>> +#if defined(CONFIG_MMC) &&
>>>> !defined(CONFIG_SKIP_EARLY_MMC_INIT)
>>>>>         initr_mmc,
>>>>>  #endif
>>>>>         initr_env,
>>>>> diff --git a/drivers/mmc/Kconfig b/drivers/mmc/Kconfig index
>>>>> ab0627a..05b1503 100644
>>>>> --- a/drivers/mmc/Kconfig
>>>>> +++ b/drivers/mmc/Kconfig
>>>>> @@ -40,6 +40,13 @@ config SPL_DM_MMC
>>>>>
>>>>>  if MMC
>>>>>
>>>>> +config SKIP_EARLY_MMC_INIT
>>>>> +       bool "Skip the MMC initialization at boot time"
>>>>> +       help
>>>>> +         Skip the MMC initialization at the boot time. After
>>>>> +getting the u-
>>>> boot
>>>>> +         console, user need to set mmc device and after setting the
>>>>> + mmc
>>>> dev, user
>>>>> +         can communicate with that device.
>>>>> +
>>>>>  config ARM_PL180_MMCI
>>>>>         bool "ARM AMBA Multimedia Card Interface and compatible
>>>> support"
>>>>>         depends on DM_MMC && OF_CONTROL
>>>>> --
>>>>> 2.7.4
>>>>>
>>>>> This email and any attachments are intended for the sole use of the
>>>> named recipient(s) and contain(s) confidential information that may
>>>> be proprietary, privileged or copyrighted under applicable law. If
>>>> you are not the intended recipient, do not read, copy, or forward
>>>> this email message or any attachments. Delete this email message and
>>>> any attachments immediately.
>>>>>
>>>>>
>>>>>
>>>
> 

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2018-01-23 10:02 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20180118053904epcas3p340d1600105299337b49cad22fd9be5fb@epcas3p3.samsung.com>
2018-01-18  5:40 ` [U-Boot] [RFC PATCH] mmc: Skipping the MMC initialization at the boot time Siva Durga Prasad Paladugu
2018-01-18  8:15   ` Jaehoon Chung
2018-01-22 11:03     ` Siva Durga Prasad Paladugu
2018-01-23  1:52       ` Jaehoon Chung
2018-01-23  9:29         ` Siva Durga Prasad Paladugu
2018-01-23  9:57           ` Michal Simek
2018-01-23 10:02           ` Jaehoon Chung

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.