Compare commits

..

11 Commits
201705 ... 3g

Author SHA1 Message Date
Daniel Willmann bf754ab498 init-install.sh: Save/restore an existing VPN certificate 2017-08-01 03:35:34 +02:00
Daniel Willmann 0eb1ff6e3b base-files: Fix /etc/fstab file to not mount the root filesystem in /boot
Fix fstab for sysmonitb-ip as well and increment princ

Ticket: SYS#3688
2017-06-15 17:36:08 +02:00
Daniel Willmann 70a8d0fef1 base-files: Fix /etc/fstab file to not mount the root filesystem in /boot
Ticket: SYS#3688
2017-06-15 17:25:57 +02:00
Daniel Willmann 8b199a88a6 sysmocom-backup: Change the list of files to backup to include 3g files 2017-05-30 20:51:40 +02:00
Daniel Willmann eb47e5d267 sysmocom-3g-image: Make sure all services are installed and started on boot 2017-05-30 20:51:40 +02:00
Daniel Willmann 037d7906d9 Add sysmonitb-ip machine as a copy of sysmocom-bsc 2017-05-30 20:51:35 +02:00
Daniel Willmann 9fc9d68ef5 Add preferred provider for the sysmocom-2g task 2017-05-08 16:27:50 +02:00
Daniel Willmann 5c8ef349c5 Add sysmocom-3g-image 2017-05-08 16:26:57 +02:00
Daniel Willmann 4f2ba173f3 ggsn/interfaces: Change secondary IP address to be in the same IP range
On 3G the femtocell needs to be able to connect to the ggsn directly, so
change the secondary IP address to be inside the same IP range
2017-05-08 16:21:45 +02:00
Daniel Willmann 7748dd8516 Add sysmocom-3g-image / task and include the task inside the image 2017-05-08 16:19:50 +02:00
Daniel Willmann 787af7f5f4 Rename task-sysmocom to task-sysmocom-2g 2017-05-08 16:17:29 +02:00
288 changed files with 5738 additions and 19766 deletions

View File

@ -1,155 +0,0 @@
# gitver-pkg.bbclass
#
# Based on gitpkgv.bbclass from meta-openembedded
PKGGITH = "${@get_pkg_gith(d, '${PN}')}"
PKGGITN = "${@get_pkg_gitn(d, '${PN}')}"
PKGGITV = "${@get_pkg_gitv(d, '${PN}')}"
def gitpkgv_drop_tag_prefix(version):
import re
if re.match("v\d", version):
return version[1:]
else:
return version
def get_pkg_gitv(d, pn):
import os
import bb
from pipes import quote
src_uri = d.getVar('SRC_URI', 1).split()
fetcher = bb.fetch2.Fetch(src_uri, d)
ud = fetcher.ud
ver = "0.0-0"
for url in ud.values():
if url.type == 'git' or url.type == 'gitsm':
for name, rev in url.revisions.items():
if not os.path.exists(url.localpath):
return None
vars = { 'repodir' : quote(url.localpath),
'rev' : quote(rev) }
# Verify of the hash is present
try:
bb.fetch2.runfetchcmd(
"cd %(repodir)s && "
"git describe %(rev)s --always 2>/dev/null" % vars,
d, quiet=True).strip()
except Exception:
bb.fetch2.runfetchcmd(
"cd %(repodir)s && git fetch 2>/dev/null" % vars,
d, quiet=True).strip()
# Try to get a version using git describe
try:
output = bb.fetch2.runfetchcmd(
"cd %(repodir)s && "
"git describe %(rev)s --long 2>/dev/null" % vars,
d, quiet=True).strip()
ver = gitpkgv_drop_tag_prefix(output)
except Exception:
try:
commits = bb.fetch2.runfetchcmd(
"cd %(repodir)s && "
"git rev-list %(rev)s --count 2> /dev/null " % vars,
d, quiet=True).strip()
if commits == "":
commits = "0"
rev = bb.fetch2.get_srcrev(d).split('+')[1]
ver = "0.0-%s-g%s" % (commits, rev[:7])
except Exception:
pass
return ver
def get_pkg_gitn(d, pn):
import os
import bb
from pipes import quote
src_uri = d.getVar('SRC_URI', 1).split()
fetcher = bb.fetch2.Fetch(src_uri, d)
ud = fetcher.ud
for url in ud.values():
if url.type == 'git' or url.type == 'gitsm':
for name, rev in url.revisions.items():
if not os.path.exists(url.localpath):
return None
vars = { 'repodir' : quote(url.localpath),
'rev' : quote(rev) }
# Verify of the hash is present
try:
bb.fetch2.runfetchcmd(
"cd %(repodir)s && "
"git describe %(rev)s --always 2>/dev/null" % vars,
d, quiet=True).strip()
except Exception:
bb.fetch2.runfetchcmd(
"cd %(repodir)s && git fetch 2>/dev/null" % vars,
d, quiet=True).strip()
try:
tag = bb.fetch2.runfetchcmd(
"cd %(repodir)s && "
"git describe --abbrev=0 %(rev)s 2>/dev/null" % vars,
d, quiet=True).strip()
vars = { 'repodir' : quote(url.localpath),
'rev' : quote(rev),
'tag' : quote(tag) }
commits = bb.fetch2.runfetchcmd(
"cd %(repodir)s && "
"git rev-list %(rev)s ^%(tag)s --count 2> /dev/null " % vars,
d, quiet=True).strip()
return commits
except Exception:
commits = bb.fetch2.runfetchcmd(
"cd %(repodir)s && "
"git rev-list %(rev)s --count 2> /dev/null " % vars,
d, quiet=True).strip()
if commits == "":
commits = "0"
return commits
return '0'
def get_pkg_gith(d, pn):
import os
import bb
from pipes import quote
src_uri = d.getVar('SRC_URI', 1).split()
fetcher = bb.fetch2.Fetch(src_uri, d)
ud = fetcher.ud
for url in ud.values():
if url.type == 'git' or url.type == 'gitsm':
for name, rev in url.revisions.items():
if not os.path.exists(url.localpath):
return None
else:
return rev
return None

View File

@ -1,139 +0,0 @@
# gitver-repo.bbclass
#
# Based on gitpkgv.bbclass from meta-openembedded
REPODIR ?= "${THISDIR}"
REPOGITH = "${@get_repo_gith(d, '${REPODIR}')}"
REPOGITN = "${@get_repo_gitn(d, '${REPODIR}')}"
REPOGITV = "${@get_repo_gitv(d, '${REPODIR}')}"
REPOGITT = "${@get_repo_gitt(d, '${REPODIR}')}"
REPOGITFN = "${@get_repo_gitfn(d, '${REPODIR}', '${REPOFILE}')}"
def gitver_repo_drop_tag_prefix(version):
import re
if re.match("v\d", version):
return version[1:]
else:
return version
def get_repo_gitv(d, repodir):
import os
import bb
from pipes import quote
vars = { 'repodir' : quote(repodir) }
try:
output = bb.fetch2.runfetchcmd(
"git -C %(repodir)s describe --long 2>/dev/null" % vars,
d, quiet=True).strip()
ver = gitver_repo_drop_tag_prefix(output)
except Exception:
return None
return ver
def get_repo_gitn(d, repodir):
import os
import bb
from pipes import quote
vars = { 'repodir' : quote(repodir) }
try:
tag = bb.fetch2.runfetchcmd(
"git -C %(repodir)s describe --abbrev=0 2>/dev/null" % vars,
d, quiet=False).strip()
vars = { 'repodir' : quote(repodir),
'tag' : quote(tag) }
commits = bb.fetch2.runfetchcmd(
"git -C %(repodir)s rev-list %(tag)s.. --count 2> /dev/null" % vars,
d, quiet=True).strip()
return commits
except Exception:
commits = bb.fetch2.runfetchcmd(
"git -C %(repodir)s rev-list --count HEAD 2>/dev/null" % vars,
d, quiet=True).strip()
if commits == "":
commits = "0"
return commits
def get_repo_gitt(d, repodir):
import os
import bb
from pipes import quote
vars = { 'repodir' : quote(repodir) }
try:
tag = bb.fetch2.runfetchcmd(
"git -C %(repodir)s describe --abbrev=0 2>/dev/null" % vars,
d, quiet=True).strip()
return tag
except Exception:
return None
def get_repo_gith(d, repodir):
import os
import bb
from pipes import quote
vars = { 'repodir' : quote(repodir) }
try:
hash = bb.fetch2.runfetchcmd(
"git -C %(repodir)s rev-parse HEAD 2>/dev/null" % vars,
d, quiet=True).strip()
return hash
except Exception:
return None
def get_repo_gitfn(d, repodir, repofile):
import os
import bb
from pipes import quote
vars = { 'repodir' : quote(repodir),
'repofile' : quote(repofile) }
try:
tag = bb.fetch2.runfetchcmd(
"git -C %(repodir)s describe --abbrev=0 2>/dev/null" % vars,
d, quiet=False).strip()
vars = { 'repodir' : quote(repodir),
'repofile' : quote(repofile),
'tag' : quote(tag) }
commits = bb.fetch2.runfetchcmd(
"git -C %(repodir)s rev-list --count %(tag)s.. %(repofile)s 2> /dev/null" % vars,
d, quiet=True).strip()
return commits
except Exception:
commits = bb.fetch2.runfetchcmd(
"git -C %(repodir)s rev-list --count HEAD %(repofile)s 2>/dev/null" % vars,
d, quiet=True).strip()
if commits == "":
commits = "0"
return commits

View File

@ -133,7 +133,7 @@ def not_tarball(d):
workdir = d.getVar('WORKDIR',True)
s = d.getVar('S',True)
if 'work-shared' in s or 'task-' in workdir or 'native' in workdir:
pn = d.getVar('PN', True)
pn = bb.data.getVar('PN', d , True)
if pn == 'gcc-cross':
return False
return True
@ -362,8 +362,8 @@ def archive_scripts_logs(d):
def dumpdata(d):
'''dump environment to "${P}-${PR}.showdata.dump" including all kinds of variables and functions when running a task'''
workdir = d.getVar('WORKDIR', 1)
distro = d.getVar('DISTRO', 1)
workdir = bb.data.getVar('WORKDIR', d, 1)
distro = bb.data.getVar('DISTRO', d, 1)
s = d.getVar('S', True)
pf = d.getVar('PF', True)
target_sys = d.getVar('TARGET_SYS', True)
@ -383,8 +383,8 @@ def dumpdata(d):
bb.data.emit_env(f, d, True)
# emit the metadata which isnt valid shell
for e in d.keys():
if d.getVarFlag(e, 'python'):
f.write("\npython %s () {\n%s}\n" % (e, d.getVar(e, 1)))
if bb.data.getVarFlag(e, 'python', d):
f.write("\npython %s () {\n%s}\n" % (e, bb.data.getVar(e, d, 1)))
f.close()
def create_diff_gz(d):
@ -460,8 +460,8 @@ python do_archive_linux_yocto(){
s = d.getVar('S', True)
if 'linux-yocto' in s:
source_tar_name = archive_sources(d,'')
if d.getVar('SOURCE_ARCHIVE_PACKAGE_TYPE', True).upper() not in 'SRPM':
move_tarball_deploy(d,[source_tar_name,''])
if d.getVar('SOURCE_ARCHIVE_PACKAGE_TYPE', True).upper() not in 'SRPM':
move_tarball_deploy(d,[source_tar_name,''])
}
do_kernel_checkout[postfuncs] += "do_archive_linux_yocto "

View File

@ -35,7 +35,3 @@ PACKAGECONFIG_pn-systemd = "compat ldconfig binfmt sysusers randomseed myhostnam
# From fido on.. build curl with libssl to avoid gnutls
PACKAGECONFIG_pn-curl="ipv6 ssl zlib"
# disable libsolv as it is broken Yocto Bug #11427
PACKAGECONFIG_pn-opkg = ""
PACKAGECONFIG_pn-opkg-native = ""

View File

@ -3,10 +3,14 @@ BBPATH := "${BBPATH}:${LAYERDIR}"
# We have a packages directory, add to BBFILES
BBFILES += "${LAYERDIR}/recipes-*/*/*.bb ${LAYERDIR}/recipes-*/*/*.bbappend"
BBFILES += "${LAYERDIR}/yocto-shared/*.bbappend"
# Now we will need to include the matching fixes for a yocto version
BBFILES += "${BBFILES_SYSMOCOM_BSP}"
# Fixes for the yocto version targeted
BBFILES += "${LAYERDIR}/yocto-fixes/*.bbappend ${LAYERDIR}/yocto-fixes/*/*.bb"
# selects specific distro or master when DISTRO_VERSION contains snapshot
BBFILES_SYSMOCOM_BSP = "${LAYERDIR}/yocto-${@dict([('1.5', 'dora')]).get(d.getVar('DISTRO_VERSION', True)[0:3],'master')}/*.bbappend"
BBFILES_SYSMOCOM_BSP += "${LAYERDIR}/yocto-${@dict([('1.5', 'dora')]).get(d.getVar('DISTRO_VERSION', True)[0:3],'master')}/*/*.bb"
BBFILE_COLLECTIONS += "sysmocom-bsp"
BBFILE_PATTERN_sysmocom-bsp := "^${LAYERDIR}/"

View File

@ -1,7 +1,7 @@
TARGET_ARCH = "arm"
PREFERRED_PROVIDER_virtual/kernel = "linux-sysmocom"
PREFERRED_VERSION_linux-sysmocom = "${@dict([('1.5', '3.10.84+git%')]).get(d.getVar('DISTRO_VERSION', True)[0:3],'4.9.59+git%')}"
PREFERRED_VERSION_linux-sysmocom = "3.10.84+git%"
PREFERRED_PROVIDERS += "virtual/${TARGET_PREFIX}depmod:module-init-tools-cross"
PREFERRED_VERSION_u-boot = "git"
@ -41,6 +41,3 @@ MACHINE_EXTRA_RDEPENDS = "\
require conf/machine/include/tune-arm926ejs.inc
require conf/machine/include/dm6446.inc
# we tune for armv5te but it ends up as armv5e on pyro and probably earlier. Help it.
ARMPKGSFX_THUMB="t"

