From: Paul Cercueil <paul@crapouillou.net>
To: Jonas Gorski <jonas.gorski@gmail.com>
Cc: Ralf Baechle <ralf@linux-mips.org>,
Paul Burton <paul.burton@mips.com>,
James Hogan <jhogan@kernel.org>,
linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] MIPS: ingenic: Add support for appended devicetree
Date: Thu, 21 Feb 2019 18:50:43 -0300 [thread overview]
Message-ID: <1550785843.28751.0@crapouillou.net> (raw)
In-Reply-To: <CAOiHx=k--4gOnERK4qJ6QfMyqqeAn4CQfYFeBZYRieWAa19cDw@mail.gmail.com>
Hi Jonas,
On Thu, 21 Feb 2019 at 21:39, Jonas Gorski <jonas.gorski@gmail.com>
wrote:
> On Thu, 21 Feb 2019 at 21:39, Paul Cercueil <paul@crapouillou.net>
> wrote:
>>
>> Add support for booting the kernel from an externally-appended
>> devicetree, if no devicetree was built-in.
>>
>> Signed-off-by: Paul Cercueil <paul@crapouillou.net>
>> ---
>> arch/mips/Kconfig | 2 +-
>> arch/mips/jz4740/setup.c | 14 +++++++++++---
>> 2 files changed, 12 insertions(+), 4 deletions(-)
>>
>> diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
>> index a84c24d894aa..8b7ea9062198 100644
>> --- a/arch/mips/Kconfig
>> +++ b/arch/mips/Kconfig
>> @@ -391,7 +391,7 @@ config MACH_INGENIC
>> select GPIOLIB
>> select COMMON_CLK
>> select GENERIC_IRQ_CHIP
>> - select BUILTIN_DTB
>> + select BUILTIN_DTB if MIPS_NO_APPENDED_DTB
>> select USE_OF
>> select LIBFDT
>>
>> diff --git a/arch/mips/jz4740/setup.c b/arch/mips/jz4740/setup.c
>> index afb40f8bce96..5c00064937c4 100644
>> --- a/arch/mips/jz4740/setup.c
>> +++ b/arch/mips/jz4740/setup.c
>> @@ -31,6 +31,7 @@
>>
>> #define JZ4740_EMC_SDRAM_CTRL 0x80
>>
>> +extern const char __appended_dtb;
>
> Does this build/link with MIPS_NO_APPENDED_DTB? I would assume it
> won't be able to resolve the symbol in that case.
Oops. You're right.
> You can also just use fw_passed_dtb from asm/bootinfo.h, which will be
> populated automatically from fw_args (if UHI) or __appended_dtb (if
> present and valid)[1], without having to care where it came from.
Thanks, I will.
Regards,
-Paul
prev parent reply other threads:[~2019-02-21 21:50 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-21 20:38 [PATCH] MIPS: ingenic: Add support for appended devicetree Paul Cercueil
2019-02-21 21:13 ` Jonas Gorski
2019-02-21 21:50 ` Paul Cercueil [this message]
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=1550785843.28751.0@crapouillou.net \
--to=paul@crapouillou.net \
--cc=jhogan@kernel.org \
--cc=jonas.gorski@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@vger.kernel.org \
--cc=paul.burton@mips.com \
--cc=ralf@linux-mips.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).