Using a workq callout, you will have to make sure to open the GPIO device in the callout, not your main() function, otherwise the file descriptor will be wrong. Likewise the ORB subscription.