Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] target /etc/inittab
@ 2013-03-15 17:34 H Hartley Sweeten
  2013-03-16 18:51 ` Thomas Petazzoni
  0 siblings, 1 reply; 4+ messages in thread
From: H Hartley Sweeten @ 2013-03-15 17:34 UTC (permalink / raw)
  To: buildroot

Hello all,

I recently pulled the latest buildroot and ran into an issue I can't
figure out.

I'm using buildroot to create a rootfs for an ep93xx board. This
board has 3 serial ports ttyAM0-3. When the rootfs is created I
get this in the /etc/inittab:

# Set up a couple of getty's
tty1::respawn:/sbin/getty 38400 tty1
tty2::respawn:/sbin/getty 38400 tty2

# Put a getty on the serial port
ttyAM0::respawn:/sbin/getty -L ttyAM0 57600 vt100 # GENERIC_SERIAL
#ttyAM1::respawn:/sbin/getty -L ttyAM1 57600 vt100 # GENERIC_SERIAL
#ttyAM2::respawn:/sbin/getty -L ttyAM2 57600 vt100 # GENERIC_SERIAL

The problem is tty1 and tty2. They don't exist on my board and
give me issues when the board boots. I can't figure out why they
are being added to /etc/inittab and how to prevent theses getty's
from showing up.

Also how do I get a getty on ttyAM1 and ttyAM2?

If I edit output/target/etc/inittab and then do a make to create the
rootfs image it just gets changed back.

Any pointers?

Thanks,
Hartley

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

* [Buildroot] target /etc/inittab
  2013-03-15 17:34 [Buildroot] target /etc/inittab H Hartley Sweeten
@ 2013-03-16 18:51 ` Thomas Petazzoni
  2013-03-18 17:10   ` H Hartley Sweeten
  0 siblings, 1 reply; 4+ messages in thread
From: Thomas Petazzoni @ 2013-03-16 18:51 UTC (permalink / raw)
  To: buildroot

Dear H Hartley Sweeten,

On Fri, 15 Mar 2013 12:34:02 -0500, H Hartley Sweeten wrote:

> I'm using buildroot to create a rootfs for an ep93xx board. This
> board has 3 serial ports ttyAM0-3. When the rootfs is created I
> get this in the /etc/inittab:
> 
> # Set up a couple of getty's
> tty1::respawn:/sbin/getty 38400 tty1
> tty2::respawn:/sbin/getty 38400 tty2

This is strange, we have removed these since
7d9d09db673abbedc1cc865c213b742e0450268d, which appeared in 2011.05 it
seems. Those lines are no longer part of the default skeleton.

> # Put a getty on the serial port
> ttyAM0::respawn:/sbin/getty -L ttyAM0 57600 vt100 # GENERIC_SERIAL
> #ttyAM1::respawn:/sbin/getty -L ttyAM1 57600 vt100 # GENERIC_SERIAL
> #ttyAM2::respawn:/sbin/getty -L ttyAM2 57600 vt100 # GENERIC_SERIAL

These are not coming from Buildroot default skeleton. Maybe you're
using a modified Buildroot version and not the upstream version?

> The problem is tty1 and tty2. They don't exist on my board and
> give me issues when the board boots. I can't figure out why they
> are being added to /etc/inittab and how to prevent theses getty's
> from showing up.

Just use a recent upstream Buildroot version, those lines are no longer
present in the default inittab.

> Also how do I get a getty on ttyAM1 and ttyAM2?

In a recent upstream Buildroot version, I would do that with a
post-build script.

Make sure to do add a # GENERIC_SERIAL comment at the end of those
additional lines: this # GENERIC_SERIAL is a marker that tells
Buildroot to modify this line to start a getty on the default tty
(which is defined in the Buildroot configuration).

Best regards,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

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

* [Buildroot] target /etc/inittab
  2013-03-16 18:51 ` Thomas Petazzoni
@ 2013-03-18 17:10   ` H Hartley Sweeten
  2013-03-19 20:29     ` Alexey Brodkin
  0 siblings, 1 reply; 4+ messages in thread
From: H Hartley Sweeten @ 2013-03-18 17:10 UTC (permalink / raw)
  To: buildroot

On Saturday, March 16, 2013 11:51 AM, Thomas Petazzoni wrote:
> On Fri, 15 Mar 2013 12:34:02 -0500, H Hartley Sweeten wrote:
>> I'm using buildroot to create a rootfs for an ep93xx board. This
>> board has 3 serial ports ttyAM0-3. When the rootfs is created I
>> get this in the /etc/inittab:
>> 
>> # Set up a couple of getty's
>> tty1::respawn:/sbin/getty 38400 tty1
>> tty2::respawn:/sbin/getty 38400 tty2
>
> This is strange, we have removed these since
> 7d9d09db673abbedc1cc865c213b742e0450268d, which appeared in 2011.05 it
> seems. Those lines are no longer part of the default skeleton.
>
>> # Put a getty on the serial port
>> ttyAM0::respawn:/sbin/getty -L ttyAM0 57600 vt100 # GENERIC_SERIAL
>> #ttyAM1::respawn:/sbin/getty -L ttyAM1 57600 vt100 # GENERIC_SERIAL
>> #ttyAM2::respawn:/sbin/getty -L ttyAM2 57600 vt100 # GENERIC_SERIAL
>
> These are not coming from Buildroot default skeleton. Maybe you're
> using a modified Buildroot version and not the upstream version?

Thomas,

I'm pretty sure there are no modifications.

$ git status
# On branch master
nothing to commit, working directory clean
$ git log
commit 87854c12d1c81bade3522405ce1ac42d45475263
Author: Samuel Martin <s.martin49@gmail.com>
Date:   Mon Mar 11 18:58:40 2013 +0000

    ussp-push: new package
