Hi Pauli, On 5/17/08, Pauli Borodulin <pauli@xxxxxxxxxxxx> wrote: > Heya! > > Since there has been some direct requests for this via email, I'm > posting a updated version of Kristian Slavov's original remote control > patch[1] for Manu's jusst.de Mantis branch. The new version is > functionally the same as the one I posted in March[2]. > > I have adapted the patch for the current driver tree and moved ir_codes > back to ir-keymaps.c & ir-common.h to follow the standard kernel > procedure for the IR stuff. The patch is against the current driver tree > (cd1fc4c7f1d8). > > [1] http://www.linuxtv.org/pipermail/linux-dvb/2007-April/017279.html > [2] http://www.linuxtv.org/pipermail/linux-dvb/2008-March/024301.html > > Regards, > Pauli Borodulin > +int mantis_rc_exit(struct mantis_pci *mantis) +{ + mmwrite(mmread(MANTIS_INT_MASK) & (~MANTIS_INT_IRQ1), MANTIS_INT_MASK); + + cancel_delayed_work(&mantis->ir.rc_query_work); + input_unregister_device(mantis->ir.rc_dev); + dprintk(verbose, MANTIS_DEBUG, 1, "RC unregistered"); + return 0; +} this might be dangerous when unloading the driver because the callback function might still be running after cancel_delayed_work. I ran into that problem a while ago and it could lock up the whole input system. There's also a note in the kernelheaders: /* * Kill off a pending schedule_delayed_work(). Note that the work callback * function may still be running on return from cancel_delayed_work(). Run * flush_scheduled_work() to wait on it. */ include/linux/workqueue.h Markus _______________________________________________ linux-dvb mailing list linux-dvb@xxxxxxxxxxx http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb