Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

XVC Server causes freezes to linux when other user application is running

Aperta
#7 10 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
25/100
Tipo di issue
Bug
Chiarezza
Da chiarire
Stato di attività
Ferma
Stack tecnologico
c, linux

Direzione di ricerca

Start with src/user/xvcServer.c, especially the device open paths, IOCTL/UIO selection, and TCP listen call. Reproduce the freeze while the custom application and Vivado hardware manager are active, then trace the kernel-driver IOCTL path and AXI access. Done means identifying whether synchronization is required and documenting or fixing the confirmed failure path.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

I've implemented the xvc server in our custom project using yocto based on petalinux and vivado 2018.2

The server running in userspace works well with the kernel driver using IOCTL with the vivado hardware manager in version 2018.2

After starting my custom made application the whole linux system freezes, if I try to connect to the xvc server from Vivado hardware manager.

System is a zynq7000 board, linux kernel 4.14, debug_bridge_0 connected at 0x8000000 (AXI_1) which is the only participant on this AXI peripheral. My custom fpga ip-cores are all mapped to AXI_0 or ACP.

Is there any synchronization mechanism required in the kernel to secure access to the AXI peripheral?

I needed to patch some parts of your code to avoid the TCP SYN error ...

diff --git a/src/user/xvcServer.c b/src/user/xvcServer.c
index 29c484e..926ed4b 100644
--- a/xvcServer.c
+++ b/xvcServer.c
@@ -232,6 +232,8 @@ int main(int argc, char **argv) {
     int fd_uio;
     volatile jtag_t* ptr = NULL;
 
+	printf("Using Memory mapping with UIO\n");
+
     fd_uio = open(UIO_PATH, O_RDWR);
     if (fd_uio < 1) {
         fprintf(stderr, "Failed to open uio: %s\n", UIO_PATH);
@@ -247,6 +249,8 @@ int main(int argc, char **argv) {
 #else /* USE_IOCTL */
     int fd_ioctl;
 
+	printf("Using IOCTL with char-device\n");
+
     fd_ioctl = open(CHAR_DEV_PATH, O_RDWR | O_SYNC);
     if (fd_ioctl < 1) {
         fprintf(stderr, "Failed to open xvc ioctl device driver: %s\n", CHAR_DEV_PATH);
@@ -288,7 +292,7 @@ int main(int argc, char **argv) {
         return 1;
     }
 
-    if (listen(s, 0) < 0) {
+    if (listen(s, 5) < 0) {
         perror("listen");
         return 1;
     }
Lingua principale
C
Stelle
292
Fork
97
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Xilinx/XilinxVirtualCable

Tutte le issue di Xilinx/XilinxVirtualCable

Issue simili

Altre issue su C

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.