View | Details | Raw Unified | Return to bug 117911 | Differences between
and this patch

Collapse All | Expand All

(-)dev/usb/ums.c (+15 lines)
Lines 359-364 Link Here
359
				hid_input, &sc->sc_loc_btn[i-1], 0);
359
				hid_input, &sc->sc_loc_btn[i-1], 0);
360
360
361
	sc->sc_isize = hid_report_size(desc, size, hid_input, &sc->sc_iid);
361
	sc->sc_isize = hid_report_size(desc, size, hid_input, &sc->sc_iid);
362
363
	// support for Gembirg MUSWC Wireless Optical Mouse
364
	if (uaa->vendor == 0x046e &&
365
	    uaa->product == 0x52e6) {
366
		sc->nbuttons = 3;
367
		sc->sc_isize = 5;
368
		sc->sc_iid = 2;
369
		sc->sc_loc_x.pos = 8;
370
		sc->sc_loc_y.pos = 16;
371
		sc->sc_loc_z.pos = 24;
372
		sc->sc_loc_btn[0].pos = 0;
373
		sc->sc_loc_btn[1].pos = 1;
374
		sc->sc_loc_btn[2].pos = 2;
375
	}
376
362
	sc->sc_ibuf = malloc(sc->sc_isize, M_USB, M_NOWAIT);
377
	sc->sc_ibuf = malloc(sc->sc_isize, M_USB, M_NOWAIT);
363
	if (!sc->sc_ibuf) {
378
	if (!sc->sc_ibuf) {
364
		printf("%s: no memory\n", device_get_nameunit(sc->sc_dev));
379
		printf("%s: no memory\n", device_get_nameunit(sc->sc_dev));

Return to bug 117911