View File

@ -1,33 +0,0 @@
#@TYPE: Machine
#@NAME: Litecel15 EVM
#@DESCRIPTION: Machine configuration for the NRW Litecell15 EVM
# (omap-a15.inc)
SOC_FAMILY = "omap-a15"
require conf/machine/include/soc-family.inc
DEFAULTTUNE = "cortexa15thf-neon"
require conf/machine/include/tune-cortexa15.inc
KERNEL_IMAGETYPE = "zImage"
UBOOT_ARCH = "arm"
UBOOT_ENTRYPOINT = "0x80008000"
UBOOT_LOADADDRESS = "0x80008000"
EXTRA_IMAGEDEPENDS += "virtual/bootloader"
PREFERRED_PROVIDER_virtual/kernel = "linux-litecell15"
PREFERRED_PROVIDER_virtual/bootloader = "u-boot-litecell15"
PREFERRED_PROVIDER_u-boot = "u-boot-litecell15"
IMAGE_FSTYPES += "tar.gz"
SERIAL_CONSOLE = "115200 ttyS2"
UBOOT_MACHINE = "litecell15_config"
# Currently removing the sgx machine feature because there is no SGX package
# available for omap5
MACHINE_FEATURES = "kernel26 apm vfat ext2"
MACHINE_GPS_DEVICE = "/dev/ttyS0"

View File

@ -1,59 +0,0 @@
#@TYPE: Machine
#@NAME: OC-2G
#@DESCRIPTION: Machine configuration for the NRW OC-2G BTS
# (omap-a15.inc)
SOC_FAMILY = "omap-a15"
require conf/machine/include/soc-family.inc
DEFAULTTUNE = "cortexa15thf-neon"
require conf/machine/include/tune-cortexa15.inc
KERNEL_IMAGETYPE = "zImage"
UBOOT_ARCH = "arm"
UBOOT_ENTRYPOINT = "0x80008000"
UBOOT_LOADADDRESS = "0x80008000"
EXTRA_IMAGEDEPENDS += "virtual/bootloader"
PREFERRED_PROVIDER_virtual/kernel = "linux-oc2g"
PREFERRED_PROVIDER_virtual/bootloader = "u-boot-oc2g"
PREFERRED_PROVIDER_u-boot = "u-boot-oc2g"
IMAGE_FSTYPES += "tar.gz"
SERIAL_CONSOLE = "115200 ttyS2"
UBOOT_MACHINE = "oc2g_config"
# Currently removing the sgx machine feature because there is no SGX package
# available for omap5
MACHINE_FEATURES = "kernel26 apm vfat ext2"
MACHINE_GPS_DEVICE = "/dev/ttyS0"
MACHINE_ESSENTIAL_EXTRA_RDEPENDS = "\
${@['watchdog', ''][d.getVar('VIRTUAL-RUNTIME_init_manager', True) == 'systemd']} \
kernel-module-rpmsg-proto \
kernel-module-rpmsg-rpc \
kernel-module-nrw-clkerr \
kernel-module-nrw-vswr \
kernel-module-adl5501 \
kernel-module-industrialio-buffer-cb \
kernel-module-input-polldev \
kernel-module-iio-hwmon \
kernel-module-ntc-thermistor \
kernel-module-mcp47x6 \
kernel-module-xilinx-xadc \
kernel-module-industrialio \
kernel-module-omap-remoteproc \
kernel-module-fpgadl \
"
MACHINE_EXTRA_RDEPENDS = "\
task-sysmocom-bts \
${@['watchdog', ''][d.getVar('VIRTUAL-RUNTIME_init_manager', True) == 'systemd']} \
"
KERNEL_VERSION_SANITY_SKIP="1"
EXTRA_IMAGEDEPENDS += "sysmobts2100-devtools"

View File

@ -1,26 +0,0 @@
# sysmoBTS 2100 machine type, based on LC15
require conf/machine/litecell15.conf
MACHINE_ESSENTIAL_EXTRA_RDEPENDS = "\
${@['watchdog', ''][d.getVar('VIRTUAL-RUNTIME_init_manager', True) == 'systemd']} \
kernel-module-rpmsg-proto \
kernel-module-rpmsg-rpc \
kernel-module-nrw-clkerr \
kernel-module-nrw-vswr \
kernel-module-adl5501 \
kernel-module-industrialio-buffer-cb \
kernel-module-input-polldev \
kernel-module-iio-hwmon \
kernel-module-ntc-thermistor \
kernel-module-mcp47x6 \
kernel-module-xilinx-xadc \
kernel-module-industrialio \
kernel-module-omap-remoteproc \
kernel-module-fpgadl \
"
MACHINE_EXTRA_RDEPENDS = "\
task-sysmocom-bts \
${@['watchdog', ''][d.getVar('VIRTUAL-RUNTIME_init_manager', True) == 'systemd']} \
"
EXTRA_IMAGEDEPENDS += "sysmobts2100-devtools"

View File

@ -1,39 +0,0 @@
#@TYPE: Machine
#@NAME: common_pc
#@DESCRIPTION: Machine configuration for sysmocom apu2 based hardware
require conf/machine/include/tune-core2.inc
require conf/machine/include/genericx86-common.inc
require sysmocom-bsc.conf
PREFERRED_PROVIDER_virtual/libgl = "mesa-dri"
PREFERRED_PROVIDER_virtual/libx11 ?= "libx11-diet"
PREFERRED_PROVIDER_virtual/xserver ?= "xserver-xf86-dri-lite"
PREFERRED_PROVIDER_virtual/xserver-xf86 ?= "xserver-xf86-dri-lite"
PREFERRED_PROVIDER_virtual/kernel = "linux-sysmocom"
PREFERRED_VERSION_linux-sysmocom = "${@dict([('1.5', '3.10.84+git%')]).get(d.getVar('DISTRO_VERSION', True)[0:3],'4.9.59+git%')}"
MACHINE_FEATURES += "kernel26 x86 usbhost pci acpi"
KERNEL_IMAGETYPE = "bzImage"
IMAGE_FSTYPES = "ext4"
# After dora core2 got renamed to core2-32
# After dora core2 got renamed to core2-32
DEFAULTTUNE := "${@['core2', 'core2-32']['core2-32' in d.getVar('AVAILTUNES', True)]}"
SERIAL_CONSOLE = "115200 ttyS0"
MACHINE_CONSOLE = "console=ttyS0,115200n8"
# We bypass swrast but we need it to be present for X to load correctly
XSERVER ?= "xserver-xf86-dri-lite \
mesa-dri-driver-swrast \
xf86-input-vmmouse \
xf86-input-keyboard \
xf86-input-evdev \
xf86-video-vmware"
GLIBC_ADDONS = "nptl"
GLIBC_EXTRA_OECONF = "--with-tls"

View File

@ -1,7 +1,38 @@
MACHINEOVERRIDES = "${MACHINE}:sysmocom-bsc"
#@TYPE: Machine
#@NAME: common_pc
#@DESCRIPTION: Machine configuration for running a common x86
MACHINE_EXTRA_RDEPENDS = "\
dnsmasq \
"
TARGET_ARCH = "i586"
DISTRO_FEATURES_append = " iu "
PREFERRED_PROVIDER_virtual/libgl = "mesa-dri"
PREFERRED_PROVIDER_virtual/libx11 ?= "libx11-diet"
PREFERRED_PROVIDER_virtual/xserver ?= "xserver-xf86-dri-lite"
PREFERRED_PROVIDER_virtual/xserver-xf86 ?= "xserver-xf86-dri-lite"
PREFERRED_PROVIDER_virtual/kernel = "${@['linux-sysmocom', 'linux']['1.1' in d.getVar('DISTRO_VERSION', True)]}"
require conf/machine/include/tune-geode.inc
MACHINE_FEATURES += "kernel26 x86 usbhost pci acpi"
KERNEL_IMAGETYPE = "bzImage"
IMAGE_FSTYPES ?= "tar.gz ext4"
SERIAL_CONSOLE = "38400 ttyS0"
MACHINE_CONSOLE = "console=ttyS0,38400n8"
# We bypass swrast but we need it to be present for X to load correctly
XSERVER ?= "xserver-xf86-dri-lite \
mesa-dri-driver-swrast \
xf86-input-vmmouse \
xf86-input-keyboard \
xf86-input-evdev \
xf86-video-vmware"
GLIBC_ADDONS = "nptl"
GLIBC_EXTRA_OECONF = "--with-tls"
#MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "v86d"
MACHINE_ESSENTIAL_EXTRA_RDEPENDS = "\
${@['', 'busybox-ifplugd'][d.getVar('DISTRO_VERSION', True)[0:3] == '1.5']} \
linux-firmware-rtl-nic "

View File

@ -10,8 +10,7 @@ PREFERRED_PROVIDER_virtual/libgl = "mesa-dri"
PREFERRED_PROVIDER_virtual/libx11 ?= "libx11-diet"
PREFERRED_PROVIDER_virtual/xserver ?= "xserver-xf86-dri-lite"
PREFERRED_PROVIDER_virtual/xserver-xf86 ?= "xserver-xf86-dri-lite"
PREFERRED_PROVIDER_virtual/kernel = "linux-sysmocom"
PREFERRED_VERSION_linux-sysmocom = "${@dict([('1.5', '3.10.84+git%')]).get(d.getVar('DISTRO_VERSION', True)[0:3],'4.9.59+git%')}"
PREFERRED_PROVIDER_virtual/kernel = "${@['linux-sysmocom', 'linux']['1.1' in d.getVar('DISTRO_VERSION', True)]}"
MACHINE_FEATURES += "kernel26 x86 usbhost pci acpi"

View File

@ -1,8 +1,6 @@
#@TYPE: Machine
#@NAME: common_pc
#@DESCRIPTION: Machine configuration for sysmocom alix2d based hardware
require sysmocom-bsc.conf
#@DESCRIPTION: Machine configuration for running a common x86
TARGET_ARCH = "i586"
@ -10,8 +8,7 @@ PREFERRED_PROVIDER_virtual/libgl = "mesa-dri"
PREFERRED_PROVIDER_virtual/libx11 ?= "libx11-diet"
PREFERRED_PROVIDER_virtual/xserver ?= "xserver-xf86-dri-lite"
PREFERRED_PROVIDER_virtual/xserver-xf86 ?= "xserver-xf86-dri-lite"
PREFERRED_PROVIDER_virtual/kernel = "linux-sysmocom"
PREFERRED_VERSION_linux-sysmocom = "${@dict([('1.5', '3.10.84+git%')]).get(d.getVar('DISTRO_VERSION', True)[0:3],'4.9.59+git%')}"
PREFERRED_PROVIDER_virtual/kernel = "${@['linux-sysmocom', 'linux']['1.1' in d.getVar('DISTRO_VERSION', True)]}"
require conf/machine/include/tune-geode.inc
@ -21,8 +18,8 @@ KERNEL_IMAGETYPE = "bzImage"
IMAGE_FSTYPES ?= "tar.gz ext4"
SERIAL_CONSOLE = "115200 ttyS0"
MACHINE_CONSOLE = "console=ttyS0,115200n8"
SERIAL_CONSOLE = "38400 ttyS0"
MACHINE_CONSOLE = "console=ttyS0,38400n8"
# We bypass swrast but we need it to be present for X to load correctly
XSERVER ?= "xserver-xf86-dri-lite \

View File

@ -7,8 +7,6 @@ SRC_URI = "http://www.harding.motd.ca/autossh/autossh-${PV}.tgz \
file://020_use_destdir_makefile.diff \
file://022_pass_ldflags.diff"
MIRRORS_append = "\n http://www.harding.motd.ca/autossh/.* https://downloads.sysmocom.de/public/mirror/source/ \n"
SRC_URI[md5sum] = "f86684b96e99d22b2e9d35dc63b0aa29"
SRC_URI[sha256sum] = "9e8e10a59d7619176f4b986e256f776097a364d1be012781ea52e08d04679156"

View File

