f_count of file structure
I was writing a charecter device driver. when i open char device node & try to print the f_count of that node, the count was 2 instead of 1. but when i made dup() or fork () the count was 3.
The concepts says that f_count is the number of file descriptor pointing to the file structure.
why it was 2 when only one file descriptor is open in user space?
is there any system file descripter who is pointing to that file structure for smooth processing?
can i trace the process id who is pointimg to a perticular file structure?
|