Re: stack issue when using littlefs (was Re: littlefs broken)

2024-04-01 Thread Takashi Yamamoto
On Tue, Mar 19, 2024 at 8:01 PM Sebastien Lorquet  wrote:
>
> Damn, that was a stack issue, but not in littlefs itself. or is it? idk.
>
>
> This is a useful "bug" to know: Littlefs uses A LOT of stack.
>
> The issue was nsh. it is configured with a 2048 bytes stack by default,
> and increasing it to 8192 did nothing, which lead me to a deep rabbit
> hole at 1 am yesterday, and critiques that were not required this time.
>
>
> However as in X-files, the truth was elsewhere.
>
> The boot task stack size is configured by CONFIG_INIT_STACKSIZE and not
> by CONFIG_NSH_STACKSIZE
>
> Good to know...
>
> But this works on sim:nsh (I checked) so this problem cannot be detected
> in CI.
>
> NuttX is fine this time, except the discrepancy of littlefs version
> between cmake and make remains.
>
> Could the default stack size of tasks be customized per architecture in
> kconfig files? here 2048 was ok for the sim (x86_64) but not for a stm32f4

FYI, sim doesn't really honor the user specified stack size.
grep SIM_STACKSIZE_ADJUSTMENT if you are interested.

>
> Thanks for pointing me to the sim.
>
> Sebastien
>
>
> Le 19/03/2024 à 07:50, Sebastien Lorquet a écrit :
> > hi Tomek
> >
> > I'll have a try and report.
> >
> > Sebastien
> >
> > On 3/19/24 01:36, Tomek CEDRO wrote:
> >> Hey there Sebastien!
> >>
> >> Sorry to hear that :-(
> >>
> >> Would it be possible to try those tests in SIM ?
> >>
> >> If yes are results the same?
> >>
> >> This could be included into CI tests with a SIM if that helps..?
> >>
> >> --
> >> CeDeROM, SQ7MHZ, http://www.tomek.cedro.info


Re: stack issue when using littlefs (was Re: littlefs broken)

2024-03-19 Thread Tomek CEDRO
Yeah, mission accomplished! :-)

Just watching The X-Files S02E16.. truth is out there and nothing is what
it seems he he :-) :-)

--
CeDeROM, SQ7MHZ, http://www.tomek.cedro.info

On Tue, Mar 19, 2024, 12:01 Sebastien Lorquet  wrote:

> Damn, that was a stack issue, but not in littlefs itself. or is it? idk.
>
>
> This is a useful "bug" to know: Littlefs uses A LOT of stack.
>
> The issue was nsh. it is configured with a 2048 bytes stack by default,
> and increasing it to 8192 did nothing, which lead me to a deep rabbit
> hole at 1 am yesterday, and critiques that were not required this time.
>
>
> However as in X-files, the truth was elsewhere.
>
> The boot task stack size is configured by CONFIG_INIT_STACKSIZE and not
> by CONFIG_NSH_STACKSIZE
>
> Good to know...
>
> But this works on sim:nsh (I checked) so this problem cannot be detected
> in CI.
>
> NuttX is fine this time, except the discrepancy of littlefs version
> between cmake and make remains.
>
> Could the default stack size of tasks be customized per architecture in
> kconfig files? here 2048 was ok for the sim (x86_64) but not for a stm32f4
>
> Thanks for pointing me to the sim.
>
> Sebastien
>
>
> Le 19/03/2024 à 07:50, Sebastien Lorquet a écrit :
> > hi Tomek
> >
> > I'll have a try and report.
> >
> > Sebastien
> >
> > On 3/19/24 01:36, Tomek CEDRO wrote:
> >> Hey there Sebastien!
> >>
> >> Sorry to hear that :-(
> >>
> >> Would it be possible to try those tests in SIM ?
> >>
> >> If yes are results the same?
> >>
> >> This could be included into CI tests with a SIM if that helps..?
> >>
> >> --
> >> CeDeROM, SQ7MHZ, http://www.tomek.cedro.info
>


stack issue when using littlefs (was Re: littlefs broken)

2024-03-19 Thread Sebastien Lorquet

Damn, that was a stack issue, but not in littlefs itself. or is it? idk.


This is a useful "bug" to know: Littlefs uses A LOT of stack.

The issue was nsh. it is configured with a 2048 bytes stack by default, 
and increasing it to 8192 did nothing, which lead me to a deep rabbit 
hole at 1 am yesterday, and critiques that were not required this time.



However as in X-files, the truth was elsewhere.

The boot task stack size is configured by CONFIG_INIT_STACKSIZE and not 
by CONFIG_NSH_STACKSIZE


Good to know...

But this works on sim:nsh (I checked) so this problem cannot be detected 
in CI.


NuttX is fine this time, except the discrepancy of littlefs version 
between cmake and make remains.


Could the default stack size of tasks be customized per architecture in 
kconfig files? here 2048 was ok for the sim (x86_64) but not for a stm32f4


Thanks for pointing me to the sim.

Sebastien


Le 19/03/2024 à 07:50, Sebastien Lorquet a écrit :

hi Tomek

I'll have a try and report.

Sebastien

On 3/19/24 01:36, Tomek CEDRO wrote:

Hey there Sebastien!

Sorry to hear that :-(

Would it be possible to try those tests in SIM ?

If yes are results the same?

This could be included into CI tests with a SIM if that helps..?

--
CeDeROM, SQ7MHZ, http://www.tomek.cedro.info