Speaking as someone who has traveled down this road previously, I would suggest that you re-engineer your driver instead of going with your current plan. I realize that you think this would be quicker and easier, but the maintenance headaches are pretty heavy as you get further into this. Doing a driver the "right" way to fit the kernel makes sense because it becomes very easy to maintain, whereas your method will require much more work for changes to kernel versions, or changes to core logic. I'm guessing the driver is pretty mature at this point, but you still live with maintaining with the kernel.From an application (userspace) or from inside the
I need to do the syscalls from kernel space. Basically
I am porting our custom vxWorks driver to Linux. We
want to basically keep the structure of the vxWorks
driver the same, so I am porting the individual
vxWorks functions such as semBcreate, semGive etc.
Thats why I want to use the SysV IPC semaphores, as
they seem to most closely resemble the vxWorks ones. I
know that there are much better ways of writing a
driver, but that wouldn't fit in with the currect
structure we have at the moment.
Now if I want to call lets say sys_semget() from
kernel space, must I use the _syscall3() function? I
saw some people using this.
Thanks for the help.