Re: [PATCH 0/2] enable procd security features by default

2020-11-26 Thread Stijn Tintel
On 7/11/2020 16:17, Daniel Golle wrote:
> Hi all!
>
> A while ago we have added some useful kernel features to !SMALL_FLASH
> devices[1]. To make more use of that by default in a way which will
> make exploiting potential vulnerabilities in OpenWrt's services much
> harder, it'd be great to also have procd-ujail as well as procd-seccomp
> installed by default, adding about 38kB to squashfs rootfs.
>
> As it was reverted after it (actually something else) had broken the
> build, I've extensively tested ujail on x86/64, ath79/generic,
> ramips/mt7621, malta/mips64be and armvirt/64.
>
> Previous problems on MIPS64 systems (originating from a very strange
> compiler bug, but I was able to work around it) are fixed now, thanks
> to help from Roman Kuzmitskii (@damex).
>
> I must admit that I have no means to do any tests on PPC platforms and
> in order to avoid similar unexpected problems, it'd be great if someone
> with PPC hardware could test-run, simply by installing procd-ujail and
> procd-seccomp to their system and checking if everything still works as
> expected after a reboot (if there are problems you would notice dnsmasq
> and ntpd not coming up, as those would be jailed by default in case of
> /sbin/ujail being found).
>
> Please report back and voice any concens, it'd be great to have this
> included in OpenWrt 20.xx (xx == 11?)
>
> [1]: commit fcb41decf6 ("config: enable some useful features on !SMALL_FLASH 
> devices")
>
>
> Daniel Golle (2):
>   target: select procd-ujail if !SMALL_FLASH
>   target: select procd-seccomp if kernel support is present
>
>  include/target.mk | 10 ++
>  1 file changed, 10 insertions(+)
>
Please have another look at de7ca7dafadfd650d031e0379ce0c002868d5936. It
does not work for devices running ext4 images. This caused me a night of
downtime and forced me to take an unpaid day off. I very much value the
work to move away from running everything as root, but breakage like
this is really not acceptable.


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH] rules.mk: use -fPIC instead of -fpic on arm64

2020-12-04 Thread Stijn Tintel
Some packages fail to build on arm64 when PKG_ASLR_PIE_ALL=y, due to
machine-specific size restrictions on the global offset table.
While the manual instructs to recompile with -fPIC if it fails with
-fpic, by doing this per package, there is still a risk of random
breakage due to version bumps or other changes, so let's use -fPIC on
arm64 by default.

While comparing the sizes of 141 packages built with -fpic vs -fPIC,
most packages are either equal or smaller in size. Only 9 of the
compared packages turned out slightly larger.

Signed-off-by: Stijn Tintel 
---
 rules.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/rules.mk b/rules.mk
index 34222a3a71..f79340b124 100644
--- a/rules.mk
+++ b/rules.mk
@@ -77,7 +77,7 @@ IS_PACKAGE_BUILD := $(if $(filter 
package/%,$(BUILD_SUBDIR)),1)
 
 OPTIMIZE_FOR_CPU=$(subst i386,i486,$(ARCH))
 
-ifeq ($(ARCH),powerpc)
+ifneq (,$(findstring $(ARCH) , aarch64 aarch64_be powerpc ))
   FPIC:=-fPIC
 else
   FPIC:=-fpic
-- 
2.26.2


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [PATCH v2] realtek: drop ethtool log noise

2021-03-11 Thread Stijn Tintel
On 11/03/2021 14:35, Bjørn Mork wrote:
> Demote a number of debugging printk's to pr_debug to avoid log
> nosie.  Several of these functions are called as a result of
> userspace activity.  This can cause a lot of log noise when
> userspace does periodic polling.
>
> Most of this could probably be removed completely, but let's
> keep it for now since these drivers are still in development.
>
Merged, thanks!

Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 0/4] import libcap from packages feed

2021-03-11 Thread Stijn Tintel
Having libcap in OpenWrt base allows us to enable libcap support in
other packages in base.

In lldpd, this would allow the monitor process to drop its privileges
instead of running as root, improving security. It will also allow us to
drop our patch to disable libcap.

I suspect some people might counter this by saying lldpd belongs in the
packages feed; I strongly disagree as imo LLDP is an essential service
for any network device, and especially switches. Even the cheapest
managed switches support LLDP for more than 5 years already.

Also see: https://github.com/openwrt/openwrt/pull/3823#issuecomment-795174537
I'll bump lldpd to the latest version after this series is merged, and
debug the problem reported by John on the realtek target.

Stijn Tintel (4):
  libcap: import from packages feed
  libcap: drop invalid copyright header
  libcap: bump to 2.48
  lldpd: add libcap dependency

 package/libs/libcap/Makefile  | 114 ++
 .../libcap/patches/300-disable-tests.patch|  10 ++
 package/network/services/lldpd/Makefile   |   4 +-
 .../lldpd/patches/001-disable_libcap.patch|  17 ---
 4 files changed, 126 insertions(+), 19 deletions(-)
 create mode 100644 package/libs/libcap/Makefile
 create mode 100644 package/libs/libcap/patches/300-disable-tests.patch
 delete mode 100644 
package/network/services/lldpd/patches/001-disable_libcap.patch

-- 
2.26.2


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 2/4] libcap: drop invalid copyright header

2021-03-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/libs/libcap/Makefile | 2 --
 1 file changed, 2 deletions(-)

diff --git a/package/libs/libcap/Makefile b/package/libs/libcap/Makefile
index 0206bd9d1d..29ff75c5cd 100644
--- a/package/libs/libcap/Makefile
+++ b/package/libs/libcap/Makefile
@@ -1,6 +1,4 @@
 #
-# Copyright (C) 2011 OpenWrt.org
-#
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
 #
-- 
2.26.2


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 3/4] libcap: bump to 2.48

2021-03-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/libs/libcap/Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/package/libs/libcap/Makefile b/package/libs/libcap/Makefile
index 29ff75c5cd..b8e45a52c7 100644
--- a/package/libs/libcap/Makefile
+++ b/package/libs/libcap/Makefile
@@ -6,12 +6,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=libcap
-PKG_VERSION:=2.43
+PKG_VERSION:=2.48
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=@KERNEL/linux/libs/security/linux-privs/libcap2
-PKG_HASH:=512a0e5fc4c1e06d472a20da26aa96a9b9bf2a26b23f094f77f1b8da56cc427f
+PKG_HASH:=4de9590ee09a87c282d558737ffb5b6175ccbfd26d580add10df44d0f047f6c2
 
 PKG_MAINTAINER:=Paul Wassi 
 PKG_LICENSE:=GPL-2.0-only
-- 
2.26.2


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 4/4] lldpd: add libcap dependency

2021-03-11 Thread Stijn Tintel
Now that libcap is in OpenWrt base, we can drop our custom patch to
disable libcap support and have lldpd depend on it instead. This will
allow the monitor process to drop its privileges instead of running as
root, improving security.

Signed-off-by: Stijn Tintel 
---
 package/network/services/lldpd/Makefile |  4 ++--
 .../lldpd/patches/001-disable_libcap.patch  | 17 -
 2 files changed, 2 insertions(+), 19 deletions(-)
 delete mode 100644 
package/network/services/lldpd/patches/001-disable_libcap.patch

diff --git a/package/network/services/lldpd/Makefile 
b/package/network/services/lldpd/Makefile
index 74d6791091..1329abe874 100644
--- a/package/network/services/lldpd/Makefile
+++ b/package/network/services/lldpd/Makefile
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=lldpd
 PKG_VERSION:=1.0.7
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=https://media.luffy.cx/files/lldpd
@@ -30,7 +30,7 @@ define Package/lldpd
   SUBMENU:=Routing and Redirection
   TITLE:=Link Layer Discovery Protocol daemon
   URL:=https://vincentbernat.github.io/lldpd/
-  DEPENDS:=+libevent2 +USE_GLIBC:libbsd +LLDPD_WITH_JSON:libjson-c 
+LLDPD_WITH_SNMP:libnetsnmp
+  DEPENDS:=+libcap +libevent2 +USE_GLIBC:libbsd +LLDPD_WITH_JSON:libjson-c 
+LLDPD_WITH_SNMP:libnetsnmp
   USERID:=lldp=121:lldp=129
   MENU:=1
 endef
diff --git a/package/network/services/lldpd/patches/001-disable_libcap.patch 
b/package/network/services/lldpd/patches/001-disable_libcap.patch
deleted file mode 100644
index 96cf00a653..00
--- a/package/network/services/lldpd/patches/001-disable_libcap.patch
+++ /dev/null
@@ -1,17 +0,0 @@
 a/configure.ac
-+++ b/configure.ac
-@@ -246,7 +246,13 @@ PKG_CHECK_MODULES([check], [check >= 0.9
- 
- # Third-party libraries
- lldp_CHECK_LIBEVENT
--lldp_CHECK_LIBCAP
-+
-+#libcap is not a core package so disable this capability
-+#lldp_CHECK_LIBCAP
-+libcap_LIBS=
-+libcap_CFLAGS=
-+AC_SUBST([libcap_LIBS])
-+AC_SUBST([libcap_CFLAGS])
- 
- # Compatibility with pkg.m4 < 0.27
- m4_ifdef([PKG_INSTALLDIR], [PKG_INSTALLDIR],
-- 
2.26.2


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[PATCH 1/4] libcap: import from packages feed

2021-03-11 Thread Stijn Tintel
Having libcap in OpenWrt base allows us to enable libcap support in
other packages in base.

In lldpd, this would allow the monitor process to drop its privileges
instead of running as root, improving security. It will also allow us to
drop our patch to disable libcap.

Signed-off-by: Stijn Tintel 
---
 package/libs/libcap/Makefile  | 116 ++
 .../libcap/patches/300-disable-tests.patch|  10 ++
 2 files changed, 126 insertions(+)
 create mode 100644 package/libs/libcap/Makefile
 create mode 100644 package/libs/libcap/patches/300-disable-tests.patch

diff --git a/package/libs/libcap/Makefile b/package/libs/libcap/Makefile
new file mode 100644
index 00..0206bd9d1d
--- /dev/null
+++ b/package/libs/libcap/Makefile
@@ -0,0 +1,116 @@
+#
+# Copyright (C) 2011 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=libcap
+PKG_VERSION:=2.43
+PKG_RELEASE:=1
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
+PKG_SOURCE_URL:=@KERNEL/linux/libs/security/linux-privs/libcap2
+PKG_HASH:=512a0e5fc4c1e06d472a20da26aa96a9b9bf2a26b23f094f77f1b8da56cc427f
+
+PKG_MAINTAINER:=Paul Wassi 
+PKG_LICENSE:=GPL-2.0-only
+PKG_LICENSE_FILES:=License
+
+PKG_INSTALL:=1
+PKG_BUILD_PARALLEL:=1
+
+include $(INCLUDE_DIR)/package.mk
+include $(INCLUDE_DIR)/kernel.mk
+
+define Package/libcap/Default
+  TITLE:=Linux capabilities library
+  SECTION:=libs
+  CATEGORY:=Libraries
+  URL:=https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/
+endef
+
+define Package/libcap/description/Default
+  Linux capabilities
+endef
+
+define Package/libcap
+  $(call Package/libcap/Default)
+  TITLE += library
+endef
+
+define Package/libcap-bin
+  $(call Package/libcap/Default)
+  TITLE += binaries
+  DEPENDS += libcap
+endef
+
+define Package/libcap-bin/description
+  $(call Package/libcap/description/Default)
+  .
+  This package contains the libcap utilities.
+endef
+
+define Package/libcap-bin/config
+  if PACKAGE_libcap-bin
+  config PACKAGE_libcap-bin-capsh-shell
+string "capsh shell"
+help
+  Set the capsh shell.
+default "/bin/sh"
+  endif
+endef
+
+MAKE_FLAGS += \
+BUILD_CC="$(CC)" \
+BUILD_CFLAGS="$(FPIC) -I$(PKG_BUILD_DIR)/libcap/include" \
+CFLAGS="$(TARGET_CFLAGS)" \
+LD="$(TARGET_CC) -Wl,-x -shared" \
+LDFLAGS="$(TARGET_LDFLAGS)" \
+INDENT="| true" \
+GOLANG="no" \
+PAM_CAP="no" \
+RAISE_SETFCAP="no" \
+DYNAMIC="yes" \
+lib="lib"
+
+ifneq ($(CONFIG_PACKAGE_libcap-bin-capsh-shell),)
+TARGET_CFLAGS += -DSHELL='\"$(CONFIG_PACKAGE_libcap-bin-capsh-shell)\"'
+endif
+
+TARGET_CFLAGS += $(if $(CONFIG_USE_MUSL),-Dpthread_yield=sched_yield)
+
+define Build/InstallDev
+   $(INSTALL_DIR) $(1)/usr/include/sys
+   $(CP) $(PKG_INSTALL_DIR)/usr/include/sys/*.h $(1)/usr/include/sys/
+   $(INSTALL_DIR) $(1)/usr/lib
+   $(CP) $(PKG_INSTALL_DIR)/lib/libcap.{so*,a} $(1)/usr/lib/
+   $(INSTALL_DATA) $(PKG_INSTALL_DIR)/lib/libpsx.a $(1)/usr/lib/
+   $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
+   $(INSTALL_DATA) $(PKG_INSTALL_DIR)/lib/pkgconfig/libcap.pc 
$(1)/usr/lib/pkgconfig/
+   $(SED) 's,exec_prefix=,exec_prefix=/usr,g' 
$(1)/usr/lib/pkgconfig/libcap.pc
+   $(SED) 's,/lib,{exec_prefix}/lib,g' $(1)/usr/lib/pkgconfig/libcap.pc
+   $(SED) 's,/usr/include,{prefix}/include,g' 
$(1)/usr/lib/pkgconfig/libcap.pc
+   $(INSTALL_DATA) $(PKG_INSTALL_DIR)/lib/pkgconfig/libpsx.pc 
$(1)/usr/lib/pkgconfig/
+   $(SED) 's,exec_prefix=,exec_prefix=/usr,g' 
$(1)/usr/lib/pkgconfig/libpsx.pc
+   $(SED) 's,/lib,{exec_prefix}/lib,g' $(1)/usr/lib/pkgconfig/libpsx.pc
+   $(SED) 's,/usr/include,{prefix}/include,g' 
$(1)/usr/lib/pkgconfig/libpsx.pc
+endef
+
+define Package/libcap/install
+   $(INSTALL_DIR) $(1)/usr/lib
+   $(CP) $(PKG_INSTALL_DIR)/lib/libcap.so* $(1)/usr/lib/
+endef
+
+define Package/libcap-bin/install
+   $(INSTALL_DIR) $(1)/usr/sbin
+   $(CP) $(PKG_INSTALL_DIR)/sbin/capsh $(1)/usr/sbin/
+   $(CP) $(PKG_INSTALL_DIR)/sbin/getcap$(1)/usr/sbin/
+   $(CP) $(PKG_INSTALL_DIR)/sbin/getpcaps  $(1)/usr/sbin/
+   $(CP) $(PKG_INSTALL_DIR)/sbin/setcap$(1)/usr/sbin/
+endef
+
+$(eval $(call BuildPackage,libcap))
+$(eval $(call BuildPackage,libcap-bin))
diff --git a/package/libs/libcap/patches/300-disable-tests.patch 
b/package/libs/libcap/patches/300-disable-tests.patch
new file mode 100644
index 00..c1779e28ec
--- /dev/null
+++ b/package/libs/libcap/patches/300-disable-tests.patch
@@ -0,0 +1,10 @@
+--- a/Makefile
 b/Makefile
+@@ -17,7 +17,6 @@ ifeq ($(GOLANG),yes)
+   $(MAKE) -C go $@
+   rm -f cap/go.sum
+ endif
+-

Re: [PATCH 0/4] import libcap from packages feed

2021-03-12 Thread Stijn Tintel

On 12/03/2021 10:50, Petr Štetiar wrote:

Stijn Tintel  [2021-03-12 01:25:24]:

Hi,


Having libcap in OpenWrt base allows us to enable libcap support in
other packages in base.

there is same functionality available through procd already so essentialy
you're throwing away that effort, increasing flash space usage etc.


Is that documented somewhere? Did you test that lldpd even starts when 
limiting it like that? I have had issues when I tried to limit the 
capabilities of infnoised [1] in the systemd unit file; it simply 
wouldn't start.


The flash space usage is a moot point, we no longer care about 4MB 
devices, and libcap is only 12kb.  We can offset that by building lldpd 
with LTO.





In lldpd, this would allow the monitor process to drop its privileges
instead of running as root, improving security. It will also allow us to
drop our patch to disable libcap.

I assume, that you can do it even better with procd's seccomp/jails and
likely confine the master process as well.


The non-monitor process already runs as the lldp user without libcap.

Processes with libcap disabled:

 1642 root  4360 S    /usr/sbin/lldpd -d -c -f -s -e -M 4 -x -X 
/var/run/agentx.sock
 1693 lldp  4804 S    /usr/sbin/lldpd -d -c -f -s -e -M 4 -x -X 
/var/run/agentx.sock


With libcap enabled:

 1804 lldp  1216 S    /usr/sbin/lldpd -d -c -f -s -e -M 4
 1886 lldp  1232 S    /usr/sbin/lldpd -d -c -f -s -e -M 4




I suspect some people might counter this by saying lldpd belongs in the
packages feed;

IMO it belongs to packages feed, because currently it's optional package.  In
other words, it's not included in any of the images by default.


See Bjorn's reply. It's required to properly support 802.3af/at/bt (PoE).

Also, I don't agree that any optional package should be moved to the 
packages feed. The packages feed is a mess, often PR's are accepted 
without maintainer approval, sometimes even after explicit NACK by the 
maintainer or others. For this reason, I'm seriously considering 
removing myself as maintainer from any packages I maintain there.





I strongly disagree as imo LLDP is an essential service for any network
device, and especially switches. Even the cheapest managed switches support
LLDP for more than 5 years already.

If it's that essential, why it's not enabled and shipped by default? I assume
it's because some folks would complain, that LLDP is use case specific, not
everybody would like to have another network exposed service running by
default, not everybody needs LLDP by default in RX/TX mode as TX mode might be
enough etc.

We're considering enabling it on realtek by default.


Cheers,

Petr


Stijn

[1] https://github.com/13-37-org/infnoise

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [PATCH] gmp: compile with -DPIC to use correct asm code

2021-03-12 Thread Stijn Tintel
On 11/03/2021 23:46, Eneas U de Queiroz wrote:
> The library is always compiled with $(FPIC) (-fPIC or -fpic), even for
> the static library.
>
> There are some assembly sources that decide whether or not to enable
> PIC code by checking if PIC is defined.  It counts on libtool to define
> it, but libtool does it only when producing code for the dynamic
> library, while we need it for both.
>
> Ensure it is defined by adding it to CFLAGS next to $(FPIC).
>
> It avoids linking errors with strongswan on x86_64:
>
> ld: libgmp.a(bdiv_q_1.o): relocation R_X86_64_PC32 against symbol
> `__gmp_binvert_limb_table' can not be used when making a shared object;
> recompile with -fPIC
>
> Cc: Stijn Tintel 
> Signed-off-by: Eneas U de Queiroz 
> ---
>
> There's an error on one architecture, and all others work fine without
> this, so I'm uneasy changing this and then breaking stuff that was
> working fine otherwise.  However, it feels wrong to me to generate PIC
> code from C files, but not use it in asm sources, which is essentially
> what I am changing here.
>
> I've looked at asm sources for different chitectures, and there are
> checks for PIC in: arm64, arm, x86_64, x86, and ppc asm sources, but the
> error only appears on x86_64.
>
> For most CPUs, ifdef(`PIC'), is just used to do different definitions of
> LEA (Load Effective Address).  However, both x86 and x86_64 have many
> other checks.
>
> I've looked at bdiv_q_1.asm for different CPUs, and they all do some
> form of LEA(binvert_limb_table), except for x86, where it will do it
> only when PIC is defined.  That may explain why x86_64 is affected, and
> x86 is not.
>
> I have not investigated further details.
>
> Alternatively, we can define it only for x86_64, which is where we know
> there's a build failure with the linker asking to recompile with -fPIC.
>
I'm sorry, but I lack the knowledge to review this.

Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [PATCH 1/2] zram-swap: clean up the makefile

2021-03-31 Thread Stijn Tintel
On 31/03/2021 16:09, Rui Salvaterra wrote:
> Break dependencies into separate lines, to improve the readability. Trim
> trailing whitespace.
>
> Signed-off-by: Rui Salvaterra 
> ---
>  package/system/zram-swap/Makefile | 12 +---
>  1 file changed, 9 insertions(+), 3 deletions(-)
>
> diff --git a/package/system/zram-swap/Makefile 
> b/package/system/zram-swap/Makefile
> index 18c6afee96..96cdcdc5ee 100644
> --- a/package/system/zram-swap/Makefile
> +++ b/package/system/zram-swap/Makefile
> @@ -17,14 +17,20 @@ include $(INCLUDE_DIR)/package.mk
>  define Package/zram-swap
>SECTION:=utils
>CATEGORY:=Base system
> -  DEPENDS:=+kmod-zram +@BUSYBOX_CONFIG_MKSWAP +@BUSYBOX_CONFIG_SWAPON 
> +@BUSYBOX_CONFIG_FEATURE_SWAPON_DISCARD +@BUSYBOX_CONFIG_FEATURE_SWAPON_PRI 
> +@BUSYBOX_CONFIG_SWAPOFF
> +  DEPENDS:= \
> + +kmod-zram \
> + +@BUSYBOX_CONFIG_MKSWAP \
> + +@BUSYBOX_CONFIG_SWAPON \
> + +@BUSYBOX_CONFIG_FEATURE_SWAPON_DISCARD \
> + +@BUSYBOX_CONFIG_FEATURE_SWAPON_PRI \
> + +@BUSYBOX_CONFIG_SWAPOFF
Please put them in alphabetical order.
>TITLE:=ZRAM swap scripts
>PKGARCH:=all
>  endef
>  
>  define Package/zram-swap/description
> - A script to activate swaping on a compressed zram partition. This 
> - could be used to increase the available memory, by using compressed 
> + A script to activate swaping on a compressed zram partition. This
> + could be used to increase the available memory, by using compressed
>   memory.
>  endef
>  

Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [PATCH] kernel: drop the conntrack rtcache patch

2021-04-08 Thread Stijn Tintel
On 9/04/2021 01:57, Rui Salvaterra wrote:
> It's in backports-5.4, but it wasn't ever merged. Upstream followed another
> approach, with flow offloading, which has much better performance. Drop this
> obsolete patch and refresh the kernel patches.

Acked-by: Stijn Tintel 

Some performance comparisons:
https://gist.github.com/stintel/299684b0b9eef896acc9746c4d8be746
Let's focus on flow offloading and drop rtcache.

Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] ar71xx: fix 82_patch_ath10k

2015-05-01 Thread Stijn Tintel
It has been broken since the new ath10k firmware introduced in r44656.

Signed-off-by: Stijn Tintel 
---
 target/linux/ar71xx/base-files/lib/preinit/82_patch_ath10k | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/target/linux/ar71xx/base-files/lib/preinit/82_patch_ath10k 
b/target/linux/ar71xx/base-files/lib/preinit/82_patch_ath10k
index bed140a..88ca1e9 100644
--- a/target/linux/ar71xx/base-files/lib/preinit/82_patch_ath10k
+++ b/target/linux/ar71xx/base-files/lib/preinit/82_patch_ath10k
@@ -5,14 +5,14 @@
 
 
 do_patch_ath10k_firmware() {
-   local firmware_file="/lib/firmware/ath10k/QCA988X/hw2.0/firmware-3.bin"
+   local firmware_file="/lib/firmware/ath10k/QCA988X/hw2.0/firmware-4.bin"
 
# bail out if firmware does not exist
[ -f "$firmware_file" ] || {
return
}
 
-   local firmware_md5_orig="5163aa8de591f80b06c77f22e9777473"
+   local firmware_md5_orig="ab36ef267d15cfc02317ceeb38e8f548"
local firmware_md5_current="$(md5sum $firmware_file)"
local firmware_md5_current="${firmware_md5_current%% *}"
 
-- 
2.0.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] octeon: build squashfs image for UBNT ERLITE

2015-05-22 Thread Stijn Tintel
---
 target/linux/octeon/image/Makefile | 8 ++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/target/linux/octeon/image/Makefile 
b/target/linux/octeon/image/Makefile
index 24bca9b..a15e87b 100644
--- a/target/linux/octeon/image/Makefile
+++ b/target/linux/octeon/image/Makefile
@@ -20,24 +20,27 @@ define Image/BuildKernel/Initramfs/Template
 endef
 
 
ER_CMDLINE:=-mtdparts=phys_mapped_flash:640k(boot0)ro,640k(boot1)ro,64k(eeprom)ro
 block2mtd.block2mtd=/dev/mmcblk0p2,65536,rootfs,5 root=/dev/mtdblock3 
rootfstype=squashfs rootwait
+ERLITE_CMDLINE:=-mtdparts=phys_mapped_flash:512k(boot0),512k(boot1),64k@1024k(eeprom)
 block2mtd.block2mtd=/dev/sda2,65536,rootfs,5 root=/dev/mtdblock3 
rootfstype=squashfs rootwait
 
 define Image/BuildKernel
$(call Image/BuildKernel/Template,generic,)
$(call Image/BuildKernel/Template,er,$(ER_CMDLINE))
+   $(call Image/BuildKernel/Template,erlite,$(ERLITE_CMDLINE))
 endef
 
 define Image/BuildKernel/Initramfs
$(call Image/BuildKernel/Initramfs/Template,generic,)
$(call Image/BuildKernel/Initramfs/Template,er,$(ER_CMDLINE))
+   $(call Image/BuildKernel/Initramfs/Template,erlite,$(ERLITE_CMDLINE))
 endef
 
 define Image/Build/sysupgrade
mkdir -p $(KDIR)/sysupgrade-$(1)/
-   echo "BOARD=er" > $(KDIR)/sysupgrade-$(1)/CONTROL
+   echo "BOARD=$(1)" > $(KDIR)/sysupgrade-$(1)/CONTROL
$(CP) $(BIN_DIR)/$(IMG_PREFIX)-$(2)-vmlinux.64 
$(KDIR)/sysupgrade-$(1)/kernel
$(CP) $(KDIR)/root.$(3) $(KDIR)/sysupgrade-$(1)/root
(cd $(KDIR); $(TAR) cvf \
-   $(BIN_DIR)/$(IMG_PREFIX)-$(1)-sysupgrade.tar sysupgrade-$(1))
+   $(BIN_DIR)/$(IMG_PREFIX)-$(1)-$(3)-sysupgrade.tar 
sysupgrade-$(1))
 endef
 
 define Image/Build/ext4
@@ -47,6 +50,7 @@ endef
 define Image/Build/squashfs
$(call prepare_generic_squashfs,$(KDIR)/root.squashfs)
$(call Image/Build/sysupgrade,er,er,squashfs)
+   $(call Image/Build/sysupgrade,erlite,erlite,squashfs)
 endef
 
 define Image/Build
-- 
2.0.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] conntrack-tools: add init script for conntrackd

2015-05-22 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/utils/conntrack-tools/Makefile  |  2 ++
 .../network/utils/conntrack-tools/files/conntrackd.init | 17 +
 2 files changed, 19 insertions(+)
 create mode 100644 package/network/utils/conntrack-tools/files/conntrackd.init

diff --git a/package/network/utils/conntrack-tools/Makefile 
b/package/network/utils/conntrack-tools/Makefile
index 2c479c0..978467b 100644
--- a/package/network/utils/conntrack-tools/Makefile
+++ b/package/network/utils/conntrack-tools/Makefile
@@ -63,6 +63,8 @@ define Package/conntrack-tools/install
$(PKG_INSTALL_DIR)/usr/sbin/conntrack \
$(PKG_INSTALL_DIR)/usr/sbin/conntrackd \
$(1)/usr/sbin/
+   $(INSTALL_DIR) $(1)/etc/init.d
+   $(INSTALL_BIN) ./files/conntrackd.init $(1)/etc/init.d/conntrackd
 endef
 
 $(eval $(call BuildPackage,conntrack-tools))
diff --git a/package/network/utils/conntrack-tools/files/conntrackd.init 
b/package/network/utils/conntrack-tools/files/conntrackd.init
new file mode 100644
index 000..a51eb88
--- /dev/null
+++ b/package/network/utils/conntrack-tools/files/conntrackd.init
@@ -0,0 +1,17 @@
+#!/bin/sh /etc/rc.common
+# Copyright (C) 2015 OpenWrt.org
+
+START=21
+STOP=89
+
+USE_PROCD=1
+PROG="/usr/sbin/conntrackd"
+
+start_service() {
+   procd_open_instance
+
+   procd_set_param command $PROG -C /etc/conntrackd/conntrackd.conf
+   procd_set_param respawn
+
+   procd_close_instance
+}
-- 
2.0.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] octeon: build squashfs image for UBNT ERLITE

2015-05-22 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/image/Makefile | 8 ++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/target/linux/octeon/image/Makefile 
b/target/linux/octeon/image/Makefile
index 24bca9b..a15e87b 100644
--- a/target/linux/octeon/image/Makefile
+++ b/target/linux/octeon/image/Makefile
@@ -20,24 +20,27 @@ define Image/BuildKernel/Initramfs/Template
 endef
 
 
ER_CMDLINE:=-mtdparts=phys_mapped_flash:640k(boot0)ro,640k(boot1)ro,64k(eeprom)ro
 block2mtd.block2mtd=/dev/mmcblk0p2,65536,rootfs,5 root=/dev/mtdblock3 
rootfstype=squashfs rootwait
+ERLITE_CMDLINE:=-mtdparts=phys_mapped_flash:512k(boot0),512k(boot1),64k@1024k(eeprom)
 block2mtd.block2mtd=/dev/sda2,65536,rootfs,5 root=/dev/mtdblock3 
rootfstype=squashfs rootwait
 
 define Image/BuildKernel
$(call Image/BuildKernel/Template,generic,)
$(call Image/BuildKernel/Template,er,$(ER_CMDLINE))
+   $(call Image/BuildKernel/Template,erlite,$(ERLITE_CMDLINE))
 endef
 
 define Image/BuildKernel/Initramfs
$(call Image/BuildKernel/Initramfs/Template,generic,)
$(call Image/BuildKernel/Initramfs/Template,er,$(ER_CMDLINE))
+   $(call Image/BuildKernel/Initramfs/Template,erlite,$(ERLITE_CMDLINE))
 endef
 
 define Image/Build/sysupgrade
mkdir -p $(KDIR)/sysupgrade-$(1)/
-   echo "BOARD=er" > $(KDIR)/sysupgrade-$(1)/CONTROL
+   echo "BOARD=$(1)" > $(KDIR)/sysupgrade-$(1)/CONTROL
$(CP) $(BIN_DIR)/$(IMG_PREFIX)-$(2)-vmlinux.64 
$(KDIR)/sysupgrade-$(1)/kernel
$(CP) $(KDIR)/root.$(3) $(KDIR)/sysupgrade-$(1)/root
(cd $(KDIR); $(TAR) cvf \
-   $(BIN_DIR)/$(IMG_PREFIX)-$(1)-sysupgrade.tar sysupgrade-$(1))
+   $(BIN_DIR)/$(IMG_PREFIX)-$(1)-$(3)-sysupgrade.tar 
sysupgrade-$(1))
 endef
 
 define Image/Build/ext4
@@ -47,6 +50,7 @@ endef
 define Image/Build/squashfs
$(call prepare_generic_squashfs,$(KDIR)/root.squashfs)
$(call Image/Build/sysupgrade,er,er,squashfs)
+   $(call Image/Build/sysupgrade,erlite,erlite,squashfs)
 endef
 
 define Image/Build
-- 
2.0.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH 0/2] mac80211: Update QCA9880 firmware (ath10k)

2015-06-25 Thread Stijn Tintel


On 22/06/15 20:19, Matti Laakso wrote:

These patches backport the new FW API v5 to ath10k
(upstream commits 8348db2, 53513c3, and dc3632a)
and change mac80211 to use the new firmware.


Could you also update 
target/linux/ar71xx/base-files/lib/preinit/82_patch_ath10k?
See https://patchwork.ozlabs.org/patch/466945/ and possibly 
https://patchwork.ozlabs.org/patch/481472/


Thanks,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] EdgeRouter POE support

2015-07-31 Thread Stijn Tintel
On 07/28/15 01:27, Wojtek Sawaściuk wrote:
> Hello,
> What is current status of support for Ubiquity's EdgeRouter POE (this
> one with 2+3switch ports) ?
>
> I can't flash it with sysupgrade using openwrt-15.05-rc3-octeon-er:
>
> "Sysupgrade is not yet supported on cavium,octeon-3860.
> Image check 'platform_check_image' failed."
I suspect r45462 (and related r45496) broke sysupgrade on EdgeRouter
devices. it fills /tmp/sysinfo/board_name with "cavium,octeon-3860"
while sysupgrade expects it to be "er" or "erlite". This is because
octeon only has a few generic dts files, nothing board specific, so
there is no useable board name in /proc/device-tree/compatible.

I worked around this by putting this
intarget/linux/octeon/base-files/lib/preinit/11_sysinfo:


#!/bin/sh

verify_sysinfo() {
   if [ -f /tmp/sysinfo/board_name ]; then

   name=$(cat /tmp/sysinfo/board_name)

   case "$name" in
   er|erlite|erpro)
   continue
   ;;
   *)
   rm /tmp/sysinfo/board_name
   ;;
   esac
   fi
}

boot_hook_add preinit_main verify_sysinfo

A real fix for this is still needed though.


>
> I can with openwrt-15.05-rc3-octeon-erlite but system detects only eth0
> and eth1, not switch interface (same status with BarierBraker).
>
I only have ERL devices without switch, so can't help you with that, sorry.

Kind regards,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 1/2] kernel/modules: add missing symbol for crypto-rng

2016-01-18 Thread Stijn Tintel
Since CRYPTO_DRBG_MENU was added in r48277, CRYPTO_DRBG_HMAC is missing.
It does not appear in kernel_menuconfig and defaults to yes, so enable
it in crypto-rng as well and add dependencies to HMAC and SHA256.

Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/crypto.mk | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index d84c802..7c71053 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -100,10 +100,11 @@ $(eval $(call KernelPackage,crypto-wq))
 
 define KernelPackage/crypto-rng
   TITLE:=CryptoAPI random number generation
-  DEPENDS:=+kmod-crypto-hash
+  DEPENDS:=+kmod-crypto-hash +kmod-crypto-hmac +kmod-crypto-sha256
   KCONFIG:= \
-   CONFIG_CRYPTO_DRBG_MENU \
CONFIG_CRYPTO_DRBG \
+   CONFIG_CRYPTO_DRBG_HMAC=y \
+   CONFIG_CRYPTO_DRBG_MENU \
CONFIG_CRYPTO_JITTERENTROPY \
CONFIG_CRYPTO_RNG2
   FILES:= \
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/2] kernel: add missing symbols for 4.1

2016-01-18 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/generic/config-4.1 | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/target/linux/generic/config-4.1 b/target/linux/generic/config-4.1
index 222f8c1..d91bedb 100644
--- a/target/linux/generic/config-4.1
+++ b/target/linux/generic/config-4.1
@@ -760,6 +760,8 @@ CONFIG_CRYPTO_BLKCIPHER2=y
 # CONFIG_CRYPTO_DEV_QCE is not set
 # CONFIG_CRYPTO_DEV_SAHARA is not set
 # CONFIG_CRYPTO_DEV_TALITOS is not set
+# CONFIG_CRYPTO_DRBG_CTR is not set
+# CONFIG_CRYPTO_DRBG_HASH is not set
 # CONFIG_CRYPTO_DRBG_MENU is not set
 # CONFIG_CRYPTO_ECB is not set
 # CONFIG_CRYPTO_FCRYPT is not set
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/3] kernel/modules: add kmod-crypto-hw-ccp

2016-01-18 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/crypto.mk | 18 ++
 1 file changed, 18 insertions(+)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index 7c71053..99fb5a0 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -177,6 +177,24 @@ endef
 $(eval $(call KernelPackage,crypto-hw-padlock))
 
 
+define KernelPackage/crypto-hw-ccp
+  TITLE:=AMD Cryptographic Coprocessor
+  DEPENDS:=+kmod-crypto-authenc +kmod-crypto-hash +kmod-crypto-manager 
+kmod-random-core
+  KCONFIG:= \
+   CONFIG_CRYPTO_HW=y \
+   CONFIG_CRYPTO_DEV_CCP=y \
+   CONFIG_CRYPTO_DEV_CCP_CRYPTO \
+   CONFIG_CRYPTO_DEV_CCP_DD
+  FILES:= \
+   $(LINUX_DIR)/drivers/crypto/ccp/ccp.ko \
+   $(LINUX_DIR)/drivers/crypto/ccp/ccp-crypto.ko
+  AUTOLOAD:=$(call AutoLoad,09,ccp ccp-crypto)
+  $(call AddDepends/crypto)
+endef
+
+$(eval $(call KernelPackage,crypto-hw-ccp))
+
+
 define KernelPackage/crypto-hw-geode
   TITLE:=AMD Geode hardware crypto module
   DEPENDS:=+kmod-crypto-manager
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 1/3] kernel: add missing symbol for 4.4

2016-01-18 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/generic/config-4.4 | 1 +
 1 file changed, 1 insertion(+)

diff --git a/target/linux/generic/config-4.4 b/target/linux/generic/config-4.4
index 6ad3008..a8b4074 100644
--- a/target/linux/generic/config-4.4
+++ b/target/linux/generic/config-4.4
@@ -748,6 +748,7 @@ CONFIG_CRYPTO_BLKCIPHER2=y
 # CONFIG_CRYPTO_DEV_IMGTEC_HASH is not set
 # CONFIG_CRYPTO_DEV_MV_CESA is not set
 # CONFIG_CRYPTO_DEV_QAT_DH895xCC is not set
+# CONFIG_CRYPTO_DEV_QAT_DH895xCCVF is not set
 # CONFIG_CRYPTO_DEV_QCE is not set
 # CONFIG_CRYPTO_DEV_SAHARA is not set
 # CONFIG_CRYPTO_DEV_TALITOS is not set
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 3/3] kernel: add patch to fix the ccp-crypto module

2016-01-18 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 ...-add-hash-state-import-and-export-support.patch | 114 +
 1 file changed, 114 insertions(+)
 create mode 100644 
target/linux/generic/patches-4.4/150-crypto-ccp-add-hash-state-import-and-export-support.patch

diff --git 
a/target/linux/generic/patches-4.4/150-crypto-ccp-add-hash-state-import-and-export-support.patch
 
b/target/linux/generic/patches-4.4/150-crypto-ccp-add-hash-state-import-and-export-support.patch
new file mode 100644
index 000..986ac5d
--- /dev/null
+++ 
b/target/linux/generic/patches-4.4/150-crypto-ccp-add-hash-state-import-and-export-support.patch
@@ -0,0 +1,114 @@
+From: Tom Lendacky 
+Subject: [PATCH v1] crypto: ccp - Add hash state import and export support
+Date: Tue, 12 Jan 2016 11:17:38 -0600
+Message-ID: <20160112171738.23496.44254.st...@tlendack-t1.amdoffice.net>
+Mime-Version: 1.0
+Content-Type: text/plain; charset="utf-8"
+Content-Transfer-Encoding: 7bit
+Cc: Herbert Xu , ,
+   "David Miller" 
+To: 
+
+Commit 8996eafdcbad ("crypto: ahash - ensure statesize is non-zero")
+added a check to prevent ahash algorithms from successfully registering
+if the import and export functions were not implemented. This prevents
+an oops in the hash_accept function of algif_hash. This commit causes
+the ccp-crypto module SHA support and AES CMAC support from successfully
+registering and causing the ccp-crypto module load to fail because the
+ahash import and export functions are not implemented.
+
+Update the CCP Crypto API support to provide import and export support
+for ahash algorithms.
+
+Cc:  # 3.14.x-
+Signed-off-by: Tom Lendacky 
+---
+ drivers/crypto/ccp/ccp-crypto-aes-cmac.c |   23 +++
+ drivers/crypto/ccp/ccp-crypto-sha.c  |   23 +++
+ 2 files changed, 46 insertions(+)
+
+--- a/drivers/crypto/ccp/ccp-crypto-aes-cmac.c
 b/drivers/crypto/ccp/ccp-crypto-aes-cmac.c
+@@ -220,6 +220,26 @@ static int ccp_aes_cmac_digest(struct ah
+   return ccp_aes_cmac_finup(req);
+ }
+ 
++static int ccp_aes_cmac_export(struct ahash_request *req, void *out)
++{
++  struct ccp_aes_cmac_req_ctx *rctx = ahash_request_ctx(req);
++  struct ccp_aes_cmac_req_ctx *state = out;
++
++  *state = *rctx;
++
++  return 0;
++}
++
++static int ccp_aes_cmac_import(struct ahash_request *req, const void *in)
++{
++  struct ccp_aes_cmac_req_ctx *rctx = ahash_request_ctx(req);
++  const struct ccp_aes_cmac_req_ctx *state = in;
++
++  *rctx = *state;
++
++  return 0;
++}
++
+ static int ccp_aes_cmac_setkey(struct crypto_ahash *tfm, const u8 *key,
+  unsigned int key_len)
+ {
+@@ -352,10 +372,13 @@ int ccp_register_aes_cmac_algs(struct li
+   alg->final = ccp_aes_cmac_final;
+   alg->finup = ccp_aes_cmac_finup;
+   alg->digest = ccp_aes_cmac_digest;
++  alg->export = ccp_aes_cmac_export;
++  alg->import = ccp_aes_cmac_import;
+   alg->setkey = ccp_aes_cmac_setkey;
+ 
+   halg = &alg->halg;
+   halg->digestsize = AES_BLOCK_SIZE;
++  halg->statesize = sizeof(struct ccp_aes_cmac_req_ctx);
+ 
+   base = &halg->base;
+   snprintf(base->cra_name, CRYPTO_MAX_ALG_NAME, "cmac(aes)");
+--- a/drivers/crypto/ccp/ccp-crypto-sha.c
 b/drivers/crypto/ccp/ccp-crypto-sha.c
+@@ -207,6 +207,26 @@ static int ccp_sha_digest(struct ahash_r
+   return ccp_sha_finup(req);
+ }
+ 
++static int ccp_sha_export(struct ahash_request *req, void *out)
++{
++  struct ccp_sha_req_ctx *rctx = ahash_request_ctx(req);
++  struct ccp_sha_req_ctx *state = out;
++
++  *state = *rctx;
++
++  return 0;
++}
++
++static int ccp_sha_import(struct ahash_request *req, const void *in)
++{
++  struct ccp_sha_req_ctx *rctx = ahash_request_ctx(req);
++  const struct ccp_sha_req_ctx *state = in;
++
++  *rctx = *state;
++
++  return 0;
++}
++
+ static int ccp_sha_setkey(struct crypto_ahash *tfm, const u8 *key,
+ unsigned int key_len)
+ {
+@@ -403,9 +423,12 @@ static int ccp_register_sha_alg(struct l
+   alg->final = ccp_sha_final;
+   alg->finup = ccp_sha_finup;
+   alg->digest = ccp_sha_digest;
++  alg->export = ccp_sha_export;
++  alg->import = ccp_sha_import;
+ 
+   halg = &alg->halg;
+   halg->digestsize = def->digest_size;
++  halg->statesize = sizeof(struct ccp_sha_req_ctx);
+ 
+   base = &halg->base;
+   snprintf(base->cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name);
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 1/3] kernel/modules: rename kmod-ipvti to kmod-ip-vti

2016-02-09 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/netsupport.mk | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/package/kernel/linux/modules/netsupport.mk 
b/package/kernel/linux/modules/netsupport.mk
index b1cce0b..cbf2ffb 100644
--- a/package/kernel/linux/modules/netsupport.mk
+++ b/package/kernel/linux/modules/netsupport.mk
@@ -404,7 +404,7 @@ endef
 $(eval $(call KernelPackage,iptunnel))
 
 
-define KernelPackage/ipvti
+define KernelPackage/ip-vti
   SUBMENU:=$(NETWORK_SUPPORT_MENU)
   TITLE:=IP VTI (Virtual Tunnel Interface)
   DEPENDS:=+kmod-iptunnel +kmod-iptunnel4 +kmod-ipsec4
@@ -413,11 +413,11 @@ define KernelPackage/ipvti
   AUTOLOAD:=$(call AutoLoad,33,ip_vti)
 endef
 
-define KernelPackage/ipvti/description
+define KernelPackage/ip-vti/description
  Kernel modules for IP VTI (Virtual Tunnel Interface)
 endef
 
-$(eval $(call KernelPackage,ipvti))
+$(eval $(call KernelPackage,ip-vti))
 
 
 define KernelPackage/iptunnel4
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 3/3] vti: fix kmod dependencies

2016-02-09 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/config/vti/Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/package/network/config/vti/Makefile 
b/package/network/config/vti/Makefile
index a81e889..7cf0ee9 100644
--- a/package/network/config/vti/Makefile
+++ b/package/network/config/vti/Makefile
@@ -32,7 +32,7 @@ endef
 define Package/vtiv4
 $(call Package/vti/Default)
   TITLE:=Virtual IPsec Tunnel Interface (IPv4) config support
-  DEPENDS:=@(PACKAGE_vti) +kmod-ip_vti
+  DEPENDS:=@(PACKAGE_vti) +kmod-ip-vti
 endef
 
 define Package/vtiv4/description
@@ -42,7 +42,7 @@ endef
 define Package/vtiv6
 $(call Package/vti/Default)
   TITLE:=Virtual IPsec Tunnel Interface (IPv6) config support
-  DEPENDS:=@(PACKAGE_vti) @IPV6 +kmod-ip6_vti
+  DEPENDS:=@(PACKAGE_vti) @IPV6 +kmod-ip6-vti
 endef
 
 define Package/vtiv6/description
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/3] kernel/modules: add kmod-ip6-vti

2016-02-09 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/netsupport.mk | 16 
 1 file changed, 16 insertions(+)

diff --git a/package/kernel/linux/modules/netsupport.mk 
b/package/kernel/linux/modules/netsupport.mk
index cbf2ffb..77bd67a 100644
--- a/package/kernel/linux/modules/netsupport.mk
+++ b/package/kernel/linux/modules/netsupport.mk
@@ -420,6 +420,22 @@ endef
 $(eval $(call KernelPackage,ip-vti))
 
 
+define KernelPackage/ip6-vti
+  SUBMENU:=$(NETWORK_SUPPORT_MENU)
+  TITLE:=IPv6 VTI (Virtual Tunnel Interface)
+  DEPENDS:=+kmod-iptunnel +kmod-ip6-tunnel +kmod-ipsec6
+  KCONFIG:=CONFIG_IPV6_VTI
+  FILES:=$(LINUX_DIR)/net/ipv6/ip6_vti.ko
+  AUTOLOAD:=$(call AutoLoad,33,ip6_vti)
+endef
+
+define KernelPackage/ip6-vti/description
+ Kernel modules for IPv6 VTI (Virtual Tunnel Interface)
+endef
+
+$(eval $(call KernelPackage,ip6-vti))
+
+
 define KernelPackage/iptunnel4
   SUBMENU:=$(NETWORK_SUPPORT_MENU)
   TITLE:=IPv4 tunneling
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] VXLAN support

2016-03-06 Thread Stijn Tintel
On 01-09-14 08:55, Jiri Pirko wrote:
> Mon, Sep 01, 2014 at 03:57:19AM CEST, ka...@stratosphere.co.jp wrote:
>> Hi,
>>
>> There's a vxlan kernel module in Linux source tree,
>> and `ip` command can create vxlan netdev.
>> Are you talking about netifd support for it?
> Yes, I am. See below...
Have you started working on this yet? If so, do you have any code to test?

Thanks,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 00/10] make symlink /var to /tmp optional

2016-03-28 Thread Stijn Tintel
When running OpenWrt on devices with a lot of storage, it might be
desirable not to have /var completely on tmpfs.

This patch series adds an option to make symlinking /var to /tmp
optional. If the option is disabled, /var/run will be symlinked to
/tmp/run so that it will still be on tmpfs.

As some init scripts generate a config file in /var/etc, change those
init scripts to generate it in /tmp/etc instead.

While at it, create /tmp/etc in /etc/init.d/boot instead of creating it
in various init scripts.

Stijn Tintel (10):
  base-files: create /tmp/etc on boot
  dnsmasq: generate config in /tmp/etc
  igmpproxy: generate config in /tmp/etc
  igmpproxy: /tmp/etc is created in /etc/init.d/boot
  openvpn: generate config in /tmp/etc
  openvpn: /tmp/etc is created in /etc/init.d/boot
  openvpn: /var/run is created in /etc/init.d/boot
  samba36: generate config in /tmp/etc
  samba36: /tmp/etc is created in /etc/init.d/boot
  base-files: add option to symlink /var to /tmp

 config/Config-images.in |  5 +
 package/base-files/Makefile |  5 +
 package/base-files/files/etc/init.d/boot|  1 +
 package/network/services/dnsmasq/files/dnsmasq.init |  2 +-
 .../network/services/igmpproxy/files/igmpproxy.init | 13 ++---
 package/network/services/openvpn/files/openvpn.init | 13 +
 package/network/services/samba36/files/samba.init   | 21 ++---
 7 files changed, 33 insertions(+), 27 deletions(-)

-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 01/10] base-files: create /tmp/etc on boot

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/base-files/files/etc/init.d/boot | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/base-files/files/etc/init.d/boot 
b/package/base-files/files/etc/init.d/boot
index ccd0afe..944c873 100755
--- a/package/base-files/files/etc/init.d/boot
+++ b/package/base-files/files/etc/init.d/boot
@@ -27,6 +27,7 @@ boot() {
mkdir -p /var/lock
mkdir -p /var/state
mkdir -p /var/tmp
+   mkdir -p /tmp/etc
mkdir -p /tmp/.uci
chmod 0700 /tmp/.uci
touch /var/log/wtmp
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 02/10] dnsmasq: generate config in /tmp/etc

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/services/dnsmasq/files/dnsmasq.init | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package/network/services/dnsmasq/files/dnsmasq.init 
b/package/network/services/dnsmasq/files/dnsmasq.init
index 61ded6a..54cd6e5 100644
--- a/package/network/services/dnsmasq/files/dnsmasq.init
+++ b/package/network/services/dnsmasq/files/dnsmasq.init
@@ -12,7 +12,7 @@ DOMAIN=""
 ADD_LOCAL_DOMAIN=1
 ADD_LOCAL_HOSTNAME=1
 
-CONFIGFILE="/var/etc/dnsmasq.conf"
+CONFIGFILE="/tmp/etc/dnsmasq.conf"
 HOSTFILE="/tmp/hosts/dhcp"
 TRUSTANCHORSFILE="/usr/share/dnsmasq/trust-anchors.conf"
 TIMESTAMPFILE="/etc/dnsmasq.time"
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 04/10] igmpproxy: /tmp/etc is created in /etc/init.d/boot

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/services/igmpproxy/files/igmpproxy.init | 1 -
 1 file changed, 1 deletion(-)

diff --git a/package/network/services/igmpproxy/files/igmpproxy.init 
b/package/network/services/igmpproxy/files/igmpproxy.init
index 7af69e3..b603921 100644
--- a/package/network/services/igmpproxy/files/igmpproxy.init
+++ b/package/network/services/igmpproxy/files/igmpproxy.init
@@ -25,7 +25,6 @@ igmp_header() {
local quickleave
config_get_bool quickleave "$1" quickleave 0
 
-   mkdir -p /tmp/etc
rm -f /tmp/etc/igmpproxy.conf
[ $quickleave -gt 0 ] && echo "quickleave" >> /tmp/etc/igmpproxy.conf
 
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 03/10] igmpproxy: generate config in /tmp/etc

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/services/igmpproxy/files/igmpproxy.init | 14 +++---
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/package/network/services/igmpproxy/files/igmpproxy.init 
b/package/network/services/igmpproxy/files/igmpproxy.init
index d03f90f..7af69e3 100644
--- a/package/network/services/igmpproxy/files/igmpproxy.init
+++ b/package/network/services/igmpproxy/files/igmpproxy.init
@@ -4,7 +4,7 @@
 START=99
 USE_PROCD=1
 PROG=/usr/sbin/igmpproxy
-CONFIGFILE=/var/etc/igmpproxy.conf
+CONFIGFILE=/tmp/etc/igmpproxy.conf
 
 # igmpproxy supports both a debug mode and verbosity, which are very useful
 # when something isn't working.
@@ -25,11 +25,11 @@ igmp_header() {
local quickleave
config_get_bool quickleave "$1" quickleave 0
 
-   mkdir -p /var/etc
-   rm -f /var/etc/igmpproxy.conf
-   [ $quickleave -gt 0 ] && echo "quickleave" >> /var/etc/igmpproxy.conf
+   mkdir -p /tmp/etc
+   rm -f /tmp/etc/igmpproxy.conf
+   [ $quickleave -gt 0 ] && echo "quickleave" >> /tmp/etc/igmpproxy.conf
 
-   [ -L /etc/igmpproxy.conf ] || ln -nsf /var/etc/igmpproxy.conf 
/etc/igmpproxy.conf
+   [ -L /etc/igmpproxy.conf ] || ln -nsf /tmp/etc/igmpproxy.conf 
/etc/igmpproxy.conf
 }
 
 igmp_add_phyint() {
@@ -55,12 +55,12 @@ igmp_add_phyint() {
 
[[ "$direction" = "upstream" ]] && has_upstream=1
 
-   echo -e "\nphyint $device $direction ratelimit 0 threshold 1" >> 
/var/etc/igmpproxy.conf
+   echo -e "\nphyint $device $direction ratelimit 0 threshold 1" >> 
/tmp/etc/igmpproxy.conf
 
if [ -n "$altnets" ]; then
local altnet
for altnet in $altnets; do
-   echo -e "\taltnet $altnet" >> /var/etc/igmpproxy.conf
+   echo -e "\taltnet $altnet" >> /tmp/etc/igmpproxy.conf
done
fi
 }
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 05/10] openvpn: generate config in /tmp/etc

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/services/openvpn/files/openvpn.init | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/package/network/services/openvpn/files/openvpn.init 
b/package/network/services/openvpn/files/openvpn.init
index 5396d0b..7ee756d 100644
--- a/package/network/services/openvpn/files/openvpn.init
+++ b/package/network/services/openvpn/files/openvpn.init
@@ -24,7 +24,7 @@ append_param() {
*_*_*)   v=${v%%_*}-${v#*_}; v=${v%%_*}-${v#*_} ;;
*_*) v=${v%%_*}-${v#*_} ;;
esac
-   echo -n "$v" >> "/var/etc/openvpn-$s.conf"
+   echo -n "$v" >> "/tmp/etc/openvpn-$s.conf"
return 0
 }
 
@@ -32,7 +32,7 @@ append_bools() {
local p; local v; local s="$1"; shift
for p in $*; do
config_get_bool v "$s" "$p"
-   [ "$v" = 1 ] && append_param "$s" "$p" && echo >> 
"/var/etc/openvpn-$s.conf"
+   [ "$v" = 1 ] && append_param "$s" "$p" && echo >> 
"/tmp/etc/openvpn-$s.conf"
done
 }
 
@@ -42,7 +42,7 @@ append_params() {
config_get v "$s" "$p"
IFS="$LIST_SEP"
for v in $v; do
-   [ -n "$v" ] && append_param "$s" "$p" && echo " $v" >> 
"/var/etc/openvpn-$s.conf"
+   [ -n "$v" ] && append_param "$s" "$p" && echo " $v" >> 
"/tmp/etc/openvpn-$s.conf"
done
unset IFS
done
@@ -89,8 +89,8 @@ start_instance() {
return
fi
 
-   [ ! -d "/var/etc" ] && mkdir -p "/var/etc"
-   [ -f "/var/etc/openvpn-$s.conf" ] && rm "/var/etc/openvpn-$s.conf"
+   [ ! -d "/tmp/etc" ] && mkdir -p "/tmp/etc"
+   [ -f "/tmp/etc/openvpn-$s.conf" ] && rm "/tmp/etc/openvpn-$s.conf"
 
# append flags
append_bools "$s" \
@@ -127,7 +127,7 @@ start_instance() {
verify_x509_name x509_username_field \
ifconfig_ipv6 route_ipv6 server_ipv6 ifconfig_ipv6_pool 
ifconfig_ipv6_push iroute_ipv6
 
-   openvpn_add_instance "$s" "/var/etc" "openvpn-$s.conf"
+   openvpn_add_instance "$s" "/tmp/etc" "openvpn-$s.conf"
 }
 
 start_service() {
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 07/10] openvpn: /var/run is created in /etc/init.d/boot

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/services/openvpn/files/openvpn.init | 2 --
 1 file changed, 2 deletions(-)

diff --git a/package/network/services/openvpn/files/openvpn.init 
b/package/network/services/openvpn/files/openvpn.init
index 221704e..5ca02ac 100644
--- a/package/network/services/openvpn/files/openvpn.init
+++ b/package/network/services/openvpn/files/openvpn.init
@@ -81,8 +81,6 @@ start_instance() {
return 1
}
 
-   [ ! -d "/var/run" ] && mkdir -p "/var/run"
-
if [ ! -z "$config" ]; then
append UCI_STARTED "$config" "$LIST_SEP"
openvpn_add_instance "$s" "${config%/*}" "$config"
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 08/10] samba36: generate config in /tmp/etc

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/services/samba36/files/samba.init | 22 +++---
 1 file changed, 11 insertions(+), 11 deletions(-)

diff --git a/package/network/services/samba36/files/samba.init 
b/package/network/services/samba36/files/samba.init
index 376ae89..f88e0f3 100755
--- a/package/network/services/samba36/files/samba.init
+++ b/package/network/services/samba36/files/samba.init
@@ -33,18 +33,18 @@ smb_header() {
config_get description $1 description "Samba on ${hostname:-OpenWrt}"
config_get charset $1 charset "UTF-8"
 
-   mkdir -p /var/etc
+   mkdir -p /tmp/etc
sed -e "s#|NAME|#$name#g" \
-e "s#|WORKGROUP|#$workgroup#g" \
-e "s#|DESCRIPTION|#$description#g" \
-e "s#|INTERFACES|#$interfaces#g" \
-e "s#|CHARSET|#$charset#g" \
-   /etc/samba/smb.conf.template > /var/etc/smb.conf
+   /etc/samba/smb.conf.template > /tmp/etc/smb.conf
 
local homes
config_get_bool homes $1 homes 0
[ $homes -gt 0 ] && {
-   cat <> /var/etc/smb.conf
+   cat <> /tmp/etc/smb.conf
 
 [homes]
comment = Home Directories
@@ -54,7 +54,7 @@ smb_header() {
 EOT
}
 
-   [ -L /etc/samba/smb.conf ] || ln -nsf /var/etc/smb.conf 
/etc/samba/smb.conf
+   [ -L /etc/samba/smb.conf ] || ln -nsf /tmp/etc/smb.conf 
/etc/samba/smb.conf
 }
 
 smb_add_share() {
@@ -78,13 +78,13 @@ smb_add_share() {
 
[ -z "$name" -o -z "$path" ] && return
 
-   echo -e "\n[$name]\n\tpath = $path" >> /var/etc/smb.conf
-   [ -n "$users" ] && echo -e "\tvalid users = $users" >> /var/etc/smb.conf
-   [ -n "$read_only" ] && echo -e "\tread only = $read_only" >> 
/var/etc/smb.conf
-   [ -n "$guest_ok" ] && echo -e "\tguest ok = $guest_ok" >> 
/var/etc/smb.conf
-   [ -n "$create_mask" ] && echo -e "\tcreate mask = $create_mask" >> 
/var/etc/smb.conf
-   [ -n "$dir_mask" ] && echo -e "\tdirectory mask = $dir_mask" >> 
/var/etc/smb.conf
-   [ -n "$browseable" ] && echo -e "\tbrowseable = $browseable" >> 
/var/etc/smb.conf
+   echo -e "\n[$name]\n\tpath = $path" >> /tmp/etc/smb.conf
+   [ -n "$users" ] && echo -e "\tvalid users = $users" >> /tmp/etc/smb.conf
+   [ -n "$read_only" ] && echo -e "\tread only = $read_only" >> 
/tmp/etc/smb.conf
+   [ -n "$guest_ok" ] && echo -e "\tguest ok = $guest_ok" >> 
/tmp/etc/smb.conf
+   [ -n "$create_mask" ] && echo -e "\tcreate mask = $create_mask" >> 
/tmp/etc/smb.conf
+   [ -n "$dir_mask" ] && echo -e "\tdirectory mask = $dir_mask" >> 
/tmp/etc/smb.conf
+   [ -n "$browseable" ] && echo -e "\tbrowseable = $browseable" >> 
/tmp/etc/smb.conf
 }
 
 init_config() {
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 06/10] openvpn: /tmp/etc is created in /etc/init.d/boot

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/services/openvpn/files/openvpn.init | 1 -
 1 file changed, 1 deletion(-)

diff --git a/package/network/services/openvpn/files/openvpn.init 
b/package/network/services/openvpn/files/openvpn.init
index 7ee756d..221704e 100644
--- a/package/network/services/openvpn/files/openvpn.init
+++ b/package/network/services/openvpn/files/openvpn.init
@@ -89,7 +89,6 @@ start_instance() {
return
fi
 
-   [ ! -d "/tmp/etc" ] && mkdir -p "/tmp/etc"
[ -f "/tmp/etc/openvpn-$s.conf" ] && rm "/tmp/etc/openvpn-$s.conf"
 
# append flags
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 09/10] samba36: /tmp/etc is created in /etc/init.d/boot

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/services/samba36/files/samba.init | 1 -
 1 file changed, 1 deletion(-)

diff --git a/package/network/services/samba36/files/samba.init 
b/package/network/services/samba36/files/samba.init
index f88e0f3..dceb6e5 100755
--- a/package/network/services/samba36/files/samba.init
+++ b/package/network/services/samba36/files/samba.init
@@ -33,7 +33,6 @@ smb_header() {
config_get description $1 description "Samba on ${hostname:-OpenWrt}"
config_get charset $1 charset "UTF-8"
 
-   mkdir -p /tmp/etc
sed -e "s#|NAME|#$name#g" \
-e "s#|WORKGROUP|#$workgroup#g" \
-e "s#|DESCRIPTION|#$description#g" \
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [RFC PATCH 10/10] base-files: add option to symlink /var to /tmp

2016-03-28 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 config/Config-images.in | 5 +
 package/base-files/Makefile | 5 +
 2 files changed, 10 insertions(+)

diff --git a/config/Config-images.in b/config/Config-images.in
index a60dd50..3619256 100644
--- a/config/Config-images.in
+++ b/config/Config-images.in
@@ -312,4 +312,9 @@ menu "Target Images"
  Include the device tree blob file(s) in the rootfs. Typically 
the DTBs
  are placed below /boot.
 
+   config TARGET_ROOTFS_LN_VAR_TMP
+   bool "Symlink /var to /tmp"
+   default y
+   help
+ Make /var a symlink to /tmp.
 endmenu
diff --git a/package/base-files/Makefile b/package/base-files/Makefile
index 8bb6225..aa7ed34 100644
--- a/package/base-files/Makefile
+++ b/package/base-files/Makefile
@@ -164,8 +164,13 @@ define Package/base-files/install
mkdir -p $(1)/www
mkdir -p $(1)/root
$(LN) /proc/mounts $(1)/etc/mtab
+ifeq ($(CONFIG_TARGET_ROOTFS_LN_VAR_TMP),y)
rm -f $(1)/var
$(LN) /tmp $(1)/var
+else
+   mkdir $(1)/var
+   $(LN) /tmp/run $(1)/var/run
+endif
mkdir -p $(1)/etc
$(LN) /tmp/resolv.conf /tmp/fstab /tmp/TZ /tmp/localtime $(1)/etc/
 
-- 
2.7.3
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] ar71xx: add 4.1 support

2015-10-17 Thread Stijn Tintel
On 17-07-15 19:35, Roman Yeryomin wrote:
> Signed-off-by: Roman Yeryomin 
> ---
>
Hi Roman,

Since ar71xx uses 4.1 kernel by default, MAC addresses on my Ubiquiti
RSPro's are random. I suspect it is due to the changes in
506-MIPS-ath79-prom-parse-redboot-args.patch. I reported the problem
here: https://dev.openwrt.org/ticket/20642. Do you mind having a look at it?

Thanks,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] ar71xx: add 4.1 support

2015-10-19 Thread Stijn Tintel
On 18-10-15 20:20, Roman Yeryomin wrote:
> On 18 October 2015 at 00:16, Stijn Tintel  wrote:
>> On 17-07-15 19:35, Roman Yeryomin wrote:
>>> Signed-off-by: Roman Yeryomin 
>>> ---
>>>
>> Hi Roman,
>>
>> Since ar71xx uses 4.1 kernel by default, MAC addresses on my Ubiquiti
>> RSPro's are random. I suspect it is due to the changes in
>> 506-MIPS-ath79-prom-parse-redboot-args.patch. I reported the problem
>> here: https://dev.openwrt.org/ticket/20642. Do you mind having a look at it?
> Those changes didn't affect functionality, it was a port to new prom API.
> Also seems you have the board correctly detected - it means prom code
> is working.
> Are you sure the bootloader is passing ethaddr as it should? Sorry, I
> don't have the hw to test.
>
The bootloader is passing it:

RedBoot> exec
Now booting linux kernel:
 Base address 0x8005 Entry 0x8006
 memsize=0x0800
 modetty0=0,n,8,1,hw
 board=RouterStation PRO
 ethaddr=00.15.6d.c3.31.57
[0.00] Linux version 4.1.10 (stijn@taz) (gcc version 4.8.3
(OpenWrt/Linaro GCC 4.8-2014.04 r47070) ) #1 Tue Oct 13 04:36:06 CEST 2015

And I don't have the problem with the 3.18 kernel, tested on 2 different
RSPro's.

Kind regards,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] kernel: Fix environment pointer setup in ar71xx/ath79

2015-10-21 Thread Stijn Tintel
On 21-10-15 17:53, Ted Hess wrote:
> Observed on ar71xx/ath79 platforms such as Ubiquiti RouterStations.Reported 
> in #20642.:
> (https://dev.openwrt.org/ticket/20642). 
>
> If embedded command-line text exists with CONFIG_IMAGE_CMDLINE_HACK=y,firmware
> init doesn't initialize environment pointer (fw_init_cmdline not called).
>
> arcs_cmdline is not initialized before calling strlcat.
>
> Signed-off-by: Ted Hess 
Tested-by: Stijn Tintel 
>
> ---
> Index: 
> target/linux/ar71xx/patches-4.1/508-MIPS-ath79-prom-image-command-line-hack.patch
> ===
> --- 
> a/target/linux/ar71xx/patches-4.1/508-MIPS-ath79-prom-image-command-line-hack.patch
> +++ 
> b/target/linux/ar71xx/patches-4.1/508-MIPS-ath79-prom-image-command-line-hack.patch
> @@ -1,6 +1,6 @@
>  --- a/arch/mips/ath79/prom.c
>  +++ b/arch/mips/ath79/prom.c
> -@@ -33,6 +33,35 @@ static void __init ath79_prom_append_cmd
> +@@ -33,6 +33,41 @@ static void __init ath79_prom_append_cmd
>   strlcat(arcs_cmdline, ath79_cmdline_buf, sizeof(arcs_cmdline));
>   }
>   
> @@ -27,6 +27,12 @@
>  +strlcat(arcs_cmdline, p, sizeof(arcs_cmdline));
>  +}
>  +
> ++/* Validate and setup environment pointer */
> ++if (fw_arg2 < CKSEG0)
> ++_fw_envp = NULL;
> ++else
> ++_fw_envp = (int *)fw_arg2;
> ++
>  +return 1;
>  +}
>  +#else
> @@ -36,7 +42,7 @@
>   static int __init ath79_prom_init_myloader(void)
>   {
>   struct myloader_info *mylo;
> -@@ -61,6 +90,8 @@ static int __init ath79_prom_init_myload
> +@@ -61,6 +96,8 @@ static int __init ath79_prom_init_myload
>   
>   ath79_prom_append_cmdline("ethaddr", mac_buf);
>   
> @@ -45,7 +51,7 @@
>   return 1;
>   }
>   
> -@@ -71,7 +102,8 @@ void __init prom_init(void)
> +@@ -71,7 +108,8 @@ void __init prom_init(void)
>   if (ath79_prom_init_myloader())
>   return;
>   
> @@ -55,3 +61,13 @@
>   
>   env = fw_getenv("ethaddr");
>   if (env)
> +--- a/arch/mips/fw/lib/cmdline.c
>  b/arch/mips/fw/lib/cmdline.c
> +@@ -35,6 +35,7 @@ void __init fw_init_cmdline(void)
> + else
> + _fw_envp = (int *)fw_arg2;
> + 
> ++arcs_cmdline[0] = '\0';
> + for (i = 1; i < fw_argc; i++) {
> + strlcat(arcs_cmdline, fw_argv(i), COMMAND_LINE_SIZE);
> + if (i < (fw_argc - 1))
> ___
> openwrt-devel mailing list
> openwrt-devel@lists.openwrt.org
> https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] iproute2: fix compile with uClibc-ng

2015-10-29 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/utils/iproute2/Makefile | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/package/network/utils/iproute2/Makefile 
b/package/network/utils/iproute2/Makefile
index 23834df..f5b5f4e 100644
--- a/package/network/utils/iproute2/Makefile
+++ b/package/network/utils/iproute2/Makefile
@@ -84,6 +84,9 @@ endif
 ifdef CONFIG_USE_MUSL
   TARGET_CFLAGS += -DHAVE_SETNS
 endif
+ifdef CONFIG_UCLIBC_USE_VERSION_NG
+  TARGET_CFLAGS += -DHAVE_SETNS
+endif
 
 TARGET_CFLAGS += -ffunction-sections -fdata-sections
 
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 1/4] base-files: add DCCP to /etc/protocols

2015-11-11 Thread Stijn Tintel
Fixes this conntrackd warning:
WARNING: getprotobyname() cannot find protocol `DCCP' in /etc/protocols

Signed-off-by: Stijn Tintel 
---
 package/base-files/files/etc/protocols | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/base-files/files/etc/protocols 
b/package/base-files/files/etc/protocols
index 53fecb6..26bc775 100644
--- a/package/base-files/files/etc/protocols
+++ b/package/base-files/files/etc/protocols
@@ -22,6 +22,7 @@ hmp   20  HMP # host monitoring protocol
 xns-idp22  XNS-IDP # Xerox NS IDP
 rdp27  RDP # "reliable datagram" protocol
 iso-tp429  ISO-TP4 # ISO Transport Protocol class 4 
[RFC905]
+dccp   33  DCCP# Datagram Congestion Control Protocol [RFC4340]
 xtp36  XTP # Xpress Transfer Protocol
 ddp37  DDP # Datagram Delivery Protocol
 idpr-cmtp 38   IDPR-CMTP   # IDPR Control Message Transport
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/4] conntrack-tools: use INSTALL_DIR once

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/utils/conntrack-tools/Makefile | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/package/network/utils/conntrack-tools/Makefile 
b/package/network/utils/conntrack-tools/Makefile
index 7dd64b6..b931d85 100644
--- a/package/network/utils/conntrack-tools/Makefile
+++ b/package/network/utils/conntrack-tools/Makefile
@@ -68,9 +68,10 @@ define Package/conntrackd/description
 endef
 
 define Package/conntrackd/install
-   $(INSTALL_DIR) $(1)/usr/sbin
+   $(INSTALL_DIR) \
+   $(1)/etc/init.d \
+   $(1)/usr/sbin
$(INSTALL_BIN)  $(PKG_INSTALL_DIR)/usr/sbin/conntrackd $(1)/usr/sbin/
-   $(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/conntrackd.init $(1)/etc/init.d/conntrackd
 endef
 
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 4/4] conntrack-tools: preserve /etc/conntrackd during upgrade

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/utils/conntrack-tools/Makefile | 2 ++
 package/network/utils/conntrack-tools/files/conntrackd.upgrade | 1 +
 2 files changed, 3 insertions(+)
 create mode 100644 
package/network/utils/conntrack-tools/files/conntrackd.upgrade

diff --git a/package/network/utils/conntrack-tools/Makefile 
b/package/network/utils/conntrack-tools/Makefile
index 51d3c41..a7a28f2 100644
--- a/package/network/utils/conntrack-tools/Makefile
+++ b/package/network/utils/conntrack-tools/Makefile
@@ -71,9 +71,11 @@ define Package/conntrackd/install
$(INSTALL_DIR) \
$(1)/etc/conntrackd \
$(1)/etc/init.d \
+   $(1)/lib/upgrade/keep.d \
$(1)/usr/sbin
$(INSTALL_BIN)  $(PKG_INSTALL_DIR)/usr/sbin/conntrackd $(1)/usr/sbin/
$(INSTALL_BIN) ./files/conntrackd.init $(1)/etc/init.d/conntrackd
+   $(INSTALL_DATA) ./files/conntrackd.upgrade 
$(1)/lib/upgrade/keep.d/conntrackd
 endef
 
 $(eval $(call BuildPackage,conntrack))
diff --git a/package/network/utils/conntrack-tools/files/conntrackd.upgrade 
b/package/network/utils/conntrack-tools/files/conntrackd.upgrade
new file mode 100644
index 000..bcff8a2
--- /dev/null
+++ b/package/network/utils/conntrack-tools/files/conntrackd.upgrade
@@ -0,0 +1 @@
+/etc/conntrackd/
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 3/4] conntrack-tools: create /etc/conntrackd directory

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/utils/conntrack-tools/Makefile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/network/utils/conntrack-tools/Makefile 
b/package/network/utils/conntrack-tools/Makefile
index b931d85..51d3c41 100644
--- a/package/network/utils/conntrack-tools/Makefile
+++ b/package/network/utils/conntrack-tools/Makefile
@@ -69,6 +69,7 @@ endef
 
 define Package/conntrackd/install
$(INSTALL_DIR) \
+   $(1)/etc/conntrackd \
$(1)/etc/init.d \
$(1)/usr/sbin
$(INSTALL_BIN)  $(PKG_INSTALL_DIR)/usr/sbin/conntrackd $(1)/usr/sbin/
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 02/10] kernel: add patch to fix prefsrc lookups

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 .../patches-4.3/192-net-Fix-presrc-lookups.patch   | 60 ++
 1 file changed, 60 insertions(+)
 create mode 100644 
target/linux/generic/patches-4.3/192-net-Fix-presrc-lookups.patch

diff --git a/target/linux/generic/patches-4.3/192-net-Fix-presrc-lookups.patch 
b/target/linux/generic/patches-4.3/192-net-Fix-presrc-lookups.patch
new file mode 100644
index 000..8a05083
--- /dev/null
+++ b/target/linux/generic/patches-4.3/192-net-Fix-presrc-lookups.patch
@@ -0,0 +1,60 @@
+From patchwork Tue Nov  3 23:59:28 2015
+Content-Type: text/plain; charset="utf-8"
+MIME-Version: 1.0
+Content-Transfer-Encoding: 7bit
+Subject: net: Fix prefsrc lookups
+From: David Ahern 
+X-Patchwork-Id: 539645
+Message-Id: <1446595168-27323-1-git-send-email-...@cumulusnetworks.com>
+To: net...@vger.kernel.org
+Cc: vl...@aresgate.net, David Ahern 
+Date: Tue,  3 Nov 2015 15:59:28 -0800
+
+A bug report (https://bugzilla.kernel.org/show_bug.cgi?id=107071) noted
+that the follwoing ip command is failing with v4.3:
+
+$ ip route add 10.248.5.0/24 dev bond0.250 table vlan_250 src 10.248.5.154
+RTNETLINK answers: Invalid argument
+
+021dd3b8a142d changed the lookup of the given preferred source address to
+use the table id passed in, but this assumes the local entries are in the
+given table which is not necessarily true for non-VRF use cases. When
+validating the preferred source fallback to the local table on failure.
+
+Fixes: 021dd3b8a142d ("net: Add routes to the table associated with the 
device")
+Signed-off-by: David Ahern 
+---
+This is needed in v4.3.
+
+ net/ipv4/fib_semantics.c | 13 ++---
+ 1 file changed, 10 insertions(+), 3 deletions(-)
+
+diff --git a/net/ipv4/fib_semantics.c b/net/ipv4/fib_semantics.c
+index 064bd3caaa4f..aac966f6162f 100644
+--- a/net/ipv4/fib_semantics.c
 b/net/ipv4/fib_semantics.c
+@@ -864,14 +864,21 @@ static bool fib_valid_prefsrc(struct fib_config *cfg, 
__be32 fib_prefsrc)
+   if (cfg->fc_type != RTN_LOCAL || !cfg->fc_dst ||
+   fib_prefsrc != cfg->fc_dst) {
+   u32 tb_id = cfg->fc_table;
++  int rc;
+ 
+   if (tb_id == RT_TABLE_MAIN)
+   tb_id = RT_TABLE_LOCAL;
+ 
+-  if (inet_addr_type_table(cfg->fc_nlinfo.nl_net,
+-   fib_prefsrc, tb_id) != RTN_LOCAL) {
+-  return false;
++  rc = inet_addr_type_table(cfg->fc_nlinfo.nl_net,
++fib_prefsrc, tb_id);
++
++  if (rc != RTN_LOCAL && tb_id != RT_TABLE_LOCAL) {
++  rc = inet_addr_type_table(cfg->fc_nlinfo.nl_net,
++fib_prefsrc, RT_TABLE_LOCAL);
+   }
++
++  if (rc != RTN_LOCAL)
++  return false;
+   }
+   return true;
+ }
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 01/10] xtables-addons: update to 2.9

2015-11-11 Thread Stijn Tintel
Fixes compilation with Linux 4.3. Runtime tested on Ubiquiti EdgeRouter
Lite with Linux 3.18, 4.1 and 4.3.

Signed-off-by: Stijn Tintel 
---
 package/network/utils/xtables-addons/Makefile | 4 ++--
 .../network/utils/xtables-addons/patches/100-add-rtsp-conntrack.patch | 2 +-
 .../utils/xtables-addons/patches/200-add-lua-packetscript.patch   | 2 +-
 .../utils/xtables-addons/patches/201-fix-lua-packetscript.patch   | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/package/network/utils/xtables-addons/Makefile 
b/package/network/utils/xtables-addons/Makefile
index ff6466f..5cfe7b5 100644
--- a/package/network/utils/xtables-addons/Makefile
+++ b/package/network/utils/xtables-addons/Makefile
@@ -9,9 +9,9 @@ include $(TOPDIR)/rules.mk
 include $(INCLUDE_DIR)/kernel.mk
 
 PKG_NAME:=xtables-addons
-PKG_VERSION:=2.7
+PKG_VERSION:=2.9
 PKG_RELEASE:=1
-PKG_MD5SUM:=81bd7ba82e5f7bfd1458fc97ddf72e1d
+PKG_MD5SUM:=87df49f3804036eccd4619f566d26bb3
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=@SF/xtables-addons
diff --git 
a/package/network/utils/xtables-addons/patches/100-add-rtsp-conntrack.patch 
b/package/network/utils/xtables-addons/patches/100-add-rtsp-conntrack.patch
index 6c169ee..bd49d92 100644
--- a/package/network/utils/xtables-addons/patches/100-add-rtsp-conntrack.patch
+++ b/package/network/utils/xtables-addons/patches/100-add-rtsp-conntrack.patch
@@ -1509,7 +1509,7 @@
 +module_exit(fini);
 --- a/extensions/Kbuild
 +++ b/extensions/Kbuild
-@@ -28,6 +28,7 @@ obj-${build_lscan}   += xt_lscan.o
+@@ -26,6 +26,7 @@ obj-${build_lscan}   += xt_lscan.o
  obj-${build_pknock}  += pknock/
  obj-${build_psd} += xt_psd.o
  obj-${build_quota2}  += xt_quota2.o
diff --git 
a/package/network/utils/xtables-addons/patches/200-add-lua-packetscript.patch 
b/package/network/utils/xtables-addons/patches/200-add-lua-packetscript.patch
index 8bc30a7..33d0d74 100644
--- 
a/package/network/utils/xtables-addons/patches/200-add-lua-packetscript.patch
+++ 
b/package/network/utils/xtables-addons/patches/200-add-lua-packetscript.patch
@@ -18134,7 +18134,7 @@
 +
 --- a/extensions/Kbuild
 +++ b/extensions/Kbuild
-@@ -29,6 +29,7 @@ obj-${build_pknock}  += pknock/
+@@ -27,6 +27,7 @@ obj-${build_pknock}  += pknock/
  obj-${build_psd} += xt_psd.o
  obj-${build_quota2}  += xt_quota2.o
  obj-${build_rtsp}+= rtsp/
diff --git 
a/package/network/utils/xtables-addons/patches/201-fix-lua-packetscript.patch 
b/package/network/utils/xtables-addons/patches/201-fix-lua-packetscript.patch
index 966d29d..06a4a17 100644
--- 
a/package/network/utils/xtables-addons/patches/201-fix-lua-packetscript.patch
+++ 
b/package/network/utils/xtables-addons/patches/201-fix-lua-packetscript.patch
@@ -78,7 +78,7 @@
  #define UCHAR_MAX 255
  #define SHRT_MAX32767
  #define BUFSIZ8192
-@@ -637,6 +641,8 @@ union luai_Cast { double l_d; long l_l; 
+@@ -637,6 +641,8 @@ union luai_Cast { double l_d; long l_l;
  */
  #if defined(__KERNEL__)
  #undef LUA_USE_ULONGJMP
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 05/10] octeon: remove 3.18 support

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/config-3.18|  250 ---
 .../100-ubnt_edgerouter2_support.patch |   31 -
 .../110-er200-ethernet_probe_order.patch   |   34 -
 .../patches-3.18/120-octeon_platform_usb.patch |   20 -
 ...add-semaphore-to-serialize-bootbus-access.patch |   21 -
 ...N-Update-octeon-model.h-code-for-new-SoCs.patch |  103 --
 ...add-host-driver-for-octeon-mmc-controller.patch | 1622 
 .../octeon/patches-3.18/160-cmdline-hack.patch |   47 -
 8 files changed, 2128 deletions(-)
 delete mode 100644 target/linux/octeon/config-3.18
 delete mode 100644 
target/linux/octeon/patches-3.18/100-ubnt_edgerouter2_support.patch
 delete mode 100644 
target/linux/octeon/patches-3.18/110-er200-ethernet_probe_order.patch
 delete mode 100644 
target/linux/octeon/patches-3.18/120-octeon_platform_usb.patch
 delete mode 100644 
target/linux/octeon/patches-3.18/130-MIPS-octeon-add-semaphore-to-serialize-bootbus-access.patch
 delete mode 100644 
target/linux/octeon/patches-3.18/140-MIPS-OCTEON-Update-octeon-model.h-code-for-new-SoCs.patch
 delete mode 100644 
target/linux/octeon/patches-3.18/150-mmc-octeon-add-host-driver-for-octeon-mmc-controller.patch
 delete mode 100644 target/linux/octeon/patches-3.18/160-cmdline-hack.patch

diff --git a/target/linux/octeon/config-3.18 b/target/linux/octeon/config-3.18
deleted file mode 100644
index 44a154a..000
--- a/target/linux/octeon/config-3.18
+++ /dev/null
@@ -1,250 +0,0 @@
-CONFIG_64BIT=y
-CONFIG_64BIT_PHYS_ADDR=y
-CONFIG_ARCH_BINFMT_ELF_RANDOMIZE_PIE=y
-CONFIG_ARCH_DISCARD_MEMBLOCK=y
-CONFIG_ARCH_DMA_ADDR_T_64BIT=y
-CONFIG_ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE=y
-# CONFIG_ARCH_HAS_SG_CHAIN is not set
-CONFIG_ARCH_HAVE_CUSTOM_GPIO_H=y
-CONFIG_ARCH_HIBERNATION_POSSIBLE=y
-CONFIG_ARCH_MIGHT_HAVE_PC_PARPORT=y
-CONFIG_ARCH_MIGHT_HAVE_PC_SERIO=y
-CONFIG_ARCH_PHYS_ADDR_T_64BIT=y
-CONFIG_ARCH_REQUIRE_GPIOLIB=y
-CONFIG_ARCH_SPARSEMEM_ENABLE=y
-CONFIG_ARCH_SUSPEND_POSSIBLE=y
-CONFIG_ARCH_WANT_COMPAT_IPC_PARSE_VERSION=y
-CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y
-CONFIG_ARCH_WANT_OLD_COMPAT_IPC=y
-CONFIG_BINFMT_ELF32=y
-CONFIG_BLK_DEV_SD=y
-CONFIG_BLOCK_COMPAT=y
-# CONFIG_BOOTPARAM_HUNG_TASK_PANIC is not set
-CONFIG_BOOTPARAM_HUNG_TASK_PANIC_VALUE=0
-CONFIG_BUILTIN_DTB=y
-# CONFIG_CAVIUM_CN63XXP1 is not set
-# CONFIG_CAVIUM_OCTEON_2ND_KERNEL is not set
-CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE=2
-CONFIG_CAVIUM_OCTEON_LOCK_L2=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_EXCEPTION=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_INTERRUPT=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_LOW_LEVEL_INTERRUPT=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_MEMCPY=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_TLB=y
-CONFIG_CAVIUM_OCTEON_SOC=y
-CONFIG_CC_OPTIMIZE_FOR_SIZE=y
-CONFIG_CEVT_R4K=y
-CONFIG_CLONE_BACKWARDS=y
-CONFIG_COMPAT=y
-CONFIG_COMPAT_BRK=y
-CONFIG_COMPAT_NETLINK_MESSAGES=y
-CONFIG_CPU_BIG_ENDIAN=y
-CONFIG_CPU_CAVIUM_OCTEON=y
-CONFIG_CPU_GENERIC_DUMP_TLB=y
-CONFIG_CPU_HAS_PREFETCH=y
-CONFIG_CPU_HAS_SYNC=y
-CONFIG_CPU_MIPSR2=y
-CONFIG_CPU_NEEDS_NO_SMARTMIPS_OR_MICROMIPS=y
-CONFIG_CPU_RMAP=y
-CONFIG_CPU_SUPPORTS_64BIT_KERNEL=y
-CONFIG_CPU_SUPPORTS_HIGHMEM=y
-CONFIG_CPU_SUPPORTS_HUGEPAGES=y
-CONFIG_CRAMFS=y
-CONFIG_CRC16=y
-CONFIG_CRYPTO_CRC32C=y
-CONFIG_CRYPTO_HASH=y
-CONFIG_CRYPTO_HASH2=y
-CONFIG_DEBUG_INFO=y
-CONFIG_DEBUG_SPINLOCK=y
-CONFIG_DEFAULT_HUNG_TASK_TIMEOUT=120
-CONFIG_DETECT_HUNG_TASK=y
-CONFIG_DEVKMEM=y
-CONFIG_DMA_COHERENT=y
-CONFIG_DNOTIFY=y
-CONFIG_DTC=y
-CONFIG_EARLY_PRINTK=y
-CONFIG_EDAC_SUPPORT=y
-CONFIG_ENABLE_MUST_CHECK=y
-CONFIG_EXT4_FS=y
-CONFIG_FAT_FS=y
-CONFIG_FRAME_WARN=2048
-CONFIG_FS_MBCACHE=y
-CONFIG_GENERIC_CLOCKEVENTS=y
-CONFIG_GENERIC_CLOCKEVENTS_BUILD=y
-CONFIG_GENERIC_CMOS_UPDATE=y
-CONFIG_GENERIC_IO=y
-CONFIG_GENERIC_IRQ_SHOW=y
-CONFIG_GENERIC_PCI_IOMAP=y
-CONFIG_GENERIC_SMP_IDLE_THREAD=y
-CONFIG_GPIOLIB=y
-CONFIG_GPIO_DEVRES=y
-CONFIG_GPIO_OCTEON=y
-CONFIG_GPIO_SYSFS=y
-CONFIG_HARDWARE_WATCHPOINTS=y
-CONFIG_HAS_DMA=y
-CONFIG_HAS_IOMEM=y
-CONFIG_HAS_IOPORT_MAP=y
-CONFIG_HAVE_64BIT_ALIGNED_ACCESS=y
-CONFIG_HAVE_ARCH_JUMP_LABEL=y
-CONFIG_HAVE_ARCH_KGDB=y
-CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
-CONFIG_HAVE_ARCH_TRACEHOOK=y
-CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y
-# CONFIG_HAVE_BOOTMEM_INFO_NODE is not set
-CONFIG_HAVE_BPF_JIT=y
-CONFIG_HAVE_CC_STACKPROTECTOR=y
-CONFIG_HAVE_CONTEXT_TRACKING=y
-CONFIG_HAVE_C_RECORDMCOUNT=y
-CONFIG_HAVE_DEBUG_KMEMLEAK=y
-CONFIG_HAVE_DEBUG_STACKOVERFLOW=y
-CONFIG_HAVE_DMA_API_DEBUG=y
-CONFIG_HAVE_DMA_ATTRS=y
-CONFIG_HAVE_DMA_CONTIGUOUS=y
-CONFIG_HAVE_DYNAMIC_FTRACE=y
-CONFIG_HAVE_FTRACE_MCOUNT_RECORD=y
-CONFIG_HAVE_FUNCTION_GRAPH_TRACER=y
-CONFIG_HAVE_FUNCTION_TRACER=y
-CONFIG_HAVE_GENERIC_DMA_COHERENT=y
-CONFIG_HAVE_IDE=y
-CONFIG_HAVE_MEMBLOCK=y
-CONFIG_HAVE_MEMBLOCK_NODE_MAP=y
-CONFIG_HAVE_MEMORY_PRESENT=y
-CONFIG_HAVE_MOD_ARCH_SPECIFIC=y
-CONFIG_HAVE_NET_DSA=y
-CONFIG_HAVE_OPROFILE=y
-CONFIG_HAVE_PERF_EVENTS=y
-CONFIG_HAVE_SYSCALL_TRACEPOINTS=y
-CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
-# CONFIG_HIGH_RES_TIMERS is not set

[OpenWrt-Devel] [PATCH 04/10] octeon: switch to 4.3

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/target/linux/octeon/Makefile b/target/linux/octeon/Makefile
index e1739e7..a6707f0 100644
--- a/target/linux/octeon/Makefile
+++ b/target/linux/octeon/Makefile
@@ -14,7 +14,7 @@ CPU_TYPE:=octeon
 CPU_CFLAGS_octeon:=-march=octeon -mabi=64
 MAINTAINER:=John Crispin 
 
-KERNEL_PATCHVER:=3.18
+KERNEL_PATCHVER:=4.3
 
 include $(INCLUDE_DIR)/target.mk
 
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 06/10] kernel/modules: add OCTEON MD5 module

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/crypto.mk | 9 -
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index 20fc858..0981102 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -442,12 +442,19 @@ $(eval $(call KernelPackage,crypto-md4))
 define KernelPackage/crypto-md5
   TITLE:=MD5 digest CryptoAPI module
   DEPENDS:=+kmod-crypto-hash
-  KCONFIG:=CONFIG_CRYPTO_MD5
+  KCONFIG:= \
+   CONFIG_CRYPTO_MD5 \
+   CONFIG_CRYPTO_MD5_OCTEON
   FILES:=$(LINUX_DIR)/crypto/md5.ko
   AUTOLOAD:=$(call AutoLoad,09,md5)
   $(call AddDepends/crypto)
 endef
 
+define KernelPackage/crypto-md5/octeon
+  FILES+=$(LINUX_DIR)/arch/mips/cavium-octeon/crypto/octeon-md5.ko
+  AUTOLOAD:=$(call AutoLoad,09,octeon-md5)
+endef
+
 $(eval $(call KernelPackage,crypto-md5))
 
 
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 07/10] kernel/modules: add OCTEON SHA1 module

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/crypto.mk | 9 -
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index 0981102..f5c5895 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -473,12 +473,19 @@ $(eval $(call KernelPackage,crypto-michael-mic))
 define KernelPackage/crypto-sha1
   TITLE:=SHA1 digest CryptoAPI module
   DEPENDS:=+kmod-crypto-hash
-  KCONFIG:=CONFIG_CRYPTO_SHA1
+  KCONFIG:= \
+   CONFIG_CRYPTO_SHA1 \
+   CONFIG_CRYPTO_SHA1_OCTEON
   FILES:=$(LINUX_DIR)/crypto/sha1_generic.ko
   AUTOLOAD:=$(call AutoLoad,09,sha1_generic)
   $(call AddDepends/crypto)
 endef
 
+define KernelPackage/crypto-sha1/octeon
+  FILES+=$(LINUX_DIR)/arch/mips/cavium-octeon/crypto/octeon-sha1.ko
+  AUTOLOAD:=$(call AutoLoad,09,octeon-sha1)
+endef
+
 $(eval $(call KernelPackage,crypto-sha1))
 
 
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 03/10] octeon: add support for 4.3

2015-11-11 Thread Stijn Tintel
Runtime tested on Ubiquiti EdgeRouter Lite.

Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/config-4.3 |  280 
 .../patches-4.3/100-ubnt_edgerouter2_support.patch |   31 +
 .../110-er200-ethernet_probe_order.patch   |   34 +
 ...add-host-driver-for-octeon-mmc-controller.patch | 1622 
 .../octeon/patches-4.3/160-cmdline-hack.patch  |   47 +
 5 files changed, 2014 insertions(+)
 create mode 100644 target/linux/octeon/config-4.3
 create mode 100644 
target/linux/octeon/patches-4.3/100-ubnt_edgerouter2_support.patch
 create mode 100644 
target/linux/octeon/patches-4.3/110-er200-ethernet_probe_order.patch
 create mode 100644 
target/linux/octeon/patches-4.3/150-mmc-octeon-add-host-driver-for-octeon-mmc-controller.patch
 create mode 100644 target/linux/octeon/patches-4.3/160-cmdline-hack.patch

diff --git a/target/linux/octeon/config-4.3 b/target/linux/octeon/config-4.3
new file mode 100644
index 000..f8702f5
--- /dev/null
+++ b/target/linux/octeon/config-4.3
@@ -0,0 +1,280 @@
+CONFIG_64BIT=y
+CONFIG_ARCH_BINFMT_ELF_STATE=y
+CONFIG_ARCH_DISCARD_MEMBLOCK=y
+CONFIG_ARCH_DMA_ADDR_T_64BIT=y
+CONFIG_ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE=y
+CONFIG_ARCH_HAS_ELF_RANDOMIZE=y
+# CONFIG_ARCH_HAS_GCOV_PROFILE_ALL is not set
+# CONFIG_ARCH_HAS_SG_CHAIN is not set
+CONFIG_ARCH_HIBERNATION_POSSIBLE=y
+CONFIG_ARCH_MIGHT_HAVE_PC_PARPORT=y
+CONFIG_ARCH_MIGHT_HAVE_PC_SERIO=y
+CONFIG_ARCH_PHYS_ADDR_T_64BIT=y
+CONFIG_ARCH_REQUIRE_GPIOLIB=y
+CONFIG_ARCH_SPARSEMEM_ENABLE=y
+CONFIG_ARCH_SUPPORTS_UPROBES=y
+CONFIG_ARCH_SUSPEND_POSSIBLE=y
+CONFIG_ARCH_USE_CMPXCHG_LOCKREF=y
+CONFIG_ARCH_WANT_COMPAT_IPC_PARSE_VERSION=y
+CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y
+CONFIG_ARCH_WANT_OLD_COMPAT_IPC=y
+CONFIG_BINFMT_ELF32=y
+CONFIG_BLK_DEV_SD=y
+CONFIG_BLOCK_COMPAT=y
+# CONFIG_BOOTPARAM_HUNG_TASK_PANIC is not set
+CONFIG_BOOTPARAM_HUNG_TASK_PANIC_VALUE=0
+CONFIG_BUILTIN_DTB=y
+# CONFIG_CAVIUM_CN63XXP1 is not set
+# CONFIG_CAVIUM_OCTEON_2ND_KERNEL is not set
+CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE=2
+CONFIG_CAVIUM_OCTEON_LOCK_L2=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_EXCEPTION=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_INTERRUPT=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_LOW_LEVEL_INTERRUPT=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_MEMCPY=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_TLB=y
+CONFIG_CAVIUM_OCTEON_SOC=y
+CONFIG_CC_OPTIMIZE_FOR_SIZE=y
+CONFIG_CEVT_R4K=y
+CONFIG_CLONE_BACKWARDS=y
+CONFIG_COMPAT=y
+CONFIG_COMPAT_BRK=y
+CONFIG_COMPAT_NETLINK_MESSAGES=y
+CONFIG_CPU_BIG_ENDIAN=y
+CONFIG_CPU_CAVIUM_OCTEON=y
+CONFIG_CPU_GENERIC_DUMP_TLB=y
+CONFIG_CPU_HAS_PREFETCH=y
+CONFIG_CPU_HAS_SYNC=y
+# CONFIG_CPU_LITTLE_ENDIAN is not set
+CONFIG_CPU_MIPSR2=y
+CONFIG_CPU_NEEDS_NO_SMARTMIPS_OR_MICROMIPS=y
+CONFIG_CPU_RMAP=y
+CONFIG_CPU_SUPPORTS_64BIT_KERNEL=y
+CONFIG_CPU_SUPPORTS_HIGHMEM=y
+CONFIG_CPU_SUPPORTS_HUGEPAGES=y
+CONFIG_CRAMFS=y
+CONFIG_CRC16=y
+CONFIG_CRYPTO_CRC32C=y
+CONFIG_CRYPTO_HASH=y
+CONFIG_CRYPTO_HASH2=y
+# CONFIG_CRYPTO_MD5_OCTEON is not set
+CONFIG_CRYPTO_RNG2=y
+# CONFIG_CRYPTO_SHA1_OCTEON is not set
+# CONFIG_CRYPTO_SHA256_OCTEON is not set
+# CONFIG_CRYPTO_SHA512_OCTEON is not set
+CONFIG_CRYPTO_WORKQUEUE=y
+CONFIG_DEBUG_INFO=y
+CONFIG_DEBUG_SPINLOCK=y
+CONFIG_DEFAULT_HUNG_TASK_TIMEOUT=120
+CONFIG_DETECT_HUNG_TASK=y
+CONFIG_DEVKMEM=y
+CONFIG_DMA_COHERENT=y
+CONFIG_DNOTIFY=y
+CONFIG_DTC=y
+CONFIG_EARLY_PRINTK=y
+CONFIG_EDAC_ATOMIC_SCRUB=y
+CONFIG_EDAC_SUPPORT=y
+CONFIG_ENABLE_MUST_CHECK=y
+CONFIG_EXT4_FS=y
+CONFIG_FAT_FS=y
+CONFIG_FRAME_WARN=2048
+CONFIG_FS_MBCACHE=y
+CONFIG_GENERIC_CLOCKEVENTS=y
+CONFIG_GENERIC_CMOS_UPDATE=y
+CONFIG_GENERIC_IO=y
+CONFIG_GENERIC_IRQ_SHOW=y
+CONFIG_GENERIC_PCI_IOMAP=y
+CONFIG_GENERIC_SMP_IDLE_THREAD=y
+CONFIG_GPIOLIB=y
+CONFIG_GPIO_DEVRES=y
+CONFIG_GPIO_OCTEON=y
+CONFIG_GPIO_SYSFS=y
+CONFIG_HARDWARE_WATCHPOINTS=y
+CONFIG_HAS_DMA=y
+CONFIG_HAS_IOMEM=y
+CONFIG_HAS_IOPORT_MAP=y
+CONFIG_HAVE_64BIT_ALIGNED_ACCESS=y
+# CONFIG_HAVE_ARCH_BITREVERSE is not set
+CONFIG_HAVE_ARCH_JUMP_LABEL=y
+CONFIG_HAVE_ARCH_KGDB=y
+CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
+CONFIG_HAVE_ARCH_TRACEHOOK=y
+CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y
+# CONFIG_HAVE_BOOTMEM_INFO_NODE is not set
+CONFIG_HAVE_BPF_JIT=y
+CONFIG_HAVE_CC_STACKPROTECTOR=y
+CONFIG_HAVE_CONTEXT_TRACKING=y
+CONFIG_HAVE_C_RECORDMCOUNT=y
+CONFIG_HAVE_DEBUG_KMEMLEAK=y
+CONFIG_HAVE_DEBUG_STACKOVERFLOW=y
+CONFIG_HAVE_DMA_API_DEBUG=y
+CONFIG_HAVE_DMA_ATTRS=y
+CONFIG_HAVE_DMA_CONTIGUOUS=y
+CONFIG_HAVE_DYNAMIC_FTRACE=y
+CONFIG_HAVE_FTRACE_MCOUNT_RECORD=y
+CONFIG_HAVE_FUNCTION_GRAPH_TRACER=y
+CONFIG_HAVE_FUNCTION_TRACER=y
+CONFIG_HAVE_GENERIC_DMA_COHERENT=y
+CONFIG_HAVE_IDE=y
+CONFIG_HAVE_IRQ_TIME_ACCOUNTING=y
+CONFIG_HAVE_MEMBLOCK=y
+CONFIG_HAVE_MEMBLOCK_NODE_MAP=y
+CONFIG_HAVE_MEMORY_PRESENT=y
+CONFIG_HAVE_MOD_ARCH_SPECIFIC=y
+CONFIG_HAVE_NET_DSA=y
+CONFIG_HAVE_OPROFILE=y
+CONFIG_HAVE_PERF_EVENTS=y
+CONFIG_HAVE_SYSCALL_TRACEPOINTS=y
+CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
+# CONFIG_HIGH_RES_TIMERS is not set
+CONFIG_HOLES_IN_ZONE=y
+# CONFIG_HUGETLBFS is not set

[OpenWrt-Devel] [PATCH 08/10] kernel/modules: add OCTEON SHA256 module

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/crypto.mk | 9 -
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index f5c5895..2328fac 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -492,12 +492,19 @@ $(eval $(call KernelPackage,crypto-sha1))
 define KernelPackage/crypto-sha256
   TITLE:=SHA224 SHA256 digest CryptoAPI module
   DEPENDS:=+kmod-crypto-hash
-  KCONFIG:=CONFIG_CRYPTO_SHA256
+  KCONFIG:= \
+   CONFIG_CRYPTO_SHA256 \
+   CONFIG_CRYPTO_SHA256_OCTEON
   FILES:=$(LINUX_DIR)/crypto/sha256_generic.ko
   AUTOLOAD:=$(call AutoLoad,09,sha256_generic)
   $(call AddDepends/crypto)
 endef
 
+define KernelPackage/crypto-sha256/octeon
+  FILES+=$(LINUX_DIR)/arch/mips/cavium-octeon/crypto/octeon-sha256.ko
+  AUTOLOAD:=$(call AutoLoad,09,octeon-sha256)
+endef
+
 $(eval $(call KernelPackage,crypto-sha256))
 
 
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 09/10] kernel/modules: move SHA512 to its own package

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/crypto.mk | 14 --
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index 2328fac..ca36c2f 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -508,6 +508,18 @@ endef
 $(eval $(call KernelPackage,crypto-sha256))
 
 
+define KernelPackage/crypto-sha512
+  TITLE:=SHA512 digest CryptoAPI module
+  DEPENDS:=+kmod-crypto-hash
+  KCONFIG:=CONFIG_CRYPTO_SHA512
+  FILES:=$(LINUX_DIR)/crypto/sha512_generic.ko
+  AUTOLOAD:=$(call AutoLoad,09,sha512_generic)
+  $(call AddDepends/crypto)
+endef
+
+$(eval $(call KernelPackage,crypto-sha512))
+
+
 define KernelPackage/crypto-misc
   TITLE:=Other CryptoAPI modules
   DEPENDS:=+kmod-crypto-manager
@@ -520,7 +532,6 @@ define KernelPackage/crypto-misc
CONFIG_CRYPTO_FCRYPT \
CONFIG_CRYPTO_KHAZAD \
CONFIG_CRYPTO_SERPENT \
-   CONFIG_CRYPTO_SHA512 \
CONFIG_CRYPTO_TEA \
CONFIG_CRYPTO_TGR192 \
CONFIG_CRYPTO_TWOFISH \
@@ -534,7 +545,6 @@ define KernelPackage/crypto-misc
$(LINUX_DIR)/crypto/cast5_generic.ko \
$(LINUX_DIR)/crypto/cast6_generic.ko \
$(LINUX_DIR)/crypto/khazad.ko \
-   $(LINUX_DIR)/crypto/sha512_generic.ko \
$(LINUX_DIR)/crypto/tea.ko \
$(LINUX_DIR)/crypto/tgr192.ko \
$(LINUX_DIR)/crypto/twofish_common.ko \
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 10/10] kernel/modules: add OCTEON SHA512 module

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/crypto.mk | 9 -
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index ca36c2f..9626b21 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -511,12 +511,19 @@ $(eval $(call KernelPackage,crypto-sha256))
 define KernelPackage/crypto-sha512
   TITLE:=SHA512 digest CryptoAPI module
   DEPENDS:=+kmod-crypto-hash
-  KCONFIG:=CONFIG_CRYPTO_SHA512
+  KCONFIG:= \
+   CONFIG_CRYPTO_SHA512 \
+   CONFIG_CRYPTO_SHA512_OCTEON
   FILES:=$(LINUX_DIR)/crypto/sha512_generic.ko
   AUTOLOAD:=$(call AutoLoad,09,sha512_generic)
   $(call AddDepends/crypto)
 endef
 
+define KernelPackage/crypto-sha512/octeon
+  FILES+=$(LINUX_DIR)/arch/mips/cavium-octeon/crypto/octeon-sha512.ko
+  AUTOLOAD:=$(call AutoLoad,09,octeon-sha512)
+endef
+
 $(eval $(call KernelPackage,crypto-sha512))
 
 
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH v2 4/4] conntrack-tools: preserve /etc/conntrackd during upgrade

2015-11-11 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/network/utils/conntrack-tools/Makefile | 4 
 1 file changed, 4 insertions(+)

diff --git a/package/network/utils/conntrack-tools/Makefile 
b/package/network/utils/conntrack-tools/Makefile
index 51d3c41..fd13e22 100644
--- a/package/network/utils/conntrack-tools/Makefile
+++ b/package/network/utils/conntrack-tools/Makefile
@@ -61,6 +61,10 @@ $(call Package/conntrack-tools/default)
   TITLE:=Connection tracking daemon
 endef
 
+define Package/conntrackd/conffiles
+/etc/conntrackd/
+endef
+
 define Package/conntrackd/description
  Conntrackd can replicate the status of the connections that are
  currently being processed by your stateful firewall based on Linux.
-- 
2.4.6
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] kernel/modules: fix crypto API RNG for >=4.2

2015-12-10 Thread Stijn Tintel
Since kernel 4.2, DRBG is the default crypto API RNG, replacing krng. As
DRBG is not enabled, there is no crypto API RNG available when running
kernel 4.2 or later. Because of this, IPsec SAs fail to install. In
strongSwan, this results in a vague error that is difficult to debug:

received netlink error: No such file or directory (2)

Solve this by adding DRBG to the kmod-crypto-rng package. As enabling
DRBG in the kernel config also enables the Jitterentropy RNG, include it
in kmod-crypto-rng instead of having it in a separate package.

Signed-off-by: Stijn Tintel 
---
 package/kernel/linux/modules/crypto.mk | 25 ++---
 1 file changed, 10 insertions(+), 15 deletions(-)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index 062afe7..fe64db4 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -100,26 +100,21 @@ $(eval $(call KernelPackage,crypto-wq))
 
 define KernelPackage/crypto-rng
   TITLE:=CryptoAPI random number generation
-  KCONFIG:=CONFIG_CRYPTO_RNG2
-  FILES:=$(LINUX_DIR)/crypto/rng.ko
-ifeq ($(strip $(call CompareKernelPatchVer,$(KERNEL_PATCHVER),lt,4.2.0)),1)
-  FILES+=$(LINUX_DIR)/crypto/krng.ko
-endif
-  AUTOLOAD:=$(call AutoLoad,09,rng krng)
+  KCONFIG:= \
+   CONFIG_CRYPTO_DRBG \
+   CONFIG_CRYPTO_JITTERENTROPY \
+   CONFIG_CRYPTO_RNG2
+  FILES:= \
+   $(LINUX_DIR)/crypto/drbg.ko@ge4.2 \
+   $(LINUX_DIR)/crypto/jitterentropy_rng.ko@ge4.2 \
+   $(LINUX_DIR)/crypto/krng.ko@lt4.2 \
+   $(LINUX_DIR)/crypto/rng.ko
+  AUTOLOAD:=$(call AutoLoad,09,drbg@ge4.2 jitterentropy_rng@ge4.2 krng@lt4.2 
rng)
   $(call AddDepends/crypto)
 endef
 
 $(eval $(call KernelPackage,crypto-rng))
 
-define KernelPackage/crypto-rng-jitterentropy
-  TITLE:=Jitterentropy Non-Deterministic Random Number Generator
-  KCONFIG:=CONFIG_CRYPTO_JITTERENTROPY
-  FILES:= $(LINUX_DIR)/crypto/jitterentropy_rng.ko
-  AUTOLOAD:=$(call AutoLoad,10,jitterentropy-rng)
-  $(call AddDepends/crypto)
-endef
-
-$(eval $(call KernelPackage,crypto-rng-jitterentropy))
 
 define KernelPackage/crypto-iv
   TITLE:=CryptoAPI initialization vectors
-- 
2.4.10
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] KERNEL_PATCHVER in master

2019-06-11 Thread Stijn Tintel
Hi,

Since we now have a 19.07 branch, is it OK to switch KERNEL_PATCHVER for
targets in master that have 4.19 support to 4.19?

Thanks,
Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH v3 2/3] network/config: add xfrm interface support scripts

2019-06-11 Thread Stijn Tintel
On 8/06/19 14:48, André Valentin wrote:
> This package adds scripts for xfrm interfaces support.
> Example configuration via /etc/config/network:
>
> config interface 'xfrm0'
> option proto 'xfrm'
> option mtu '1300'
> option zone 'VPN'
> option tunlink 'wan'
> option ifid 30
>
> config interface 'xfrm0_static'
> option proto 'static'
> option ifname '@xfrm0'
> option ip6addr 'fe80::1/64'
> option ipaddr '10.0.0.1/30'
>
Is there really no simpler way to do this? Can't we combine these into 1
config interface 'xxx' section?

Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH 1/2] base-files: make USE_PROCD=1 default

2019-07-28 Thread Stijn Tintel
On 23/07/19 16:37, Petr Štetiar wrote:
> Transition period for init script migration was long enough, let's
> make USE_PROCD=1 default now so there's enough time to convert the
> remaining services/init scripts for the next release.
>
> Signed-off-by: Petr Štetiar 
> ---
>  package/base-files/files/etc/rc.common | 113 ++---
>  1 file changed, 47 insertions(+), 66 deletions(-)
>
Acked-by: Stijn Tintel 

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH 2/2] treewide: remove now default USE_PROCD=1 from init scripts

2019-07-28 Thread Stijn Tintel
On 23/07/19 16:37, Petr Štetiar wrote:
> commit 08abd36204a8 ("base-files: make USE_PROCD=1 default") made
> USE_PROCD=1 default, so let's remove this line from all init scripts.
>
> Signed-off-by: Petr Štetiar 
> ---
>  package/base-files/files/etc/init.d/gpio_switch   | 1 -
>  package/base-files/files/etc/init.d/system| 1 -
>  package/kernel/om-watchdog/files/om-watchdog.init | 1 -
>  package/network/config/firewall/files/firewall.init   | 1 -
>  package/network/config/ltq-adsl-app/files/dsl_control | 1 -
>  package/network/config/ltq-vdsl-app/files/dsl_control | 1 -
>  package/network/config/netifd/files/etc/init.d/network| 1 -
>  package/network/config/qos-scripts/files/etc/init.d/qos   | 1 -
>  package/network/services/dnsmasq/files/dnsmasq.init   | 1 -
>  package/network/services/dropbear/files/dropbear.init | 1 -
>  package/network/services/igmpproxy/files/igmpproxy.init   | 1 -
>  package/network/services/ipset-dns/files/ipset-dns.init   | 1 -
>  package/network/services/lldpd/files/lldpd.init   | 1 -
>  package/network/services/odhcpd/files/odhcpd.init | 1 -
>  package/network/services/omcproxy/files/omcproxy.init | 1 -
>  package/network/services/openvpn/files/openvpn.init   | 1 -
>  package/network/services/relayd/files/relay.init  | 1 -
>  package/network/services/samba36/files/samba.init | 1 -
>  package/network/services/uhttpd/files/uhttpd.init | 1 -
>  package/network/services/umdns/files/umdns.init   | 1 -
>  package/network/utils/linux-atm/files/br2684ctl   | 1 -
>  package/system/fstools/files/blockd.init  | 1 -
>  package/system/rpcd/files/rpcd.init   | 1 -
>  package/system/ubox/files/log.init| 1 -
>  package/system/urandom-seed/files/etc/init.d/urandom_seed | 1 -
>  package/system/urngd/files/urngd.init | 1 -
>  package/utils/busybox/files/cron  | 1 -
>  package/utils/busybox/files/sysntpd   | 1 -
>  package/utils/ct-bugcheck/src/bugcheck.initd  | 1 -
>  package/utils/mdadm/files/mdadm.init  | 1 -
>  package/utils/ugps/files/ugps.init| 1 -
>  package/utils/usbmode/files/usbmode.init  | 1 -
>  32 files changed, 32 deletions(-)
>
>
Acked-by: Stijn Tintel 

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 1/5] tools: add meson-tools

2018-10-19 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 tools/Makefile |  1 +
 tools/meson-tools/Makefile | 31 +++
 2 files changed, 32 insertions(+)
 create mode 100644 tools/meson-tools/Makefile

diff --git a/tools/Makefile b/tools/Makefile
index 9a354f6c70..0adc13acbf 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -38,6 +38,7 @@ tools-$(BUILD_B43_TOOLS) += b43-tools
 tools-$(BUILD_ISL) += isl
 tools-$(CONFIG_USE_SPARSE) += sparse
 tools-$(CONFIG_TARGET_apm821xx) += genext2fs
+tools-$(CONFIG_TARGET_mesongx) += meson-tools
 
 # builddir dependencies
 $(curdir)/bison/compile := $(curdir)/flex/compile
diff --git a/tools/meson-tools/Makefile b/tools/meson-tools/Makefile
new file mode 100644
index 00..ee7d499e8a
--- /dev/null
+++ b/tools/meson-tools/Makefile
@@ -0,0 +1,31 @@
+#
+# Copyright (C) 2017 Stijn Tintel 
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=meson-tools
+PKG_VERSION:=0.1
+PKG_RELEASE:=1
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
+PKG_HASH:=f1bd619368075186b742af84a02a83f60ffba2e6da67433abbe6e6d5c77373cb
+PKG_SOURCE_URL:=https://github.com/afaerber/meson-tools/archive/v$(PKG_VERSION)
+
+PKG_LICENSE:=GPL-2.0
+PKG_LICENSE_FILES:=COPYING
+
+include $(INCLUDE_DIR)/host-build.mk
+include $(INCLUDE_DIR)/kernel.mk
+
+define Host/Install
+   $(INSTALL_BIN) $(HOST_BUILD_DIR)/amlbootsig $(STAGING_DIR_HOST)/bin/
+endef
+
+define Host/Clean
+   rm -f $(STAGING_DIR_HOST)/bin/amlbootsig
+endef
+
+$(eval $(call HostBuild))
-- 
2.16.4


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/5] tools: add fiptool

2018-10-19 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 tools/Makefile |  2 +-
 tools/fiptool/Makefile | 37 +
 2 files changed, 38 insertions(+), 1 deletion(-)
 create mode 100644 tools/fiptool/Makefile

diff --git a/tools/Makefile b/tools/Makefile
index 0adc13acbf..f11c738ac6 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -38,7 +38,7 @@ tools-$(BUILD_B43_TOOLS) += b43-tools
 tools-$(BUILD_ISL) += isl
 tools-$(CONFIG_USE_SPARSE) += sparse
 tools-$(CONFIG_TARGET_apm821xx) += genext2fs
-tools-$(CONFIG_TARGET_mesongx) += meson-tools
+tools-$(CONFIG_TARGET_mesongx) += fiptool meson-tools
 
 # builddir dependencies
 $(curdir)/bison/compile := $(curdir)/flex/compile
diff --git a/tools/fiptool/Makefile b/tools/fiptool/Makefile
new file mode 100644
index 00..e92729e51a
--- /dev/null
+++ b/tools/fiptool/Makefile
@@ -0,0 +1,37 @@
+#
+# Copyright (C) 2017 Stijn Tintel 
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=fiptool
+
+PKG_SOURCE_URL=https://github.com/hardkernel/u-boot.git
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_DATE:=2016-06-01
+PKG_SOURCE_VERSION:=3a2dd09540d3639671d86145336f400ec07b1a4e
+
+PKG_LICENSE:=BSD-3-Clause
+
+include $(INCLUDE_DIR)/host-build.mk
+
+define Host/Compile
+   +$(HOST_MAKE_VARS) \
+   $(MAKE) $(HOST_JOBS) -C $(HOST_BUILD_DIR)/tools/fip_create \
+   $(HOST_MAKE_FLAGS) \
+   $(1)
+endef
+
+define Host/Install
+   $(INSTALL_BIN) \
+   $(HOST_BUILD_DIR)/tools/fip_create/fip_create \
+   $(STAGING_DIR_HOST)/bin/
+endef
+
+define Host/Clean
+   rm -f $(STAGING_DIR_HOST)/bin/fip_create
+endef
+
+$(eval $(call HostBuild))
-- 
2.16.4


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 4/5] odroid-firmware: add new package

2018-10-19 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/firmware/odroid/Makefile | 46 
 1 file changed, 46 insertions(+)
 create mode 100644 package/firmware/odroid/Makefile

diff --git a/package/firmware/odroid/Makefile b/package/firmware/odroid/Makefile
new file mode 100644
index 00..21f3f244dd
--- /dev/null
+++ b/package/firmware/odroid/Makefile
@@ -0,0 +1,46 @@
+#
+# Copyright (C) 2017 Stijn Tintel 
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=odroid-firmware
+PKG_VERSION:=2017-02-24
+PKG_RELEASE:=1
+
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_URL:=https://github.com/hardkernel/u-boot.git
+PKG_SOURCE_VERSION:=205c7b3259559283161703a1a200b787c2c445a5
+PKG_MIRROR_HASH:=
+
+PKG_MAINTAINER:=Stijn Tintel 
+
+PKG_FLAGS:=nonshared
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/odroid-firmware-c2
+  SECTION:=firmware
+  CATEGORY:=Firmware
+  TITLE:=Odroid C2 firmware
+  DEPENDS:=@TARGET_mesongx
+endef
+
+define Build/Compile
+
+endef
+
+define Package/odroid-firmware-c2/install
+   $(INSTALL_DIR) $(STAGING_DIR_IMAGE)/odroidc2
+   $(CP) \
+   $(PKG_BUILD_DIR)/fip/gxb/*.{bin,package} \
+   $(STAGING_DIR_IMAGE)/odroidc2
+   $(CP) \
+   $(PKG_BUILD_DIR)/sd_fuse/bl1.bin.hardkernel \
+   $(STAGING_DIR_IMAGE)/odroidc2
+endef
+
+$(eval $(call BuildPackage,odroid-firmware-c2))
-- 
2.16.4


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 3/5] uboot-mesongx: add new package

2018-10-19 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 package/boot/uboot-mesongx/Makefile | 33 +
 1 file changed, 33 insertions(+)
 create mode 100644 package/boot/uboot-mesongx/Makefile

diff --git a/package/boot/uboot-mesongx/Makefile 
b/package/boot/uboot-mesongx/Makefile
new file mode 100644
index 00..4e64628148
--- /dev/null
+++ b/package/boot/uboot-mesongx/Makefile
@@ -0,0 +1,33 @@
+#
+# Copyright (C) 2017-2018 Stijn Tintel 
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+include $(INCLUDE_DIR)/kernel.mk
+
+PKG_VERSION:=2018.09
+PKG_RELEASE:=1
+
+PKG_HASH:=839bf23cfe8ce613a77e583a60375179d0ad324e92c82fbdd07bebf0fd142268
+
+include $(INCLUDE_DIR)/u-boot.mk
+include $(INCLUDE_DIR)/package.mk
+
+define U-Boot/Default
+  ARCH:=arm
+  BUILD_TARGET:=mesongx
+  HIDDEN:=1
+endef
+
+define U-Boot/odroid-c2
+  TITLE:=ODROID C2
+  BUILD_DEVICES:=odroid-c2
+endef
+
+UBOOT_TARGETS:= \
+   odroid-c2
+
+$(eval $(call BuildPackage/U-Boot))
-- 
2.16.4


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 0/5] mesongx: new target for AmLogic S9 SoCs

2018-10-19 Thread Stijn Tintel
This patch series adds a new target "mesongx", which supports AmLogic
S9 SoCs. This has been developed and tested on the ODROID C2 (S905).
This is using a vanilla 4.14 kernel without patches. There is no HDMI
output, because this either requires a 4.16 kernel, or Hardkernel's
U-Boot fork. Most other boards don't have this limitation, and HDMI
should work with the 4.14 kernel.

For more information about what is supported, see
http://www.linux-meson.com/doku.php?id=start.

Stijn Tintel (5):
  tools: add meson-tools
  tools: add fiptool
  uboot-mesongx: add new package
  odroid-firmware: add new package
  mesongx: new target

 package/boot/uboot-mesongx/Makefile|  33 ++
 package/firmware/odroid/Makefile   |  46 +++
 target/linux/mesongx/Makefile  |  36 ++
 target/linux/mesongx/base-files/etc/inittab|   5 +
 .../mesongx/base-files/lib/preinit/79_move_config  |  22 +
 .../mesongx/base-files/lib/upgrade/platform.sh |  95 +
 target/linux/mesongx/config-4.14   | 455 +
 target/linux/mesongx/image/Makefile|  66 +++
 target/linux/mesongx/image/boot.odroid-c2.txt  |   8 +
 tools/Makefile |   1 +
 tools/fiptool/Makefile |  37 ++
 tools/meson-tools/Makefile |  31 ++
 12 files changed, 835 insertions(+)
 create mode 100644 package/boot/uboot-mesongx/Makefile
 create mode 100644 package/firmware/odroid/Makefile
 create mode 100644 target/linux/mesongx/Makefile
 create mode 100644 target/linux/mesongx/base-files/etc/inittab
 create mode 100644 target/linux/mesongx/base-files/lib/preinit/79_move_config
 create mode 100644 target/linux/mesongx/base-files/lib/upgrade/platform.sh
 create mode 100644 target/linux/mesongx/config-4.14
 create mode 100644 target/linux/mesongx/image/Makefile
 create mode 100644 target/linux/mesongx/image/boot.odroid-c2.txt
 create mode 100644 tools/fiptool/Makefile
 create mode 100644 tools/meson-tools/Makefile

-- 
2.16.4


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 5/5] mesongx: new target

2018-10-19 Thread Stijn Tintel
This target supports Amlogic S9 SoCs.

Signed-off-by: Stijn Tintel 
---
 target/linux/mesongx/Makefile  |  36 ++
 target/linux/mesongx/base-files/etc/inittab|   5 +
 .../mesongx/base-files/lib/preinit/79_move_config  |  22 +
 .../mesongx/base-files/lib/upgrade/platform.sh |  95 +
 target/linux/mesongx/config-4.14   | 455 +
 target/linux/mesongx/image/Makefile|  66 +++
 target/linux/mesongx/image/boot.odroid-c2.txt  |   8 +
 7 files changed, 687 insertions(+)
 create mode 100644 target/linux/mesongx/Makefile
 create mode 100644 target/linux/mesongx/base-files/etc/inittab
 create mode 100644 target/linux/mesongx/base-files/lib/preinit/79_move_config
 create mode 100644 target/linux/mesongx/base-files/lib/upgrade/platform.sh
 create mode 100644 target/linux/mesongx/config-4.14
 create mode 100644 target/linux/mesongx/image/Makefile
 create mode 100644 target/linux/mesongx/image/boot.odroid-c2.txt

diff --git a/target/linux/mesongx/Makefile b/target/linux/mesongx/Makefile
new file mode 100644
index 00..507f5d2526
--- /dev/null
+++ b/target/linux/mesongx/Makefile
@@ -0,0 +1,36 @@
+#
+# Copyright (C) 2017-2018 Stijn Tintel 
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+ARCH:=aarch64
+BOARD:=mesongx
+BOARDNAME:=Amlogic S9 family
+CPU_TYPE:=cortex-a53
+DEVICE_TYPE:=other
+FEATURES:=audio boot-part ext4 fpu squashfs usbgadget
+MAINTAINER:=Stijn Tintel 
+
+KERNEL_PATCHVER:=4.14
+
+define Target/Description
+   Build firmware image for Amlogic S9 SoC devices.
+endef
+
+include $(INCLUDE_DIR)/target.mk
+
+DEFAULT_PACKAGES += \
+   e2fsprogs \
+   kmod-sound-core \
+   kmod-usb-hid \
+   mkf2fs \
+   partx-utils \
+   v4l-utils
+
+KERNELNAME:=Image dtbs
+
+$(eval $(call BuildTarget))
diff --git a/target/linux/mesongx/base-files/etc/inittab 
b/target/linux/mesongx/base-files/etc/inittab
new file mode 100644
index 00..a5100a7050
--- /dev/null
+++ b/target/linux/mesongx/base-files/etc/inittab
@@ -0,0 +1,5 @@
+::sysinit:/etc/init.d/rcS S boot
+::shutdown:/etc/init.d/rcS K shutdown
+::askconsole:/usr/libexec/login.sh
+tty1::askfirst:/usr/libexec/login.sh
+ttyAML0::askfirst:/usr/libexec/login.sh
diff --git a/target/linux/mesongx/base-files/lib/preinit/79_move_config 
b/target/linux/mesongx/base-files/lib/preinit/79_move_config
new file mode 100644
index 00..6ac1b3be69
--- /dev/null
+++ b/target/linux/mesongx/base-files/lib/preinit/79_move_config
@@ -0,0 +1,22 @@
+#!/bin/sh
+# Copyright (C) 2012-2015 OpenWrt.org
+
+move_config() {
+   local partdev
+
+   . /lib/upgrade/common.sh
+
+   if export_bootdevice && export_partdevice partdev 1; then
+   mkdir -p /boot
+   if mount -t ext4 -o ro,noatime "/dev/$partdev" /boot; then
+   if [ -f /boot/sysupgrade.tgz ]; then
+   mount /boot -o remount,rw,noatime
+   mv -f /boot/sysupgrade.tgz /
+   mount /boot -o remount,ro,noatime
+   fi
+   fi
+   fi
+}
+
+boot_hook_add preinit_mount_root move_config
+
diff --git a/target/linux/mesongx/base-files/lib/upgrade/platform.sh 
b/target/linux/mesongx/base-files/lib/upgrade/platform.sh
new file mode 100644
index 00..3bfefc6b92
--- /dev/null
+++ b/target/linux/mesongx/base-files/lib/upgrade/platform.sh
@@ -0,0 +1,95 @@
+platform_check_image() {
+   local diskdev partdev diff
+   [ "$#" -gt 1 ] && return 1
+
+   case "$(get_magic_word "$1")" in
+   24c8) ;;
+   *)
+   echo "Invalid image type"
+   return 1
+   ;;
+   esac
+
+   export_bootdevice && export_partdevice diskdev 0 || {
+   echo "Unable to determine upgrade device"
+   return 1
+   }
+
+   get_partitions "/dev/$diskdev" bootdisk
+
+   #extract the boot sector from the image
+   get_image "$@" | dd of=/tmp/image.bs count=1 bs=512b 2>/dev/null
+
+   get_partitions /tmp/image.bs image
+
+   #compare tables
+   diff="$(grep -F -x -v -f /tmp/partmap.bootdisk /tmp/partmap.image)"
+
+   rm -f /tmp/image.bs /tmp/partmap.bootdisk /tmp/partmap.image
+
+   if [ -n "$diff" ]; then
+   echo "Partition layout has changed. Full image will be written."
+   ask_bool 0 "Abort" && exit 1
+   return 0
+   fi
+}
+
+platform_copy_config() {
+   local partdev
+
+   if export_partdevice partdev 1; then
+   mount -t ext4 -o rw,noatime "/dev/$partdev" /mnt
+   cp -af "$CONF_TAR

Re: [OpenWrt-Devel] brcm2708: add kernel 4.14 support

2018-11-11 Thread Stijn Tintel
Hi,

I have just pushed support for the 4.14 kernel on the brcm2708 target to
my staging tree [1], and would like to get some feedback before pushing
it to master. It would also be nice if people could do runtime tests on
bcm2709 and bcm2710, as I don't own such hardware.

Thanks,
Stijn

[1]
https://git.openwrt.org/?p=openwrt/staging/stintel.git;a=shortlog;h=refs/heads/brcm2708-4_14


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] brcm2708: add kernel 4.14 support

2018-11-12 Thread Stijn Tintel
On 12/11/18 15:26, Alexandru Ardelean wrote:
> Hey,
Hi, please don't top-post :-)
>
> The lan78xx stuff you removed seems to cause some endless prints like this:
> ** 10 printk messages dropped ** [ timestamp ] lan78xx 1-1.1.1:1.0
> eth0: kevent 4 may have been dropped
I'll add the lan78xx patches again.
>
> This happens shortly after booting up.
>
> I tested on a RPi 3 Model B+.
> The kernel is 32bit .
>
> [Related to RPi] The RPi kernel seems a bit hard to maintain in the
> OpenWrt tree, because if you pull patches from the RPi github tree
> (branch rpi-4.14.y) you need to periodically check & update them.
> I tried to keep a 4.14 of OpenWrt in my own tree, and it's a pain to
> maintain [just for my personal need].
> Every couple of 4.14.xxx bumps, some of the patches don't apply
> anymore, because some of them are too big [thrown in], and conflict
> with upstream stuff.
> So, if going forward with OpenWrt + RPi [which I would love to see],
> this will be a somewhat hefty work-load.
The problem of patches no longer applying happens with other platforms
as well sometimes. Once we have kernel 4.19 support and 19.01 has been
branched, I would like to introduce a new target bcm283x and phase out
brcm2708. The idea is to use a vanilla kernel with as little patches as
possible,  and boot with vanilla u-boot. But to support the target at
all in 19.01, which will use kernel 4.14, I would like to push this to
master, and preferably sooner rather than later.
>
> Thanks
> Alex
>
> On Sun, Nov 11, 2018 at 6:37 PM Stijn Tintel  wrote:
>> Hi,
>>
>> I have just pushed support for the 4.14 kernel on the brcm2708 target to
>> my staging tree [1], and would like to get some feedback before pushing
>> it to master. It would also be nice if people could do runtime tests on
>> bcm2709 and bcm2710, as I don't own such hardware.
>>
>> Thanks,
>> Stijn
>>
>> [1]
>> https://git.openwrt.org/?p=openwrt/staging/stintel.git;a=shortlog;h=refs/heads/brcm2708-4_14
>>
Thanks,
Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] octeon: Allow sysupgrade restore on ER

2018-11-12 Thread Stijn Tintel
On 12/11/18 17:56, Jonathan Thibault wrote:
> This is a very simple patch that completes sysupgrade functionality on
> UBNT ER8.
>
> Default layout leaves about 128MB free on the kernel partition so
> there is plenty of space for temporary config backups.
>
>
> diff --git a/target/linux/octeon/base-files/lib/preinit/79_move_config
> b/target/linux/octeon/base-files/lib/preinit/79_move_config
> index ec63d9f5ff..d50bac081b 100644
> --- a/target/linux/octeon/base-files/lib/preinit/79_move_config
> +++ b/target/linux/octeon/base-files/lib/preinit/79_move_config
> @@ -10,6 +10,11 @@ move_config() {
>     [ -f /mnt/sysupgrade.tgz ] && mv -f
> /mnt/sysupgrade.tgz /
>     umount /mnt
>     ;;
> +   er)
> +   mount -t vfat /dev/mmcblk0p1 /mnt
> +   [ -f /mnt/sysupgrade.tgz ] && mv -f
> /mnt/sysupgrade.tgz /
> +   umount /mnt
> +   ;;
Please order the options alphabetically.
>     esac
>  }
>
> diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh
> b/target/linux/octeon/base-files/lib/upgrade/platform.sh
> index cd49c0da36..2a2136f196 100755
> --- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
> +++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
> @@ -28,6 +28,11 @@ platform_copy_config() {
>     cp -af "$CONF_TAR" /mnt/
>     umount /mnt
>     ;;
> +   er)
> +   mount -t vfat /dev/mmcblk0p1 /mnt
> +   cp -af "$CONF_TAR" /mnt/
> +   umount /mnt
> +   ;;
Same here.
>     esac
>  }
>
Thanks,
Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] brcm2708: add kernel 4.14 support

2018-11-12 Thread Stijn Tintel
On 12/11/18 19:00, Christian Lamparter wrote:
> (Did some EMails get mangled?:
> "openwrt-devel@lists.openwrt.org j...@openwrt.org" ")
>
> On Monday, November 12, 2018 4:55:12 PM CET Stijn Tintel wrote:
>> On 12/11/18 15:26, Alexandru Ardelean wrote:
>>> [Related to RPi] The RPi kernel seems a bit hard to maintain in the
>>> OpenWrt tree, because if you pull patches from the RPi github tree
>>> (branch rpi-4.14.y) you need to periodically check & update them.
>>> I tried to keep a 4.14 of OpenWrt in my own tree, and it's a pain to
>>> maintain [just for my personal need].
>>> Every couple of 4.14.xxx bumps, some of the patches don't apply
>>> anymore, because some of them are too big [thrown in], and conflict
>>> with upstream stuff.
>>> So, if going forward with OpenWrt + RPi [which I would love to see],
>>> this will be a somewhat hefty work-load.
>> The problem of patches no longer applying happens with other platforms
>> as well sometimes. Once we have kernel 4.19 support and 19.01 has been
>> branched, I would like to introduce a new target bcm283x and phase out
>> brcm2708. The idea is to use a vanilla kernel with as little patches as
>> possible,  and boot with vanilla u-boot. But to support the target at
>> all in 19.01, which will use kernel 4.14, I would like to push this to
>> master, and preferably sooner rather than later.
> There's atleast one easy-to-overlook issue/conflict with the rpi-4.14.y
> trees and what's upstream in vanilla-4.14 (and for 4.19 in the future):
> missing or conflicting dt machine compatibles.
>
> And they are important because the brcm2708 target was switched to
> Mathias' "generic dt" method 
> (see commit 6f041288927b6b7 "brcm2708: convert to dt-based board-detection")
>
> Back then, I added the upstream compatibles in the 
> "brcm2708: add compatible strings" with the caveat that the 
> ComputeModules are still WIP. (see patch/commit message:
> <https://lists.openwrt.org/pipermail/openwrt-devel/2017-December/010359.html>)
> But it doesn't look like that patch "960-add-rasbperrypi-compatible.patch"
> made it into your repo. So I wonder if sysupgrade is working at all?

This is partially handled by the following patches now:

950-0247-ARM-dts-Add-model-specific-compatible-strings.patch
950-0253-BCM270X_DT-Add-Pi-3-dts-files.patch

I'll adapt your patch for the ones that are still missing, and use
upstream names for compute modules.

Thanks,
Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] brcm2708: add kernel 4.14 support

2018-12-06 Thread Stijn Tintel
On 11/11/18 18:37, Stijn Tintel wrote:
> Hi,
>
> I have just pushed support for the 4.14 kernel on the brcm2708 target to
> my staging tree [1], and would like to get some feedback before pushing
> it to master. It would also be nice if people could do runtime tests on
> bcm2709 and bcm2710, as I don't own such hardware.
>
> Thanks,
> Stijn
>
> [1]
> https://git.openwrt.org/?p=openwrt/staging/stintel.git;a=shortlog;h=refs/heads/brcm2708-4_14
>
Updated [1]:
- based on 4.14.86
- split kmod changes in separate commits
- kept lan78xx patches except those that are superseded by upstream
changes, added another one that attempts to fix broken ethernet and
"kevent 4 may have been dropped" flood
- added missing compatible strings using upstream names for compute modules
- no longer removing the sense HAT patch, I might add kmod packages for
that later

Compile-tested all 3 subtargets again with CONFIG_ALL_KMODS=y, and
runtime-tested bcm2708 on RPi0W and bcm2710 on RPi3B+. The wired
interface on the latter seems to be usable now.

I'm planning to push this to master as soon as Koen pushed the 4.14.86
bump. If there are any objections, please speak up ASAP.

Thanks,
Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] brcm2708: add kernel 4.14 support

2018-12-07 Thread Stijn Tintel
On 7/12/18 10:17, Alexandru Ardelean wrote:
> On Fri, Dec 7, 2018 at 5:06 AM Stijn Tintel  wrote:
>> On 11/11/18 18:37, Stijn Tintel wrote:
>>> Hi,
>>>
>>> I have just pushed support for the 4.14 kernel on the brcm2708 target to
>>> my staging tree [1], and would like to get some feedback before pushing
>>> it to master. It would also be nice if people could do runtime tests on
>>> bcm2709 and bcm2710, as I don't own such hardware.
>>>
>>> Thanks,
>>> Stijn
>>>
>>> [1]
>>> https://git.openwrt.org/?p=openwrt/staging/stintel.git;a=shortlog;h=refs/heads/brcm2708-4_14
>>>
>> Updated [1]:
>> - based on 4.14.86
>> - split kmod changes in separate commits
>> - kept lan78xx patches except those that are superseded by upstream
>> changes, added another one that attempts to fix broken ethernet and
>> "kevent 4 may have been dropped" flood
>> - added missing compatible strings using upstream names for compute modules
>> - no longer removing the sense HAT patch, I might add kmod packages for
>> that later
>>
>> Compile-tested all 3 subtargets again with CONFIG_ALL_KMODS=y, and
>> runtime-tested bcm2708 on RPi0W and bcm2710 on RPi3B+. The wired
>> interface on the latter seems to be usable now.
>>
>> I'm planning to push this to master as soon as Koen pushed the 4.14.86
>> bump. If there are any objections, please speak up ASAP.
>>
> This one booted fine on a RPi 3.
> I used the 32 bit image.
>
> root@OpenWrt:~# uname -a
> Linux OpenWrt 4.14.86 #0 SMP Fri Dec 7 03:03:39 2018 armv7l GNU/Linux
Thanks for testing, I added your "Tested-by".
>
> A few minor/ignorable errors:
> [0.769743] Error: Driver 'sdhost-bcm2835' is already registered, 
> aborting...
Fixed by disabling CONFIG_MMC_BCM2835_MMC since we want to prefer
upstream when possible.
> [8.689456] brcmfmac mmc1:0001:1: Direct firmware load for
> brcm/brcmfmac43455-sdio.raspberrypi,3-model-b-plus.txt failed with
> error -2
>
Similar error appeared for me with 4.9. Since it's non-fatal, I'm going
to ignore this for now.

Thanks,
Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] brcm2708: add kernel 4.14 support

2018-12-12 Thread Stijn Tintel
On 7/12/18 05:06, Stijn Tintel wrote:
> On 11/11/18 18:37, Stijn Tintel wrote:
>> Hi,
>>
>> I have just pushed support for the 4.14 kernel on the brcm2708 target to
>> my staging tree [1], and would like to get some feedback before pushing
>> it to master. It would also be nice if people could do runtime tests on
>> bcm2709 and bcm2710, as I don't own such hardware.
>>
>> Thanks,
>> Stijn
>>
>> [1]
>> https://git.openwrt.org/?p=openwrt/staging/stintel.git;a=shortlog;h=refs/heads/brcm2708-4_14
>>
> Updated [1]:
> - based on 4.14.86
> - split kmod changes in separate commits
> - kept lan78xx patches except those that are superseded by upstream
> changes, added another one that attempts to fix broken ethernet and
> "kevent 4 may have been dropped" flood
> - added missing compatible strings using upstream names for compute modules
> - no longer removing the sense HAT patch, I might add kmod packages for
> that later
>
> Compile-tested all 3 subtargets again with CONFIG_ALL_KMODS=y, and
> runtime-tested bcm2708 on RPi0W and bcm2710 on RPi3B+. The wired
> interface on the latter seems to be usable now.
>
> I'm planning to push this to master as soon as Koen pushed the 4.14.86
> bump. If there are any objections, please speak up ASAP.
>

After flashing one of my RPi0W's running headless, it didn't come back.
When testing it on my desk, it works just fine. After some digging I
found that not having HDMI plugged in during boot causes the problem.
This happens because brcmfmac fails to load due to a "vmalloc:
allocation failure":

[   17.527326] vmap allocation for size 253952 failed: use
vmalloc= to increase size
[   17.540014] kmodloader: vmalloc: allocation failure: 249856 bytes,
mode:0x14000c0(GFP_KERNEL), nodemask=(null)
[   17.554778] CPU: 0 PID: 212 Comm: kmodloader Tainted: G C
O    4.14.87 #0
[   17.566819] Hardware name: BCM2835
[   17.572486] [] (unwind_backtrace) from []
(show_stack+0x10/0x14)
[   17.584649] [] (show_stack) from []
(warn_alloc+0xac/0x168)
[   17.594362] [] (warn_alloc) from []
(__vmalloc_node_range+0x1f0/0x238)
[   17.607085] [] (__vmalloc_node_range) from []
(module_alloc+0x3c/0x4c)
[   17.620019] [] (module_alloc) from []
(load_module+0x7fc/0x2160)
[   17.632592] [] (load_module) from []
(SyS_init_module+0x138/0x168)
[   17.645312] [] (SyS_init_module) from []
(ret_fast_syscall+0x0/0x54)
[   17.658224] Mem-Info:
[   17.662897] active_anon:232 inactive_anon:0 isolated_anon:0
[   17.662897]  active_file:2793 inactive_file:1495 isolated_file:0
[   17.662897]  unevictable:0 dirty:104 writeback:0 unstable:0
[   17.662897]  slab_reclaimable:670 slab_unreclaimable:1282
[   17.662897]  mapped:258 shmem:3 pagetables:21 bounce:0
[   17.662897]  free:102979 free_pcp:75 free_cma:3749
[   17.708759] Node 0 active_anon:928kB inactive_anon:0kB
active_file:11172kB inactive_file:5980kB unevictable:0kB
isolated(anon):0kB isolated(file):0kB mapped:1032kB dirty:416kB
writeback:0kB shmem:12kB writeback_tmp:0kB unstable:0kB al
l_unreclaimable? no
[   17.740097] Normal free:411916kB min:2624kB low:3280kB high:3936kB
active_anon:928kB inactive_anon:0kB active_file:11172kB
inactive_file:5980kB unevictable:0kB writepending:416kB present:458752kB
managed:447900kB mlocked:0kB kernel_st
ack:360kB pagetables:84kB bounce:0kB free_pcp:300kB local_pcp:300kB
free_cma:14996kB
[   17.777379] lowmem_reserve[]: 0 0
[   17.782966] Normal: 3*4kB (UMC) 32*8kB (UMEC) 18*16kB (MEC) 7*32kB
(UMC) 2*64kB (UC) 3*128kB (MC) 2*256kB (EC) 1*512kB (U) 2*1024kB (ME)
1*2048kB (C) 99*4096kB (MC) = 411916kB
[   17.805336] 4291 total pagecache pages
[   17.811267] 0 pages in swap cache
[   17.816776] Swap cache stats: add 0, delete 0, find 0/0
[   17.824208] Free swap  = 0kB
[   17.829227] Total swap = 0kB
[   17.834223] 114688 pages RAM
[   17.839137] 0 pages HighMem/MovableOnly
[   17.845094] 2713 pages reserved
[   17.850284] 4096 pages cma reserved

I'm running into this problem because I have both kmod-video-bcm2835 and
kmod-drm-vc4 enabled in my config. If I remove the related files that
load these modules from /etc/modules.d, brcmfmac loads fine without HDMI
attached. If I manually load either of the disabled modules afterwards,
this fails the same way. I'm going to report this problem upstream, and
will hold off pushing this to master until a fix is available.

Stijn


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH 2/4 v2] gemini: Switch to kernel v4.19

2019-01-24 Thread Stijn Tintel
On 23/01/19 19:59, Linus Walleij wrote:
> This adds a config and augments the gemini makefile to
> use kernel v4.19.
>
> These devices work so much better with v4.19 so let's
> immediately make it the default.

NAK. All targets need to be on 4.14 until 19.01 is branched.

Stijn



___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH net-snmp] add package snmp-mibs

2016-10-31 Thread Stijn Tintel
On 30-10-16 19:18, Sven Roederer wrote:
> PACKAGE: net/net-snmp
> this installs the default MIBS-files under /usr/share/snmp/mibs
Please send a PR on Github: https://github.com/openwrt/packages

Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH oldpackage/eventlog oldpackage/syslog-ng3] version bump to latest

2017-01-06 Thread Stijn Tintel
On 06-01-17 20:38, Hauke Mehrtens wrote:
> Please do not send a mail with just an attachment, oldpackage is frozen
> since some years, please send add the package to the official openwrt
> package repository, add yourself as a maintainer and send a pull request
> on github.
There are PRs for this already, which I have merged just a few moments ago.

Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] openwrt and lede - remerge proposal V3

2017-05-29 Thread Stijn Tintel
On 29-05-17 09:03, John Crispin wrote:
> (resend, this time as plain text)
>
> Hi,
>
> here is a V3 of the remerge proposal, I tried to fold all the comments
> people made into it, if anything is missing let me know. Please
> remeber that post remerge anything can be voted on, so cluttering the
> proposal with many details will delay the remerge even more.
>
> Ideally we manage to vote during this week.
>
Full ACK from me.

Thanks,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] Enable DCO check on Github OpenWrt organisation

2018-01-21 Thread Stijn Tintel
On 19-01-18 15:02, Piotr Dymacz wrote:
>
>
> On 19.01.2018 13:09, Etienne Champetier wrote:
>
>> We can also make it mandatory (show "required" on the fail test line)
>> Also this is a good minimum check to have on ALL repo
>> There are many ways to do it, enabling DCO is a 2 minutes job (if
>> someone want to do a similar script and host it that's totally fine
>> with me)
>
> I'm OK with DCO enabled for all repos. We should probably give some
> time others to comment and if there are no objections, we can enable it.
>
ACK to enable it for packages, not sure if it makes sense for core as we
enforce this in the project git repo already, and Github is just a mirror.

Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] brcm2708: add squashfs rootfs image

2018-04-24 Thread Stijn Tintel
On 27-03-18 20:42, Christian Lamparter wrote:
> This patch adds a image with squashfs as the root filesystem.
> A rootfs_data partition will be generated on the first boot
> and placed inside the rootfs partition (just after the squashfs
> image).
>
> advantages:
>  - it is possible to migrate from an existing -ext4
>installation and back via sysupgrade.
>  - existing partition layout will not be lost.
>  - slightly smaller image size.
>  - support for attendedsysupgrade
>
> disadvantages:
>  - needs f2fs + tools as well. This is because fs-tools decides on the
>blocksize of the sdcard. So either f2fs or ext4 can get choosen as
>the rootfs_data filesystem (depends on the size of the root partition).
>  - rootfs_data is placed into the rootfs partition. This makes
>it difficult for tools that expect a /dev/mmc0pX device.
>It also makes it difficult for data recovery tools since they
>might not expect to find a embedded partition or will be
>confused.
>
> For people with existing build configurations: make sure to include mkf2fs
> and f2fsck package into the image... Otherwise the new -squashfs image will
> boot of a ram-overlay and won't keep the configurations after a reboot.
>
Tried to sysupgrade one of my RPi0W from ext4 to squashfs, and it
appeared to work at first, until I rebooted it again. Apparently the
overlay is completely missing, the SD card only has /boot (FAT32) and /
(squashfs). Can you please look into this? If you can get it resolved I
will merge the patch.

Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] brcm2708: add squashfs rootfs image

2018-04-24 Thread Stijn Tintel
On 24-04-18 17:59, Christian Lamparter wrote:
> On Dienstag, 24. April 2018 13:29:17 CEST Stijn Tintel wrote:
>> On 27-03-18 20:42, Christian Lamparter wrote:
>>> This patch adds a image with squashfs as the root filesystem.
>>> A rootfs_data partition will be generated on the first boot
>>> and placed inside the rootfs partition (just after the squashfs
>>> image).
>>>
>>> advantages:
>>>  - it is possible to migrate from an existing -ext4
>>>installation and back via sysupgrade.
>>>  - existing partition layout will not be lost.
>>>  - slightly smaller image size.
>>>  - support for attendedsysupgrade
>>>
>>> disadvantages:
>>>  - needs f2fs + tools as well. This is because fs-tools decides on the
>>>blocksize of the sdcard. So either f2fs or ext4 can get choosen as
>>>the rootfs_data filesystem (depends on the size of the root partition).
>>>  - rootfs_data is placed into the rootfs partition. This makes
>>>it difficult for tools that expect a /dev/mmc0pX device.
>>>It also makes it difficult for data recovery tools since they
>>>might not expect to find a embedded partition or will be
>>>confused.
>>>
>>> For people with existing build configurations: make sure to include mkf2fs
>>> and f2fsck package into the image... Otherwise the new -squashfs image will
>>> boot of a ram-overlay and won't keep the configurations after a reboot.
>>>
>> Tried to sysupgrade one of my RPi0W from ext4 to squashfs, and it
>> appeared to work at first, until I rebooted it again. Apparently the
>> overlay is completely missing, the SD card only has /boot (FAT32) and /
>> (squashfs). Can you please look into this?
> I think know the problem. The commit-message mentions it and the symptoms
> you are describing would fit. But just in case: can you please provide the
> image's diffconfig (or full-config ... and I guess a bootlog wouldn't
> hurt either - but it would be optional) to confirm?
Please find diffconfig attached. The machine was running headless so I
don't have a bootlog.
>
> (I also tested it again on an uptodate "OpenWrt SNAPSHOT, r6759+2-9e848f901c"
> with my rpi-b - which should be in the same family/subtarget as your RPi0W so
> I can try your generated images as well.)
>
>> If you can get it resolved I will merge the patch.
> The original issue [0] has been addressed by this patch [1]. And indeed
> the luci-app will now successfully generate a image (currently, only for the 
> rpi-3 though!):
> "openwrt-dbbb09d2658d5c2-brcm2708-bcm2710-rpi-3-ext4-sdcard.img.gz"
> and install it.
>
> this patch is therefore no longer necessary since it the existing ext4
> images work as well. :) ... Plus the ext4 images don't confuse tools and
> brains as much.
I still find it useful, I've had way too many corrupted ext4 filesystems
on my RPis, and I'm hoping squashfs + f2fs would be more reliable than
ext4 on SD cards...

Thanks,
Stijn

CONFIG_TARGET_brcm2708=y
CONFIG_TARGET_brcm2708_bcm2708=y
CONFIG_TARGET_brcm2708_bcm2708_DEVICE_rpi=y
CONFIG_BRCM2708_SD_BOOT_PARTSIZE=256
CONFIG_BUILD_PATENTED=y
CONFIG_DEBUG=y
CONFIG_DROPBEAR_ECC=y
# CONFIG_KERNEL_CC_STACKPROTECTOR_REGULAR is not set
CONFIG_KERNEL_CC_STACKPROTECTOR_STRONG=y
CONFIG_LIBCURL_COOKIES=y
CONFIG_LIBCURL_FILE=y
CONFIG_LIBCURL_FTP=y
CONFIG_LIBCURL_HTTP=y
CONFIG_LIBCURL_NGHTTP2=y
CONFIG_LIBCURL_NO_SMB="!"
CONFIG_LIBCURL_OPENSSL=y
CONFIG_LIBCURL_PROXY=y
CONFIG_LIBIIO_LOCAL_BACKEND=y
CONFIG_LIBIIO_NETWORK_BACKEND=y
CONFIG_LIBIIO_XML_BACKEND=y
CONFIG_LLDPD_WITH_CDP=y
CONFIG_LLDPD_WITH_CUSTOM=y
CONFIG_LLDPD_WITH_DOT1=y
CONFIG_LLDPD_WITH_DOT3=y
CONFIG_LLDPD_WITH_EDP=y
CONFIG_LLDPD_WITH_FDP=y
CONFIG_LLDPD_WITH_LLDPMED=y
CONFIG_LLDPD_WITH_PRIVSEP=y
CONFIG_LLDPD_WITH_SONMP=y
CONFIG_MINIUPNPD_IGDv2=y
CONFIG_OPENSSL_OPTIMIZE_SPEED=y
CONFIG_OPENSSL_WITH_DEPRECATED=y
CONFIG_OPENSSL_WITH_EC=y
CONFIG_OPENSSL_WITH_NPN=y
CONFIG_OPENSSL_WITH_PSK=y
CONFIG_OPENSSL_WITH_SRP=y
CONFIG_PACKAGE_BRCM80211_DEBUG=y
CONFIG_PACKAGE_avahi-dbus-daemon=y
CONFIG_PACKAGE_bfgminer=y
CONFIG_PACKAGE_block-mount=y
CONFIG_PACKAGE_ca-certificates=y
CONFIG_PACKAGE_cgi-io=y
CONFIG_PACKAGE_dbus=y
# CONFIG_PACKAGE_dnsmasq is not set
CONFIG_PACKAGE_fontconfig=y
CONFIG_PACKAGE_gdb=y
CONFIG_PACKAGE_gdbserver=y
CONFIG_PACKAGE_i2c-tools=y
CONFIG_PACKAGE_iio-utils=y
CONFIG_PACKAGE_iiod=y
CONFIG_PACKAGE_ip-full=y
CONFIG_PACKAGE_iperf=y
CONFIG_PACKAGE_iperf3=y
CONFIG_PACKAGE_ipset=y
CONFIG_PACKAGE_iptables-mod-ipsec=y
CONFIG_PACKAGE_iputils-ping=y
CONFIG_PACKAGE_iputils-ping6=y
# CONFIG_PACKAGE_iwinfo is not set
CONFIG_PACKAGE_jansson=y
CONFIG_PACKAGE_kmod-bluetooth=y
CONFIG_PACKAGE_kmod-crypto-aead=y
CONFIG

Re: [OpenWrt-Devel] [PATCH] brcm2708: add squashfs rootfs image

2018-04-24 Thread Stijn Tintel
On 24-04-18 19:17, Stijn Tintel wrote:
> On 24-04-18 17:59, Christian Lamparter wrote:
>> On Dienstag, 24. April 2018 13:29:17 CEST Stijn Tintel wrote:
>>> On 27-03-18 20:42, Christian Lamparter wrote:
>>>> This patch adds a image with squashfs as the root filesystem.
>>>> A rootfs_data partition will be generated on the first boot
>>>> and placed inside the rootfs partition (just after the squashfs
>>>> image).
>>>>
>>>> advantages:
>>>>  - it is possible to migrate from an existing -ext4
>>>>installation and back via sysupgrade.
>>>>  - existing partition layout will not be lost.
>>>>  - slightly smaller image size.
>>>>  - support for attendedsysupgrade
>>>>
>>>> disadvantages:
>>>>  - needs f2fs + tools as well. This is because fs-tools decides on the
>>>>blocksize of the sdcard. So either f2fs or ext4 can get choosen as
>>>>the rootfs_data filesystem (depends on the size of the root partition).
>>>>  - rootfs_data is placed into the rootfs partition. This makes
>>>>it difficult for tools that expect a /dev/mmc0pX device.
>>>>It also makes it difficult for data recovery tools since they
>>>>might not expect to find a embedded partition or will be
>>>>confused.
>>>>
>>>> For people with existing build configurations: make sure to include mkf2fs
>>>> and f2fsck package into the image... Otherwise the new -squashfs image will
>>>> boot of a ram-overlay and won't keep the configurations after a reboot.
>>>>
>>> Tried to sysupgrade one of my RPi0W from ext4 to squashfs, and it
>>> appeared to work at first, until I rebooted it again. Apparently the
>>> overlay is completely missing, the SD card only has /boot (FAT32) and /
>>> (squashfs). Can you please look into this?
>> I think know the problem. The commit-message mentions it and the symptoms
>> you are describing would fit. But just in case: can you please provide the
>> image's diffconfig (or full-config ... and I guess a bootlog wouldn't
>> hurt either - but it would be optional) to confirm?
> Please find diffconfig attached. The machine was running headless so I
> don't have a bootlog.
>> (I also tested it again on an uptodate "OpenWrt SNAPSHOT, r6759+2-9e848f901c"
>> with my rpi-b - which should be in the same family/subtarget as your RPi0W so
>> I can try your generated images as well.)
>>
>>> If you can get it resolved I will merge the patch.
>> The original issue [0] has been addressed by this patch [1]. And indeed
>> the luci-app will now successfully generate a image (currently, only for the 
>> rpi-3 though!):
>> "openwrt-dbbb09d2658d5c2-brcm2708-bcm2710-rpi-3-ext4-sdcard.img.gz"
>> and install it.
>>
>> this patch is therefore no longer necessary since it the existing ext4
>> images work as well. :) ... Plus the ext4 images don't confuse tools and
>> brains as much.
> I still find it useful, I've had way too many corrupted ext4 filesystems
> on my RPis, and I'm hoping squashfs + f2fs would be more reliable than
> ext4 on SD cards...
Read the commit message again, and I see what you mean. Must have
misread CONFIG_DEFAULT_mkf2fs=y as CONFIG_PACKAGE_mkf2fs=y. Too bad make
defconfig doesn't enable DEFAULT_PACKAGES. Sorry for the noise, I'll do
some more testing and accept this patch.

Thanks,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [LEDE-DEV] Enable DCO check on Github OpenWrt organisation

2018-05-17 Thread Stijn Tintel
On 09-05-18 03:03, Etienne Champetier wrote:
> Hi All,
>
> 2018-01-18 13:59 GMT-08:00 Etienne Champetier :
>> Hi All,
>>
>> Could someone enable this https://github.com/integration/dco on the
>> whole OpenWrt github org? (or at least on the packages repo)
> Friendly ping
> (I'm only a "member" not an "owner" (admin) )
>
>
I had enabled this back in January but disabled it immediately
afterwards because of this limitation:

23|10:02:24< stintel> if the first SoB != author it fails, instead of
looking for next SoB line
23|10:02:26< stintel> disabling it again

Stijn

___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
http://lists.infradead.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] "iwinfo_cli.c:(.text.startup+0x120): undefined reference to `iwinfo_backend_by_name'"

2014-10-27 Thread Stijn Tintel
On 27-10-14 21:54, Robert P. J. Day wrote:
>   just updated my git repo, tried to build for TL-MR3220 and got:
>
> iwinfo_cli.o: In function `main':
> iwinfo_cli.c:(.text.startup+0x120): undefined reference to 
> `iwinfo_backend_by_name'
> collect2: error: ld returned 1 exit status
> Makefile:40: recipe for target 'compile' failed
>
See https://dev.openwrt.org/ticket/18234 - make dirclean fixed it for me.

Kind regards,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/2] octeon: sysupgrade: support config restore

2014-12-04 Thread Stijn Tintel
---
 target/linux/octeon/base-files/lib/upgrade/platform.sh | 9 +
 1 file changed, 9 insertions(+)

diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh 
b/target/linux/octeon/base-files/lib/upgrade/platform.sh
index 11399a2..d81d7fd 100755
--- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
+++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
@@ -23,6 +23,15 @@ platform_get_rootfs() {
fi
 }
 
+platform_copy_config() {
+   local board="$(octeon_board_name)"
+   local rootfs="$(platform_get_rootfs)"
+
+   mount -t ext4 -o rw,noatime "${rootfs}" /mnt
+   cp -af "$CONF_TAR" /mnt/
+   umount /mnt
+}
+
 platform_do_upgrade() {
local board=$(octeon_board_name)
local rootfs="$(platform_get_rootfs)"
-- 
1.8.5.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 1/2] octeon: sysupgrade: get rootfsdev from kernel cmdline

2014-12-04 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 .../octeon/base-files/lib/upgrade/platform.sh  | 26 --
 1 file changed, 24 insertions(+), 2 deletions(-)

diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh 
b/target/linux/octeon/base-files/lib/upgrade/platform.sh
index e4c7b6f..11399a2 100755
--- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
+++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
@@ -1,11 +1,33 @@
 #
-# Copyright (C) 2010 OpenWrt.org
+# Copyright (C) 2014 OpenWrt.org
 #
 
 . /lib/functions/octeon.sh
 
+platform_get_rootfs() {
+   local rootfsdev
+
+   if read cmdline < /proc/cmdline; then
+   case "$cmdline" in
+   *block2mtd=*)
+   rootfsdev="${cmdline##*block2mtd=}"
+   rootfsdev="${rootfsdev%%,*}"
+   ;;
+   *root=*)
+   rootfsdev="${cmdline##*root=}"
+   rootfsdev="${rootfsdev%% *}"
+   ;;
+   esac
+
+   echo "${rootfsdev}"
+   fi
+}
+
 platform_do_upgrade() {
local board=$(octeon_board_name)
+   local rootfs="$(platform_get_rootfs)"
+
+   [ -d "${rootfs}" ] || return 1
 
case "$board" in
erlite)
@@ -22,7 +44,7 @@ platform_do_upgrade() {
mount -t vfat /dev/sda1 /boot
tar xf $tar_file sysupgrade-erlite/kernel -O > /boot/vmlinux.64
md5sum /boot/vmlinux.64 | cut -f1 -d " " > /boot/vmlinux.64.md5
-   tar xf $tar_file sysupgrade-erlite/root -O | dd of=/dev/sda2 
bs=4096
+   tar xf $tar_file sysupgrade-erlite/root -O | dd of="${rootfs}" 
bs=4096
sync
umount /mnt
return 0
-- 
1.8.5.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/3] octeon: sysupgrade: support config restore

2014-12-04 Thread Stijn Tintel
---
 target/linux/octeon/base-files/lib/upgrade/platform.sh | 9 +
 1 file changed, 9 insertions(+)

diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh 
b/target/linux/octeon/base-files/lib/upgrade/platform.sh
index 11399a2..d81d7fd 100755
--- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
+++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
@@ -23,6 +23,15 @@ platform_get_rootfs() {
fi
 }
 
+platform_copy_config() {
+   local board="$(octeon_board_name)"
+   local rootfs="$(platform_get_rootfs)"
+
+   mount -t ext4 -o rw,noatime "${rootfs}" /mnt
+   cp -af "$CONF_TAR" /mnt/
+   umount /mnt
+}
+
 platform_do_upgrade() {
local board=$(octeon_board_name)
local rootfs="$(platform_get_rootfs)"
-- 
1.8.5.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 3/3] octeon: add support for 3.18 kernel

2014-12-04 Thread Stijn Tintel
Runtime tested on Ubiquiti EdgeRouter Lite.

Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/config-3.18| 252 +
 .../100-ubnt_edgerouter2_support.patch |  31 +++
 .../110-er200-ethernet_probe_order.patch   |  34 +++
 .../patches-3.18/120-octeon_platform_usb.patch |  20 ++
 4 files changed, 337 insertions(+)
 create mode 100644 target/linux/octeon/config-3.18
 create mode 100644 
target/linux/octeon/patches-3.18/100-ubnt_edgerouter2_support.patch
 create mode 100644 
target/linux/octeon/patches-3.18/110-er200-ethernet_probe_order.patch
 create mode 100644 
target/linux/octeon/patches-3.18/120-octeon_platform_usb.patch

diff --git a/target/linux/octeon/config-3.18 b/target/linux/octeon/config-3.18
new file mode 100644
index 000..280014c
--- /dev/null
+++ b/target/linux/octeon/config-3.18
@@ -0,0 +1,252 @@
+CONFIG_64BIT=y
+CONFIG_64BIT_PHYS_ADDR=y
+CONFIG_ARCH_BINFMT_ELF_RANDOMIZE_PIE=y
+CONFIG_ARCH_DISCARD_MEMBLOCK=y
+CONFIG_ARCH_DMA_ADDR_T_64BIT=y
+CONFIG_ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE=y
+# CONFIG_ARCH_HAS_SG_CHAIN is not set
+CONFIG_ARCH_HAVE_CUSTOM_GPIO_H=y
+CONFIG_ARCH_HIBERNATION_POSSIBLE=y
+CONFIG_ARCH_MIGHT_HAVE_PC_PARPORT=y
+CONFIG_ARCH_MIGHT_HAVE_PC_SERIO=y
+# CONFIG_ARCH_NEEDS_CPU_IDLE_COUPLED is not set
+CONFIG_ARCH_PHYS_ADDR_T_64BIT=y
+CONFIG_ARCH_REQUIRE_GPIOLIB=y
+CONFIG_ARCH_SPARSEMEM_ENABLE=y
+CONFIG_ARCH_SUSPEND_POSSIBLE=y
+CONFIG_ARCH_WANT_COMPAT_IPC_PARSE_VERSION=y
+CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y
+CONFIG_ARCH_WANT_OLD_COMPAT_IPC=y
+# CONFIG_AUDIT_ARCH_COMPAT_GENERIC is not set
+CONFIG_BINFMT_ELF32=y
+CONFIG_BLK_DEV_SD=y
+CONFIG_BLOCK_COMPAT=y
+# CONFIG_BOOTPARAM_HUNG_TASK_PANIC is not set
+CONFIG_BOOTPARAM_HUNG_TASK_PANIC_VALUE=0
+CONFIG_BUILTIN_DTB=y
+# CONFIG_CAVIUM_CN63XXP1 is not set
+# CONFIG_CAVIUM_OCTEON_2ND_KERNEL is not set
+CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE=2
+CONFIG_CAVIUM_OCTEON_LOCK_L2=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_EXCEPTION=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_INTERRUPT=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_LOW_LEVEL_INTERRUPT=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_MEMCPY=y
+CONFIG_CAVIUM_OCTEON_LOCK_L2_TLB=y
+CONFIG_CAVIUM_OCTEON_SOC=y
+CONFIG_CC_OPTIMIZE_FOR_SIZE=y
+CONFIG_CEVT_R4K=y
+CONFIG_CLONE_BACKWARDS=y
+CONFIG_COMPAT=y
+CONFIG_COMPAT_BRK=y
+CONFIG_COMPAT_NETLINK_MESSAGES=y
+CONFIG_CPU_BIG_ENDIAN=y
+CONFIG_CPU_CAVIUM_OCTEON=y
+CONFIG_CPU_GENERIC_DUMP_TLB=y
+CONFIG_CPU_HAS_PREFETCH=y
+CONFIG_CPU_HAS_SYNC=y
+CONFIG_CPU_MIPSR2=y
+CONFIG_CPU_NEEDS_NO_SMARTMIPS_OR_MICROMIPS=y
+CONFIG_CPU_RMAP=y
+CONFIG_CPU_SUPPORTS_64BIT_KERNEL=y
+CONFIG_CPU_SUPPORTS_HIGHMEM=y
+CONFIG_CPU_SUPPORTS_HUGEPAGES=y
+CONFIG_CRAMFS=y
+CONFIG_CRC16=y
+CONFIG_CRYPTO_CRC32C=y
+CONFIG_CRYPTO_HASH=y
+CONFIG_CRYPTO_HASH2=y
+CONFIG_DEBUG_INFO=y
+CONFIG_DEBUG_SPINLOCK=y
+CONFIG_DEFAULT_HUNG_TASK_TIMEOUT=120
+CONFIG_DETECT_HUNG_TASK=y
+CONFIG_DEVKMEM=y
+CONFIG_DMA_COHERENT=y
+CONFIG_DNOTIFY=y
+CONFIG_DTC=y
+CONFIG_EARLY_PRINTK=y
+CONFIG_EDAC_SUPPORT=y
+CONFIG_ENABLE_MUST_CHECK=y
+CONFIG_EXT4_FS=y
+CONFIG_FAT_FS=y
+CONFIG_FRAME_WARN=2048
+CONFIG_FS_MBCACHE=y
+CONFIG_GENERIC_CLOCKEVENTS=y
+CONFIG_GENERIC_CLOCKEVENTS_BUILD=y
+CONFIG_GENERIC_CMOS_UPDATE=y
+CONFIG_GENERIC_IO=y
+CONFIG_GENERIC_IRQ_SHOW=y
+CONFIG_GENERIC_PCI_IOMAP=y
+CONFIG_GENERIC_SMP_IDLE_THREAD=y
+CONFIG_GPIOLIB=y
+CONFIG_GPIO_DEVRES=y
+CONFIG_GPIO_OCTEON=y
+CONFIG_GPIO_SYSFS=y
+# CONFIG_HAMRADIO is not set
+CONFIG_HARDWARE_WATCHPOINTS=y
+CONFIG_HAS_DMA=y
+CONFIG_HAS_IOMEM=y
+CONFIG_HAS_IOPORT_MAP=y
+CONFIG_HAVE_64BIT_ALIGNED_ACCESS=y
+CONFIG_HAVE_ARCH_JUMP_LABEL=y
+CONFIG_HAVE_ARCH_KGDB=y
+CONFIG_HAVE_ARCH_SECCOMP_FILTER=y
+CONFIG_HAVE_ARCH_TRACEHOOK=y
+CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y
+# CONFIG_HAVE_BOOTMEM_INFO_NODE is not set
+CONFIG_HAVE_BPF_JIT=y
+CONFIG_HAVE_CC_STACKPROTECTOR=y
+CONFIG_HAVE_CONTEXT_TRACKING=y
+CONFIG_HAVE_C_RECORDMCOUNT=y
+CONFIG_HAVE_DEBUG_KMEMLEAK=y
+CONFIG_HAVE_DEBUG_STACKOVERFLOW=y
+CONFIG_HAVE_DMA_API_DEBUG=y
+CONFIG_HAVE_DMA_ATTRS=y
+CONFIG_HAVE_DMA_CONTIGUOUS=y
+CONFIG_HAVE_DYNAMIC_FTRACE=y
+CONFIG_HAVE_FTRACE_MCOUNT_RECORD=y
+CONFIG_HAVE_FUNCTION_GRAPH_TRACER=y
+CONFIG_HAVE_FUNCTION_TRACER=y
+CONFIG_HAVE_GENERIC_DMA_COHERENT=y
+CONFIG_HAVE_IDE=y
+CONFIG_HAVE_MEMBLOCK=y
+CONFIG_HAVE_MEMBLOCK_NODE_MAP=y
+CONFIG_HAVE_MEMORY_PRESENT=y
+CONFIG_HAVE_MOD_ARCH_SPECIFIC=y
+CONFIG_HAVE_NET_DSA=y
+CONFIG_HAVE_OPROFILE=y
+CONFIG_HAVE_PERF_EVENTS=y
+CONFIG_HAVE_SYSCALL_TRACEPOINTS=y
+CONFIG_HAVE_VIRT_CPU_ACCOUNTING_GEN=y
+# CONFIG_HIGH_RES_TIMERS is not set
+CONFIG_HOLES_IN_ZONE=y
+# CONFIG_HUGETLBFS is not set
+CONFIG_HW_HAS_PCI=y
+CONFIG_HW_RANDOM=y
+CONFIG_HW_RANDOM_OCTEON=y
+CONFIG_HZ=250
+# CONFIG_HZ_100 is not set
+CONFIG_HZ_250=y
+CONFIG_HZ_PERIODIC=y
+CONFIG_INITRAMFS_SOURCE=""
+CONFIG_IOMMU_HELPER=y
+CONFIG_IRQCHIP=y
+CONFIG_IRQ_DOMAIN=y
+CONFIG_IRQ_FORCED_THREADING=y
+CONFIG_IRQ_WORK=y
+CONFIG_JBD2=y
+CONFIG_KALLSYMS=y
+CONFIG_KERNFS=y
+CONFIG_KEXEC=y
+CONFIG_LIBFDT=y
+CONFIG_MDIO_BOARDINFO=y
+CONFIG_MDIO_OCTEON=y
+CON

[OpenWrt-Devel] [PATCH 1/3] octeon: sysupgrade: get rootfsdev from kernel cmdline

2014-12-04 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 .../octeon/base-files/lib/upgrade/platform.sh  | 26 --
 1 file changed, 24 insertions(+), 2 deletions(-)

diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh 
b/target/linux/octeon/base-files/lib/upgrade/platform.sh
index e4c7b6f..11399a2 100755
--- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
+++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
@@ -1,11 +1,33 @@
 #
-# Copyright (C) 2010 OpenWrt.org
+# Copyright (C) 2014 OpenWrt.org
 #
 
 . /lib/functions/octeon.sh
 
+platform_get_rootfs() {
+   local rootfsdev
+
+   if read cmdline < /proc/cmdline; then
+   case "$cmdline" in
+   *block2mtd=*)
+   rootfsdev="${cmdline##*block2mtd=}"
+   rootfsdev="${rootfsdev%%,*}"
+   ;;
+   *root=*)
+   rootfsdev="${cmdline##*root=}"
+   rootfsdev="${rootfsdev%% *}"
+   ;;
+   esac
+
+   echo "${rootfsdev}"
+   fi
+}
+
 platform_do_upgrade() {
local board=$(octeon_board_name)
+   local rootfs="$(platform_get_rootfs)"
+
+   [ -d "${rootfs}" ] || return 1
 
case "$board" in
erlite)
@@ -22,7 +44,7 @@ platform_do_upgrade() {
mount -t vfat /dev/sda1 /boot
tar xf $tar_file sysupgrade-erlite/kernel -O > /boot/vmlinux.64
md5sum /boot/vmlinux.64 | cut -f1 -d " " > /boot/vmlinux.64.md5
-   tar xf $tar_file sysupgrade-erlite/root -O | dd of=/dev/sda2 
bs=4096
+   tar xf $tar_file sysupgrade-erlite/root -O | dd of="${rootfs}" 
bs=4096
sync
umount /mnt
return 0
-- 
1.8.5.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH 1/3] octeon: sysupgrade: get rootfsdev from kernel cmdline

2014-12-04 Thread Stijn Tintel
On 05-12-14 01:01, Stijn Tintel wrote:
>  platform_do_upgrade() {
>   local board=$(octeon_board_name)
> + local rootfs="$(platform_get_rootfs)"
> +
> + [ -d "${rootfs}" ] || return 1
This should be -b, please ignore this patch series, I'll send a new one.

Kind regards,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] octeon: sysupgrade: fix test for rootfs device

2014-12-04 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/base-files/lib/upgrade/platform.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh 
b/target/linux/octeon/base-files/lib/upgrade/platform.sh
index d81d7fd..1df3d17 100755
--- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
+++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
@@ -36,7 +36,7 @@ platform_do_upgrade() {
local board=$(octeon_board_name)
local rootfs="$(platform_get_rootfs)"
 
-   [ -d "${rootfs}" ] || return 1
+   [ -b "${rootfs}" ] || return 1
 
case "$board" in
erlite)
-- 
1.8.5.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 3/3] octeon: sysupgrade: support config restore on ERL

2014-12-04 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 .../linux/octeon/base-files/lib/preinit/79_move_config | 18 ++
 target/linux/octeon/base-files/lib/upgrade/platform.sh | 11 +++
 2 files changed, 25 insertions(+), 4 deletions(-)
 create mode 100644 target/linux/octeon/base-files/lib/preinit/79_move_config

diff --git a/target/linux/octeon/base-files/lib/preinit/79_move_config 
b/target/linux/octeon/base-files/lib/preinit/79_move_config
new file mode 100644
index 000..39cefd5
--- /dev/null
+++ b/target/linux/octeon/base-files/lib/preinit/79_move_config
@@ -0,0 +1,18 @@
+#!/bin/sh
+# Copyright (C) 2014 OpenWrt.org
+
+move_config() {
+   . /lib/functions/octeon.sh
+
+   local board="$(octeon_board_name)"
+
+   case "$board" in
+   erlite)
+   mount -t vfat /dev/sda1 /mnt
+   mv -f /mnt/sysupgrade.tgz /
+   umount /mnt
+   ;;
+   esac
+}
+
+boot_hook_add preinit_mount_root move_config
diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh 
b/target/linux/octeon/base-files/lib/upgrade/platform.sh
index 8d6f9a1..ad075d5 100755
--- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
+++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
@@ -25,11 +25,14 @@ platform_get_rootfs() {
 
 platform_copy_config() {
local board="$(octeon_board_name)"
-   local rootfs="$(platform_get_rootfs)"
 
-   mount -t ext4 -o rw,noatime "${rootfs}" /mnt
-   cp -af "$CONF_TAR" /mnt/
-   umount /mnt
+   case "$board" in
+   erlite)
+   mount -t vfat /dev/sda1 /mnt
+   cp -af "$CONF_TAR" /mnt/
+   umount /mnt
+   ;;
+   esac
 }
 
 platform_do_upgrade() {
-- 
2.0.4
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 1/3] octeon: sysupgrade: fix test for rootfs device

2014-12-04 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/base-files/lib/upgrade/platform.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh 
b/target/linux/octeon/base-files/lib/upgrade/platform.sh
index d81d7fd..1df3d17 100755
--- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
+++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
@@ -36,7 +36,7 @@ platform_do_upgrade() {
local board=$(octeon_board_name)
local rootfs="$(platform_get_rootfs)"
 
-   [ -d "${rootfs}" ] || return 1
+   [ -b "${rootfs}" ] || return 1
 
case "$board" in
erlite)
-- 
2.0.4
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/3] octeon: sysupgrade: rename old kernel after mounting /boot

2014-12-04 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/base-files/lib/upgrade/platform.sh | 7 ---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/target/linux/octeon/base-files/lib/upgrade/platform.sh 
b/target/linux/octeon/base-files/lib/upgrade/platform.sh
index 1df3d17..8d6f9a1 100755
--- a/target/linux/octeon/base-files/lib/upgrade/platform.sh
+++ b/target/linux/octeon/base-files/lib/upgrade/platform.sh
@@ -44,18 +44,19 @@ platform_do_upgrade() {
local kernel_length=`(tar xf $tar_file sysupgrade-erlite/kernel 
-O | wc -c) 2> /dev/null`
local rootfs_length=`(tar xf $tar_file sysupgrade-erlite/root 
-O | wc -c) 2> /dev/null`
 
+   mkdir -p /boot
+   mount -t vfat /dev/sda1 /boot
+
[ -f /boot/vmlinux.64 -a ! -L /boot/vmlinux.64 ] && {
mv /boot/vmlinux.64 /boot/vmlinux.64.previous
mv /boot/vmlinux.64.md5 /boot/vmlinux.64.md5.previous
}
 
-   mkdir -p /boot
-   mount -t vfat /dev/sda1 /boot
tar xf $tar_file sysupgrade-erlite/kernel -O > /boot/vmlinux.64
md5sum /boot/vmlinux.64 | cut -f1 -d " " > /boot/vmlinux.64.md5
tar xf $tar_file sysupgrade-erlite/root -O | dd of="${rootfs}" 
bs=4096
sync
-   umount /mnt
+   umount /boot
return 0
;;
esac
-- 
2.0.4
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] 090-backport_netfilter_rtcache.patch and IPsec routing/connection errors/packet loss

2014-12-22 Thread Stijn Tintel
On 20-12-14 00:04, Andre Valentin wrote:
> Hi!
>
> If I enable this patch/module, I get strange errors with my OpenWRT based 
> IPsec router. Packets are accepted and then lost, and not encrypted. Only the 
> first comes through, especially if stateless
> protocolls (udp, icmp) are used.
>
I noticed this as well, both with 3.14 kernel + backported patch, and
with 3.18 kernel + patch. Reporting it to netfilter-devel and netdev
lists is still on my todo list. Feel free to beat me to it

Kind regards,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] 090-backport_netfilter_rtcache.patch and IPsec routing/connection errors/packet loss

2014-12-23 Thread Stijn Tintel
On 23-12-14 20:11, Andre Valentin wrote:
> Hi!
>
> I just recompiled the module and loaded it on the router. But it seems that 
> this does not fix the error. 5 minutes later I got several alerts (ping 
> checks).
The workaround below seems to work for me. How did you apply this patch
to the OpenWrt code
>> Untested workaround.
>> I'll look into this in more detail over the holidays.
>>
>> netfilter: rtcache: don't cache dst for skb with active transformer
>>
>> diff --git a/net/netfilter/nf_conntrack_rtcache.c 
>> b/net/netfilter/nf_conntrack_rtcache.c
>> --- a/net/netfilter/nf_conntrack_rtcache.c
>> +++ b/net/netfilter/nf_conntrack_rtcache.c
>> @@ -19,6 +19,7 @@
>>  #include 
>>
>>  #include 
>> +#include 
>>
>>  #include 
>>  #include 
>> @@ -191,6 +192,9 @@ static unsigned int nf_rtcache_forward(const struct 
>> nf_hook_ops *ops,
>> struct nf_conn *ct;
>> int iif;
>>
>> +   if (secpath_exists(skb))
>> +   return NF_ACCEPT;
>> +
>> ct = nf_ct_get(skb, &ctinfo);
>> if (!ct)
>> return NF_ACCEPT;
Kind regards,
Stijn
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 2/2] octeon: enable VLAN support

2015-01-01 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/config-3.14 | 1 -
 target/linux/octeon/config-3.18 | 1 -
 2 files changed, 2 deletions(-)

diff --git a/target/linux/octeon/config-3.14 b/target/linux/octeon/config-3.14
index baabe91..79f1efe 100644
--- a/target/linux/octeon/config-3.14
+++ b/target/linux/octeon/config-3.14
@@ -232,7 +232,6 @@ CONFIG_USB_SUPPORT=y
 # CONFIG_USB_UHCI_HCD is not set
 CONFIG_USE_OF=y
 CONFIG_VFAT_FS=y
-# CONFIG_VLAN_8021Q is not set
 CONFIG_VM_EVENT_COUNTERS=y
 CONFIG_WEAK_ORDERING=y
 CONFIG_XPS=y
diff --git a/target/linux/octeon/config-3.18 b/target/linux/octeon/config-3.18
index 280014c..2055aef 100644
--- a/target/linux/octeon/config-3.18
+++ b/target/linux/octeon/config-3.18
@@ -243,7 +243,6 @@ CONFIG_USB_SUPPORT=y
 # CONFIG_USB_UHCI_HCD is not set
 CONFIG_USE_OF=y
 CONFIG_VFAT_FS=y
-# CONFIG_VLAN_8021Q is not set
 CONFIG_VM_EVENT_COUNTERS=y
 CONFIG_WEAK_ORDERING=y
 CONFIG_XPS=y
-- 
2.0.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH 1/2] octeon: remove config-default

2015-01-01 Thread Stijn Tintel
Signed-off-by: Stijn Tintel 
---
 target/linux/octeon/config-default | 244 -
 1 file changed, 244 deletions(-)
 delete mode 100644 target/linux/octeon/config-default

diff --git a/target/linux/octeon/config-default 
b/target/linux/octeon/config-default
deleted file mode 100644
index f83daac..000
--- a/target/linux/octeon/config-default
+++ /dev/null
@@ -1,244 +0,0 @@
-CONFIG_64BIT=y
-CONFIG_64BIT_PHYS_ADDR=y
-CONFIG_ARCH_BINFMT_ELF_RANDOMIZE_PIE=y
-CONFIG_ARCH_DISCARD_MEMBLOCK=y
-CONFIG_ARCH_DMA_ADDR_T_64BIT=y
-CONFIG_ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE=y
-CONFIG_ARCH_HAVE_CUSTOM_GPIO_H=y
-CONFIG_ARCH_HIBERNATION_POSSIBLE=y
-CONFIG_ARCH_PHYS_ADDR_T_64BIT=y
-CONFIG_ARCH_REQUIRE_GPIOLIB=y
-CONFIG_ARCH_SPARSEMEM_ENABLE=y
-CONFIG_ARCH_SUPPORTS_MSI=y
-CONFIG_ARCH_SUSPEND_POSSIBLE=y
-CONFIG_ARCH_WANT_COMPAT_IPC_PARSE_VERSION=y
-CONFIG_ARCH_WANT_IPC_PARSE_VERSION=y
-CONFIG_ARCH_WANT_OLD_COMPAT_IPC=y
-# CONFIG_ARPD is not set
-CONFIG_BINFMT_ELF32=y
-CONFIG_BLK_DEV_SD=y
-CONFIG_BLOCK_COMPAT=y
-# CONFIG_BOOTPARAM_HUNG_TASK_PANIC is not set
-CONFIG_BOOTPARAM_HUNG_TASK_PANIC_VALUE=0
-# CONFIG_CAVIUM_CN63XXP1 is not set
-# CONFIG_CAVIUM_OCTEON_2ND_KERNEL is not set
-CONFIG_CAVIUM_OCTEON_CVMSEG_SIZE=2
-CONFIG_CAVIUM_OCTEON_HW_FIX_UNALIGNED=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_EXCEPTION=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_INTERRUPT=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_LOW_LEVEL_INTERRUPT=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_MEMCPY=y
-CONFIG_CAVIUM_OCTEON_LOCK_L2_TLB=y
-CONFIG_CAVIUM_OCTEON_REFERENCE_BOARD=y
-CONFIG_CC_OPTIMIZE_FOR_SIZE=y
-CONFIG_CEVT_R4K=y
-CONFIG_CLONE_BACKWARDS=y
-CONFIG_COMPAT=y
-CONFIG_COMPAT_BRK=y
-CONFIG_COMPAT_NETLINK_MESSAGES=y
-CONFIG_CPU_BIG_ENDIAN=y
-CONFIG_CPU_CAVIUM_OCTEON=y
-CONFIG_CPU_GENERIC_DUMP_TLB=y
-CONFIG_CPU_HAS_PREFETCH=y
-CONFIG_CPU_HAS_SYNC=y
-CONFIG_CPU_MIPSR2=y
-CONFIG_CPU_RMAP=y
-CONFIG_CPU_SUPPORTS_64BIT_KERNEL=y
-CONFIG_CPU_SUPPORTS_HIGHMEM=y
-CONFIG_CPU_SUPPORTS_HUGEPAGES=y
-CONFIG_CRAMFS=y
-CONFIG_CRC16=y
-CONFIG_CRYPTO_CRC32C=y
-CONFIG_CRYPTO_HASH=y
-CONFIG_CRYPTO_HASH2=y
-CONFIG_DEBUG_INFO=y
-CONFIG_DEBUG_SPINLOCK=y
-CONFIG_DEFAULT_HUNG_TASK_TIMEOUT=120
-CONFIG_DETECT_HUNG_TASK=y
-CONFIG_DEVKMEM=y
-CONFIG_DMA_COHERENT=y
-CONFIG_DNOTIFY=y
-CONFIG_DTC=y
-CONFIG_EARLY_PRINTK=y
-CONFIG_EDAC_SUPPORT=y
-CONFIG_ENABLE_MUST_CHECK=y
-CONFIG_EXT4_FS=y
-CONFIG_FAT_FS=y
-CONFIG_FRAME_WARN=2048
-CONFIG_FS_MBCACHE=y
-CONFIG_GENERIC_CLOCKEVENTS=y
-CONFIG_GENERIC_CLOCKEVENTS_BUILD=y
-CONFIG_GENERIC_CMOS_UPDATE=y
-CONFIG_GENERIC_IO=y
-CONFIG_GENERIC_IRQ_SHOW=y
-CONFIG_GENERIC_PCI_IOMAP=y
-CONFIG_GENERIC_SMP_IDLE_THREAD=y
-CONFIG_GPIOLIB=y
-CONFIG_GPIO_DEVRES=y
-CONFIG_GPIO_OCTEON=y
-CONFIG_GPIO_SYSFS=y
-# CONFIG_HAMRADIO is not set
-CONFIG_HARDWARE_WATCHPOINTS=y
-CONFIG_HAS_DMA=y
-CONFIG_HAS_IOMEM=y
-CONFIG_HAS_IOPORT=y
-CONFIG_HAVE_64BIT_ALIGNED_ACCESS=y
-CONFIG_HAVE_ARCH_JUMP_LABEL=y
-CONFIG_HAVE_ARCH_KGDB=y
-CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE=y
-# CONFIG_HAVE_BOOTMEM_INFO_NODE is not set
-CONFIG_HAVE_C_RECORDMCOUNT=y
-CONFIG_HAVE_DEBUG_KMEMLEAK=y
-CONFIG_HAVE_DMA_API_DEBUG=y
-CONFIG_HAVE_DMA_ATTRS=y
-CONFIG_HAVE_DYNAMIC_FTRACE=y
-CONFIG_HAVE_FTRACE_MCOUNT_RECORD=y
-CONFIG_HAVE_FUNCTION_GRAPH_TRACER=y
-CONFIG_HAVE_FUNCTION_TRACER=y
-CONFIG_HAVE_FUNCTION_TRACE_MCOUNT_TEST=y
-CONFIG_HAVE_GENERIC_DMA_COHERENT=y
-CONFIG_HAVE_GENERIC_HARDIRQS=y
-CONFIG_HAVE_IDE=y
-CONFIG_HAVE_MEMBLOCK=y
-CONFIG_HAVE_MEMBLOCK_NODE_MAP=y
-CONFIG_HAVE_MEMORY_PRESENT=y
-CONFIG_HAVE_MOD_ARCH_SPECIFIC=y
-CONFIG_HAVE_NET_DSA=y
-CONFIG_HAVE_OPROFILE=y
-CONFIG_HAVE_PERF_EVENTS=y
-# CONFIG_HIGH_RES_TIMERS is not set
-CONFIG_HOLES_IN_ZONE=y
-# CONFIG_HUGETLBFS is not set
-CONFIG_HW_HAS_PCI=y
-CONFIG_HW_RANDOM=y
-CONFIG_HW_RANDOM_OCTEON=y
-CONFIG_HZ=250
-# CONFIG_HZ_100 is not set
-CONFIG_HZ_250=y
-CONFIG_HZ_PERIODIC=y
-# CONFIG_I2C_OCTEON is not set
-CONFIG_INITRAMFS_SOURCE=""
-CONFIG_IOMMU_HELPER=y
-CONFIG_IRQCHIP=y
-CONFIG_IRQ_DOMAIN=y
-CONFIG_IRQ_FORCED_THREADING=y
-CONFIG_IRQ_WORK=y
-CONFIG_JBD2=y
-CONFIG_KALLSYMS=y
-CONFIG_KEXEC=y
-CONFIG_LIBFDT=y
-CONFIG_MDIO_BOARDINFO=y
-CONFIG_MDIO_OCTEON=y
-CONFIG_MIPS=y
-CONFIG_MIPS32_COMPAT=y
-CONFIG_MIPS32_N32=y
-CONFIG_MIPS32_O32=y
-# CONFIG_MIPS_HUGE_TLB_SUPPORT is not set
-CONFIG_MIPS_L1_CACHE_SHIFT=7
-# CONFIG_MIPS_MACHINE is not set
-CONFIG_MIPS_MT_DISABLED=y
-CONFIG_MIPS_PGD_C0_CONTEXT=y
-CONFIG_MODULES_USE_ELF_REL=y
-CONFIG_MODULES_USE_ELF_RELA=y
-# CONFIG_MTD_CFI_INTELEXT is not set
-CONFIG_MTD_CMDLINE_PARTS=y
-# CONFIG_MTD_COMPLEX_MAPPINGS is not set
-CONFIG_MTD_OF_PARTS=y
-CONFIG_MTD_PHYSMAP=y
-CONFIG_MTD_PHYSMAP_OF=y
-CONFIG_MUTEX_SPIN_ON_OWNER=y
-CONFIG_NEED_SG_DMA_LENGTH=y
-CONFIG_NLS=y
-CONFIG_NLS_CODEPAGE_437=y
-CONFIG_NLS_ISO8859_1=y
-CONFIG_NO_GENERIC_PCI_IOPORT_MAP=y
-CONFIG_NR_CPUS=16
-CONFIG_NR_CPUS_DEFAULT_16=y
-CONFIG_OCTEON_ETHERNET=y
-# CONFIG_OCTEON_ILM is not set
-CONFIG_OCTEON_MGMT_ETHERNET=y
-CONFIG_OCTEON_USB=y
-CONFIG_OCTEON_WDT=y
-CONFIG_OF=y
-CONFIG_OF_ADDRESS=y
-CONFIG_O

[OpenWrt-Devel] [PATCH 03/10] kernel/modules: kmod-crypto-manager: depend on kmod-crypto-aead

2015-01-02 Thread Stijn Tintel
---
 package/kernel/linux/modules/crypto.mk | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/package/kernel/linux/modules/crypto.mk 
b/package/kernel/linux/modules/crypto.mk
index ad1fe4e..d17f1e1 100644
--- a/package/kernel/linux/modules/crypto.mk
+++ b/package/kernel/linux/modules/crypto.mk
@@ -12,7 +12,6 @@ CRYPTO_MODULES = \
BLKCIPHER2=crypto_blkcipher
 
 CRYPTOMGR_MODULES = \
-   AEAD2=aead \
MANAGER2=cryptomgr
 
 crypto_confvar=CONFIG_CRYPTO_$(word 1,$(subst =,$(space),$(1)))
@@ -65,9 +64,8 @@ $(eval $(call KernelPackage,crypto-hash))
 
 define KernelPackage/crypto-manager
   TITLE:=CryptoAPI algorithm manager
-  DEPENDS:=+kmod-crypto-hash +kmod-crypto-pcompress
+  DEPENDS:=+kmod-crypto-aead +kmod-crypto-hash +kmod-crypto-pcompress
   KCONFIG:= \
-   CONFIG_CRYPTO_AEAD \
CONFIG_CRYPTO_MANAGER \
$(foreach mod,$(CRYPTOMGR_MODULES),$(call crypto_confvar,$(mod)))
   FILES:=$(foreach mod,$(CRYPTOMGR_MODULES),$(call crypto_file,$(mod)))
-- 
2.0.5
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


  1   2   3   4   >