diff options
-rw-r--r-- | .github/workflows/build-and-run.yml | 5 | ||||
-rw-r--r-- | .github/workflows/run-tests-32bit.yml | 2 | ||||
-rw-r--r-- | .github/workflows/run-tests-bigendian.yml | 10 | ||||
-rw-r--r-- | .github/workflows/run-tests.yml | 11 | ||||
-rw-r--r-- | accel-pppd/ctrl/ipoe/dhcpv4_options.c | 2 | ||||
-rw-r--r-- | accel-pppd/ipv6/dhcpv6.c | 29 | ||||
-rw-r--r-- | drivers/ipoe/ipoe.c | 13 |
7 files changed, 50 insertions, 22 deletions
diff --git a/.github/workflows/build-and-run.yml b/.github/workflows/build-and-run.yml index 67d01b9c..3dfebd86 100644 --- a/.github/workflows/build-and-run.yml +++ b/.github/workflows/build-and-run.yml @@ -14,9 +14,6 @@ jobs: fail-fast: false matrix: include: - - distro: ubuntu-20.04 - pkg-distro: ubuntu20.04 - cpack-type: Ubuntu20 - distro: ubuntu-22.04 pkg-distro: ubuntu22.04 cpack-type: Ubuntu22 @@ -88,7 +85,6 @@ jobs: "debian:11", "debian:12", "debian:trixie", - "ubuntu:20.04", "ubuntu:22.04", "ubuntu:24.04", "ubuntu:devel" @@ -108,7 +104,6 @@ jobs: ubuntu:devel) CPACK_TYPE=Ubuntu24 ; HEADERS_SUFFIX=generic ;; ubuntu:24.04) CPACK_TYPE=Ubuntu24 ; HEADERS_SUFFIX=generic ;; ubuntu:22.04) CPACK_TYPE=Ubuntu22 ; HEADERS_SUFFIX=generic ;; - ubuntu:20.04) CPACK_TYPE=Ubuntu20 ; HEADERS_SUFFIX=generic ;; esac; echo HEADERS_SUFFIX=$HEADERS_SUFFIX >> $GITHUB_ENV; echo DISTRO=$DISTRO >> $GITHUB_ENV; diff --git a/.github/workflows/run-tests-32bit.yml b/.github/workflows/run-tests-32bit.yml index 5f635b73..94d158ab 100644 --- a/.github/workflows/run-tests-32bit.yml +++ b/.github/workflows/run-tests-32bit.yml @@ -15,7 +15,7 @@ jobs: strategy: fail-fast: false matrix: - distro: [latest-stable, edge] + distro: [v3.20] steps: - name: Check out repository code diff --git a/.github/workflows/run-tests-bigendian.yml b/.github/workflows/run-tests-bigendian.yml index 0e98ab47..d5dce83b 100644 --- a/.github/workflows/run-tests-bigendian.yml +++ b/.github/workflows/run-tests-bigendian.yml @@ -39,8 +39,8 @@ jobs: run: | ssh-keygen -t ed25519 -q -N "" -f ssh-key qemu-img create -f raw disk.raw 5G - wget -nv https://dl-cdn.alpinelinux.org/alpine/latest-stable/releases/s390x/netboot/vmlinuz-lts - wget -nv https://dl-cdn.alpinelinux.org/alpine/latest-stable/releases/s390x/netboot/initramfs-lts + wget -nv https://dl-cdn.alpinelinux.org/alpine/v3.20/releases/s390x/netboot/vmlinuz-lts + wget -nv https://dl-cdn.alpinelinux.org/alpine/v3.20/releases/s390x/netboot/initramfs-lts - name: Run http server for ssh-key run: | sudo ip addr add 192.0.2.1/32 dev lo # stable ip for http server @@ -54,8 +54,8 @@ jobs: -drive format=raw,file=disk.raw -kernel vmlinuz-lts -initrd initramfs-lts - -append "ip=dhcp alpine_repo=https://dl-cdn.alpinelinux.org/alpine/latest-stable/main - modloop=https://dl-cdn.alpinelinux.org/alpine/latest-stable/releases/s390x/netboot/modloop-lts + -append "ip=dhcp alpine_repo=https://dl-cdn.alpinelinux.org/alpine/v3.20/main + modloop=https://dl-cdn.alpinelinux.org/alpine/v3.20/releases/s390x/netboot/modloop-lts ssh_key=http://192.0.2.1:8000/ssh-key.pub" - name: Check that target OS is running run: | @@ -77,7 +77,7 @@ jobs: echo '' >> setup_alpine_conf && echo 'DISKOPTS=\"-m sys /dev/vda\"' >> setup_alpine_conf && echo 'ROOTSSHKEY=\"http://192.0.2.1:8000/ssh-key.pub\"' >> setup_alpine_conf && - echo 'APKREPOSOPTS=\"https://dl-cdn.alpinelinux.org/alpine/latest-stable/main\"' >> setup_alpine_conf && + echo 'APKREPOSOPTS=\"https://dl-cdn.alpinelinux.org/alpine/v3.20/main\"' >> setup_alpine_conf && cat setup_alpine_conf && yes | setup-alpine -e -f setup_alpine_conf" - name: Poweroff the VM diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index b217d71d..af7b5727 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -26,11 +26,6 @@ jobs: untar: false format: qcow2 - - distro: Ubuntu-20.04 - image: https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img - untar: false - format: qcow2 - - distro: Debian13 image: https://cloud.debian.org/images/cloud/trixie/daily/latest/debian-13-generic-amd64-daily.tar.xz untar: true @@ -222,7 +217,7 @@ jobs: run: | mkdir img # we need to use metal image because virt image doesn't provide pppoe driver (https://gitlab.alpinelinux.org/alpine/aports/-/issues/13739) - wget -nv https://dl-cdn.alpinelinux.org/alpine/latest-stable/releases/cloud/nocloud_alpine-3.20.2-x86_64-bios-cloudinit-metal-r0.qcow2 -O img/image + wget -nv https://dl-cdn.alpinelinux.org/alpine/v3.20/releases/cloud/nocloud_alpine-3.20.3-x86_64-bios-cloudinit-metal-r0.qcow2 -O img/image qemu-img resize -f qcow2 img/`ls -1 img` +2G - name: Run target OS first time (for cloud-init actions) run: sudo qemu-system-x86_64 -enable-kvm -cpu host -m 4096 -nographic -drive format=qcow2,file=img/`ls -1 img` -drive format=raw,file=init.img @@ -318,7 +313,7 @@ jobs: strategy: fail-fast: false matrix: - distro: ["ubuntu-24.04", "ubuntu-22.04", "ubuntu-20.04"] + distro: ["ubuntu-24.04", "ubuntu-22.04"] runs-on: ${{ matrix.distro }} steps: @@ -373,7 +368,7 @@ jobs: strategy: fail-fast: false matrix: - distro: ["ubuntu-24.04", "ubuntu-22.04", "ubuntu-20.04"] + distro: ["ubuntu-24.04", "ubuntu-22.04"] runs-on: ${{ matrix.distro }} steps: diff --git a/accel-pppd/ctrl/ipoe/dhcpv4_options.c b/accel-pppd/ctrl/ipoe/dhcpv4_options.c index b5f2b3bf..0175dee7 100644 --- a/accel-pppd/ctrl/ipoe/dhcpv4_options.c +++ b/accel-pppd/ctrl/ipoe/dhcpv4_options.c @@ -46,7 +46,7 @@ static struct known_option options[] = { { 26, 2, 2, 2, "MTU", print_int }, { 28, 4, 4, 4, "Broadcast", print_ip }, { 33, 8, 255, 8, "Route", print_route }, - { 42, 4, 4, 4, "NTP", print_ip }, + { 42, 4, 255, 4, "NTP", print_ip }, { 43, 1, 255, 1, "Vendor-Specific", print_hex }, { 50, 4, 4, 4, "Request-IP", print_ip }, { 51, 4, 4, 4, "Lease-Time", print_uint }, diff --git a/accel-pppd/ipv6/dhcpv6.c b/accel-pppd/ipv6/dhcpv6.c index 77fc32f7..85863e0c 100644 --- a/accel-pppd/ipv6/dhcpv6.c +++ b/accel-pppd/ipv6/dhcpv6.c @@ -752,6 +752,32 @@ static void dhcpv6_recv_rebind(struct dhcpv6_packet *req) dhcpv6_send_reply2(req, pd, D6_REPLY); } +static void dhcpv6_recv_confirm(struct dhcpv6_packet *req) +{ + struct dhcpv6_pd *pd = req->pd; + + if (!req->clientid) { + log_ppp_error("dhcpv6: no Client-ID option\n"); + return; + } + + if (req->serverid) { + log_ppp_error("dhcpv6: unexcpected Server-ID option\n"); + return; + } + + if (!pd->clientid) + return; + else if (pd->clientid->hdr.len != req->clientid->hdr.len || memcmp(pd->clientid, req->clientid, sizeof(struct dhcpv6_opt_hdr) + ntohs(req->clientid->hdr.len))) { + log_ppp_error("dhcpv6: unmatched Client-ID option\n"); + return; + } + + req->serverid = conf_serverid; + + dhcpv6_send_reply(req, pd, D6_REPLY); +} + static void dhcpv6_recv_release(struct dhcpv6_packet *pkt) { // don't answer @@ -783,6 +809,9 @@ static void dhcpv6_recv_packet(struct dhcpv6_packet *pkt) case D6_REBIND: dhcpv6_recv_rebind(pkt); break; + case D6_CONFIRM: + dhcpv6_recv_confirm(pkt); + break; case D6_RELEASE: dhcpv6_recv_release(pkt); break; diff --git a/drivers/ipoe/ipoe.c b/drivers/ipoe/ipoe.c index c6b88620..14b6416a 100644 --- a/drivers/ipoe/ipoe.c +++ b/drivers/ipoe/ipoe.c @@ -702,7 +702,11 @@ nl_err: if (!list_empty(&ipoe_list2_u)) mod_timer(&ipoe_timer_u, jiffies + IPOE_TIMEOUT_U * HZ); else +#if LINUX_VERSION_CODE < KERNEL_VERSION(6,2,0) del_timer(&ipoe_timer_u); +#else + timer_delete(&ipoe_timer_u); +#endif } static struct ipoe_session *ipoe_lookup(__be32 addr) @@ -1105,7 +1109,9 @@ static void ipoe_netdev_setup(struct net_device *dev) dev->iflink = 0; #endif dev->addr_len = ETH_ALEN; -#if LINUX_VERSION_CODE >= KERNEL_VERSION(6,12,0) +#if LINUX_VERSION_CODE >= KERNEL_VERSION(6,15,0) + dev->netns_immutable = true; +#elif LINUX_VERSION_CODE >= KERNEL_VERSION(6,12,0) dev->netns_local = true; #else dev->features |= NETIF_F_NETNS_LOCAL; @@ -1988,8 +1994,11 @@ static void __exit ipoe_fini(void) flush_work(&ipoe_queue_work); skb_queue_purge(&ipoe_queue); - +#if LINUX_VERSION_CODE < KERNEL_VERSION(6,2,0) del_timer(&ipoe_timer_u); +#else + timer_delete(&ipoe_timer_u); +#endif for (i = 0; i <= IPOE_HASH_BITS; i++) rcu_assign_pointer(ipoe_list[i].next, &ipoe_list[i]); |