Hi,
Had the same issue. (ERROR: modpost: "irq_to_desc" [/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prl_tg.ko] undefined!)
After a few hours of digging into it I found a solution. It seems that the symbol irq_to_desc is not anymore exported from the kernel. I managed to change the code to use irq_get_irq_data instead.
I also have tried your suggestion, but it still fails.
Start installation or upgrade of Guest Tools
installer:%10.000000
installer:%20.000000
new version of parallels tools
Installed Guest Tools were not found
Register service to install new Guest Tools
installer:%30.000000
Perform installation into the /usr/lib/parallels-tools directory
installer:%40.000000
make: Entering directory '/usr/lib/parallels-tools/kmods'
Will use compiler CC="cc".
Compiler version "cc (Ubuntu 10.3.0-1ubuntu1) 10.3.0"
cd prl_tg/Toolgate/Guest/Linux/prl_tg && make CC=cc
make[1]: Entering directory '/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg'
1: /lib/modules/5.11.0-22-generic/build
2: /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg
3: 20210705
4: 1.9.0
Start compile prl_tg...
make -C /lib/modules/5.11.0-22-generic/build M=/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg SRCROOT=/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg CC=cc modules
make[2]: Entering directory '/usr/src/linux-headers-5.11.0-22-generic'
1: /lib/modules/5.11.0-22-generic/build
2: /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg
3: 20210705
4: 1.9.0
CC [M] /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.o
In file included from /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:21:
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h: In function 'tg_out':
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h:186:7: warning: assignment to 'long unsigned int' from 'void *' makes integer from pointer without a cast [-Wint-conversion]
186 | port += dev->base_addr;
| ^~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h:190:17: warning: passing argument 2 of 'iowrite64' makes pointer from integer without a cast [-Wint-conversion]
190 | iowrite64(val, port);
| ^~~~
| |
| long unsigned int
In file included from ./arch/arm64/include/asm/io.h:194,
from ./include/linux/io.h:13,
from /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:8:
./include/asm-generic/io.h:769:64: note: expected 'volatile void *' but argument is of type 'long unsigned int'
769 | static inline void iowrite64(u64 value, volatile void __iomem *addr)
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c: In function 'prl_tg_initialize':
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:434:22: warning: multi-character character constant [-Wmultichar]
434 | if ((int)regs.a0 != 'MMIO') {
| ^~~~~~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:447:22: warning: multi-character character constant [-Wmultichar]
447 | if ((int)regs.a0 != 'EIRQ' || regs.a1 + regs.a2 > NR_IRQS) {
| ^~~~~~
In file included from ./include/linux/printk.h:7,
from ./include/linux/kernel.h:16,
from ./include/linux/list.h:9,
from ./include/linux/module.h:12,
from /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:5:
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c: In function 'prl_tg_probe_common':
./include/linux/kern_levels.h:5:18: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 3 has type 'void *' [-Wformat=]
5 | #define KERN_SOH "\001" /* ASCII Start Of Header */
| ^~~~~~
./include/linux/kern_levels.h:14:19: note: in expansion of macro 'KERN_SOH'
14 | #define KERN_INFO KERN_SOH "6" /* informational */
| ^~~~~~~~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:568:9: note: in expansion of macro 'KERN_INFO'
568 | printk(KERN_INFO "detected %s, base addr %llx, IRQ = {%d, %d %d %d}\n",
| ^~~~~~~~~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:568:46: note: format string is defined here
568 | printk(KERN_INFO "detected %s, base addr %llx, IRQ = {%d, %d %d %d}\n",
| ~~~^
| |
| long long unsigned int
| %p
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c: In function 'prl_tg_deinitialize':
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg.c:599:2: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
599 | int i = 0;
| ^~~
CC [M] /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.o
In file included from /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c:15:
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h: In function 'tg_out':
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h:186:7: warning: assignment to 'long unsigned int' from 'void *' makes integer from pointer without a cast [-Wint-conversion]
186 | port += dev->base_addr;
| ^~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_common.h:190:17: warning: passing argument 2 of 'iowrite64' makes pointer from integer without a cast [-Wint-conversion]
190 | iowrite64(val, port);
| ^~~~
| |
| long unsigned int
In file included from ./arch/arm64/include/asm/io.h:194,
from ./include/linux/scatterlist.h:9,
from ./include/linux/dma-mapping.h:10,
from /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c:9:
./include/asm-generic/io.h:769:64: note: expected 'volatile void *' but argument is of type 'long unsigned int'
769 | static inline void iowrite64(u64 value, volatile void __iomem *addr)
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c: In function 'tg_req_map_internal':
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c:66:18: warning: unused variable 'pdev' [-Wunused-variable]
66 | struct pci_dev *pdev = req->dev->pci_dev;
| ^~~~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c: In function 'tg_req_map_user_pages':
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c:105:18: warning: unused variable 'pdev' [-Wunused-variable]
105 | struct pci_dev *pdev = req->dev->pci_dev;
| ^~~~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c: In function 'tg_req_map_kernel_pages':
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c:168:18: warning: unused variable 'pdev' [-Wunused-variable]
168 | struct pci_dev *pdev = req->dev->pci_dev;
| ^~~~
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c: In function 'tg_req_unmap_pages':
/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prltg_call.c:236:18: warning: unused variable 'pdev' [-Wunused-variable]
236 | struct pci_dev *pdev = req->dev->pci_dev;
| ^~~~
LD [M] /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prl_tg.o
1: /lib/modules/5.11.0-22-generic/build
2: /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg
3: 20210705
4: 1.9.0
MODPOST /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/Module.symvers
ERROR: modpost: "irq_to_desc" [/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/prl_tg.ko] undefined!
make[3]: *** [scripts/Makefile.modpost:111: /usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/Module.symvers] Error 1
make[3]: *** Deleting file '/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg/Module.symvers'
make[2]: *** [Makefile:1752: modules] Error 2
make[2]: Leaving directory '/usr/src/linux-headers-5.11.0-22-generic'
make[1]: *** [Makefile:43: prl_tg] Error 2
make[1]: Leaving directory '/usr/lib/parallels-tools/kmods/prl_tg/Toolgate/Guest/Linux/prl_tg'
make: *** [Makefile.kmods:30: compile] Error 2
make: Leaving directory '/usr/lib/parallels-tools/kmods'
Error: could not build kernel modules
Error: failed to install Parallels Guest Tools!
It would have been nice. Parallels support has told me that they are aware and wil come with an update. But when? When the next version of Ubuntu is coming along?
At least Ubuntu still works fine in a way, but no more shares of macOS or copy paste functions between guest and host. May be you find a fix?