All of lore.kernel.org
 help / color / mirror / Atom feed
* Change DEBUG console port on SabreSD image
@ 2014-02-24 15:31 Niklas Molin
  2014-02-24 15:45 ` Fabio Estevam
  0 siblings, 1 reply; 10+ messages in thread
From: Niklas Molin @ 2014-02-24 15:31 UTC (permalink / raw)
  To: meta-freescale

[-- Attachment #1: Type: text/plain, Size: 670 bytes --]

Hi.

I'm working on a custom board and basing my image on the SabreSD board.
We used UART2 as Debug console port and wonder how I change from UART1 to
UART2 for the DEBUG console port?

Got u-boot I found mx6sabresd.h and changed CONFIG_MXC_UART_BASE
to UART2_BASE.
Do I also need to change CONFIG_CONSOLE_DEV to ttymxc1, or can I still
use ttymxc0?

For the Linux-image I found in defconfig:
CONFIG_CMDLINE(which includes the ttymxc and CONFIG_DEBUG_IMX_UART_PORT,
which I'll change to 2.

I just wanted to check if this is the right approach?

Do I need to change the ttymxc number or is it enough to change the UART
port number?

Thanks,
Niklas

[-- Attachment #2: Type: text/html, Size: 888 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-24 15:31 Change DEBUG console port on SabreSD image Niklas Molin
@ 2014-02-24 15:45 ` Fabio Estevam
  2014-02-24 19:11   ` Niklas Molin
  0 siblings, 1 reply; 10+ messages in thread
From: Fabio Estevam @ 2014-02-24 15:45 UTC (permalink / raw)
  To: Niklas Molin; +Cc: meta-freescale

On Mon, Feb 24, 2014 at 12:31 PM, Niklas Molin <niklas.p.molin@gmail.com> wrote:
> Hi.
>
> I'm working on a custom board and basing my image on the SabreSD board.
> We used UART2 as Debug console port and wonder how I change from UART1 to
> UART2 for the DEBUG console port?

This is more a question to the U-boot list. Not really meta-fsl-arm related.

>
> Got u-boot I found mx6sabresd.h and changed CONFIG_MXC_UART_BASE to
> UART2_BASE.
> Do I also need to change CONFIG_CONSOLE_DEV to ttymxc1, or can I still use
> ttymxc0?

You need to use ttymxc1.

> For the Linux-image I found in defconfig:
> CONFIG_CMDLINE(which includes the ttymxc and CONFIG_DEBUG_IMX_UART_PORT,
> which I'll change to 2.
>
> I just wanted to check if this is the right approach?
>
> Do I need to change the ttymxc number or is it enough to change the UART
> port number?

Make sure you also change the configuration of the UART pads IOMUX to
the correct ones that are used by your hardware.

Regards,

Fabio Estevam


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-24 15:45 ` Fabio Estevam
@ 2014-02-24 19:11   ` Niklas Molin
  2014-02-24 22:18     ` Fabio Estevam
  0 siblings, 1 reply; 10+ messages in thread
From: Niklas Molin @ 2014-02-24 19:11 UTC (permalink / raw)
  To: Fabio Estevam; +Cc: meta-freescale