@ -0,0 +1,77 @@
#! /bin/sh
### BEGIN INIT INFO
# Provides: sysklogd
# Required-Start: $remote_fs $time
# Required-Stop: $remote_fs $time
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: System logger
### END INIT INFO
set -e
if [ -f /etc/syslog.conf ]; then
. /etc/syslog.conf
LOG_LOCAL=0
LOG_REMOTE=0
for D in $DESTINATION; do
if [ "$D" = "buffer" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -C$BUFFERSIZE"
LOG_LOCAL=1
elif [ "$D" = "file" ]; then
if [ -n "$LOGFILE" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -O $LOGFILE"
fi
if [ -n "$ROTATESIZE" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -s $ROTATESIZE"
fi
if [ -n "$ROTATEGENS" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -b $ROTATEGENS"
fi
LOCAL=0
elif [ "$D" = "remote" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -R $REMOTE"
LOG_REMOTE=1
fi
done
if [ "$LOG_LOCAL" = "1" -a "$LOG_REMOTE" = "1" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -L"
fi
if [ "$REDUCE" = "yes" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -S"
fi
if [ "$DROPDUPLICATES" = "yes" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -D"
fi
if [ -n "$LOGLEVEL" ]; then
SYSLOG_ARGS="$SYSLOG_ARGS -l $LOGLEVEL"
fi
else
# default: log to 16K shm circular buffer
SYSLOG_ARGS="-C"
fi
case "$1" in
start)
echo -n "Starting syslogd/klogd: "
start-stop-daemon -S -b -n syslogd -a /sbin/syslogd -- -n $SYSLOG_ARGS
start-stop-daemon -S -b -n klogd -a /sbin/klogd -- -n
echo "done"
;;
stop)
echo -n "Stopping syslogd/klogd: "
start-stop-daemon -K -n syslogd
start-stop-daemon -K -n klogd
echo "done"
;;
restart)
$0 stop
$0 start
;;
*)
echo "Usage: syslog { start | stop | restart }" >&2
exit 1
;;
esac
exit 0

View File

@ -0,0 +1,22 @@
DESTINATION="buffer" # log destinations (buffer file remote)
MARKINT=20 # intervall between --mark-- entries
LOGFILE=/var/log/messages # where to log (file)
REMOTE=loghost:514 # where to log (syslog remote)
REDUCE=no # reduce-size logging
#ROTATESIZE=0 # rotate log if grown beyond X [kByte] (incompatible with busybox)
#ROTATEGENS=3 # keep X generations of rotated logs (incompatible with busybox)
BUFFERSIZE=64 # size of circular buffer [kByte]
FOREGROUND=no # run in foreground (don't use!)
LOGLEVEL=6
# magic when a MMC card is mounted
USING_MMC_CARD=`/bin/mount | grep /media/mmcblk0p1 | wc -l`
if [ 1 -eq $USING_MMC_CARD ] ; then
if [ -e /media/mmcblk0p1/log ] ; then
echo "Using mmc card"
LOGFILE=/media/mmcblk0p1/log/messages
DESTINATION="file"
ROTATESIZE=2048
ROTATEGENS=20
fi
fi

View File

@ -0,0 +1,18 @@
require sysmocom-image.inc
IMAGE_INSTALL += " task-sysmocom-3g "
# Activate osmo-hnbgw, osmo-hlr, osmo-msc, osmo-sgsn and openggsn for 3G
activate_core() {
}
activate_systemd_core() {
ln -sf ${systemd_unitdir}/system/osmo-hnbgw.service ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/
ln -sf ${systemd_unitdir}/system/osmo-msc.service ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/
ln -sf ${systemd_unitdir}/system/osmo-bsc-mgcp.service ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/
ln -sf ${systemd_unitdir}/system/osmo-sgsn.service ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/
ln -sf ${systemd_unitdir}/system/osmo-hlr.service ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/
ln -sf ${systemd_unitdir}/system/openggsn.service ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/
}
IMAGE_PREPROCESS_COMMAND += "${@base_contains('DISTRO_FEATURES','systemd','activate_systemd_core','activate_core',d)}; "

View File

@ -0,0 +1,15 @@
require sysmocom-image.inc
IMAGE_LINGUAS = " "
IMAGE_INSTALL_append = " dnsmasq "
# This variant of the image will run osmo-bts and osmo-bsc
activate_bsc() {
echo "NO_START=0" > ${IMAGE_ROOTFS}/etc/default/osmo-bsc
}
activate_systemd_bsc() {
ln -sf ${systemd_unitdir}/system/osmo-bsc.service ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/
}
IMAGE_PREPROCESS_COMMAND += "${@base_contains('DISTRO_FEATURES','systemd','activate_systemd_bsc','activate_bsc',d)}; "

View File

@ -1,4 +1,4 @@
IMAGE_INSTALL = "task-core-boot packagegroup-osmocom task-sysmocom-tools"
IMAGE_INSTALL = "task-core-boot ${ROOTFS_PKGMANAGE_BOOTSTRAP} packagegroup-osmocom task-sysmocom-2g"
IMAGE_LINGUAS = " "
LICENSE = "MIT"

View File

@ -1,2 +0,0 @@
require sysmocom-core-image.bb
require sysmocom-rauc-slot.inc

View File

@ -1,5 +1,5 @@
DEPENDS = "${MACHINE_EXTRA_RDEPENDS} util-linux-native"
IMAGE_INSTALL = "task-core-boot ${ROOTFS_PKGMANAGE} packagegroup-osmocom task-sysmocom-debug task-sysmocom-tools ${MACHINE_EXTRA_RDEPENDS} "
IMAGE_INSTALL = "task-core-boot ${ROOTFS_PKGMANAGE_BOOTSTRAP} ${ROOTFS_PKGMANAGE} packagegroup-osmocom task-sysmocom-debug task-sysmocom-tools ${MACHINE_EXTRA_RDEPENDS} "
IMAGE_LINGUAS = " "
IMAGE_FEATURES += " package-management "
LICENSE = "MIT"

View File

@ -1,3 +1,14 @@
require sysmocom-image.inc
IMAGE_INSTALL_append = " task-sysmocom-cs task-gprscore "
IMAGE_INSTALL += " task-sysmocom-2g "
# This variant of the image will run osmo-bts and osmo-nitb
activate_nitb() {
echo "NO_START=0" > ${IMAGE_ROOTFS}/etc/default/osmo-nitb
}
activate_systemd_nitb() {
ln -sf ${systemd_unitdir}/system/osmo-nitb.service ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/
}
IMAGE_PREPROCESS_COMMAND += "${@base_contains('DISTRO_FEATURES','systemd','activate_systemd_nitb','activate_nitb',d)}; "

View File

@ -1,11 +0,0 @@
require sysmocom-image.inc
IMAGE_INSTALL_append = " task-sysmocom-cs osmo-sip-connector "
# osmo-pcu is included in sysmobts targets due to machine .conf depending on
# task-sysmocom-bts. Since we only want voice here, let's disable osmo-pcu and
# be done with it:
disable_systemd_osmo_pcu() {
rm -f ${IMAGE_ROOTFS}/etc/systemd/system/multi-user.target.wants/osmo-pcu.service
}
IMAGE_PREPROCESS_COMMAND += "disable_systemd_osmo_pcu "

View File

@ -0,0 +1,7 @@
[Unit]
Description=/data
[Mount]
What=/dev/sda4
Where=/data
Type=ext4

View File

@ -19,9 +19,9 @@ do_install() {
install -m 0755 ${WORKDIR}/sysmocom-backup-data ${D}${sbindir}/
install -m 0755 ${WORKDIR}/sysmocom-restore-data ${D}${sbindir}/
install -d ${D}${systemd_system_unitdir}
install -m 0644 ${WORKDIR}/data.mount ${D}${systemd_system_unitdir}/
install -m 0644 ${WORKDIR}/sysmocom-restore.service ${D}${systemd_system_unitdir}/
install -d ${D}${systemd_unitdir}/system
install -m 0644 ${WORKDIR}/data.mount ${D}${systemd_unitdir}/system/
install -m 0644 ${WORKDIR}/sysmocom-restore.service ${D}${systemd_unitdir}/system/
}
SYSTEMD_PACKAGES = "${PN}"

View File

@ -4,10 +4,12 @@ etc/network/interfaces
etc/openvpn
etc/opkg/sysmocom-config.conf
etc/osmocom
etc/systemd/system/multi-user.target.wants
etc/ggsn.conf
etc/default
var/lib/osmocom/hlr.db
etc/lcr
/etc/dnsmasq.conf
etc/dnsmasq.conf
etc/sysmocom/backup.d
etc/machine-id
etc/dropbear/dropbear_rsa_host_key

View File

@ -1,7 +1,7 @@
DESCRIPTION = "sysmocom config backup and restore scripts"
LICENSE = "GPLv3+"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
PR = "r16"
PR = "r13"
SRC_URI = " \
file://sysmocom-backup \

View File

@ -0,0 +1,9 @@
start 10.23.24.123
end 10.23.24.254
interface eth1
option router 10.23.24.1
option subnet 255.255.255.0
option broadcast 10.23.24.255
option dns 8.8.8.8

View File

@ -0,0 +1,11 @@
[Unit]
Description=UDHCPD
Requires=sys-subsystem-net-devices-eth1.device
After=sys-subsystem-net-devices-eth1.device
[Service]
Type=simple
ExecStart=/usr/sbin/udhcpd -fS /etc/udhcpd.conf
[Install]
WantedBy=multi-user.target

View File

@ -14,7 +14,7 @@ FILES_${PN} += "${systemd_unitdir}"
do_install() {
install -d ${D}${sysconfdir}
install -m 0644 ${WORKDIR}/udhcpd.conf ${D}${sysconfdir}/
install -d ${D}${systemd_system_unitdir}/multi-user.target.wants/
install -m 0644 /${WORKDIR}/udhcpd.service ${D}${systemd_system_unitdir}/
ln -sf ../udhcpd.service ${D}${systemd_system_unitdir}/multi-user.target.wants/
install -d ${D}${systemd_unitdir}/system/multi-user.target.wants/
install -m 0644 /${WORKDIR}/udhcpd.service ${D}${systemd_unitdir}/system/
ln -sf ../udhcpd.service ${D}${systemd_unitdir}/system/multi-user.target.wants/
}

View File

@ -7,7 +7,8 @@ ALLOW_EMPTY_${PN} = "1"
PR = "r1"
RDEPENDS_${PN} = "\
osmo-ggsn \
gprs-routing \
osmo-sgsn \
openggsn \
gprs-routing osmo-sgsn \
sysmocom-ggsn-config \
"

View File

@ -0,0 +1,24 @@
DESCRIPTION = "Task for sysmocom 2G"
LICENSE = "MIT"
LIC_FILES_CHKSUM = " \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
DEPENDS = "virtual/kernel"
ALLOW_EMPTY_${PN} = "1"
PR = "r11"
RDEPENDS_${PN} = "\
task-sysmocom-tools \
osmo-bsc \
osmo-bsc-mgcp \
osmo-bsc-nat \
osmo-gbproxy \
osmo-nitb \
ipaccess-utils \
"
PREFERRED_PROVIDER_osmo-bsc = "openbsc"
PREFERRED_PROVIDER_osmo-bsc-mgcp = "openbsc"
PREFERRED_PROVIDER_osmo-bsc-nat = "openbsc"
PREFERRED_PROVIDER_osmo-bsc-nitb = "openbsc"
PREFERRED_PROVIDER_osmo-bsc-gbproxy = "openbsc"
PREFERRED_PROVIDER_ipaccess-utils = "openbsc"

View File

@ -0,0 +1,29 @@
DESCRIPTION = "Task for sysmocom 3G"
LICENSE = "MIT"
LIC_FILES_CHKSUM = " \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
DEPENDS = "virtual/kernel"
ALLOW_EMPTY_${PN} = "1"
PR = "r2"
RDEPENDS_${PN} = "\
task-sysmocom-tools \
osmo-hnbgw \
osmo-hlr \
osmo-msc \
osmo-sgsn \
osmo-bsc-mgcp \
openggsn \
dnsmasq \
sysmocom-ggsn-config \
gprs-routing \
sqlite3 \
"
PREFERRED_PROVIDER_osmo-bsc-mgcp = "osmocom-3g"
PREFERRED_PROVIDER_osmo-bsc-nat = "osmocom-3g"
PREFERRED_PROVIDER_osmo-bsc-nitb = "osmocom-3g"
PREFERRED_PROVIDER_osmo-bsc-gbproxy = "osmocom-3g"
PREFERRED_PROVIDER_osmo-sgsn = "osmocom-3g"
#PREFERRED_VERSION_osmocom-3g =

View File

@ -4,23 +4,22 @@ LIC_FILES_CHKSUM = " \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
DEPENDS = "virtual/kernel"
ALLOW_EMPTY_${PN} = "1"
PR = "r25"
PR = "r23"
CALIB = ""
CALIB_sysmobts-v2 = "sysmobts-calib sysmobts-util"
UTIL = ""
UTIL_sysmobts-v2 = "sbts2050-util gpsd gps-utils gpsdate"
UTIL_sysmobts2100 = "gpsd gps-utils gpsdate lc15-sysdev-remap"
UTIL_oc2g = "gpsd gps-utils gpsdate oc2g-sysdev-remap"
UTIL_sysmobts-v2 = "sbts2050-util gpsd gps-utils"
# TODO: re-add femtobts-calib after it went through the API migration
RDEPENDS_${PN} = "\
osmo-bts \
osmo-bts-remote \
osmo-pcu \
lmsensors-scripts \
sysmobts-config \
${CALIB} \
${UTIL} \
"
RDEPENDS_${PN}_append_sysmobts-v2 = " osmo-bts-remote sysmobts-config"
PACKAGE_ARCH = "${MACHINE_ARCH}"

View File

@ -1,16 +0,0 @@
DESCRIPTION = "Task for sysmocom"
LICENSE = "MIT"
LIC_FILES_CHKSUM = " \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
DEPENDS = "virtual/kernel"
ALLOW_EMPTY_${PN} = "1"
PR = "r0"
RDEPENDS_${PN} = "\
osmo-bsc \
osmo-mgw \
osmo-msc \
osmo-hlr \
osmo-stp \
${@bb.utils.contains('DISTRO_FEATURES', 'iu', 'osmo-hnbgw', '', d)} \
"

View File

@ -4,7 +4,7 @@ LIC_FILES_CHKSUM = " \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
DEPENDS = "virtual/kernel"
ALLOW_EMPTY_${PN} = "1"
PR = "r5"
PR = "r4"
RDEPENDS_${PN} = "\
dropbear \
@ -14,6 +14,5 @@ RDEPENDS_${PN} = "\
gdb \
gdbserver \
net-tools \
n2n \
"

View File

@ -3,54 +3,17 @@ LICENSE = "MIT"
LIC_FILES_CHKSUM = " \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
ALLOW_EMPTY_${PN} = "1"
PR = "r25"
PR = "r21"
RDEPENDS_${PN} = "\
task-sysmocom-tools \
task-sysmocom-debug \
task-sysmocom-legacy \
task-gprscore \
packagegroup-sysmobts-sob \
sysmocom-openvpn-config \
minicom \
vlan \
patch \
procps \
psmisc \
ppp \
rsync \
sed \
usbutils \
openvpn \
iperf \
lcr \
cronie \
iproute2 \
i2c-tools \
cu \
python-pyserial \
python-pexpect \
bridge-utils \
pciutils \
nfacct \
logrotate \
dnsmasq \
ifupdown \
logrotate \
python-jsonrpclib \
python-enum \
iputils \
rtl8169-eeprom \
autossh \
perl \
libdbd-sqlite-perl \
libdbi-perl \
libjson-perl \
netcat-openbsd \
perf \
lksctp-tools \
osmo-sip-connector \
osmo-sysmon \
osmo-pcap \
nfs-utils \
"
minicom vlan patch procps psmisc \
ppp rsync sed usbutils openvpn iperf \
lcr cronie iproute2 i2c-tools cu \
python-pyserial python-pexpect bridge-utils \
pciutils nfacct logrotate dnsmasq ifupdown \
logrotate python-jsonrpclib python-enum iputils \
packagegroup-sysmobts-sob rtl8169-eeprom autossh \
perl libdbd-sqlite-perl libdbi-perl libjson-perl \
netcat-openbsd perf lksctp-tools task-gprscore"

View File

@ -1,12 +0,0 @@
DESCRIPTION = "Task for sysmocom"
LICENSE = "MIT"
LIC_FILES_CHKSUM = " \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
DEPENDS = "virtual/kernel"
ALLOW_EMPTY_${PN} = "1"
PR = "r1"
RDEPENDS_${PN} = "\
task-sysmocom-tools \
osmo-gbproxy \
"

View File

@ -3,7 +3,7 @@ LICENSE = "MIT"
LIC_FILES_CHKSUM = " \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
ALLOW_EMPTY_${PN} = "1"
PR = "r14"
PR = "r10"
RDEPENDS_${PN} = "\
lmsensors-scripts \
@ -14,11 +14,8 @@ RDEPENDS_${PN} = "\
ntpdate \
wget \
ca-cacert-rootcert \
ipaccess-utils \
abisip-find \
sysmocom-backup \
sysmocom-backup-default \
sysmocom-systemd \
sysmocom-configure \
osmo-config-merge \
"

View File

@ -2,7 +2,7 @@ require barebox.inc
SRCREV = "ce8849b03a40718fdaa9d7fc30312eeeb0fafcac"
SRC_URI = " \
git://gitea.sysmocom.de/sysmo-bts/barebox.git;protocol=https;branch=v2015.06 \
git://git.sysmocom.de/barebox.git;branch=v2015.06 \
file://defconfig \
"

View File

@ -4,7 +4,7 @@ RDEPENDS_${PN} += "${PN}-mlo"
SRCREV = "ec82959f054af3e4a27267290905cfd895f75331"
SRC_URI = " \
git://gitea.sysmocom.de/sysmo-bts/barebox.git;protocol=https;branch=v2015.06 \
git://git.sysmocom.de/barebox.git;branch=v2015.06 \
file://0001-OWHW-HACK-hard-code-the-bootstate-backend-node.patch \
file://defconfig \
"

View File

@ -1,8 +1,8 @@
require barebox.inc
SRCREV = "d87c27d7ab143d58f358df5722be2b9675103d2e"
SRCREV = "f2b03e21a869b8df30e428ac9408d7988d55279a"
SRC_URI = " \
git://gitea.sysmocom.de/sysmo-bts/barebox.git;protocol=https;branch=v2015.06 \
git://git.sysmocom.de/barebox.git;branch=v2015.06 \
file://defconfig \
"
@ -17,9 +17,6 @@ BAREBOX_BIN_SYMLINK ?= "barebox-${MACHINE}.bin"
# generated using echo -n 'bts-stop' | sha1sum
BAREBOX_PASSWORD = "5a7ef8875df28cb95a0f833906f94df8573bcc5d"
# Provide a replacement for calling whoami
export KBUILD_BUILD_USER="poky"
do_configure_append () {
mkdir -p ${WORKDIR}/env/nv
echo 5 > ${WORKDIR}/env/nv/login.timeout

View File

@ -2,7 +2,7 @@ require barebox.inc
SRCREV = "34a48171a699560d8a41d00d2c07ed37a79c00d8"
SRC_URI = " \
git://gitea.sysmocom.de/sysmo-bts/barebox.git;protocol=https;branch=v2015.06 \
git://git.sysmocom.de/barebox.git;branch=v2015.06 \
file://defconfig \
"

View File

@ -4,7 +4,7 @@ RDEPENDS_${PN} += "${PN}-mlo"
SRCREV = "34a48171a699560d8a41d00d2c07ed37a79c00d8"
SRC_URI = " \
git://gitea.sysmocom.de/sysmo-bts/barebox.git;protocol=https;branch=v2015.06 \
git://git.sysmocom.de/barebox.git;branch=v2015.06 \
file://defconfig \
"

View File

@ -1,4 +1,4 @@
THISDIR := "${@os.path.dirname(d.getVar('FILE', True))}"
THISDIR := "${@os.path.dirname(bb.data.getVar('FILE', d, True))}"
FILESPATH =. "${@base_set_filespath(["${THISDIR}/files"], d)}:"
PRINC="5"
PRINC="4"

View File

@ -0,0 +1,6 @@
rootfs / auto defaults 0 1
proc /proc proc defaults 0 0
devpts /dev/pts devpts mode=0620,gid=5 0 0
usbdevfs /proc/bus/usb usbdevfs noauto 0 0
tmpfs /run tmpfs mode=0755,nodev,nosuid,strictatime 0 0
tmpfs /var/volatile tmpfs defaults 0 0

View File

@ -3,7 +3,7 @@ HOMEPAGE = "http://sourceforge.net/projects/b-o-s-s-a/"
LICENSE = "GPLv3"
LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=d32239bcb673463ab874e80d47fae504"
SRCREV = "05bfcc39bc0453c3028b1161175b95a81af7a901"
SRC_URI = "git://git.code.sf.net/p/b-o-s-s-a/code;protocol=https"
SRC_URI = "git://git.code.sf.net/p/b-o-s-s-a/code"
DEPENDS = "readline"
PV = "v0.0+git${SRCPV}"

View File

@ -6,16 +6,16 @@ SRC_URI = "\
file://early-date \
file://early-date.service"
FILES_${PN} = "${systemd_system_unitdir} /sbin"
FILES_${PN} = "${systemd_unitdir}/system /sbin"
RDPEPENDS_${PN} = "systemd"
do_install() {
install -d ${D}/sbin
install -d ${D}${systemd_system_unitdir}/basic.target.wants
install -d ${D}${systemd_unitdir}/system/basic.target.wants
# Copy the service file and link it
install -m 0644 ${WORKDIR}/early-date.service ${D}${systemd_system_unitdir}
ln -sf ../early-date.service ${D}${systemd_system_unitdir}/basic.target.wants/
install -m 0644 ${WORKDIR}/early-date.service ${D}${systemd_unitdir}/system
ln -sf ../early-date.service ${D}${systemd_unitdir}/system/basic.target.wants/
# Hardcode to /sbin
# TODO: Set the date as of the build time..

View File

@ -0,0 +1,23 @@
# /etc/network/interfaces -- configuration file for ifup(8), ifdown(8)
# The loopback interface
auto lo
iface lo inet loopback
#eth0 is our gateway to the network.
auto eth0
iface eth0 inet dhcp
#eth1 will provide dhcp to clients
auto eth1
iface eth1 inet static
address 10.23.24.1
netmask 255.255.255.0
network 10.23.24.0
auto eth1:1
iface eth1:1 inet static
address 10.23.123.1
netmask 255.255.255.0
network 10.23.123.0

View File

@ -16,7 +16,7 @@ iface eth1 inet static
auto eth1:1
iface eth1:1 inet static
address 10.23.123.1
address 10.23.24.2
netmask 255.255.255.0
network 10.23.123.0
network 10.23.24.0

View File

@ -0,0 +1,22 @@
# /etc/network/interfaces -- configuration file for ifup(8), ifdown(8)
# The loopback interface
auto lo
iface lo inet loopback
#eth0 is our gateway to the network. ifplugd will run ifup/ifdown for us
iface eth0 inet dhcp
#eth1 will provide dhcp to clients
auto eth1
iface eth1 inet static
address 10.23.24.1
netmask 255.255.255.0
network 10.23.24.0
auto eth1:1
iface eth1:1 inet static
address 10.23.24.2
netmask 255.255.255.0
network 10.23.24.0

View File

@ -1,2 +1,2 @@
SYSMOCOM := "${@os.path.dirname(d.getVar('FILE', True))}"
SYSMOCOM := "${@os.path.dirname(bb.data.getVar('FILE', d, True))}"
FILESEXTRAPATHS_prepend := "${SYSMOCOM}/init-ifupdown-${PV}:${SYSMOCOM}/init-ifupdown-master:"

View File

@ -1,4 +1,4 @@
SYSMOCOM := "${@os.path.dirname(d.getVar('FILE', True))}"
SYSMOCOM := "${@os.path.dirname(bb.data.getVar('FILE', d, True))}"
FILESEXTRAPATHS_prepend := "${SYSMOCOM}/init-ifupdown-${PV}:${SYSMOCOM}/init-ifupdown:"
PRINC = "13"

View File

@ -4,7 +4,7 @@ LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://LICENSE;md5=e6868d1ce8f058ecc5658ecebb086636"
SRCREV = "1103417819fe855d8d0d3e6a277870679ad01bd2"
SRC_URI = "git://github.com/mlaurijsse/linux-mpu9150;protocol=https"
SRC_URI = "git://github.com/mlaurijsse/linux-mpu9150.git"
PV = "v0.0+git${SRCPV}"
PR = "r1a"

File diff suppressed because it is too large Load Diff

View File

@ -1,33 +0,0 @@
From 83bf55510af35cc9e0872bc25ad5628dfae2f4a8 Mon Sep 17 00:00:00 2001
From: Pau Espin Pedrol <pespin@sysmocom.de>
Date: Mon, 7 Aug 2017 10:27:36 +0200
Subject: [PATCH] litecell15.dts: Set default let trigger to none
---
arch/arm/boot/dts/litecell15.dts | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/arm/boot/dts/litecell15.dts b/arch/arm/boot/dts/litecell15.dts
index a0c9db31eaf4..a2a08d64f313 100644
--- a/arch/arm/boot/dts/litecell15.dts
+++ b/arch/arm/boot/dts/litecell15.dts
@@ -318,14 +318,14 @@
led@0 {
label = "usr0";
gpios = <&gpio7 31 GPIO_ACTIVE_HIGH>;
- linux,default-trigger = "heartbeat";
+ linux,default-trigger = "none";
default-state = "on";
};
led@1 {
label = "usr1";
gpios = <&gpio7 30 GPIO_ACTIVE_HIGH>;
- linux,default-trigger = "cpu0";
+ linux,default-trigger = "none";
default-state = "off";
};
--
2.13.4

File diff suppressed because it is too large Load Diff

View File

@ -1,79 +0,0 @@
SECTION = "kernel"
DESCRIPTION = "Linux kernel for the LiteCell 1.5"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
require recipes-kernel/linux/linux-yocto.inc
KERNEL_IMAGETYPE = "zImage"
COMPATIBLE_MACHINE = "(litecell15|sysmobts2100)"
RDEPENDS_kernel-base += "kernel-devicetree"
KERNEL_DEVICETREE_litecell15 = "litecell15.dtb"
KERNEL_DEVICETREE_sysmobts2100 = "litecell15.dtb"
RDEPENDS_kernel-devicetree += "update-alternatives-opkg"
LINUX_VERSION = "${PV}"
LINUX_VERSION_EXTENSION = "-lc15"
RDEPENDS_kernel-image += "update-alternatives-opkg"
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}-${PV}:"
S = "${WORKDIR}/git"
NRW_LC15_MIRROR ??= "gitlab.com/nrw_litecell15"
inherit gitver-pkg gitver-repo
REPODIR = "${THISDIR}"
REPOFILE = "linux-litecell15_4.4.32.bb"
PR := "r${REPOGITFN}"
REPODIR = "${THISDIR}/files"
REPOFILE = "."
PR := "${PR}.${REPOGITFN}"
PV = "4.4.32.33+git${SRCPV}"
PKGV = "${PKGGITV}"
DEV_BRANCH = "${@ 'nrw/litecell15-next' if d.getVar('NRW_BSP_DEVEL', False) == "next" else 'nrw/litecell15'}"
DEV_SRCREV = "${AUTOREV}"
DEV_SRCURI := "git://${NRW_LC15_MIRROR}/processor-sdk-linux.git;protocol=https;branch=${DEV_BRANCH}"
REL_BRANCH = "nrw/litecell15"
REL_SRCREV = "a54d64a4be25d87032a8600b97b271f255587844"
REL_SRCURI := "git://${NRW_LC15_MIRROR}/processor-sdk-linux.git;protocol=https;branch=${REL_BRANCH}"
BRANCH = "${@ '${DEV_BRANCH}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_BRANCH}'}"
SRCREV = "${@ '${DEV_SRCREV}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_SRCREV}'}"
SRC_URI = "${@ '${DEV_SRCURI}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_SRCURI}'}"
addtask showversion after do_compile before do_install
do_showversion() {
bbplain "${PN}: ${PKGGITV} => ${BRANCH}:${PKGGITH}"
}
do_configure_prepend() {
sed -i -e 's/EXTRAVERSION =.*/EXTRAVERSION = .${PKGGITN}-lc15/g' ${S}/Makefile
}
SRC_URI += "file://defconfig \
file://0001-litecell15.dts-Set-default-let-trigger-to-none.patch"
# autoload defaults
module_autoload_nrw_clkerr = "nrw-clkerr"
module_autoload_nrw_vswr = "nrw-vswr"
module_autoload_rpmsg_proto = "rpmsg-proto"
module_autoload_rpmsg_rpc = "rpmsg-rpc"
module_autoload_iio_hwmon = "iio-hwmon"
module_autoload_ntc_thermistor = "ntc-thermistor"
KERNEL_MODULE_PROBECONF_append = "adl5501 configfs fpgadl iio_hwmon industrialio industrialio-buffer-cb input-polldev mcp47x6 nrw_clkerr nrw_vswr ntc_thermistor omap_remoteproc rpmsg_proto rpmsg_rpc xilinx-xadc"
KERNEL_MODULE_AUTOLOAD_append = "adl5501 configfs fpgadl iio_hwmon industrialio industrialio-buffer-cb input-polldev mcp47x6 nrw_clkerr nrw_vswr ntc_thermistor omap_remoteproc rpmsg_proto rpmsg_rpc xilinx-xadc"
RDEPENDS_kernel-module-omap-remoteproc += "lc15-firmware"
RDEPENDS_kernel-module-fpgadl += "lc15-firmware"

File diff suppressed because it is too large Load Diff

View File

@ -1 +0,0 @@
use-kernel-config=oc2g_defconfig

View File

@ -1,63 +0,0 @@
SECTION = "kernel"
DESCRIPTION = "Linux kernel for the OC-2G"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
require recipes-kernel/linux/linux-yocto.inc
KERNEL_IMAGETYPE = "zImage"
COMPATIBLE_MACHINE = "oc2g"
RDEPENDS_kernel-base += "kernel-devicetree"
KERNEL_DEVICETREE_oc2g = "oc2g.dtb oc2gplus.dtb"
RDEPENDS_kernel-devicetree += "update-alternatives-opkg"
LINUX_VERSION = "${PV}"
LINUX_VERSION_EXTENSION = "-oc2g"
RDEPENDS_kernel-image += "update-alternatives-opkg"
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}-${PV}:"
S = "${WORKDIR}/git"
NRW_OC2G_MIRROR ??= "git@gitlab.com/nrw_oc2g"
inherit gitver-pkg gitver-repo
REPODIR = "${THISDIR}"
REPOFILE = "linux-oc2g_4.4.32.bb"
PR := "r${REPOGITFN}"
REPODIR = "${THISDIR}/linux-oc2g-4.4.32"
REPOFILE = ""
PR := "${PR}.${REPOGITFN}"
PV = "4.4.32+git${SRCPV}"
PKGV = "${PKGGITV}"
DEV_BRANCH = "${@ 'nrw/oc2g-next' if d.getVar('NRW_BSP_DEVEL', False) == "next" else 'nrw/oc2g'}"
DEV_SRCREV = "${AUTOREV}"
DEV_SRCURI := "git://${NRW_OC2G_MIRROR}/processor-sdk-linux.git;protocol=ssh;branch=${DEV_BRANCH}"
REL_BRANCH = "nrw/oc2g"
REL_SRCREV = "5a36597a52fe4fc24fc0d9f8a02e3c3ff30e6aff"
REL_SRCURI := "git://${NRW_OC2G_MIRROR}/processor-sdk-linux.git;protocol=ssh;branch=${REL_BRANCH}"
BRANCH = "${@ '${DEV_BRANCH}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_BRANCH}'}"
SRCREV = "${@ '${DEV_SRCREV}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_SRCREV}'}"
SRC_URI = "${@ '${DEV_SRCURI}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_SRCURI}'}"
addtask showversion after do_compile before do_install
do_showversion() {
bbplain "${PN}: ${PKGGITV} => ${BRANCH}:${PKGGITH}"
}
do_configure_prepend() {
sed -i -e 's/EXTRAVERSION =.*/EXTRAVERSION = .${PKGGITN}-oc2g/g' ${S}/Makefile
}
SRC_URI += "file://defconfig"

View File

@ -18,12 +18,12 @@ SRCREV = "60c9ebbd1a683e8691223042a12958c5dc661feb"
PR = "r43"
PV = "${LINUX_VERSION}+git${SRCPV}"
SRC_URI = "git://gitea.sysmocom.de/sysmo-bts/linux.git;protocol=https;branch=linux-3.10.84 \
SRC_URI = "git://git.sysmocom.de/sysmo-bts/linux.git;protocol=git;branch=linux-3.10.84 \
file://defconfig"
S = "${WORKDIR}/git"
COMPATIBLE_MACHINE = "(sysmobts-v2|sysmocom-bsc)"
COMPATIBLE_MACHINE = "(sysmobts-v2|sysmocom-bsc|sysmonitb-ip)"
EXTRA_OEMAKE += "KALLSYMS_EXTRA_PASS=1"
require linux-tools.inc

View File

@ -14,7 +14,7 @@ PR = "r43"
PV = "${LINUX_VERSION}+git${SRCPV}"
SRC_URI = " \
git://gitea.sysmocom.de/sysmo-bts/linux.git;protocol=https;branch=${BRANCH} \
git://git.sysmocom.de/sysmo-bts/linux.git;protocol=git;branch=${BRANCH} \
file://mISDN_loop.patch;patch=1 \
file://defconfig"
S = "${WORKDIR}/git"

View File

@ -1,51 +0,0 @@
inherit kernel
require linux-sysmocom.inc
DEPENDS += "bc-native"
# ATTENTION: Update linux-backports PR on version change. In Dora the
# reverse dependency tracking for the kernel doesn't appear to work. So
# please bump the PR on version changes!
# at versions changes do not forget to update conf/machine/include/sysmobts.inc too
LINUX_VERSION ?= "4.9.59"
LINUX_VERSION_EXTENSION ?= "-sysmocom-${LINUX_KERNEL_TYPE}"
# Overrides for the sysmocom bts v2
BTS_FIRMWARE_NAME_sysmobts-v2 = "sysmobts-v2"
SRCREV = "27afed74546b4fa5546aeea26128eae2dcdc7c1f"
PR = "r6"
PV = "${LINUX_VERSION}+git${SRCPV}"
SRC_URI = "git://gitea.sysmocom.de/sysmo-bts/linux.git;protocol=https;branch=tracking/linux-stable-4.9 \
file://defconfig"
S = "${WORKDIR}/git"
COMPATIBLE_MACHINE = "(sysmobts-v2|sysmocom-bsc)"
EXTRA_OEMAKE += "KALLSYMS_EXTRA_PASS=1"
require linux-tools.inc
do_configure() {
install -m 0644 ${WORKDIR}/defconfig ${B}/.config
oe_runmake -C ${S} O=${B} oldconfig
}
# autoload defaults (alphabetically sorted)
KERNEL_MODULE_PROBECONF += "davinci_mmc dspdl_dm644x fpgadl_par leds-gpio mmc_block msgqueue rtfifo"
KERNEL_MODULE_AUTOLOAD += "davinci_mmc dspdl_dm644x fpgadl_par leds-gpio mmc_block msgqueue rtfifo"
# module configs (alphabetically sorted)
module_conf_dspdl_dm644x = "options dspdl_dm644x fw_name=${BTS_FIRMWARE_NAME}.out debug=0"
module_conf_fpgadl_par = "options fpgadl_par fw_name=${BTS_FIRMWARE_NAME}.bit"
module_conf_msgqueue = "options msgqueue fw_name=${BTS_FIRMWARE_NAME}.out"
module_conf_rtfifo = "options rtfifo fw_name=${BTS_FIRMWARE_NAME}.out"
RDEPENDS_kernel-module-dspdl-dm644x += "sysmobts-firmware"
RDEPENDS_kernel-module-fpgadl-par += "sysmobts-firmware"
RDEPENDS_kernel-module-msgqueue += "sysmobts-firmware"
RDEPENDS_kernel-module-rtfifo += "sysmobts-firmware"
DEFAULT_PREFERENCE = "-1"

View File

@ -1,4 +1,4 @@
SYSMOCOM := "${@os.path.dirname(d.getVar('FILE', True))}"
SYSMOCOM := "${@os.path.dirname(bb.data.getVar('FILE', d, True))}"
FILESEXTRAPATHS_prepend := "${SYSMOCOM}/${PN}-${PV}:${SYSMOCOM}/${PN}:"
PRINC = "21"

View File

@ -94,10 +94,10 @@ do_install_append() {
install -d ${D}/${sysconfdir}/network/if-up.d
ln -s ${bindir}/ntpdate-sync ${D}/${sysconfdir}/network/if-up.d
install -d ${D}${systemd_system_unitdir}
install -m 0644 ${WORKDIR}/ntpdate.service ${D}${systemd_system_unitdir}/
install -m 0644 ${WORKDIR}/ntpd.service ${D}${systemd_system_unitdir}/
install -m 0644 ${WORKDIR}/sntp.service ${D}${systemd_system_unitdir}/
install -d ${D}${systemd_unitdir}/system
install -m 0644 ${WORKDIR}/ntpdate.service ${D}${systemd_unitdir}/system/
install -m 0644 ${WORKDIR}/ntpd.service ${D}${systemd_unitdir}/system/
install -m 0644 ${WORKDIR}/sntp.service ${D}${systemd_unitdir}/system/
install -d ${D}${systemd_unitdir}/ntp-units.d
install -m 0644 ${WORKDIR}/ntpd.list ${D}${systemd_unitdir}/ntp-units.d/60-ntpd.list
@ -145,13 +145,13 @@ FILES_ntpdate = "${sbindir}/ntpdate \
${sysconfdir}/network/if-up.d/ntpdate-sync \
${bindir}/ntpdate-sync \
${sysconfdir}/default/ntpdate \
${systemd_system_unitdir}/ntpdate.service \
${systemd_unitdir}/system/ntpdate.service \
${bindir}/ntpdate-cron \
${sysconfdir}/cron.d/ntpdate \
"
FILES_sntp = "${sbindir}/sntp \
${sysconfdir}/default/sntp \
${systemd_system_unitdir}/sntp.service \
${systemd_unitdir}/system/sntp.service \
"
CONFFILES_${PN} = "${sysconfdir}/ntp.conf"

View File

@ -4,8 +4,8 @@ LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
DEPENDS = "pciutils"
SRCREV = "2052514dc99575140af40b25e41c438c98eb9b48"
SRC_URI = "git://gitea.sysmocom.de/sysmocom/rtl8168-eeprom.git;protocol=https;branch=master"
SRCREV = "e62e515ce314599e48b268dac69d2f16a504264c"
SRC_URI = "git://git.sysmocom.de/rtl8168-eeprom;protocol=git;branch=master"
PV = "v0.0.1+git${SRCPV}"
PR = "r0"

View File

@ -25,9 +25,9 @@ do_install() {
install -m 0755 ${WORKDIR}/usb2514 ${D}${bindir}/
install -m 0755 ${WORKDIR}/gpio_usb2514 ${D}${bindir}/
install -m 0755 ${WORKDIR}/odu-gpiotool ${D}${bindir}/
install -d ${D}${systemd_system_unitdir}/multi-user.target.wants/
install -m 0644 /${WORKDIR}/usb2514.service ${D}${systemd_system_unitdir}/
ln -sf ../usb2514.service ${D}${systemd_system_unitdir}/multi-user.target.wants/
install -d ${D}${systemd_unitdir}/system/multi-user.target.wants/
install -m 0644 /${WORKDIR}/usb2514.service ${D}${systemd_unitdir}/system/
ln -sf ../usb2514.service ${D}${systemd_unitdir}/system/multi-user.target.wants/
}
FILES_${PN} += "${systemd_unitdir}"

View File

@ -1,183 +0,0 @@
From b33c1d7ab8881cf9e68ef9692a8c5079f1b53db7 Mon Sep 17 00:00:00 2001
From: Pau Espin Pedrol <pespin@sysmocom.de>
Date: Fri, 28 Jul 2017 12:12:05 +0200
Subject: [PATCH] Add sysmocom specific tweaks
---
common/autoboot.c | 2 +-
include/configs/litecell15.h | 91 +++++++++++++++++++++++++++++++++------
include/configs/ti_armv7_common.h | 2 +-
3 files changed, 80 insertions(+), 15 deletions(-)
diff --git a/common/autoboot.c b/common/autoboot.c
index c4e21452df..369f2c55a1 100644
--- a/common/autoboot.c
+++ b/common/autoboot.c
@@ -352,7 +352,7 @@ const char *bootdelay_process(void)
s = getenv("bootcmd");
process_fdt_options(gd->fdt_blob);
- stored_bootdelay = bootdelay;
+ stored_bootdelay = CONFIG_BOOTDELAY;
return s;
}
diff --git a/include/configs/litecell15.h b/include/configs/litecell15.h
index bb6629a3ce..6d030bedcb 100644
--- a/include/configs/litecell15.h
+++ b/include/configs/litecell15.h
@@ -81,13 +81,19 @@
#define CONFIG_SYS_NS16550_COM9 UART9_BASE /* GPS Port B */
#define CONFIG_BAUDRATE 115200
-/* These 3 lines keep from inadvertly stopping u-boot by any serial glitch, at least a specific character must be pressed */
+#define CONFIG_SYS_AUTOLOAD "n" /* No autoload */
+/* These lines keep from inadvertly stopping u-boot by any serial glitch, at least a specific character must be pressed */
#define CONFIG_AUTOBOOT_KEYED
-#define CONFIG_AUTOBOOT_DELAY_STR "c"
-#define CONFIG_AUTOBOOT_PROMPT "Autoboot in %d seconds, press <" CONFIG_AUTOBOOT_DELAY_STR "> to abort...\n",bootdelay
+#define CONFIG_AUTOBOOT_DELAY_STR "bts-delay"
+#define CONFIG_AUTOBOOT_STOP_STR "bts-stop"
+#define CONFIG_BOOTDELAY 8 /* -1 disables auto-boot */
+#define CONFIG_AUTOBOOT_PROMPT "Autoboot in %d seconds, press <" CONFIG_AUTOBOOT_STOP_STR "> to abort...\n"
#define CONFIG_SYS_OMAP_ABE_SYSCK
+/* Write to ext4 partitions */
+#define CONFIG_CMD_EXT4_WRITE
+
/* CONFIG_HW_WATCHDOG when activated implies a lot of boot mechanisms to allow wdt reboot, boot counting, reset event detection (available for kernel info also), */
/* multiple u-boot qspi images alternance, hardware watchdog ticking, failsafe boot alternative after a specific boot count limit exausted, */
/* autoboot failing protection, etc. */
@@ -99,9 +105,9 @@
/*#define CONFIG_WDT_LOCK*/
/* Comment the following 3 definitions to allow to stay at u-boot command prompt forever when autoboot was manually stopped (defeat WDT safe boot protection in that case) */
-#define CONFIG_BOOT_RETRY_TIME 600
-#define CONFIG_BOOT_RETRY_MIN 60
-#define CONFIG_RESET_TO_RETRY
+/* #define CONFIG_BOOT_RETRY_TIME 600 */
+/* #define CONFIG_BOOT_RETRY_MIN 60 */
+/* #define CONFIG_RESET_TO_RETRY */
/* WDT by default 128 secs (2<<CONFIG_WDT_INIT, max 128secs), theorically do not use lower than 1 (2 secs) to match CONFIG_MIN_WDT_TICK_TIME */
/* WARNING: actual wdt expiration min value is (2<<CONFIG_WDT_INIT) secs, but it could be as long as 2 * (2<<CONFIG_WDT_INIT) secs */
@@ -204,21 +210,75 @@
"sf erase 0x120000 0x80000 && " \
"sf write 0x83000000 0x120000 0x80000 \0"
+#define ERASE_UBOOT_ENV \
+ "erase_uboot_env=echo Erasing saved u-boot env...; " \
+ "sf probe 0 && " \
+ "sf erase 0x100000 0x10000 && " \
+ "sf erase 0x110000 0x10000;\0"
+
+#define TFTP_FLASH_MLO \
+ "tftp_flash_mlo=echo Loading MLO from network and flashing it....; " \
+ "setenv prev_bootfile ${bootfile}; " \
+ "setenv autoload no; " \
+ "dhcp && " \
+ "setenv filesize 0 && " \
+ "if tftp ${loadaddr} MLO; then " \
+ "sf probe 0 && " \
+ "sf erase 0x00000 0x20000 && " \
+ "sf write ${loadaddr} 0x00000 0x20000 && " \
+ "sf erase 0x20000 0x20000 && " \
+ "sf write ${loadaddr} 0x20000 0x20000 && " \
+ "sf erase 0x40000 0x20000 && " \
+ "sf write ${loadaddr} 0x40000 0x20000 && " \
+ "sf erase 0x60000 0x20000 && " \
+ "sf write ${loadaddr} 0x60000 0x20000; " \
+ "fi; " \
+ "setenv bootfile ${prev_bootfile};\0"
+
+#define TFTP_FLASH_UBOOT \
+ "tftp_flash_uboot=echo Loading u-boot.img from network and flashing it....; " \
+ "setenv prev_bootfile ${bootfile}; " \
+ "setenv autoload no; " \
+ "dhcp && " \
+ "setenv filesize 0 && " \
+ "if tftp ${loadaddr} u-boot.img; then " \
+ "sf probe 0 && " \
+ "sf erase 0x80000 0x80000 && " \
+ "sf write ${loadaddr} 0x80000 0x80000 && " \
+ "sf erase 0x120000 0x80000 && " \
+ "sf write ${loadaddr} 0x120000 0x80000; " \
+ "fi; " \
+ "setenv bootfile ${prev_bootfile};\0"
+
+#define TFTP_FLASH_ROOTFS \
+ "tftp_flash_rootfs=echo Loading rootfs from network and flashing to mmc...; " \
+ "setenv prev_bootfile ${bootfile}; " \
+ "setenv autoload no; " \
+ "dhcp && " \
+ "setenv filesize 0 && " \
+ "if tftp ${loadaddr} rootfs-sysmobts2100.img; then " \
+ "setexpr fs ${filesize} + 0x1ff; " \
+ "setexpr fs ${fs} / 0x200; " \
+ "mmc write ${fileaddr} 0x0001f000 ${fs} && " \
+ "mmc write ${fileaddr} 0x003ef800 ${fs}; " \
+ "fi; " \
+ "setenv bootfile ${prev_bootfile};\0"
+
#include <configs/ti_omap5_common.h>
/* Internal memory boot */
#ifdef CONFIG_SPL_INTMEM_BOOT
-#undef CONFIG_SPL_STACK
+#undef CONFIG_SPL_STACK
#undef CONFIG_SPL_BSS_START_ADDR
#undef CONFIG_SPL_BSS_MAX_SIZE
#undef CONFIG_SYS_SPL_MALLOC_START
#undef CONFIG_SYS_SPL_MALLOC_SIZE
-#define CONFIG_SPL_STACK 0x40400000
-#define CONFIG_SPL_BSS_START_ADDR 0x40500000
-#define CONFIG_SPL_BSS_MAX_SIZE 0x00080000
-#define CONFIG_SYS_SPL_MALLOC_START 0x40580000
-#define CONFIG_SYS_SPL_MALLOC_SIZE 0x00080000
+#define CONFIG_SPL_STACK 0x40400000
+#define CONFIG_SPL_BSS_START_ADDR 0x40500000
+#define CONFIG_SPL_BSS_MAX_SIZE 0x00080000
+#define CONFIG_SYS_SPL_MALLOC_START 0x40580000
+#define CONFIG_SYS_SPL_MALLOC_SIZE 0x00080000
#endif
/* Overwrite extra settings */
@@ -226,6 +286,7 @@
#define CONFIG_EXTRA_ENV_SETTINGS \
DEFAULT_LINUX_BOOT_ENV \
"console=" CONSOLEDEV ",115200n8\0" \
+ "bootdelay=" __stringify(CONFIG_BOOTDELAY) "\0" \
"fdtfile=litecell15.dtb\0" \
"bootdir=/boot\0" \
"bootfile=zImage\0" \
@@ -292,7 +353,11 @@
MYBOOT_LIMIT \
NANDARGS \
FLASH_UBOOT_LINUXFS \
- FLASH_UBOOT2
+ FLASH_UBOOT2 \
+ ERASE_UBOOT_ENV \
+ TFTP_FLASH_MLO \
+ TFTP_FLASH_UBOOT \
+ TFTP_FLASH_ROOTFS
#undef CONFIG_BOOTCOMMAND
#define CONFIG_BOOTCOMMAND \
diff --git a/include/configs/ti_armv7_common.h b/include/configs/ti_armv7_common.h
index 6011cf8c65..9680246feb 100644
--- a/include/configs/ti_armv7_common.h
+++ b/include/configs/ti_armv7_common.h
@@ -93,7 +93,7 @@
/*
* Default to a quick boot delay.
*/
-#define CONFIG_BOOTDELAY 1
+/* #define CONFIG_BOOTDELAY 1 */
/*
* DDR information. If the CONFIG_NR_DRAM_BANKS is not defined,
--
2.13.3

View File

@ -1,12 +0,0 @@
diff --git a/tools/env/fw_env.c b/tools/env/fw_env.c
index daa02a7..eff638a 100644
--- a/tools/env/fw_env.c
+++ b/tools/env/fw_env.c
@@ -17,6 +17,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
+#include <inttypes.h>
#include <string.h>
#include <sys/types.h>
#include <sys/ioctl.h>

View File

@ -1,91 +0,0 @@
From 07373b2e477ae61f9f6a0e2eff41be3276d92923 Mon Sep 17 00:00:00 2001
From: yocto <yocto@yocto.org>
Date: Thu, 2 Jun 2016 03:21:51 -0500
Subject: [PATCH] fix build error under gcc6
Fix the following error:
| ../include/linux/compiler-gcc.h:114:30: fatal error: linux/compiler-gcc6.h: No such file or directory
| #include gcc_header(__GNUC__)
Signed-off-by: Zhenhua Luo <zhenhua.luo@nxp.com>
Upstream-Status: Pending
---
include/linux/compiler-gcc6.h | 65 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 65 insertions(+)
create mode 100644 include/linux/compiler-gcc6.h
diff --git a/include/linux/compiler-gcc6.h b/include/linux/compiler-gcc6.h
new file mode 100644
index 0000000..c8c5659
--- /dev/null
+++ b/include/linux/compiler-gcc6.h
@@ -0,0 +1,65 @@
+#ifndef __LINUX_COMPILER_H
+#error "Please don't include <linux/compiler-gcc5.h> directly, include <linux/compiler.h> instead."
+#endif
+
+#define __used __attribute__((__used__))
+#define __must_check __attribute__((warn_unused_result))
+#define __compiler_offsetof(a, b) __builtin_offsetof(a, b)
+
+/* Mark functions as cold. gcc will assume any path leading to a call
+ to them will be unlikely. This means a lot of manual unlikely()s
+ are unnecessary now for any paths leading to the usual suspects
+ like BUG(), printk(), panic() etc. [but let's keep them for now for
+ older compilers]
+
+ Early snapshots of gcc 4.3 don't support this and we can't detect this
+ in the preprocessor, but we can live with this because they're unreleased.
+ Maketime probing would be overkill here.
+
+ gcc also has a __attribute__((__hot__)) to move hot functions into
+ a special section, but I don't see any sense in this right now in
+ the kernel context */
+#define __cold __attribute__((__cold__))
+
+#define __UNIQUE_ID(prefix) __PASTE(__PASTE(__UNIQUE_ID_, prefix), __COUNTER__)
+
+#ifndef __CHECKER__
+# define __compiletime_warning(message) __attribute__((warning(message)))
+# define __compiletime_error(message) __attribute__((error(message)))
+#endif /* __CHECKER__ */
+
+/*
+ * Mark a position in code as unreachable. This can be used to
+ * suppress control flow warnings after asm blocks that transfer
+ * control elsewhere.
+ *
+ * Early snapshots of gcc 4.5 don't support this and we can't detect
+ * this in the preprocessor, but we can live with this because they're
+ * unreleased. Really, we need to have autoconf for the kernel.
+ */
+#define unreachable() __builtin_unreachable()
+
+/* Mark a function definition as prohibited from being cloned. */
+#define __noclone __attribute__((__noclone__))
+
+/*
+ * Tell the optimizer that something else uses this function or variable.
+ */
+#define __visible __attribute__((externally_visible))
+
+/*
+ * GCC 'asm goto' miscompiles certain code sequences:
+ *
+ * http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58670
+ *
+ * Work it around via a compiler barrier quirk suggested by Jakub Jelinek.
+ *
+ * (asm goto is automatically volatile - the naming reflects this.)
+ */
+#define asm_volatile_goto(x...) do { asm goto(x); asm (""); } while (0)
+
+#ifdef CONFIG_ARCH_USE_BUILTIN_BSWAP
+#define __HAVE_BUILTIN_BSWAP32__
+#define __HAVE_BUILTIN_BSWAP64__
+#define __HAVE_BUILTIN_BSWAP16__
+#endif /* CONFIG_ARCH_USE_BUILTIN_BSWAP */
--
2.5.0

View File

@ -1,45 +0,0 @@
require u-boot-litecell15-${PV}.inc
SUMMARY = "U-Boot bootloader fw_printenv/setenv utilities"
SECTION = "bootloader"
DEPENDS = "mtd-utils u-boot"
PROVIDES_litecell15 = "u-boot-fw-utils"
S = "${WORKDIR}/git"
REPODIR = "${THISDIR}"
REPOFILE = "u-boot-fw-utils_2015.07.bb"
PR := "${INC_PR}.${REPOGITFN}"
INSANE_SKIP_${PN} = "already-stripped"
EXTRA_OEMAKE_class-target = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
EXTRA_OEMAKE_class-cross = 'ARCH=${TARGET_ARCH} CC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
inherit uboot-config
do_compile () {
oe_runmake ${UBOOT_MACHINE}
oe_runmake env
}
do_install () {
install -d ${D}${base_sbindir}
install -d ${D}${sysconfdir}
install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_printenv
install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_setenv
install -m 0644 ${S}/tools/env/fw_env.config ${D}${sysconfdir}/fw_env.config
}
do_install_class-cross () {
install -d ${D}${bindir_cross}
install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_printenv
install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_setenv
}
SYSROOT_PREPROCESS_FUNCS_class-cross = "uboot_fw_utils_cross"
uboot_fw_utils_cross() {
sysroot_stage_dir ${D}${bindir_cross} ${SYSROOT_DESTDIR}${bindir_cross}
}
PACKAGE_ARCH = "${MACHINE_ARCH}"
BBCLASSEXTEND = "cross"

View File

@ -1,42 +0,0 @@
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://Licenses/README;md5=0507cd7da8e7ad6d6701926ec9b84c95"
NRW_LC15_MIRROR ??= "gitlab.com/nrw_litecell15"
inherit gitver-pkg gitver-repo
# Should match the one in u-boot.inc
INC_PR ??= "r1"
REPODIR = "${THISDIR}"
REPOFILE = "u-boot-litecell15-2015.07.inc"
INC_PR := "${INC_PR}.${REPOGITFN}"
PV = "2015.07+git${SRCPV}"
PKGV = "${PKGGITV}"
DEV_BRANCH = "${@ 'nrw/litecell15-next' if d.getVar('NRW_BSP_DEVEL', False) == "next" else 'nrw/litecell15'}"
DEV_SRCREV = "${AUTOREV}"
DEV_SRCURI := "git://${NRW_LC15_MIRROR}/u-boot.git;protocol=https;branch=${DEV_BRANCH}"
REL_BRANCH = "nrw/litecell15"
REL_SRCREV = "e2b1ddd84d72d8c57815265860ae58f6b170551c"
REL_SRCURI := "git://${NRW_LC15_MIRROR}/u-boot.git;protocol=https;branch=${REL_BRANCH}"
BRANCH = "${@ '${DEV_BRANCH}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_BRANCH}'}"
SRCREV = "${@ '${DEV_SRCREV}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_SRCREV}'}"
SRC_URI = "${@ '${DEV_SRCURI}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_SRCURI}'}"
SRC_URI += "file://0001-fw_env-missing-header.patch"
SRC_URI += "file://fix-build-error-under-gcc6.patch"
SRC_URI += "file://0001-Add-sysmocom-specific-tweaks.patch"
addtask showversion after do_compile before do_install
do_showversion() {
bbplain "${PN}: ${PKGGITV} => ${BRANCH}:${PKGGITH}"
}
do_configure_prepend() {
sed -i -e 's/SUBLEVEL =.*/SUBLEVEL = ${PKGGITN}/g' ${S}/Makefile
sed -i -e 's/EXTRAVERSION =.*/EXTRAVERSION = -lc15/g' ${S}/Makefile
}

View File

@ -1,22 +0,0 @@
require u-boot.inc
require ${PN}-${PV}.inc
PROVIDES_litecell15 = " \
u-boot \
virtual/bootloader \
"
DESCRIPTION = "u-boot bootloader for LC15 / sysmoBTS 2100"
REPODIR = "${THISDIR}"
REPOFILE = "u-boot-litecell15_2015.07.bb"
PR := "${INC_PR}.${REPOGITFN}"
# set theses two variables to 1 to specify u-boot update requierement when the rootfs is updated
export MLO_UPGRADE = "1"
export UBOOT_UPGRADE = "1"
SPL_BINARY = "MLO"
SPL_UART_BINARY = "u-boot-spl.bin"

View File

@ -1,41 +0,0 @@
LICENSE = "GPLv2+"
LIC_FILES_CHKSUM = "file://Licenses/README;md5=0507cd7da8e7ad6d6701926ec9b84c95"
NRW_OC2G_MIRROR ??= "git@gitlab.com/nrw_oc2g"
inherit gitver-pkg gitver-repo
# Should match the one in u-boot.inc
INC_PR ??= "r1"
REPODIR = "${THISDIR}"
REPOFILE = "u-boot-oc2g-2015.07.inc"
INC_PR := "${INC_PR}.${REPOGITFN}"
PV = "2015.07+git${SRCPV}"
PKGV = "${PKGGITV}"
DEV_BRANCH = "${@ 'nrw/oc2g-next' if d.getVar('NRW_BSP_DEVEL', False) == "next" else 'nrw/oc2g'}"
DEV_SRCREV = "${AUTOREV}"
DEV_SRCURI := "git://${NRW_OC2G_MIRROR}/u-boot.git;protocol=ssh;branch=${DEV_BRANCH}"
REL_BRANCH = "nrw/oc2g"
REL_SRCREV = "f8da7e9b975e1806b6cb896600b6a67c5fcf4afd"
REL_SRCURI := "git://${NRW_OC2G_MIRROR}/u-boot.git;protocol=ssh;branch=${REL_BRANCH}"
BRANCH = "${@ '${DEV_BRANCH}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_BRANCH}'}"
SRCREV = "${@ '${DEV_SRCREV}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_SRCREV}'}"
SRC_URI = "${@ '${DEV_SRCURI}' if d.getVar('NRW_BSP_DEVEL', False) else '${REL_SRCURI}'}"
SRC_URI += "file://0001-fw_env-missing-header.patch"
SRC_URI += "file://fix-build-error-under-gcc6.patch"
addtask showversion after do_compile before do_install
do_showversion() {
bbplain "${PN}: ${PKGGITV} => ${BRANCH}:${PKGGITH}"
}
do_configure_prepend() {
sed -i -e 's/SUBLEVEL =.*/SUBLEVEL = ${PKGGITN}/g' ${S}/Makefile
sed -i -e 's/EXTRAVERSION =.*/EXTRAVERSION = -oc2g/g' ${S}/Makefile
}

View File

@ -1,20 +0,0 @@
require u-boot.inc
require ${PN}-${PV}.inc
PROVIDES_oc2g = " \
u-boot \
virtual/bootloader \
"
DESCRIPTION = "u-boot bootloader for TI devices supported by the GLSDK product"
REPODIR = "${THISDIR}"
REPOFILE = "u-boot-oc2g_2015.07.bb"
PR := "${INC_PR}.${REPOGITFN}"
# set theses two variables to 1 to specify u-boot update requierement when the rootfs is updated
export MLO_UPGRADE = "1"
export UBOOT_UPGRADE = "1"
SPL_BINARY = "MLO"
SPL_UART_BINARY = "u-boot-spl.bin"

View File

@ -1,76 +0,0 @@
require ${COREBASE}/meta/recipes-bsp/u-boot/u-boot.inc
FILESEXTRAPATHS_prepend := "${THISDIR}/u-boot:"
INC_PR = "r2"
PACKAGE_ARCH = "${MACHINE_ARCH}"
PROVIDES += "u-boot"
PKG_${PN} = "u-boot"
PKG_${PN}-dev = "u-boot-dev"
PKG_${PN}-dbg = "u-boot-dbg"
S = "${WORKDIR}/git"
UBOOT_SUFFIX = "img"
#RDEPENDS_${PN} = "repair"
# SPL (Second Program Loader) to be loaded over UART
SPL_UART_BINARY ?= ""
SPL_UART_IMAGE ?= "${SPL_UART_BINARY}-${MACHINE}-${PV}-${PR}"
SPL_UART_SYMLINK ?= "${SPL_UART_BINARY}-${MACHINE}"
MLO_BIN ?= "MLO-${MACHINE}-${PV}-${PR}"
do_install_append () {
if [ "x${SPL_UART_BINARY}" != "x" ]
then
install ${B}/spl/${SPL_UART_BINARY} ${D}/boot/${SPL_UART_IMAGE}
ln -sf ${SPL_UART_IMAGE} ${D}/boot/${SPL_UART_BINARY}
fi
#FIXME: do we want/need this? replace iwth 'openssl enc -base64 -d'?
#md5sum ${D}/boot/${MLO_BIN} | cut -d ' ' -f 1 | xxd -r -p >> ${D}/boot/${MLO_BIN}
install -d ${D}${sysconfdir}
echo "MLO_UPGRADE=${MLO_UPGRADE}" >> ${D}${sysconfdir}/mlo.conf
echo "UBOOT_UPGRADE=${UBOOT_UPGRADE}" >> ${D}${sysconfdir}/uboot.conf
chmod 755 ${D}${sysconfdir}/mlo.conf
chmod 755 ${D}${sysconfdir}/uboot.conf
}
do_deploy_append () {
cd ${DEPLOYDIR}
if [ "x${SPL_UART_BINARY}" != "x" ]
then
install ${B}/spl/${SPL_UART_BINARY} ${DEPLOYDIR}/${SPL_UART_IMAGE}
rm -f ${DEPLOYDIR}/${SPL_UART_BINARY} ${DEPLOYDIR}/${SPL_UART_SYMLINK}
ln -sf ${SPL_UART_IMAGE} ${DEPLOYDIR}/${SPL_UART_BINARY}
ln -sf ${SPL_UART_IMAGE} ${DEPLOYDIR}/${SPL_UART_SYMLINK}
fi
#FIXME: do we want/need this? replace iwth 'openssl enc -base64 -d'?
#md5sum ${DEPLOYDIR}/${MLO_BIN} | cut -d ' ' -f 1 | xxd -r -p >> ${DEPLOYDIR}/${MLO_BIN}
}
pkg_postinst_${PN}_append() {
if [ x"$D" = "x" ]; then
if [ -f /usr/bin/checkboot ]; then
echo "Verify boot file possible update..."
/usr/bin/checkboot -c -d
__CHECK_RET=$?
if test ${__CHECK_RET} -eq 100; then
sleep 30s
/usr/bin/checkboot -c -d
__CHECK_RET=$?
fi
if test ${__CHECK_RET} -ne 0; then
echo "Verify boot file possible update... error!"
else
echo "Verify boot file possible update... done!"
fi
fi
fi
}
FILES_${PN} += "${sysconfdir}/mlo.conf \
${sysconfdir}/uboot.conf \
"

View File

@ -0,0 +1,81 @@
#!/bin/sh
#/etc/init.d/watchdog: start watchdog daemon.
#based on debian/init of watchdog
### BEGIN INIT INFO
# Provides: watchdog
# Short-Description: Start software watchdog daemon
# Required-Start: $local_fs
# Required-Stop:
# Should-Start:
# Should-Stop:
# Default-Start: S
# Default-Stop:
### END INIT INFO
PATH=/bin:/usr/bin:/sbin:/usr/sbin
test -x /usr/sbin/watchdog || exit 0
# For configuration of the init script use the file
# /etc/default/watchdog, do not edit this init script.
# Set run_watchdog to 1 to start watchdog or 0 to disable it.
# Specify additional watchdog options here (see manpage).
watchdog_options=""
# Specify module to load
watchdog_module="none"
run_watchdog=1
[ -e /etc/default/watchdog ] && . /etc/default/watchdog
NAME=watchdog
DAEMON=/usr/sbin/watchdog
case "$1" in
start)
if [ $run_watchdog = 1 ]
then
# do we have to load a module?
[ ${watchdog_module:-none} != "none" ] && /sbin/modprobe $watchdog_module
# Unconditionally start watchdog daemon because we want to run it even
# if wd_keepalive wasn't running
echo "Starting watchdog daemon..."
start-stop-daemon --start --quiet --pidfile /var/run/$NAME.pid \
--exec $DAEMON -- $watchdog_options
fi
;;
stop)
if [ $run_watchdog = 1 ]
then
echo "Stopping watchdog daemon..."
start-stop-daemon --stop -s 9 --quiet \
--pidfile /var/run/$NAME.pid
fi
;;
restart)
$0 force-reload
;;
force-reload)
if [ $run_watchdog = 0 ]; then exit 0; fi
echo "Restarting ${NAME}"
$0 stop
$0 start
;;
*)
echo "Usage: /etc/init.d/watchdog {start|stop|restart|force-reload}"
exit 1
esac
exit 0

