Re: [OpenWrt-Devel] Broken packaging of modules (updating them) when using @lt or @gt
On Sat, 15 Dec 2018 at 06:00, Rafał Miłecki wrote: > > I've noticed a problem with kmod-phy-bcm-ns-usb2 defined in the > target/linux/bcm53xx/modules.mk > > Steps to reproduce: > 1) Setup .config with: > CONFIG_TARGET_bcm53xx > CONFIG_TARGET_MULTI_PROFILE > TARGET_ALL_PROFILES > CONFIG_TARGET_PER_DEVICE_ROOTFS > 2) make V=s > 3) vim > build_dir/target-*/linux-*/linux-*/drivers/phy/broadcom/phy-bcm-ns-usb2.c > 4) make V=s > > That will result in rebuilding: > build_dir/target-*/linux-*/linux-*/drivers/phy/broadcom/phy-bcm-ns-usb2.ko > (expected). > > However it won't update: > build_dir/target-*/linux-*/target-dir-*/lib/modules/4.14.88/phy-bcm-ns-usb2.ko > > I've bisected/notices it's caused by using: > $(LINUX_DIR)/drivers/phy/phy-bcm-ns-usb2.ko@lt4.13 \ > $(LINUX_DIR)/drivers/phy/broadcom/phy-bcm-ns-usb2.ko@gt4.13 > > If I drop old kernel compatibility and simply use: > $(LINUX_DIR)/drivers/phy/broadcom/phy-bcm-ns-usb2.ko > the problem disappears. Probably because kmod .ipk was not rebuilt. How about also applying version_filter $(FILES) in the following line [1] $$(IPKG_kmod-$(1)): $$(wildcard $$(FILES)) [1] https://git.openwrt.org/?p=openwrt/openwrt.git;a=blob;f=include/kernel.mk;h=38613756c71d8d5511a72849354bf818f57043ea;hb=HEAD#l262 yousong ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] Broken packaging of modules (updating them) when using @lt or @gt
On Sat, 15 Dec 2018 at 08:05, Yousong Zhou wrote: > > On Sat, 15 Dec 2018 at 06:00, Rafał Miłecki wrote: > > > > I've noticed a problem with kmod-phy-bcm-ns-usb2 defined in the > > target/linux/bcm53xx/modules.mk > > > > Steps to reproduce: > > 1) Setup .config with: > > CONFIG_TARGET_bcm53xx > > CONFIG_TARGET_MULTI_PROFILE > > TARGET_ALL_PROFILES > > CONFIG_TARGET_PER_DEVICE_ROOTFS > > 2) make V=s > > 3) vim > > build_dir/target-*/linux-*/linux-*/drivers/phy/broadcom/phy-bcm-ns-usb2.c > > 4) make V=s > > > > That will result in rebuilding: > > build_dir/target-*/linux-*/linux-*/drivers/phy/broadcom/phy-bcm-ns-usb2.ko > > (expected). > > > > However it won't update: > > build_dir/target-*/linux-*/target-dir-*/lib/modules/4.14.88/phy-bcm-ns-usb2.ko > > > > I've bisected/notices it's caused by using: > > $(LINUX_DIR)/drivers/phy/phy-bcm-ns-usb2.ko@lt4.13 \ > > $(LINUX_DIR)/drivers/phy/broadcom/phy-bcm-ns-usb2.ko@gt4.13 > > > > If I drop old kernel compatibility and simply use: > > $(LINUX_DIR)/drivers/phy/broadcom/phy-bcm-ns-usb2.ko > > the problem disappears. > > Probably because kmod .ipk was not rebuilt. How about also applying > version_filter $(FILES) in the following line [1] > > $$(IPKG_kmod-$(1)): $$(wildcard $$(FILES)) > > [1] > https://git.openwrt.org/?p=openwrt/openwrt.git;a=blob;f=include/kernel.mk;h=38613756c71d8d5511a72849354bf818f57043ea;hb=HEAD#l262 Can you provide a diff or at least a complete line I should replace above one with, please? -- Rafał ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] Broken packaging of modules (updating them) when using @lt or @gt
On Mon, 17 Dec 2018 at 12:59, Rafał Miłecki wrote: > > On Sat, 15 Dec 2018 at 08:05, Yousong Zhou wrote: > > > > On Sat, 15 Dec 2018 at 06:00, Rafał Miłecki wrote: > > > > > > I've noticed a problem with kmod-phy-bcm-ns-usb2 defined in the > > > target/linux/bcm53xx/modules.mk > > > > > > Steps to reproduce: > > > 1) Setup .config with: > > > CONFIG_TARGET_bcm53xx > > > CONFIG_TARGET_MULTI_PROFILE > > > TARGET_ALL_PROFILES > > > CONFIG_TARGET_PER_DEVICE_ROOTFS > > > 2) make V=s > > > 3) vim > > > build_dir/target-*/linux-*/linux-*/drivers/phy/broadcom/phy-bcm-ns-usb2.c > > > 4) make V=s > > > > > > That will result in rebuilding: > > > build_dir/target-*/linux-*/linux-*/drivers/phy/broadcom/phy-bcm-ns-usb2.ko > > > (expected). > > > > > > However it won't update: > > > build_dir/target-*/linux-*/target-dir-*/lib/modules/4.14.88/phy-bcm-ns-usb2.ko > > > > > > I've bisected/notices it's caused by using: > > > $(LINUX_DIR)/drivers/phy/phy-bcm-ns-usb2.ko@lt4.13 \ > > > $(LINUX_DIR)/drivers/phy/broadcom/phy-bcm-ns-usb2.ko@gt4.13 > > > > > > If I drop old kernel compatibility and simply use: > > > $(LINUX_DIR)/drivers/phy/broadcom/phy-bcm-ns-usb2.ko > > > the problem disappears. > > > > Probably because kmod .ipk was not rebuilt. How about also applying > > version_filter $(FILES) in the following line [1] > > > > $$(IPKG_kmod-$(1)): $$(wildcard $$(FILES)) > > > > [1] > > https://git.openwrt.org/?p=openwrt/openwrt.git;a=blob;f=include/kernel.mk;h=38613756c71d8d5511a72849354bf818f57043ea;hb=HEAD#l262 > > Can you provide a diff or at least a complete line I should replace > above one with, please? Something like the following. Note that version_filter requires macro KERNEL_PATCHVER from target makefile which I assume is not available at dump time, but this should work at ipk packaging time. diff --git a/include/kernel.mk b/include/kernel.mk index 38613756c7..19ecf4fa9a 100644 --- a/include/kernel.mk +++ b/include/kernel.mk @@ -259,7 +259,7 @@ $(call KernelPackage/$(1)/config) endif $$(eval $$(call BuildPackage,kmod-$(1))) - $$(IPKG_kmod-$(1)): $$(wildcard $$(FILES)) + $$(IPKG_kmod-$(1)): $$(wildcard $$(call version_filter,$$(FILES))) endef regards, yousong > > -- > Rafał ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] Broken packaging of modules (updating them) when using @lt or @gt
On 17.12.2018 07:20, Yousong Zhou wrote: On Mon, 17 Dec 2018 at 12:59, Rafał Miłecki wrote: On Sat, 15 Dec 2018 at 08:05, Yousong Zhou wrote: On Sat, 15 Dec 2018 at 06:00, Rafał Miłecki wrote: I've noticed a problem with kmod-phy-bcm-ns-usb2 defined in the target/linux/bcm53xx/modules.mk Steps to reproduce: 1) Setup .config with: CONFIG_TARGET_bcm53xx CONFIG_TARGET_MULTI_PROFILE TARGET_ALL_PROFILES CONFIG_TARGET_PER_DEVICE_ROOTFS 2) make V=s 3) vim build_dir/target-*/linux-*/linux-*/drivers/phy/broadcom/phy-bcm-ns-usb2.c 4) make V=s That will result in rebuilding: build_dir/target-*/linux-*/linux-*/drivers/phy/broadcom/phy-bcm-ns-usb2.ko (expected). However it won't update: build_dir/target-*/linux-*/target-dir-*/lib/modules/4.14.88/phy-bcm-ns-usb2.ko I've bisected/notices it's caused by using: $(LINUX_DIR)/drivers/phy/phy-bcm-ns-usb2.ko@lt4.13 \ $(LINUX_DIR)/drivers/phy/broadcom/phy-bcm-ns-usb2.ko@gt4.13 If I drop old kernel compatibility and simply use: $(LINUX_DIR)/drivers/phy/broadcom/phy-bcm-ns-usb2.ko the problem disappears. Probably because kmod .ipk was not rebuilt. How about also applying version_filter $(FILES) in the following line [1] $$(IPKG_kmod-$(1)): $$(wildcard $$(FILES)) [1] https://git.openwrt.org/?p=openwrt/openwrt.git;a=blob;f=include/kernel.mk;h=38613756c71d8d5511a72849354bf818f57043ea;hb=HEAD#l262 Can you provide a diff or at least a complete line I should replace above one with, please? Something like the following. Note that version_filter requires macro KERNEL_PATCHVER from target makefile which I assume is not available at dump time, but this should work at ipk packaging time. diff --git a/include/kernel.mk b/include/kernel.mk index 38613756c7..19ecf4fa9a 100644 --- a/include/kernel.mk +++ b/include/kernel.mk @@ -259,7 +259,7 @@ $(call KernelPackage/$(1)/config) endif $$(eval $$(call BuildPackage,kmod-$(1))) - $$(IPKG_kmod-$(1)): $$(wildcard $$(FILES)) + $$(IPKG_kmod-$(1)): $$(wildcard $$(call version_filter,$$(FILES))) endef It works! Could you send a patch with that fix, please? ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel