Changeset 78dbf5b in mainline for uspace/drv/usbhid/subdrivers.c


Ignore:
Timestamp:
2011-05-07T08:38:40Z (13 years ago)
Author:
Lubos Slovak <lubos.slovak@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
fb295b6
Parents:
6c6a95d2 (diff), 45a2688 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Fixes (parsing), mouse driver improved, generic HID driver improved

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/usbhid/subdrivers.c

    r6c6a95d2 r78dbf5b  
    3636#include "subdrivers.h"
    3737#include "usb/classes/hidut.h"
     38#include "usb/classes/hidpath.h"
    3839
    3940#include "lgtch-ultrax/lgtch-ultrax.h"
     41#include "mouse/mousedev.h"
    4042
    4143static usb_hid_subdriver_usage_t path_kbd[] = {
    4244        {USB_HIDUT_PAGE_KEYBOARD, 0},
     45        {0, 0}
     46};
     47
     48static usb_hid_subdriver_usage_t path_mouse[] = {
     49        {USB_HIDUT_PAGE_GENERIC_DESKTOP, USB_HIDUT_USAGE_GENERIC_DESKTOP_MOUSE},
     50        {USB_HIDUT_PAGE_GENERIC_DESKTOP,
     51         USB_HIDUT_USAGE_GENERIC_DESKTOP_POINTER},
     52        {0, 0}
     53};
     54
     55static usb_hid_subdriver_usage_t path_mouse2[] = {
     56        {USB_HIDUT_PAGE_GENERIC_DESKTOP, USB_HIDUT_USAGE_GENERIC_DESKTOP_X},
    4357        {0, 0}
    4458};
     
    7993                }
    8094        },
     95        {
     96                path_mouse,
     97                -1,
     98                USB_HID_PATH_COMPARE_COLLECTION_ONLY,
     99                -1,
     100                -1,
     101                {
     102                        .init = usb_mouse_init,
     103                        .deinit = usb_mouse_deinit,
     104                        .poll = usb_mouse_polling_callback,
     105                        .poll_end = NULL
     106                }
     107        },
     108        {
     109                path_mouse2,
     110                -1,
     111                USB_HID_PATH_COMPARE_END
     112                | USB_HID_PATH_COMPARE_USAGE_PAGE_ONLY,
     113                -1,
     114                -1,
     115                {
     116                        .init = usb_mouse_init,
     117                        .deinit = usb_mouse_deinit,
     118                        .poll = usb_mouse_polling_callback,
     119                        .poll_end = NULL
     120                }
     121        },
    81122        {NULL, -1, 0, -1, -1, {NULL, NULL, NULL, NULL}}
    82123};
Note: See TracChangeset for help on using the changeset viewer.