* [U-Boot] Use .data section in SPL ?
@ 2014-12-10 7:39 Masahiro Yamada
2014-12-10 14:06 ` Tom Rini
0 siblings, 1 reply; 6+ messages in thread
From: Masahiro Yamada @ 2014-12-10 7:39 UTC (permalink / raw)
To: u-boot
Hi.
I notice SPL is using .data section
u32 *boot_params_ptr = NULL;
struct spl_image_info spl_image;
/* Define board data structure */
static bd_t bdata __attribute__ ((section(".data")));
If SPL is running on an execute-in-place device such NOR flash,
.data section is not writable.
common/spl/spl_nor.c does not work.
Shall we ban global variables on SPL (and pre-relocation) ?
or
Shall we make .data section available?
Best Regards
Masahiro Yamada
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] Use .data section in SPL ?
2014-12-10 7:39 [U-Boot] Use .data section in SPL ? Masahiro Yamada
@ 2014-12-10 14:06 ` Tom Rini
2014-12-11 1:56 ` Simon Glass
0 siblings, 1 reply; 6+ messages in thread
From: Tom Rini @ 2014-12-10 14:06 UTC (permalink / raw)
To: u-boot
On Wed, Dec 10, 2014 at 04:39:39PM +0900, Masahiro Yamada wrote:
> Hi.
>
>
> I notice SPL is using .data section
>
>
>
> u32 *boot_params_ptr = NULL;
> struct spl_image_info spl_image;
>
> /* Define board data structure */
> static bd_t bdata __attribute__ ((section(".data")));
>
>
>
> If SPL is running on an execute-in-place device such NOR flash,
> .data section is not writable.
>
> common/spl/spl_nor.c does not work.
spl_nor.c only works today on PowerPC where there's nothing shoved into
the .data section.
And all of this is related to what's needed to enable DM in SPL on ARM
as well, iirc anyhow.
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20141210/e9757d80/attachment.pgp>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] Use .data section in SPL ?
2014-12-10 14:06 ` Tom Rini
@ 2014-12-11 1:56 ` Simon Glass
2014-12-11 2:04 ` Tom Rini
0 siblings, 1 reply; 6+ messages in thread
From: Simon Glass @ 2014-12-11 1:56 UTC (permalink / raw)
To: u-boot
Hi Tom,
On 10 December 2014 at 07:06, Tom Rini <trini@ti.com> wrote:
> On Wed, Dec 10, 2014 at 04:39:39PM +0900, Masahiro Yamada wrote:
>> Hi.
>>
>>
>> I notice SPL is using .data section
>>
>>
>>
>> u32 *boot_params_ptr = NULL;
>> struct spl_image_info spl_image;
>>
>> /* Define board data structure */
>> static bd_t bdata __attribute__ ((section(".data")));
>>
>>
>>
>> If SPL is running on an execute-in-place device such NOR flash,
>> .data section is not writable.
>>
>> common/spl/spl_nor.c does not work.
>
> spl_nor.c only works today on PowerPC where there's nothing shoved into
> the .data section.
>
> And all of this is related to what's needed to enable DM in SPL on ARM
> as well, iirc anyhow.
>
Can you please explain the SPL problem on ARM a bit more? If It could
understand what is going on, or how to repeat it, I might be able to
help. I'd really like to enable this DM SPL support...
Regards,
Simon
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] Use .data section in SPL ?
2014-12-11 1:56 ` Simon Glass
@ 2014-12-11 2:04 ` Tom Rini
2014-12-11 2:13 ` Simon Glass
0 siblings, 1 reply; 6+ messages in thread
From: Tom Rini @ 2014-12-11 2:04 UTC (permalink / raw)
To: u-boot
On Wed, Dec 10, 2014 at 06:56:02PM -0700, Simon Glass wrote:
> Hi Tom,
>
> On 10 December 2014 at 07:06, Tom Rini <trini@ti.com> wrote:
> > On Wed, Dec 10, 2014 at 04:39:39PM +0900, Masahiro Yamada wrote:
> >> Hi.
> >>
> >>
> >> I notice SPL is using .data section
> >>
> >>
> >>
> >> u32 *boot_params_ptr = NULL;
> >> struct spl_image_info spl_image;
> >>
> >> /* Define board data structure */
> >> static bd_t bdata __attribute__ ((section(".data")));
> >>
> >>
> >>
> >> If SPL is running on an execute-in-place device such NOR flash,
> >> .data section is not writable.
> >>
> >> common/spl/spl_nor.c does not work.
> >
> > spl_nor.c only works today on PowerPC where there's nothing shoved into
> > the .data section.
> >
> > And all of this is related to what's needed to enable DM in SPL on ARM
> > as well, iirc anyhow.
>
> Can you please explain the SPL problem on ARM a bit more? If It could
> understand what is going on, or how to repeat it, I might be able to
> help. I'd really like to enable this DM SPL support...
Did you see the WIP patch I sent out in reply to the SPL DM series?
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20141210/62adc49e/attachment.pgp>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] Use .data section in SPL ?
2014-12-11 2:04 ` Tom Rini
@ 2014-12-11 2:13 ` Simon Glass
2014-12-11 2:20 ` Tom Rini
0 siblings, 1 reply; 6+ messages in thread
From: Simon Glass @ 2014-12-11 2:13 UTC (permalink / raw)
To: u-boot
Hi Tom,
On 10 December 2014 at 19:04, Tom Rini <trini@ti.com> wrote:
> On Wed, Dec 10, 2014 at 06:56:02PM -0700, Simon Glass wrote:
>> Hi Tom,
>>
>> On 10 December 2014 at 07:06, Tom Rini <trini@ti.com> wrote:
>> > On Wed, Dec 10, 2014 at 04:39:39PM +0900, Masahiro Yamada wrote:
>> >> Hi.
>> >>
>> >>
>> >> I notice SPL is using .data section
>> >>
>> >>
>> >>
>> >> u32 *boot_params_ptr = NULL;
>> >> struct spl_image_info spl_image;
>> >>
>> >> /* Define board data structure */
>> >> static bd_t bdata __attribute__ ((section(".data")));
>> >>
>> >>
>> >>
>> >> If SPL is running on an execute-in-place device such NOR flash,
>> >> .data section is not writable.
>> >>
>> >> common/spl/spl_nor.c does not work.
>> >
>> > spl_nor.c only works today on PowerPC where there's nothing shoved into
>> > the .data section.
>> >
>> > And all of this is related to what's needed to enable DM in SPL on ARM
>> > as well, iirc anyhow.
>>
>> Can you please explain the SPL problem on ARM a bit more? If It could
>> understand what is going on, or how to repeat it, I might be able to
>> help. I'd really like to enable this DM SPL support...
>
> Did you see the WIP patch I sent out in reply to the SPL DM series?
Not that I recall - you mean this one?
http://patchwork.ozlabs.org/patch/417792/
I might have been asleep. Will take a look.
Regards,
Simon
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] Use .data section in SPL ?
2014-12-11 2:13 ` Simon Glass
@ 2014-12-11 2:20 ` Tom Rini
0 siblings, 0 replies; 6+ messages in thread
From: Tom Rini @ 2014-12-11 2:20 UTC (permalink / raw)
To: u-boot
On Wed, Dec 10, 2014 at 07:13:51PM -0700, Simon Glass wrote:
> Hi Tom,
>
> On 10 December 2014 at 19:04, Tom Rini <trini@ti.com> wrote:
> > On Wed, Dec 10, 2014 at 06:56:02PM -0700, Simon Glass wrote:
> >> Hi Tom,
> >>
> >> On 10 December 2014 at 07:06, Tom Rini <trini@ti.com> wrote:
> >> > On Wed, Dec 10, 2014 at 04:39:39PM +0900, Masahiro Yamada wrote:
> >> >> Hi.
> >> >>
> >> >>
> >> >> I notice SPL is using .data section
> >> >>
> >> >>
> >> >>
> >> >> u32 *boot_params_ptr = NULL;
> >> >> struct spl_image_info spl_image;
> >> >>
> >> >> /* Define board data structure */
> >> >> static bd_t bdata __attribute__ ((section(".data")));
> >> >>
> >> >>
> >> >>
> >> >> If SPL is running on an execute-in-place device such NOR flash,
> >> >> .data section is not writable.
> >> >>
> >> >> common/spl/spl_nor.c does not work.
> >> >
> >> > spl_nor.c only works today on PowerPC where there's nothing shoved into
> >> > the .data section.
> >> >
> >> > And all of this is related to what's needed to enable DM in SPL on ARM
> >> > as well, iirc anyhow.
> >>
> >> Can you please explain the SPL problem on ARM a bit more? If It could
> >> understand what is going on, or how to repeat it, I might be able to
> >> help. I'd really like to enable this DM SPL support...
> >
> > Did you see the WIP patch I sent out in reply to the SPL DM series?
>
> Not that I recall - you mean this one?
>
> http://patchwork.ozlabs.org/patch/417792/
>
> I might have been asleep. Will take a look.
Yup, that's the one. Fixing that (and the similar constructs the other
TI platforms have) and then a few other similar constructs elsewhere is
why we have to throw things into .data but write to them today in ARM.
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20141210/25c22f25/attachment.pgp>
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2014-12-11 2:20 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-10 7:39 [U-Boot] Use .data section in SPL ? Masahiro Yamada
2014-12-10 14:06 ` Tom Rini
2014-12-11 1:56 ` Simon Glass
2014-12-11 2:04 ` Tom Rini
2014-12-11 2:13 ` Simon Glass
2014-12-11 2:20 ` Tom Rini
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox