Source: linux Version: 4.19~rc2-1~exp1 Severity: wishlist Tags: patch X-Debbugs-CC: debian-ri...@lists.debian.org User: debian-ri...@lists.debian.org Usertags: riscv64
Hello, starting with version 4.19rc2, the mainline Linux kernel includes all drivers necessary for running a riscv64 system in qemu, so it would be great if the "linux" source package could be extended to build a linux-image-*-riscv64 binary package. Attached is a patch that tries to add the necessary bits. Unfortunately, with the patch applied the kernel itself builds successfully, but the package build process then fails with -----8<----------8<----------8<----------8<----------8<----- make[3]: Leaving directory '<<builddir>>/linux-4.19~rc2/debian/build/build_riscv64_none_riscv64' debian/bin/buildcheck.py debian/build/build_riscv64_none_riscv64 riscv64 none riscv64 ABI is not completely versioned! Refusing to continue. Unversioned symbols: _mcount module: vmlinux, version: 0x00000000, export: EXPORT_SYMBOL return_to_handler module: vmlinux, version: 0x00000000, export: EXPORT_SYMBOL Can't read ABI reference. ABI not checked! make[2]: *** [debian/rules.real:217: debian/stamps/build_riscv64_none_riscv64] Fehler 1 -----8<----------8<----------8<----------8<----------8<----- I'm somewhat stuck here - is this an upstream issue or have I overlooked something on the packaging side? Pointers welcome :). Regards, Karsten -- Gem. Par. 28 Abs. 4 Bundesdatenschutzgesetz widerspreche ich der Nutzung sowie der Weitergabe meiner personenbezogenen Daten für Zwecke der Werbung sowie der Markt- oder Meinungsforschung.
>From d1d47c22d5c41bb3b1924d2534aa06e86a16c10d Mon Sep 17 00:00:00 2001 From: Karsten Merker <mer...@debian.org> Date: Sat, 1 Sep 2018 23:02:11 +0200 Subject: [PATCH] Build a kernel image for riscv64 --- debian/config/riscv64/config | 79 +++++++++++++++++++ debian/config/riscv64/defines | 6 +- debian/config/riscv64/none/defines | 3 + debian/installer/modules/riscv64/ata-modules | 1 + .../installer/modules/riscv64/btrfs-modules | 1 + .../modules/riscv64/compress-modules | 1 + debian/installer/modules/riscv64/crc-modules | 1 + .../modules/riscv64/crypto-dm-modules | 1 + .../installer/modules/riscv64/crypto-modules | 1 + .../installer/modules/riscv64/event-modules | 1 + debian/installer/modules/riscv64/ext4-modules | 1 + debian/installer/modules/riscv64/fat-modules | 1 + debian/installer/modules/riscv64/fuse-modules | 1 + debian/installer/modules/riscv64/i2c-modules | 1 + .../installer/modules/riscv64/input-modules | 1 + .../installer/modules/riscv64/isofs-modules | 1 + debian/installer/modules/riscv64/jfs-modules | 1 + debian/installer/modules/riscv64/kernel-image | 1 + debian/installer/modules/riscv64/leds-modules | 1 + debian/installer/modules/riscv64/loop-modules | 1 + debian/installer/modules/riscv64/md-modules | 1 + debian/installer/modules/riscv64/mmc-modules | 1 + debian/installer/modules/riscv64/mtd-modules | 1 + .../modules/riscv64/multipath-modules | 1 + debian/installer/modules/riscv64/nbd-modules | 1 + debian/installer/modules/riscv64/nic-modules | 1 + .../modules/riscv64/nic-shared-modules | 1 + .../installer/modules/riscv64/nic-usb-modules | 1 + .../modules/riscv64/nic-wireless-modules | 1 + debian/installer/modules/riscv64/pata-modules | 1 + debian/installer/modules/riscv64/ppp-modules | 1 + debian/installer/modules/riscv64/sata-modules | 1 + .../modules/riscv64/scsi-core-modules | 1 + debian/installer/modules/riscv64/scsi-modules | 2 + .../modules/riscv64/squashfs-modules | 1 + debian/installer/modules/riscv64/udf-modules | 1 + .../installer/modules/riscv64/uinput-modules | 1 + debian/installer/modules/riscv64/usb-modules | 1 + .../modules/riscv64/usb-storage-modules | 1 + .../installer/modules/riscv64/virtio-modules | 1 + debian/installer/modules/riscv64/zlib-modules | 1 + 41 files changed, 126 insertions(+), 1 deletion(-) create mode 100644 debian/config/riscv64/config create mode 100644 debian/config/riscv64/none/defines create mode 100644 debian/installer/modules/riscv64/ata-modules create mode 100644 debian/installer/modules/riscv64/btrfs-modules create mode 100644 debian/installer/modules/riscv64/compress-modules create mode 100644 debian/installer/modules/riscv64/crc-modules create mode 100644 debian/installer/modules/riscv64/crypto-dm-modules create mode 100644 debian/installer/modules/riscv64/crypto-modules create mode 100644 debian/installer/modules/riscv64/event-modules create mode 100644 debian/installer/modules/riscv64/ext4-modules create mode 100644 debian/installer/modules/riscv64/fat-modules create mode 100644 debian/installer/modules/riscv64/fuse-modules create mode 100644 debian/installer/modules/riscv64/i2c-modules create mode 100644 debian/installer/modules/riscv64/input-modules create mode 100644 debian/installer/modules/riscv64/isofs-modules create mode 100644 debian/installer/modules/riscv64/jfs-modules create mode 100644 debian/installer/modules/riscv64/kernel-image create mode 100644 debian/installer/modules/riscv64/leds-modules create mode 100644 debian/installer/modules/riscv64/loop-modules create mode 100644 debian/installer/modules/riscv64/md-modules create mode 100644 debian/installer/modules/riscv64/mmc-modules create mode 100644 debian/installer/modules/riscv64/mtd-modules create mode 100644 debian/installer/modules/riscv64/multipath-modules create mode 100644 debian/installer/modules/riscv64/nbd-modules create mode 100644 debian/installer/modules/riscv64/nic-modules create mode 100644 debian/installer/modules/riscv64/nic-shared-modules create mode 100644 debian/installer/modules/riscv64/nic-usb-modules create mode 100644 debian/installer/modules/riscv64/nic-wireless-modules create mode 100644 debian/installer/modules/riscv64/pata-modules create mode 100644 debian/installer/modules/riscv64/ppp-modules create mode 100644 debian/installer/modules/riscv64/sata-modules create mode 100644 debian/installer/modules/riscv64/scsi-core-modules create mode 100644 debian/installer/modules/riscv64/scsi-modules create mode 100644 debian/installer/modules/riscv64/squashfs-modules create mode 100644 debian/installer/modules/riscv64/udf-modules create mode 100644 debian/installer/modules/riscv64/uinput-modules create mode 100644 debian/installer/modules/riscv64/usb-modules create mode 100644 debian/installer/modules/riscv64/usb-storage-modules create mode 100644 debian/installer/modules/riscv64/virtio-modules create mode 100644 debian/installer/modules/riscv64/zlib-modules diff --git a/debian/config/riscv64/config b/debian/config/riscv64/config new file mode 100644 index 000000000..36473d7db --- /dev/null +++ b/debian/config/riscv64/config @@ -0,0 +1,79 @@ +CONFIG_SMP=y +CONFIG_PCI=y +CONFIG_PCIE_XILINX=y +CONFIG_SYSVIPC=y +CONFIG_POSIX_MQUEUE=y +CONFIG_IKCONFIG=y +CONFIG_IKCONFIG_PROC=y +CONFIG_CGROUPS=y +CONFIG_CGROUP_SCHED=y +CONFIG_CFS_BANDWIDTH=y +CONFIG_CGROUP_BPF=y +CONFIG_NAMESPACES=y +CONFIG_USER_NS=y +CONFIG_BLK_DEV_INITRD=y +CONFIG_EXPERT=y +CONFIG_CHECKPOINT_RESTORE=y +CONFIG_BPF_SYSCALL=y +CONFIG_NET=y +CONFIG_PACKET=y +CONFIG_UNIX=y +CONFIG_INET=y +CONFIG_IP_MULTICAST=y +CONFIG_IP_ADVANCED_ROUTER=y +CONFIG_IP_PNP=y +CONFIG_IP_PNP_DHCP=y +CONFIG_IP_PNP_BOOTP=y +CONFIG_IP_PNP_RARP=y +CONFIG_NETLINK_DIAG=y +CONFIG_DEVTMPFS=y +CONFIG_BLK_DEV_LOOP=y +CONFIG_VIRTIO_BLK=y +CONFIG_BLK_DEV_SD=y +CONFIG_BLK_DEV_SR=y +CONFIG_ATA=y +CONFIG_SATA_AHCI=y +CONFIG_SATA_AHCI_PLATFORM=y +CONFIG_NETDEVICES=y +CONFIG_VIRTIO_NET=y +CONFIG_MACB=y +CONFIG_E1000E=y +CONFIG_R8169=y +CONFIG_MICROSEMI_PHY=y +CONFIG_INPUT_MOUSEDEV=y +CONFIG_SERIAL_8250=y +CONFIG_SERIAL_8250_CONSOLE=y +CONFIG_SERIAL_OF_PLATFORM=y +CONFIG_HVC_RISCV_SBI=y +# CONFIG_PTP_1588_CLOCK is not set +CONFIG_DRM=y +CONFIG_DRM_RADEON=y +CONFIG_FRAMEBUFFER_CONSOLE=y +CONFIG_USB=y +CONFIG_USB_XHCI_HCD=y +CONFIG_USB_XHCI_PLATFORM=y +CONFIG_USB_EHCI_HCD=y +CONFIG_USB_EHCI_HCD_PLATFORM=y +CONFIG_USB_OHCI_HCD=y +CONFIG_USB_OHCI_HCD_PLATFORM=y +CONFIG_USB_STORAGE=y +CONFIG_USB_UAS=y +CONFIG_VIRTIO_MMIO=y +CONFIG_RAS=y +CONFIG_EXT4_FS=y +CONFIG_EXT4_FS_POSIX_ACL=y +CONFIG_AUTOFS4_FS=y +CONFIG_MSDOS_FS=y +CONFIG_VFAT_FS=y +CONFIG_TMPFS=y +CONFIG_TMPFS_POSIX_ACL=y +CONFIG_NFS_FS=y +CONFIG_NFS_V4=y +CONFIG_NFS_V4_1=y +CONFIG_NFS_V4_2=y +CONFIG_ROOT_NFS=y +# CONFIG_RCU_TRACE is not set +CONFIG_CRYPTO_USER_API_HASH=y +CONFIG_MODULES=y +CONFIG_MODULE_UNLOAD=y +CONFIG_SIFIVE_PLIC=y diff --git a/debian/config/riscv64/defines b/debian/config/riscv64/defines index 7d49f44d8..e6c557608 100644 --- a/debian/config/riscv64/defines +++ b/debian/config/riscv64/defines @@ -1,4 +1,8 @@ [base] kernel-arch: riscv featuresets: -# empty; just building headers yet + none + +[riscv64_description] +hardware: 64-bit RISC-V platforms +hardware-long: 64-bit RISC-V platforms diff --git a/debian/config/riscv64/none/defines b/debian/config/riscv64/none/defines new file mode 100644 index 000000000..5070c6bc0 --- /dev/null +++ b/debian/config/riscv64/none/defines @@ -0,0 +1,3 @@ +[base] +flavours: + riscv64 diff --git a/debian/installer/modules/riscv64/ata-modules b/debian/installer/modules/riscv64/ata-modules new file mode 100644 index 000000000..ab5e7fdf0 --- /dev/null +++ b/debian/installer/modules/riscv64/ata-modules @@ -0,0 +1 @@ +libata ? diff --git a/debian/installer/modules/riscv64/btrfs-modules b/debian/installer/modules/riscv64/btrfs-modules new file mode 100644 index 000000000..e261e1388 --- /dev/null +++ b/debian/installer/modules/riscv64/btrfs-modules @@ -0,0 +1 @@ +#include <btrfs-modules> diff --git a/debian/installer/modules/riscv64/compress-modules b/debian/installer/modules/riscv64/compress-modules new file mode 100644 index 000000000..804616619 --- /dev/null +++ b/debian/installer/modules/riscv64/compress-modules @@ -0,0 +1 @@ +#include <compress-modules> diff --git a/debian/installer/modules/riscv64/crc-modules b/debian/installer/modules/riscv64/crc-modules new file mode 100644 index 000000000..7e00de705 --- /dev/null +++ b/debian/installer/modules/riscv64/crc-modules @@ -0,0 +1 @@ +#include <crc-modules> diff --git a/debian/installer/modules/riscv64/crypto-dm-modules b/debian/installer/modules/riscv64/crypto-dm-modules new file mode 100644 index 000000000..4c8f2354c --- /dev/null +++ b/debian/installer/modules/riscv64/crypto-dm-modules @@ -0,0 +1 @@ +#include <crypto-dm-modules> diff --git a/debian/installer/modules/riscv64/crypto-modules b/debian/installer/modules/riscv64/crypto-modules new file mode 100644 index 000000000..3a1e862b4 --- /dev/null +++ b/debian/installer/modules/riscv64/crypto-modules @@ -0,0 +1 @@ +#include <crypto-modules> diff --git a/debian/installer/modules/riscv64/event-modules b/debian/installer/modules/riscv64/event-modules new file mode 100644 index 000000000..f8819afd3 --- /dev/null +++ b/debian/installer/modules/riscv64/event-modules @@ -0,0 +1 @@ +#include <event-modules> diff --git a/debian/installer/modules/riscv64/ext4-modules b/debian/installer/modules/riscv64/ext4-modules new file mode 100644 index 000000000..394c577ce --- /dev/null +++ b/debian/installer/modules/riscv64/ext4-modules @@ -0,0 +1 @@ +#include <ext4-modules> diff --git a/debian/installer/modules/riscv64/fat-modules b/debian/installer/modules/riscv64/fat-modules new file mode 100644 index 000000000..274584eb6 --- /dev/null +++ b/debian/installer/modules/riscv64/fat-modules @@ -0,0 +1 @@ +#include <fat-modules> diff --git a/debian/installer/modules/riscv64/fuse-modules b/debian/installer/modules/riscv64/fuse-modules new file mode 100644 index 000000000..0b6ba0c8c --- /dev/null +++ b/debian/installer/modules/riscv64/fuse-modules @@ -0,0 +1 @@ +#include <fuse-modules> diff --git a/debian/installer/modules/riscv64/i2c-modules b/debian/installer/modules/riscv64/i2c-modules new file mode 100644 index 000000000..203a607e7 --- /dev/null +++ b/debian/installer/modules/riscv64/i2c-modules @@ -0,0 +1 @@ +#include <i2c-modules> diff --git a/debian/installer/modules/riscv64/input-modules b/debian/installer/modules/riscv64/input-modules new file mode 100644 index 000000000..5ecb595a4 --- /dev/null +++ b/debian/installer/modules/riscv64/input-modules @@ -0,0 +1 @@ +#include <input-modules> diff --git a/debian/installer/modules/riscv64/isofs-modules b/debian/installer/modules/riscv64/isofs-modules new file mode 100644 index 000000000..da4fa9a3c --- /dev/null +++ b/debian/installer/modules/riscv64/isofs-modules @@ -0,0 +1 @@ +#include <isofs-modules> diff --git a/debian/installer/modules/riscv64/jfs-modules b/debian/installer/modules/riscv64/jfs-modules new file mode 100644 index 000000000..7e4d912b9 --- /dev/null +++ b/debian/installer/modules/riscv64/jfs-modules @@ -0,0 +1 @@ +#include <jfs-modules> diff --git a/debian/installer/modules/riscv64/kernel-image b/debian/installer/modules/riscv64/kernel-image new file mode 100644 index 000000000..1d11b1921 --- /dev/null +++ b/debian/installer/modules/riscv64/kernel-image @@ -0,0 +1 @@ +#include <kernel-image> diff --git a/debian/installer/modules/riscv64/leds-modules b/debian/installer/modules/riscv64/leds-modules new file mode 100644 index 000000000..85d9f2565 --- /dev/null +++ b/debian/installer/modules/riscv64/leds-modules @@ -0,0 +1 @@ +#include <leds-modules> diff --git a/debian/installer/modules/riscv64/loop-modules b/debian/installer/modules/riscv64/loop-modules new file mode 100644 index 000000000..c1c948fa3 --- /dev/null +++ b/debian/installer/modules/riscv64/loop-modules @@ -0,0 +1 @@ +#include <loop-modules> diff --git a/debian/installer/modules/riscv64/md-modules b/debian/installer/modules/riscv64/md-modules new file mode 100644 index 000000000..26115e10b --- /dev/null +++ b/debian/installer/modules/riscv64/md-modules @@ -0,0 +1 @@ +#include <md-modules> diff --git a/debian/installer/modules/riscv64/mmc-modules b/debian/installer/modules/riscv64/mmc-modules new file mode 100644 index 000000000..dadfd5334 --- /dev/null +++ b/debian/installer/modules/riscv64/mmc-modules @@ -0,0 +1 @@ +#include <mmc-modules> diff --git a/debian/installer/modules/riscv64/mtd-modules b/debian/installer/modules/riscv64/mtd-modules new file mode 100644 index 000000000..5dd7997b2 --- /dev/null +++ b/debian/installer/modules/riscv64/mtd-modules @@ -0,0 +1 @@ +#include <mtd-modules> diff --git a/debian/installer/modules/riscv64/multipath-modules b/debian/installer/modules/riscv64/multipath-modules new file mode 100644 index 000000000..a8b69b253 --- /dev/null +++ b/debian/installer/modules/riscv64/multipath-modules @@ -0,0 +1 @@ +#include <multipath-modules> diff --git a/debian/installer/modules/riscv64/nbd-modules b/debian/installer/modules/riscv64/nbd-modules new file mode 100644 index 000000000..3c9b3e5d4 --- /dev/null +++ b/debian/installer/modules/riscv64/nbd-modules @@ -0,0 +1 @@ +#include <nbd-modules> diff --git a/debian/installer/modules/riscv64/nic-modules b/debian/installer/modules/riscv64/nic-modules new file mode 100644 index 000000000..2512e8395 --- /dev/null +++ b/debian/installer/modules/riscv64/nic-modules @@ -0,0 +1 @@ +#include <nic-modules> diff --git a/debian/installer/modules/riscv64/nic-shared-modules b/debian/installer/modules/riscv64/nic-shared-modules new file mode 100644 index 000000000..cc84b14dc --- /dev/null +++ b/debian/installer/modules/riscv64/nic-shared-modules @@ -0,0 +1 @@ +#include <nic-shared-modules> diff --git a/debian/installer/modules/riscv64/nic-usb-modules b/debian/installer/modules/riscv64/nic-usb-modules new file mode 100644 index 000000000..c479669b4 --- /dev/null +++ b/debian/installer/modules/riscv64/nic-usb-modules @@ -0,0 +1 @@ +#include <nic-usb-modules> diff --git a/debian/installer/modules/riscv64/nic-wireless-modules b/debian/installer/modules/riscv64/nic-wireless-modules new file mode 100644 index 000000000..53fd18d7f --- /dev/null +++ b/debian/installer/modules/riscv64/nic-wireless-modules @@ -0,0 +1 @@ +#include <nic-wireless-modules> diff --git a/debian/installer/modules/riscv64/pata-modules b/debian/installer/modules/riscv64/pata-modules new file mode 100644 index 000000000..b0cd6337a --- /dev/null +++ b/debian/installer/modules/riscv64/pata-modules @@ -0,0 +1 @@ +#include <pata-modules> diff --git a/debian/installer/modules/riscv64/ppp-modules b/debian/installer/modules/riscv64/ppp-modules new file mode 100644 index 000000000..1f26aa1ee --- /dev/null +++ b/debian/installer/modules/riscv64/ppp-modules @@ -0,0 +1 @@ +#include <ppp-modules> diff --git a/debian/installer/modules/riscv64/sata-modules b/debian/installer/modules/riscv64/sata-modules new file mode 100644 index 000000000..01318c258 --- /dev/null +++ b/debian/installer/modules/riscv64/sata-modules @@ -0,0 +1 @@ +#include <sata-modules> diff --git a/debian/installer/modules/riscv64/scsi-core-modules b/debian/installer/modules/riscv64/scsi-core-modules new file mode 100644 index 000000000..dd65d6614 --- /dev/null +++ b/debian/installer/modules/riscv64/scsi-core-modules @@ -0,0 +1 @@ +#include <scsi-core-modules> diff --git a/debian/installer/modules/riscv64/scsi-modules b/debian/installer/modules/riscv64/scsi-modules new file mode 100644 index 000000000..675462a14 --- /dev/null +++ b/debian/installer/modules/riscv64/scsi-modules @@ -0,0 +1,2 @@ +#include <scsi-modules> + diff --git a/debian/installer/modules/riscv64/squashfs-modules b/debian/installer/modules/riscv64/squashfs-modules new file mode 100644 index 000000000..42d77887a --- /dev/null +++ b/debian/installer/modules/riscv64/squashfs-modules @@ -0,0 +1 @@ +#include <squashfs-modules> diff --git a/debian/installer/modules/riscv64/udf-modules b/debian/installer/modules/riscv64/udf-modules new file mode 100644 index 000000000..b90d7ee9b --- /dev/null +++ b/debian/installer/modules/riscv64/udf-modules @@ -0,0 +1 @@ +#include <udf-modules> diff --git a/debian/installer/modules/riscv64/uinput-modules b/debian/installer/modules/riscv64/uinput-modules new file mode 100644 index 000000000..58a833779 --- /dev/null +++ b/debian/installer/modules/riscv64/uinput-modules @@ -0,0 +1 @@ +#include <uinput-modules> diff --git a/debian/installer/modules/riscv64/usb-modules b/debian/installer/modules/riscv64/usb-modules new file mode 100644 index 000000000..c598dedd8 --- /dev/null +++ b/debian/installer/modules/riscv64/usb-modules @@ -0,0 +1 @@ +#include <usb-modules> diff --git a/debian/installer/modules/riscv64/usb-storage-modules b/debian/installer/modules/riscv64/usb-storage-modules new file mode 100644 index 000000000..8c5e81b55 --- /dev/null +++ b/debian/installer/modules/riscv64/usb-storage-modules @@ -0,0 +1 @@ +#include <usb-storage-modules> diff --git a/debian/installer/modules/riscv64/virtio-modules b/debian/installer/modules/riscv64/virtio-modules new file mode 100644 index 000000000..61da39659 --- /dev/null +++ b/debian/installer/modules/riscv64/virtio-modules @@ -0,0 +1 @@ +#include <virtio-modules> diff --git a/debian/installer/modules/riscv64/zlib-modules b/debian/installer/modules/riscv64/zlib-modules new file mode 100644 index 000000000..e02ad64bf --- /dev/null +++ b/debian/installer/modules/riscv64/zlib-modules @@ -0,0 +1 @@ +#include <zlib-modules> -- 2.19.0.rc2