The child thread has what appears to be a pretty tight for loop. &p->ftdicwhich if by chance is the same memory location, might benefit from a mutex lock. Thank you!Īdditionally I found that other drivers linked against pthread do not work, e.g. Please, have a look at it and help us getting this to work on FreeBSD. The start_routine should probably use pthread_exit and may be wrong by trying to return an int, but that's not the question here. P->parent_flag = 1 // show we're now a happy parent, birth successful. Report(RPT_INFO, "%s: read thread created") Report(RPT_ERR, "%s: pthread_create() - %s", drvthis->name, strerror(err)) create a thread to keep a read up on the device P = (PrivateData *) drvthis->private_data įor (size = ftdi_read_data(&p->ftdic, buffer, 64) size > 0 size = ftdi_read_data(&p->ftdic, buffer, 64))
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |