I have a patch for linuxwacom to deal with this issue. The patch has been under an automated testing for some time and it has survived close to 40k hotpluggings. I'll make a patch for xf86-input-wacom in a week or so. Let's see if that one covers this case or not.
I have one comment inline. Ping On Tue, Feb 8, 2011 at 3:50 PM, Peter Hutterer <[email protected]> wrote: > This is a stopgap solution only. Due to the current hotplugging approach, > the dependent tools are initialised before the parent device. This leaves us > with a time window where the parent device does not yet have a DeviceIntPtr > attached. > > If an event from the parent device comes in during this time window, posting > the event causes segfaults. Fix this for now by checking if there is a > device attached to it yet. > > Signed-off-by: Peter Hutterer <[email protected]> > --- > I don't seem to find the time to fix this properly, so let's use the > quickfix for now. > > src/wcmCommon.c | 5 ++--- > 1 files changed, 2 insertions(+), 3 deletions(-) > > diff --git a/src/wcmCommon.c b/src/wcmCommon.c > index 59c7af3..e315977 100644 > --- a/src/wcmCommon.c > +++ b/src/wcmCommon.c > @@ -1187,10 +1187,9 @@ static void commonDispatchDevice(WacomCommonPtr > common, unsigned int channel, > > /* Tool on the tablet when driver starts. This sometime causes > * access errors to the device */ > - if (!miPointerGetScreen(pInfo->dev)) > + if (!pInfo->dev || !pInfo->dev->enabled) We can remove the screen check since we do not care about screen info any more. But testing result showed pInfo could be null some how. We should clean the extra area code since no one is maintaining it. Without the mixed area code, the logic here would be easier to follow. I do not have time to work on that cleanup though. > { > - xf86Msg(X_ERROR, "wcmEvent: Wacom driver can not get Current > Screen ID\n"); > - xf86Msg(X_ERROR, "Please remove Wacom tool from the tablet > and bring it back again.\n"); > + xf86Msg(X_ERROR, "wcmEvent: tool not initialized yet. > Skipping event. \n"); > return; > } > > -- > 1.7.3.5 > > > ------------------------------------------------------------------------------ > The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE: > Pinpoint memory and threading errors before they happen. > Find and fix more than 250 security defects in the development cycle. > Locate bottlenecks in serial and parallel code that limit performance. > http://p.sf.net/sfu/intel-dev2devfeb > _______________________________________________ > Linuxwacom-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel > ------------------------------------------------------------------------------ The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE: Pinpoint memory and threading errors before they happen. Find and fix more than 250 security defects in the development cycle. Locate bottlenecks in serial and parallel code that limit performance. http://p.sf.net/sfu/intel-dev2devfeb _______________________________________________ Linuxwacom-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel
