I wrote a kernel module for a touch screen monitor and earlier I used inputattach (written in userspace) to open serial port, set baud rate, control flags, line discipline etc.
But now I want to implement the functionalities of inputattach directly in our driver as we don't want to trigger our driver from an userspace program i.e inputattch.
But I cant able to set c_ispeed, c_ospeed, c_cflag, c_iflag, line discipline, etc., in kernel space.
Is there any solution to set baud rate, line discipline etc., by only using our kernel module?