From: Justin C. <jp...@do...> - 2001-01-16 19:52:33
|
Trying to get the input drivers working on Arm (sa1100), and having problems with inputattach. First is that it isnt dropping RTS to reset the devices. Someone else is working on that - it doesnt matter for all devices anyway. However I am getting a failure in devt = SERIO_RS232 | input_types[type].type | (input_types[type].extra << 16); if(ioctl(fd, SPIOCSTYPE, &devt)) { fprintf(stderr, "inputattach: can't set device type\n"); return 1; } basically the ioctl seems to fail, which is from serport.c: static int serport_ldisc_ioctl(struct tty_struct * tty, struct file * file, unsigned int cmd, unsigned long arg) { struct serport *serport = (struct serport*) tty->disc_data; switch (cmd) { case SPIOCSTYPE: return get_user(serport->serio.type, (unsigned long *) arg); } return -EINVAL; } Any idea whats wrong here? The cast looks a little odd to me. But I dont really know my way around this code very well yet... Justin |