Device drivers for Hewlet Packard HP-UX version 7

Charles Hirst chas at vision.UUCP
Wed Mar 21 03:10:03 AEST 1990


Can anybody on the net help

I am currently porting a windowing device driver to a HP 9000 series 825 machine running Version 7 of HP-UX. The device driver in question is PC-Connect if it
means anything to anybody.

As of the moment it all works fine except for one problem. When a csh is run in one of the virtual windows it appears to work. If however you run say ls in the shell window, the csh places it in the background. It will not allow you to pull it back to the forground either.

I traced the problem to the failure of the TIOCSPGRP ioctl issued by the csh. As this fails, the newly forked process, e.g. ls is not a process group leader as the shell is expecting it to be. The csh therefore shoves it into the background.

I have got round this problem by implementing the TIOCSPGRP ioctl myself. Normally we handle any ioctls recieved by our pseudo devices that are specific to our driver and then pass the rest down to l_control and l_ioctl.

However if I pass the TIOCSPGRP ioctl down it fails with error 25, ENOTTY. As a fix I trap it myself and simply fill the tty t_pgrp field in with the supplied argument ( the requested pid to set process group to ).

Can anybody tell me what fields need filling in, in a tty structure during the open routine. Looking at the tty struct does not help as HP have played with it a lot to get POSIX compatibility. I currently treat it like a BSD structure.

The driver used to work with version 3 of HP-UX, if that helps.

Many thanks.
-- 
--------------------------------------------------------------------------------
 ||    /    / 
 ||   /    /         Charles Hirst             Life is but a bowl 
 ||  /    /        Software Engineer           of worm gears !   
 || /    /
 ||//|  /          chas at vision.UUCP           VisionWare Ltd,
 | / | /   ...!uunet!mcsun!ukc!vision!chas    57, Cardigan Lane,
 |/  |/           +44-532-788858              Leeds, LS4 2LE,
                                                 United Kingdom
--------------------------------------------------------------------------------
			VISIONWARE DOS/UNIX Integration
--------------------------------------------------------------------------------



More information about the Comp.unix.wizards mailing list