...

$ grep 'export BR2_VERSION:=' Makefile
export BR2_VERSION:=2013.05-git

I think the ttyAM0 getty is getting created because of my .config.

BR2_TARGET_GENERIC_GETTY_PORT="ttyAM0"

I'm not sure why the commented out ttyAM1 and ttyAM2 getty's
are showing up.

>> The problem is tty1 and tty2. They don't exist on my board and
>> give me issues when the board boots. I can't figure out why they
>> are being added to /etc/inittab and how to prevent theses getty's
>> from showing up.
>
> Just use a recent upstream Buildroot version, those lines are no longer
> present in the default inittab.

Those lines are not in the default inittab in the Buildroot
version I am trying... Strange...

>> Also how do I get a getty on ttyAM1 and ttyAM2?
>
> In a recent upstream Buildroot version, I would do that with a
> post-build script.

It just seems strange that they are getting put into the inittab for some
reason.

> Make sure to do add a # GENERIC_SERIAL comment at the end of those
> additional lines: this # GENERIC_SERIAL is a marker that tells
> Buildroot to modify this line to start a getty on the default tty
> (which is defined in the Buildroot configuration).

Regards,
Hartley

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

* [Buildroot] target /etc/inittab
  2013-03-18 17:10   ` H Hartley Sweeten
@ 2013-03-19 20:29     ` Alexey Brodkin
  0 siblings, 0 replies; 4+ messages in thread
From: Alexey Brodkin @ 2013-03-19 20:29 UTC (permalink / raw)
  To: buildroot

On 03/18/2013 09:10 PM, H Hartley Sweeten wrote:
> On Saturday, March 16, 2013 11:51 AM, Thomas Petazzoni wrote:
>> On Fri, 15 Mar 2013 12:34:02 -0500, H Hartley Sweeten wrote:
>>> I'm using buildroot to create a rootfs for an ep93xx board. This
>>> board has 3 serial ports ttyAM0-3. When the rootfs is created I
>>> get this in the /etc/inittab:
>>>
>>> # Set up a couple of getty's
>>> tty1::respawn:/sbin/getty 38400 tty1
>>> tty2::respawn:/sbin/getty 38400 tty2
>>
>> This is strange, we have removed these since
>> 7d9d09db673abbedc1cc865c213b742e0450268d, which appeared in 2011.05 it
>> seems. Those lines are no longer part of the default skeleton.
>>
>>> # Put a getty on the serial port
>>> ttyAM0::respawn:/sbin/getty -L ttyAM0 57600 vt100 # GENERIC_SERIAL
>>> #ttyAM1::respawn:/sbin/getty -L ttyAM1 57600 vt100 # GENERIC_SERIAL
>>> #ttyAM2::respawn:/sbin/getty -L ttyAM2 57600 vt100 # GENERIC_SERIAL
>>
>> These are not coming from Buildroot default skeleton. Maybe you're
>> using a modified Buildroot version and not the upstream version?

I've just tried to rebuild target's rootfs with your .config and only 
see 1 instance of ttyAMx:
===
# Put a getty on the serial port
ttyAM0::respawn:/sbin/getty -L ttyAM0 57600 vt100 # GENERIC_SERIAL
===

So I have no ideas on where another 2 got from in your case.

Also below is configuration I used (got it with "make savedefconfig" 
from your .config):
===
BR2_arm=y
BR2_arm920t=y
BR2_JLEVEL=2
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TARGET_GENERIC_HOSTNAME="EP9307"
BR2_TARGET_GENERIC_ISSUE="Welcome to Vision EP9307"
BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_MDEV=y
BR2_TARGET_GENERIC_GETTY_PORT="ttyAM0"
BR2_TARGET_GENERIC_GETTY_BAUDRATE_57600=y
BR2_PACKAGE_SDL=y
BR2_PACKAGE_SDL_IMAGE=y
BR2_PACKAGE_SDL_IMAGE_PNG=y
BR2_PACKAGE_SDL_NET=y
BR2_PACKAGE_SDL_GFX=y
BR2_PACKAGE_MTD=y
# BR2_PACKAGE_MTD_UBIATTACH is not set
# BR2_PACKAGE_MTD_UBICRC32 is not set
# BR2_PACKAGE_MTD_UBIDETACH is not set
# BR2_PACKAGE_MTD_UBIFORMAT is not set
# BR2_PACKAGE_MTD_UBIMKVOL is not set
# BR2_PACKAGE_MTD_UBINFO is not set
# BR2_PACKAGE_MTD_UBINIZE is not set
# BR2_PACKAGE_MTD_UBIRENAME is not set
# BR2_PACKAGE_MTD_UBIRMVOL is not set
# BR2_PACKAGE_MTD_UBIRSVOL is not set
# BR2_PACKAGE_MTD_UBIUPDATEVOL is not set
BR2_PACKAGE_NCURSES_TARGET_PANEL=y
BR2_PACKAGE_NCURSES_TARGET_FORM=y
BR2_PACKAGE_NCURSES_TARGET_MENU=y
BR2_PACKAGE_ETHTOOL=y
BR2_PACKAGE_PORTMAP=y
BR2_PACKAGE_NANO=y
BR2_TARGET_ROOTFS_EXT2=y
BR2_TARGET_ROOTFS_EXT2_GZIP=y
# BR2_TARGET_ROOTFS_TAR is not set
===

-Alexey

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

end of thread, other threads:[~2013-03-19 20:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-15 17:34 [Buildroot] target /etc/inittab H Hartley Sweeten
2013-03-16 18:51 ` Thomas Petazzoni
2013-03-18 17:10   ` H Hartley Sweeten
2013-03-19 20:29     ` Alexey Brodkin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox