Thanks in advance.
I’m working on a Macnica Helio with Golden 14.1 as my base and we’ve got a custom daughter card.
I’ve written a lot of custom device drivers, but only that requires one minor number (one open and only one address space). In my current design I have a custom IP that is used twice (so there are two address regions I need to work with). So, I created two /dev entries “/dev/custom_0 240 0” and “/dev/custom_1 240 1.”
When the OS boots it does probe twice and I can see that the correct addresses are assigned to Minor 0 and Minor 1. I can open the device driver twice and I see that everything is fine (I’ve got printk’s that show me the major and minor number and the Virtual address)
fd_custom0 and fd_custom1
BUT - when I do a “read” with the fd_custom1 file descriptor the “read routine” thinks it’s for MINOR 0 ???
Also, if I only do an open for fd_custom1 ONLY it looks fine BUT when I try and do a “read” nothing happens.
So, could someone explain to me what I’m doing incorrectly?
I have the structures like the scull driver in Rubini.