View File

@ -0,0 +1,41 @@
#ping = 172.31.14.1
#ping = 172.26.1.255
#interface = eth0
#file = /var/log/messages
#change = 1407
# Uncomment to enable test. Setting one of these values to '0' disables it.
# These values will hopefully never reboot your machine during normal use
# (if your machine is really hung, the loadavg will go much higher than 25)
#max-load-1 = 24
#max-load-5 = 18
#max-load-15 = 12
# Note that this is the number of pages!
# To get the real size, check how large the pagesize is on your machine.
#min-memory = 1
#repair-binary = /usr/sbin/repair
#repair-timeout =
#test-binary =
#test-timeout =
watchdog-device = /dev/watchdog
# Defaults compiled into the binary
#temperature-device =
#max-temperature = 120
# Defaults compiled into the binary
#admin = root
#interval = 1
#logtick = 1
#log-dir = /var/log/watchdog
# This greatly decreases the chance that watchdog won't be scheduled before
# your machine is really loaded
realtime = yes
priority = 1
# Check if syslogd is still running by enabling the following line
#pidfile

View File

@ -0,0 +1,24 @@
SYSMOCOM := "${@os.path.dirname(bb.data.getVar('FILE', d, True))}"
FILESEXTRAPATHS_prepend := "${SYSMOCOM}/${PN}-${PV}:${SYSMOCOM}/${PN}:"
PRINC = "9"
inherit update-rc.d
SRC_URI_append_sysmobts-v2 = " file://watchdog.conf file://init"
do_install_append() {
if [ -e ${WORKDIR}/watchdog.conf ]; then
install -D -m 0644 ${WORKDIR}/watchdog.conf ${D}/${sysconfdir}/
fi
install -D -m 0755 ${WORKDIR}/init ${D}/${sysconfdir}/init.d/watchdog
}
CONFFILES_${PN} = "${sysconfdir}/watchdog.conf"
INITSCRIPT_PACKAGES = "${PN}"
INITSCRIPT_NAME_${PN} = "watchdog"
INITSCRIPT_PARAMS_${PN} = "start 06 S ."
# bug in poky meta/classes/base.bbclass?
PACKAGE_ARCH = "${MACHINE_ARCH}"

View File

@ -0,0 +1,88 @@
##############################################################################
#
# Sample ggsn configuration file
#
##############################################################################
# TAG: fg
# Include this flag if process is to run in the foreground
#
#fg
# TAG: debug
# Include this flag to include debug information.
#debug
# TAG: conf
# Configuration file to use. This file is the configuration file,
# so changing this parameter in the configuration file does not make
# sense. Use it on the command line instead.
# TAG: pidfile
# File to store information about the process id of the program.
# The program must have write access to this file/directory.
#pidfile /var/run/ggsn.pid
# TAG: statedir
# Directory to use for nonvolatile storage.
# The program must have write access to this directory.
#statedir /var/lib/ggsn/
# TAG: listen
# Specifies the local IP address to listen to
#listen 10.0.0.240
listen 10.23.24.2
# TAG: net
# IP network address of external packet data network
# Used to set up network interface.
net 10.23.42.0/24
# TAG: ipup
# Script executed after network interface has been brought up.
# Executed with the following parameters: <devicename> <ip address>
#ipup /etc/ggsn/ip-up
# TAG: ipdown
# Script executed after network interface has been taken down.
# Executed with the following parameters: <devicename> <ip address>
#ipdown /etc/ggsn/ip-down
# TAG: dynip
# Dynamic IP address pool.
# Used for allocation of dynamic IP address when address is not given
# by HLR.
# If this option is not given then the net option is used as a substitute.
#dynip 192.168.0.0/24
# TAG: statip
# Use of this tag is currently UNSUPPORTED
# Static IP address pool.
# Used for allocation of static IP address by means of HLR.
#statip 192.168.1.0/24
# TAG: pcodns1
# Protocol configuration option domain name system server 1.
pcodns1 8.8.8.8
# TAG: pcodns2
# Protocol configuration option domain name system server 2.
#pcodns2 0.0.0.0
# TAG: timelimit
# Exit after timelimit seconds.
# Setting timelimit to zero will cause the program not to exit.
#timelimit 0
# TAG: apn
# Use of this tag is EXPERIMENTAL
# Access point name to connect to when run in client mode.
#apn internet
# TAG: qos
# Use of this tag is EXPERIMENTAL
# Requested Quality of Service used when run in client mode.
# 3 bytes corresponding to ????
#qos 0x0b921f

View File

@ -0,0 +1,88 @@
##############################################################################
#
# Sample ggsn configuration file
#
##############################################################################
# TAG: fg
# Include this flag if process is to run in the foreground
#
#fg
# TAG: debug
# Include this flag to include debug information.
#debug
# TAG: conf
# Configuration file to use. This file is the configuration file,
# so changing this parameter in the configuration file does not make
# sense. Use it on the command line instead.
# TAG: pidfile
# File to store information about the process id of the program.
# The program must have write access to this file/directory.
#pidfile /var/run/ggsn.pid
# TAG: statedir
# Directory to use for nonvolatile storage.
# The program must have write access to this directory.
#statedir /var/lib/ggsn/
# TAG: listen
# Specifies the local IP address to listen to
#listen 10.0.0.240
listen 127.0.0.2
# TAG: net
# IP network address of external packet data network
# Used to set up network interface.
net 10.23.42.0/24
# TAG: ipup
# Script executed after network interface has been brought up.
# Executed with the following parameters: <devicename> <ip address>
#ipup /etc/ggsn/ip-up
# TAG: ipdown
# Script executed after network interface has been taken down.
# Executed with the following parameters: <devicename> <ip address>
#ipdown /etc/ggsn/ip-down
# TAG: dynip
# Dynamic IP address pool.
# Used for allocation of dynamic IP address when address is not given
# by HLR.
# If this option is not given then the net option is used as a substitute.
#dynip 192.168.0.0/24
# TAG: statip
# Use of this tag is currently UNSUPPORTED
# Static IP address pool.
# Used for allocation of static IP address by means of HLR.
#statip 192.168.1.0/24
# TAG: pcodns1
# Protocol configuration option domain name system server 1.
pcodns1 8.8.8.8
# TAG: pcodns2
# Protocol configuration option domain name system server 2.
#pcodns2 0.0.0.0
# TAG: timelimit
# Exit after timelimit seconds.
# Setting timelimit to zero will cause the program not to exit.
#timelimit 0
# TAG: apn
# Use of this tag is EXPERIMENTAL
# Access point name to connect to when run in client mode.
#apn internet
# TAG: qos
# Use of this tag is EXPERIMENTAL
# Requested Quality of Service used when run in client mode.
# 3 bytes corresponding to ????
#qos 0x0b921f

View File

@ -0,0 +1,11 @@
DESCRIPTION = "OpenGGSN config by sysmocom"
SRC_URI = "file://ggsn.conf"
LICENSE = "closed"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
do_install() {
install -d ${D}${sysconfdir}
install -m 0660 ${WORKDIR}/ggsn.conf ${D}${sysconfdir}/
}
CONFFILES_${PN} = "${sysconfdir}/ggsn.conf"

View File

@ -0,0 +1,11 @@
#!/bin/sh
TEST_VALUE="default"
. /slot/system.conf
cat >/etc/sysmocom/test.cfg <<EOF
[main]
bla=$TEST_VALUE
model=sysmonitb-ip
EOF

View File

@ -1,12 +1,12 @@
#OpenVPN client conf
tls-client
client
remote-cert-tls server
ns-cert-type server
dev tun
proto udp
tun-mtu 1500
remote vpn.sysmocom.de
remote admin.sysmocom.de
remote 78.46.147.238
comp-lzo
pkcs12 sysmocom-client-cert.p12
cipher AES-256-CBC
nobind
cipher BF-CBC

View File

@ -5,12 +5,21 @@ LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
SRC_URI = "file://sysmocom-vpn.conf"
PR = "r7"
PR = "r4"
CONFFILES_${PN} = "${sysconfdir}/openvpn/sysmocom-vpn.conf"
CONFFILES_${PN} = "${sysconfdir}/openvpn/sysmocom-vpn.conf.off"
PACKAGE_ARCH = "all"
do_install() {
install -d ${D}${sysconfdir}/openvpn
install -m 0644 ${WORKDIR}/sysmocom-vpn.conf ${D}${sysconfdir}/openvpn
install -m 0644 ${WORKDIR}/sysmocom-vpn.conf ${D}${sysconfdir}/openvpn/sysmocom-vpn.conf.off
}
# Always enable the OpenVPN service. This assumes that
# this package will never be inside the nornal sysmocom
# feed.
FILES_${PN} += "${systemd_unitdir}"
do_install_append() {
install -d ${D}${systemd_unitdir}/system/multi-user.target.wants/
ln -sf ../openvpn.service ${D}${systemd_unitdir}/system/multi-user.target.wants/
}

View File

@ -1,10 +0,0 @@
#!/bin/sh
cd tests
for i in `ls *`; do
if [ ./$i ] ; then
echo "PASS: $i"
else
echo "FAIL: $i"
fi
done

View File

@ -1,32 +0,0 @@
DESCRIPTION = "ZeroMQ looks like an embeddable networking library but acts like a concurrency framework"
HOMEPAGE = "http://www.zeromq.org"
LICENSE = "LGPLv3+"
LIC_FILES_CHKSUM = "file://COPYING.LESSER;md5=d5311495d952062e0e4fbba39cbf3de1"
PACKAGECONFIG ??= "libsodium"
PACKAGECONFIG[libsodium] = "--with-libsodium, --without-libsodium, libsodium"
SRC_URI = "http://github.com/zeromq/zeromq4-1/releases/download/v${PV}/zeromq-${PV}.tar.gz \
file://run-ptest \
"
SRC_URI[md5sum] = "c89db4dbc0b90c34c9f4983cbff6d321"
SRC_URI[sha256sum] = "02ebf60a43011e770799336365bcbce2eb85569e9b5f52aa0d8cc04672438a0a"
S = "${WORKDIR}/zeromq-${PV}"
#Uncomment to choose polling system manually. valid values are kqueue, epoll, devpoll, poll or select
#EXTRA_OECONF += "--with-poller=kqueue"
#CFLAGS_append = " -O0"
#CXXFLAGS_append = " -O0"
inherit autotools ptest pkgconfig
do_compile_ptest () {
echo 'buildtest-TESTS: $(check_PROGRAMS)' >> ${B}/Makefile
oe_runmake buildtest-TESTS
}
do_install_ptest () {
install -d ${D}${PTEST_PATH}/tests
install -m 0755 ${B}/.libs/test_* ${D}${PTEST_PATH}/tests
}

View File

@ -0,0 +1,36 @@
#!/bin/sh
DAEMON=/usr/sbin/ifplugd
NAME=ifplugd
DESC="Busybox ifplugd Server"
ARGS=" -i eth0 -M -I -r /etc/ifplugd.sh"
test -f $DAEMON || exit 1
set -e
case "$1" in
start)
echo -n "starting $DESC: $NAME... "
/sbin/start-stop-daemon -S -b -n $NAME -a $DAEMON -- $ARGS
echo "done."
;;
stop)
echo -n "stopping $DESC: $NAME... "
/sbin/start-stop-daemon -K -n $NAME
echo "done."
;;
restart)
echo "Not restarting $DESC: $NAME... "
;;
reload)
echo -n "reloading $DESC: $NAME... "
killall -HUP $(basename ${DAEMON})
echo "done."
;;
*)
echo "Usage: $0 {start|stop|restart|reload}"
exit 1
;;
esac
exit 0

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,62 @@
Upstream-Status: Backport
Signed-off-by: Henning Heinold <henning@itconsulting-heinold.de>
From da331d779c19d7d5d4ef05152ee467d617913a01 Mon Sep 17 00:00:00 2001
From: Tito Ragusa <farmatito@tiscali.it>
Date: Sun, 4 Aug 2013 18:08:40 +0200
Subject: [PATCH 001/104] ifplugd: use a larger netlink buffer
function old new delta
check_existence_through_netlink 310 321 +11
Signed-off-by: Tito Ragusa <farmatito@tiscali.it>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
---
networking/ifplugd.c | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/networking/ifplugd.c b/networking/ifplugd.c
index 3cdc2c9..b578f4c 100644
--- a/networking/ifplugd.c
+++ b/networking/ifplugd.c
@@ -451,20 +451,24 @@ static smallint detect_link(void)
static NOINLINE int check_existence_through_netlink(void)
{
int iface_len;
- char replybuf[1024];
+ /* Buffer was 1K, but on linux-3.9.9 it was reported to be too small.
+ * netlink.h: "limit to 8K to avoid MSG_TRUNC when PAGE_SIZE is very large".
+ * Note: on error returns (-1) we exit, no need to free replybuf.
+ */
+ enum { BUF_SIZE = 8 * 1024 };
+ char *replybuf = xmalloc(BUF_SIZE);
iface_len = strlen(G.iface);
while (1) {
struct nlmsghdr *mhdr;
ssize_t bytes;
- bytes = recv(netlink_fd, &replybuf, sizeof(replybuf), MSG_DONTWAIT);
+ bytes = recv(netlink_fd, replybuf, BUF_SIZE, MSG_DONTWAIT);
if (bytes < 0) {
if (errno == EAGAIN)
- return G.iface_exists;
+ goto ret;
if (errno == EINTR)
continue;
-
bb_perror_msg("netlink: recv");
return -1;
}
@@ -507,6 +511,8 @@ static NOINLINE int check_existence_through_netlink(void)
}
}
+ ret:
+ free(replybuf);
return G.iface_exists;
}
--
1.7.10.4

File diff suppressed because it is too large Load Diff

View File

@ -1,26 +0,0 @@
#OPTIONS="-C"
# The above option means syslogd will log to 16K shm circular buffer.
# You could use `logread' to read it.
# All available options are:
# -O FILE : Log to FILE (default:/var/log/messages)
# -l N : Log only messages more urgent than prio N (1-8)
# -S : Smaller output
# -s SIZE : Max size (KB) before rotation (default:200KB, 0=off)
# -b N : N rotated logs to keep (default:1, max=99, 0=purge)
# -R HOST[:PORT]: Log to HOST:PORT (default PORT:514)
# -L : Log locally and via network
# -D : Drop duplicates
# -C[size_kb] : Log to shared mem buffer (use logread to read it)
# -f FILE : Use FILE as config (default:/etc/syslog.conf)
# -m MIN : Minutes between mark lines (default:20, 0=off)
# -K : Log to kernel printk buffer (use dmesg to read it)
# Example 1:
# Log to local file /var/log/mylog
# OPTIONS="-O /var/log/mylog"
#
# Example 2:
# Log to remote host
# OPTIONS="-R 192.168.1.1:601"
OPTIONS="-C64"

View File

@ -1,6 +1,6 @@
SYSMOCOM := "${@os.path.dirname(d.getVar('FILE', True))}"
SYSMOCOM := "${@os.path.dirname(bb.data.getVar('FILE', d, True))}"
FILESEXTRAPATHS_prepend := "${SYSMOCOM}/busybox-${SYSMOCOM_ORIG_PV}:${SYSMOCOM}/files:"
PRINC = "32"
PRINC = "30"
SRC_URI += "file://udhcpc-ntp.sh \
file://udhcpc-ntp.default \

View File

@ -0,0 +1,18 @@
PRINC := "${@int(PRINC) + 1}"
SRC_URI += "file://ifplugd-use-a-larger-netlink-buffer.patch \
file://busybox-ifplugd.sh \
file://ifplugd.sh \
"
PACKAGES =+ "${PN}-ifplugd"
FILES_${PN}-ifplugd = "${sysconfdir}/ifplugd.sh ${sysconfdir}/init.d/busybox-ifplugd.sh"
INITSCRIPT_PACKAGES += "${PN}-ifplugd"
INITSCRIPT_NAME = "busybox-ifplugd.sh"
do_install_append() {
install -m 0755 ${WORKDIR}/ifplugd.sh ${D}${sysconfdir}/
install -m 0755 ${WORKDIR}/busybox-ifplugd.sh ${D}${sysconfdir}/init.d/
}

View File

@ -1,4 +1,4 @@
# Make busybox work nicely with systemd
SYSMOCOM_D := "${@os.path.dirname(d.getVar('FILE', True))}"
SYSMOCOM_D := "${@os.path.dirname(bb.data.getVar('FILE', d, True))}"
FILESEXTRAPATHS_prepend := "${SYSMOCOM}/${PN}-systemd:${SYSMOCOM_D}/${PN}:"
PRINC := "${@int(PRINC) + 3}"

Some files were not shown because too many files have changed in this diff Show More