[PATCH 3/4] platform: Apply relocatable address

Inochi Amaoto inochiama at outlook.com
Thu Feb 22 23:25:09 PST 2024


On Fri, Feb 23, 2024 at 10:33:09AM +0530, Anup Patel wrote:
> On Fri, Feb 2, 2024 at 9:35 AM Inochi Amaoto <inochiama at outlook.com> wrote:
> >
> > Since jump and payload firmware support relocatable address, make
> > general platform use runtime relocatable address.
> >
> > Signed-off-by: Inochi Amaoto <inochiama at outlook.com>
> 
> This patch should also update platform/template/objects.mk.
> 

Thanks for the reminder.

> Regards,
> Anup
> 
> > ---
> >  platform/generic/objects.mk | 8 ++++----
> >  1 file changed, 4 insertions(+), 4 deletions(-)
> >
> > diff --git a/platform/generic/objects.mk b/platform/generic/objects.mk
> > index 136853e..85aa723 100644
> > --- a/platform/generic/objects.mk
> > +++ b/platform/generic/objects.mk
> > @@ -27,12 +27,12 @@ FW_DYNAMIC=y
> >  FW_JUMP=y
> >  ifeq ($(PLATFORM_RISCV_XLEN), 32)
> >    # This needs to be 4MB aligned for 32-bit system
> > -  FW_JUMP_ADDR=$(shell printf "0x%X" $$(($(FW_TEXT_START) + 0x400000)))
> > +  FW_JUMP_OFFSET=0x400000
> >  else
> >    # This needs to be 2MB aligned for 64-bit system
> > -  FW_JUMP_ADDR=$(shell printf "0x%X" $$(($(FW_TEXT_START) + 0x200000)))
> > +  FW_JUMP_OFFSET=0x200000
> >  endif
> > -FW_JUMP_FDT_ADDR=$(shell printf "0x%X" $$(($(FW_TEXT_START) + 0x2200000)))
> > +FW_JUMP_FDT_OFFSET=0x2200000
> >  FW_PAYLOAD=y
> >  ifeq ($(PLATFORM_RISCV_XLEN), 32)
> >    # This needs to be 4MB aligned for 32-bit system
> > @@ -41,4 +41,4 @@ else
> >    # This needs to be 2MB aligned for 64-bit system
> >    FW_PAYLOAD_OFFSET=0x200000
> >  endif
> > -FW_PAYLOAD_FDT_ADDR=$(FW_JUMP_FDT_ADDR)
> > +FW_PAYLOAD_FDT_OFFSET=$(FW_JUMP_FDT_OFFSET)
> > --
> > 2.43.0
> >



More information about the opensbi mailing list