All of lore.kernel.org
 help / color / mirror / Atom feed
From: hl <hl@rock-chips.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/2] rockchip: add CONFIG_SPL_ROCKCHIP_SERIAL
Date: Tue, 01 Dec 2015 14:51:57 +0800	[thread overview]
Message-ID: <565D438D.4070007@rock-chips.com> (raw)
In-Reply-To: <CAPnjgZ03oGtm-kuKwDgcOHQjupMaTvUkViGOjbQeNyts5dos7g@mail.gmail.com>

Hi Simon,

On 27/11/15 11:37, Simon Glass wrote:
> Hi Lin,
>
> On 26 November 2015 at 19:35, Simon Glass <sjg@chromium.org> wrote:
>> Hi Lin,
>>
>> On 19 November 2015 at 22:58, Lin Huang <hl@rock-chips.com> wrote:
>>> we can use this config to disable rockchip serial driver in SPL stage,
>>> since some rockchip soc sram size is small(rk3036 etc), so we don't
>>> want rockchip serial driver build in SPL, but we still want use common
>>> debug driver in SPL.
>>>
>>> Signed-off-by: Lin Huang <hl@rock-chips.com>
>>> ---
>>>   arch/arm/mach-rockchip/Kconfig  | 3 +++
>>>   drivers/serial/Makefile         | 2 +-
>>>   include/configs/rk3288_common.h | 1 +
>>>   3 files changed, 5 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/arch/arm/mach-rockchip/Kconfig b/arch/arm/mach-rockchip/Kconfig
>>> index ccff81a..595263c 100644
>>> --- a/arch/arm/mach-rockchip/Kconfig
>>> +++ b/arch/arm/mach-rockchip/Kconfig
>>> @@ -59,6 +59,9 @@ config DM_GPIO
>>>   config ROCKCHIP_SERIAL
>>>          default y
>>>
>>> +config SPL_ROCKCHIP_SERIAL
>>> +       default n
>>> +
>> It will already default to 'n', so this can be omitted.
>>
>> Also you should add this new CONFIG to drivers/serial/Kconfig, below
>> the existing (non-SPL) one.
>>
>>>   source "arch/arm/mach-rockchip/rk3288/Kconfig"
>>>   source "arch/arm/mach-rockchip/rk3036/Kconfig"
>>>   endif
>>> diff --git a/drivers/serial/Makefile b/drivers/serial/Makefile
>>> index 1818c7c..73e30c6 100644
>>> --- a/drivers/serial/Makefile
>>> +++ b/drivers/serial/Makefile
>>> @@ -41,7 +41,7 @@ obj-$(CONFIG_ZYNQ_SERIAL) += serial_zynq.o
>>>   obj-$(CONFIG_BFIN_SERIAL) += serial_bfin.o
>>>   obj-$(CONFIG_FSL_LPUART) += serial_lpuart.o
>>>   obj-$(CONFIG_MXS_AUART) += mxs_auart.o
>>> -obj-$(CONFIG_ROCKCHIP_SERIAL) += serial_rockchip.o
>>> +obj-$(CONFIG_$(SPL_)ROCKCHIP_SERIAL) += serial_rockchip.o
>>>   obj-$(CONFIG_ARC_SERIAL) += serial_arc.o
>>>   obj-$(CONFIG_TEGRA_SERIAL) += serial_tegra.o
>>>   obj-$(CONFIG_UNIPHIER_SERIAL) += serial_uniphier.o
>>> diff --git a/include/configs/rk3288_common.h b/include/configs/rk3288_common.h
>>> index 74c7ee1..7f3d1ee 100644
>>> --- a/include/configs/rk3288_common.h
>>> +++ b/include/configs/rk3288_common.h
>>> @@ -30,6 +30,7 @@
>>>   #define CONFIG_SPL_LIBCOMMON_SUPPORT
>>>   #define CONFIG_SPL_LIBGENERIC_SUPPORT
>>>   #define CONFIG_SPL_SERIAL_SUPPORT
>>> +#define CONFIG_SPL_ROCKCHIP_SERIAL
>> You should add this to the rk3288 defconfig files, instead of here.
>> Kconfig items should not be added to config header files - in fact we
>> plan to eventually remove the config header files.
>>
>>>   #define CONFIG_SYS_NS16550
>>>   #define CONFIG_SYS_NS16550_MEM32
>>>   #define CONFIG_SPL_BOARD_INIT
>>> --
>>> 1.9.1
>>>
> Actually, serial_rockchip.c has been removed in mainline. So you may
> not need this patch, or maybe it can be reduced in size. Please check
> the current u-boot-rockchip/master.
     i cherry-pick the

     [PATCH 2/2] rockchip: rk3036: enable CONFIG_DEBUG_UART, and use 
ns16550 uart driver

     in u-boot-rockchip/master branch, build it,  but fail, it is will 
call hang() in arch/arm/lib/div0,
     so i need to define  CONFIG_SPL_LIBGENERIC_SUPPORT, but if i do it, 
the spl size too big.
> Regards,
> Simon
>
>
>

-- 
Lin Huang

  reply	other threads:[~2015-12-01  6:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-20  6:58 [U-Boot] [PATCH 1/2] rockchip: add CONFIG_SPL_ROCKCHIP_SERIAL Lin Huang
2015-11-20  6:58 ` [U-Boot] [PATCH 2/2] rockchip: rk3036: enable CONFIG_DEBUG_UART, and use ns16550 uart driver Lin Huang
2015-11-27  3:35   ` Simon Glass
2015-11-27  3:35 ` [U-Boot] [PATCH 1/2] rockchip: add CONFIG_SPL_ROCKCHIP_SERIAL Simon Glass
2015-11-27  3:37   ` Simon Glass
2015-12-01  6:51     ` hl [this message]
2015-12-01 15:12       ` Simon Glass

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=565D438D.4070007@rock-chips.com \
    --to=hl@rock-chips.com \
    --cc=u-boot@lists.denx.de \
    /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 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.