[-- Attachment #1: Type: text/plain, Size: 1606 bytes --]

Thanks for the information.

Seems like I was on the right path then.

I also tried to change the port for the linux-image (in the defconfig), but
it seems like it used the "original" settings.
I saw something about DEBUG_LL setting, which I could not find the
menuconfig (I could se in the defconfig that it was not set).
How to enable this, so I can change the DEBUG port in the linux image?

Best regards,
Niklas


On Mon, Feb 24, 2014 at 7:45 AM, Fabio Estevam <festevam@gmail.com> wrote:

> On Mon, Feb 24, 2014 at 12:31 PM, Niklas Molin <niklas.p.molin@gmail.com>
> wrote:
> > Hi.
> >
> > I'm working on a custom board and basing my image on the SabreSD board.
> > We used UART2 as Debug console port and wonder how I change from UART1 to
> > UART2 for the DEBUG console port?
>
> This is more a question to the U-boot list. Not really meta-fsl-arm
> related.
>
> >
> > Got u-boot I found mx6sabresd.h and changed CONFIG_MXC_UART_BASE to
> > UART2_BASE.
> > Do I also need to change CONFIG_CONSOLE_DEV to ttymxc1, or can I still
> use
> > ttymxc0?
>
> You need to use ttymxc1.
>
> > For the Linux-image I found in defconfig:
> > CONFIG_CMDLINE(which includes the ttymxc and CONFIG_DEBUG_IMX_UART_PORT,
> > which I'll change to 2.
> >
> > I just wanted to check if this is the right approach?
> >
> > Do I need to change the ttymxc number or is it enough to change the UART
> > port number?
>
> Make sure you also change the configuration of the UART pads IOMUX to
> the correct ones that are used by your hardware.
>
> Regards,
>
> Fabio Estevam
>

[-- Attachment #2: Type: text/html, Size: 2244 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-24 19:11   ` Niklas Molin
@ 2014-02-24 22:18     ` Fabio Estevam
  2014-02-25  5:55       ` Niklas Molin
  0 siblings, 1 reply; 10+ messages in thread
From: Fabio Estevam @ 2014-02-24 22:18 UTC (permalink / raw)
  To: Niklas Molin; +Cc: meta-freescale

On Mon, Feb 24, 2014 at 4:11 PM, Niklas Molin <niklas.p.molin@gmail.com> wrote:
> Thanks for the information.
>
> Seems like I was on the right path then.
>
> I also tried to change the port for the linux-image (in the defconfig), but
> it seems like it used the "original" settings.
> I saw something about DEBUG_LL setting, which I could not find the
> menuconfig (I could se in the defconfig that it was not set).
> How to enable this, so I can change the DEBUG port in the linux image?

You need to change your board file or dts (if you use 3.10, for
example) to use uart2 instead of uart1.

Regards,

Fabio Estevam


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-24 22:18     ` Fabio Estevam
@ 2014-02-25  5:55       ` Niklas Molin
  2014-02-25 10:54         ` Fabio Estevam
  0 siblings, 1 reply; 10+ messages in thread
From: Niklas Molin @ 2014-02-25  5:55 UTC (permalink / raw)
  To: Fabio Estevam; +Cc: meta-freescale

[-- Attachment #1: Type: text/plain, Size: 984 bytes --]

Hi Fabio.

I'm using 3.10, so I assume it should be setup in the dts then. But I can't
find in any of the dts/dtsi files where to set which UART (and tty) that
should be used for the debug port.

best regards,
Niklas


On Mon, Feb 24, 2014 at 2:18 PM, Fabio Estevam <festevam@gmail.com> wrote:

> On Mon, Feb 24, 2014 at 4:11 PM, Niklas Molin <niklas.p.molin@gmail.com>
> wrote:
> > Thanks for the information.
> >
> > Seems like I was on the right path then.
> >
> > I also tried to change the port for the linux-image (in the defconfig),
> but
> > it seems like it used the "original" settings.
> > I saw something about DEBUG_LL setting, which I could not find the
> > menuconfig (I could se in the defconfig that it was not set).
> > How to enable this, so I can change the DEBUG port in the linux image?
>
> You need to change your board file or dts (if you use 3.10, for
> example) to use uart2 instead of uart1.
>
> Regards,
>
> Fabio Estevam
>

[-- Attachment #2: Type: text/html, Size: 1477 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-25  5:55       ` Niklas Molin
@ 2014-02-25 10:54         ` Fabio Estevam
  2014-02-25 18:37           ` Niklas Molin
  0 siblings, 1 reply; 10+ messages in thread
From: Fabio Estevam @ 2014-02-25 10:54 UTC (permalink / raw)
  To: Niklas Molin; +Cc: meta-freescale

Please don't top post.

On Tue, Feb 25, 2014 at 2:55 AM, Niklas Molin <niklas.p.molin@gmail.com> wrote:
> Hi Fabio.
>
> I'm using 3.10, so I assume it should be setup in the dts then. But I can't
> find in any of the dts/dtsi files where to set which UART (and tty) that
> should be used for the debug port.


Take a look at http://git.freescale.com/git/cgit.cgi/imx/linux-2.6-imx.git/tree/arch/arm/boot/dts/imx6qdl-sabresd.dtsi?h=imx_3.10.17_1.0.0_beta

&uart1 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_uart1_1>;
status = "okay";
};

You should just remove this uart1 node and add your uart2 instead.

Regards,

Fabio Estevam


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-25 10:54         ` Fabio Estevam
@ 2014-02-25 18:37           ` Niklas Molin
  2014-02-25 21:01             ` Fabio Estevam
  0 siblings, 1 reply; 10+ messages in thread
From: Niklas Molin @ 2014-02-25 18:37 UTC (permalink / raw)
  To: Fabio Estevam; +Cc: meta-freescale

[-- Attachment #1: Type: text/plain, Size: 506 bytes --]

HI Fabio.

Thanks for the info.

I found it.
Will this also change the ttymxc to 1 (instead of 0)?

Best regards,
Niklas



>
> Take a look at
> http://git.freescale.com/git/cgit.cgi/imx/linux-2.6-imx.git/tree/arch/arm/boot/dts/imx6qdl-sabresd.dtsi?h=imx_3.10.17_1.0.0_beta
>
> &uart1 {
> pinctrl-names = "default";
> pinctrl-0 = <&pinctrl_uart1_1>;
> status = "okay";
> };
>
> You should just remove this uart1 node and add your uart2 instead.
>
> Regards,
>
> Fabio Estevam
>

[-- Attachment #2: Type: text/html, Size: 1048 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-25 18:37           ` Niklas Molin
@ 2014-02-25 21:01             ` Fabio Estevam
  2014-02-25 22:35               ` Niklas Molin
  0 siblings, 1 reply; 10+ messages in thread
From: Fabio Estevam @ 2014-02-25 21:01 UTC (permalink / raw)
  To: Niklas Molin; +Cc: meta-freescale

On Tue, Feb 25, 2014 at 3:37 PM, Niklas Molin <niklas.p.molin@gmail.com> wrote:
> HI Fabio.
>
> Thanks for the info.
>
> I found it.
> Will this also change the ttymxc to 1 (instead of 0)?

The dts nodes will make the kernel to register the different interfaces.

If you add a node for uart2 then uart2 will be registered.

You need to make sure that your kernel command line passes
console=ttymxc1 though.

Regards,

Fabio Estevam


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-25 21:01             ` Fabio Estevam
@ 2014-02-25 22:35               ` Niklas Molin
  2014-02-25 22:50                 ` Fabio Estevam
  0 siblings, 1 reply; 10+ messages in thread
From: Niklas Molin @ 2014-02-25 22:35 UTC (permalink / raw)
  To: Fabio Estevam; +Cc: meta-freescale

[-- Attachment #1: Type: text/plain, Size: 618 bytes --]

Hi Fabio.

I assume that console=ttymxc1 is changed in menuconfig?

I just realized that in my .dtsi file I have multiple uarts (since we are
using some uarts to communicate with other chips).
How will the compiler know which uart it should use for the console (so I
interact via the terminal console window)?

Best regards,
Niklas


> The dts nodes will make the kernel to register the different interfaces.
>
> If you add a node for uart2 then uart2 will be registered.
>
> You need to make sure that your kernel command line passes
> console=ttymxc1 though.
>
> Regards,
>
> Fabio Estevam
>

[-- Attachment #2: Type: text/html, Size: 1014 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Change DEBUG console port on SabreSD image
  2014-02-25 22:35               ` Niklas Molin
@ 2014-02-25 22:50                 ` Fabio Estevam
  0 siblings, 0 replies; 10+ messages in thread
From: Fabio Estevam @ 2014-02-25 22:50 UTC (permalink / raw)
  To: Niklas Molin; +Cc: meta-freescale

On Tue, Feb 25, 2014 at 7:35 PM, Niklas Molin <niklas.p.molin@gmail.com> wrote:
> Hi Fabio.
>
> I assume that console=ttymxc1 is changed in menuconfig?
>
> I just realized that in my .dtsi file I have multiple uarts (since we are
> using some uarts to communicate with other chips).
> How will the compiler know which uart it should use for the console (so I
> interact via the terminal console window)?

You should pass console=ttymxc1 from U-boot.

Then kernel will use uart2 as console.


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2014-02-25 22:50 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-24 15:31 Change DEBUG console port on SabreSD image Niklas Molin
2014-02-24 15:45 ` Fabio Estevam
2014-02-24 19:11   ` Niklas Molin
2014-02-24 22:18     ` Fabio Estevam
2014-02-25  5:55       ` Niklas Molin
2014-02-25 10:54         ` Fabio Estevam
2014-02-25 18:37           ` Niklas Molin
2014-02-25 21:01             ` Fabio Estevam
2014-02-25 22:35               ` Niklas Molin
2014-02-25 22:50                 ` Fabio Estevam

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.