I have developped a Java application that talk with the CAN bus (under Linux through SocketCAN). Instead of writing a complete JNI wrapper, I prefered to put the file descriptor from the socket (opened through JNI) into a FileDescriptor Java object. With OpenJDK or the official Java library, the FileDescriptor class contains a "fd" attribute and all work fine (I can use the CAN bus as a file). But surprisingly GNU Classpath use a FileDescriptor class without the "fd" attribute...
I searched on Internet and found a guy who had already submitted a patch without any responses.