wacom->dev.keybit[LONG(BTN_DIGI)] |= BIT(BTN_TOOL_RUBBER) | BIT(BTN_TOOL_MOUSE) | BIT(BTN_STYLUS2); 
wacom->dev.keybit[LONG(BTN_DIGI)] |= BIT(BTN_TOOL_RUBBER) | BIT(BTN_TOOL_MOUSE) | BIT(BTN_STYLUS2); 
static int wacom_probe(struct usb_interface *intf, const struct usb_device_id *id){	struct usb_device *dev = interface_to_usbdev(intf);	struct usb_endpoint_descriptor *endpoint;	char rep_data[2] = {0x02, 0x02};	struct wacom *wacom;	char path[64];	if (!(wacom = kmalloc(sizeof(struct wacom), GFP_KERNEL)))		return -ENOMEM;	memset(wacom, 0, sizeof(struct wacom));	wacom->data = usb_buffer_alloc(dev, 10, GFP_KERNEL, &wacom->data_dma);	if (!wacom->data) {		kfree(wacom);		return -ENOMEM;	}	wacom->irq = usb_alloc_urb(0, GFP_KERNEL);	if (!wacom->irq) {		usb_buffer_free(dev, 10, wacom->data, wacom->data_dma);		kfree(wacom);		return -ENOMEM;	}	wacom->features = wacom_features + (id - wacom_ids);	wacom->dev.evbit[0] |= BIT(EV_KEY) | BIT(EV_ABS);	wacom->dev.absbit[0] |= BIT(ABS_X) | BIT(ABS_Y) | BIT(ABS_PRESSURE);	wacom->dev.keybit[LONG(BTN_DIGI)] |= BIT(BTN_TOOL_PEN) | BIT(BTN_TOUCH) | BIT(BTN_STYLUS);	switch (wacom->features->type) {		case 1:			wacom->dev.evbit[0] |= BIT(EV_REL);			wacom->dev.relbit[0] |= BIT(REL_WHEEL);			wacom->dev.absbit[0] |= BIT(ABS_DISTANCE);			wacom->dev.keybit[LONG(BTN_LEFT)] |= BIT(BTN_LEFT) | BIT(BTN_RIGHT) | BIT(BTN_MIDDLE); 			wacom->dev.keybit[LONG(BTN_DIGI)] |= BIT(BTN_TOOL_RUBBER) | BIT(BTN_TOOL_MOUSE) | BIT(BTN_STYLUS2);			break;		case 4: /* new functions for Intuos3 */			wacom->dev.keybit[LONG(BTN_DIGI)] |= BIT(BTN_TOOL_FINGER);			wacom->dev.keybit[LONG(BTN_LEFT)] |= BIT(BTN_0) | BIT(BTN_1) | BIT(BTN_2) | BIT(BTN_3) | BIT(BTN_4) | BIT(BTN_5) | BIT(BTN_6) | BIT(BTN_7);			wacom->dev.absbit[0] |= BIT(ABS_RX) | BIT(ABS_RY);			/* fall through */		case 2:			wacom->dev.evbit[0] |= BIT(EV_MSC) | BIT(EV_REL);			wacom->dev.mscbit[0] |= BIT(MSC_SERIAL);			wacom->dev.relbit[0] |= BIT(REL_WHEEL);			wacom->dev.keybit[LONG(BTN_LEFT)] |= BIT(BTN_LEFT) | BIT(BTN_RIGHT) | BIT(BTN_MIDDLE) | BIT(BTN_SIDE) | BIT(BTN_EXTRA); 			wacom->dev.keybit[LONG(BTN_DIGI)] |= BIT(BTN_TOOL_RUBBER) | BIT(BTN_TOOL_MOUSE)	| BIT(BTN_TOOL_BRUSH)							  | BIT(BTN_TOOL_PENCIL) | BIT(BTN_TOOL_AIRBRUSH) | BIT(BTN_TOOL_LENS) | BIT(BTN_STYLUS2);			wacom->dev.absbit[0] |= BIT(ABS_DISTANCE) | BIT(ABS_WHEEL) | BIT(ABS_TILT_X) | BIT(ABS_TILT_Y) | BIT(ABS_RZ) | BIT(ABS_THROTTLE);			break;		case 3: 			wacom->dev.keybit[LONG(BTN_DIGI)] |= BIT(BTN_STYLUS2) | BIT(BTN_TOOL_RUBBER);			break;	}	wacom->dev.absmax[ABS_X] = wacom->features->x_max;	wacom->dev.absmax[ABS_Y] = wacom->features->y_max;	wacom->dev.absmax[ABS_PRESSURE] = wacom->features->pressure_max;	wacom->dev.absmax[ABS_DISTANCE] = wacom->features->distance_max;	wacom->dev.absmax[ABS_TILT_X] = 127;	wacom->dev.absmax[ABS_TILT_Y] = 127;	wacom->dev.absmax[ABS_WHEEL] = 1023;	wacom->dev.absmax[ABS_RX] = 4097;	wacom->dev.absmax[ABS_RY] = 4097;	wacom->dev.absmin[ABS_RZ] = -900;	wacom->dev.absmax[ABS_RZ] = 899;	wacom->dev.absmin[ABS_THROTTLE] = -1023;	wacom->dev.absmax[ABS_THROTTLE] = 1023;	wacom->dev.absfuzz[ABS_X] = 4;	wacom->dev.absfuzz[ABS_Y] = 4;	wacom->dev.private = wacom;	wacom->dev.open = wacom_open;	wacom->dev.close = wacom_close;	usb_make_path(dev, path, 64);	sprintf(wacom->phys, "%s/input0", path);	wacom->dev.name = wacom->features->name;	wacom->dev.phys = wacom->phys;	wacom->dev.id.bustype = BUS_USB;	wacom->dev.id.vendor = le16_to_cpu(dev->descriptor.idVendor);	wacom->dev.id.product = le16_to_cpu(dev->descriptor.idProduct);	wacom->dev.id.version = le16_to_cpu(dev->descriptor.bcdDevice);	wacom->dev.dev = &intf->dev;	wacom->usbdev = dev;	endpoint = &intf->cur_altsetting->endpoint[0].desc;	if (wacom->features->pktlen > 10)		BUG();	usb_fill_int_urb(wacom->irq, dev,			 usb_rcvintpipe(dev, endpoint->bEndpointAddress),			 wacom->data, wacom->features->pktlen,			 wacom->features->irq, wacom, endpoint->bInterval);	wacom->irq->transfer_dma = wacom->data_dma;	wacom->irq->transfer_flags |= URB_NO_TRANSFER_DMA_MAP;	input_register_device(&wacom->dev);	/* ask the tablet to report tablet data */	usb_set_report(intf, 3, 2, rep_data, 2);	/* repeat once (not sure why the first call often fails) */	usb_set_report(intf, 3, 2, rep_data, 2);	printk(KERN_INFO "input: %s on %s\n", wacom->features->name, path);	usb_set_intfdata(intf, wacom);	return 0;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/05f091ab4c8c1f12f8dd38ee789489904fea327d/wacom.c/clean/drivers/usb/input/wacom.c