On Wed, Feb 26, 2014 at 05:01:10PM +0100, Johan Hovold wrote: > On Tue, Feb 25, 2014 at 03:55:07PM +0000, Ludovic wrote: > > At 1st the driver detected the USB key and set-up the serial ports. But when > > trying to write I got a kernel panic on the router. > > Are you able to get a stack trace? > > > I finally found that it seems to work properly with 'debug=0', and I also > > added the patch below. > > Hmm. The patch below is not correct, though (more below). > > I assume you're still using an old kernel as the debug module parameter > doesn't exist anymore. Can you reproduce this on a recent kernel? > > > So I need: > > 1- to find what cause the panic on my router with debug=1 > > 2- to test the patch on a LE system. > > > > Thanks for you time, > > You're welcome. > > > Ludovic. > > > > --- io_ti.c.ok2002 2014-02-24 21:54:46.000000000 +0100 > > +++ io_ti.c 2014-02-24 21:56:33.000000000 +0100 > > @@ -2408,8 +2408,8 @@ > > dbg("bUartMode: %d", config->bUartMode); > > > > /* move the word values into big endian mode */ > > - cpu_to_be16s(&config->wFlags); > > - cpu_to_be16s(&config->wBaudRate); > > + swab16s(&config->wFlags); > > + swab16s(&config->wBaudRate); > > This isn't right. The config buffer is transferred as data and only > needs to be byte-swapped on LE-systems (i.e. cpu_to_be16s is correct). > > Could you verify that my patch works without those two additional > changes (with debug=0)? > > > status = send_cmd(edge_port->port->serial->dev, UMPC_SET_CONFIG, > > (__u8)(UMPM_UART1_PORT + port_number), Did you get a chance to verify my (unmodified) patch (on BE and LE)? Are you able to test it against a recent kernel on your router or are you stuck with an old kernel? Thanks, Johan -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html