I'm having an issue where a 3rd party application is opening a device node it shouldn't.
I wrote a SPI Slave device driver that does some processing of messages. When the driver loads its in "Initialize Mode" which only replies to a specific message. To re-initialize communications I must unload and reload the driver. The problem is that the system has a 3rd party application, running as root, that opens all character devices. The only way to make this all work is to stop the app and unload which causes a huge problem with the over all project.
Is it possible to open a connection to a Character Device without actually having a device node? Right now I use fopen('/dev/spi') and everything works fine until I need to reload and the above issue ensues. Is there any sort of system call that can be made that would result in a file descriptor to a specific Major/Minor node number without having the actual /dev/spi file?