Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Issue-52]: add kmod-p44-ledchain #21

Merged
merged 1 commit into from
Oct 2, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions onion/patches/254-p44-ledchain.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
--- /dev/null
+++ b/package/kernel/p44-ledchain/Makefile
@@ -0,0 +1,35 @@
+include $(TOPDIR)/rules.mk
+include $(INCLUDE_DIR)/kernel.mk
+
+PKG_NAME:=p44-ledchain
+
+PKG_MIRROR_HASH:=dc5c915d8d9c236486ecbebe242a9ac2558072f53bda4184cd978640d48d9b60
+PKG_SOURCE_URL:=https://github.com/plan44/plan44-feed.git
+PKG_SOURCE_DATE:=2023-08-16
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_VERSION:=9d4ed3ebe1a2d06cad67524a7bbb2ad7596f133e
+
+include $(INCLUDE_DIR)/package.mk
+
+define KernelPackage/$(PKG_NAME)
+ SUBMENU:=Other modules
+ DEPENDS:=@(TARGET_ramips_mt76x8||TARGET_ramips_mt7688)
+ TITLE:=p44-ledchain driver for WS28xx/SK68xx
+ FILES:= $(PKG_BUILD_DIR)/p44-ledchain/src/p44-ledchain.ko
+endef
+
+define KernelPackage/$(PKG_NAME)/description
+ This package contains the p44-ledchain kernel driver for WS28xx and SK68xx type serial LED chains
+ for MT7688, which uses PWM unit to generate the WS28xx timing without blocking IRQs.
+endef
+
+MAKE_OPTS:= \
+ ARCH="$(LINUX_KARCH)" \
+ CROSS_COMPILE="$(TARGET_CROSS)" \
+ SUBDIRS="$(PKG_BUILD_DIR)"
+
+define Build/Compile
+ $(KERNEL_MAKE) EXTRA_CFLAGS=-Wno-vla M="$(PKG_BUILD_DIR)/p44-ledchain/src"
+endef
+
+$(eval $(call KernelPackage,$(PKG_NAME)))