func: static int pp_ioctl(CharDriverState *chr, int cmd, void *arg) ParallelCharDriver * drv = chr -> opaque ; int fd = drv -> fd ; uint8_t b ; switch ( cmd )  if ( ioctl ( fd , PPRDATA , & b ) < 0 )  * ( uint8_t * ) arg = b; b = * ( uint8_t * ) arg; if ( ioctl ( fd , PPRCONTROL , & b ) < 0 )  * ( uint8_t * ) arg = b | 0xc0; b = * ( uint8_t * ) arg; if ( ioctl ( fd , PPRSTATUS , & b ) < 0 )  * ( uint8_t * ) arg = b; if ( pp_hw_mode ( drv , IEEE1284_MODE_EPP | IEEE1284_ADDR ) )  static int pp_hw_mode(ParallelCharDriver *s, uint16_t mode) if ( s -> mode != mode )  if ( ioctl ( s -> fd , PPSETMODE , & m ) < 0 )  return 0 ; return 1 ; struct ParallelIOArg * parg = arg ; int n = write ( fd , parg -> buffer , parg -> count ) ; if ( n != parg -> count )  