Changeset 0f21c0c in mainline for uspace/lib/usb


Ignore:
Timestamp:
2011-02-20T23:21:20Z (14 years ago)
Author:
Vojtech Horky <vojtechhorky@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
41b70d30, 9f554e64
Parents:
83c291d
Message:

Removal of API that use phones directly

Location:
uspace/lib/usb
Files:
5 deleted
6 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usb/Makefile

    r83c291d r0f21c0c  
    3838        src/debug.c \
    3939        src/dp.c \
    40         src/drvpsync.c \
    4140        src/dump.c \
    4241        src/hidparser.c \
     
    4948        src/usb.c \
    5049        src/usbdevice.c \
    51         src/usbdrvreq.c \
    52         src/usbdrv.c \
    5350        src/usbmem.c
    5451
  • uspace/lib/usb/include/usb/recognise.h

    r83c291d r0f21c0c  
    4141#include <ipc/devman.h>
    4242
     43int usb_device_create_match_ids_from_device_descriptor(
     44    const usb_standard_device_descriptor_t *, match_id_list_t *);
     45
    4346int usb_device_create_match_ids_from_interface(
    4447    const usb_standard_device_descriptor_t *,
  • uspace/lib/usb/include/usb/request.h

    r83c291d r0f21c0c  
    4141#include <usb/descriptor.h>
    4242
     43/** Standard device request. */
     44typedef enum {
     45        USB_DEVREQ_GET_STATUS = 0,
     46        USB_DEVREQ_CLEAR_FEATURE = 1,
     47        USB_DEVREQ_SET_FEATURE = 3,
     48        USB_DEVREQ_SET_ADDRESS = 5,
     49        USB_DEVREQ_GET_DESCRIPTOR = 6,
     50        USB_DEVREQ_SET_DESCRIPTOR = 7,
     51        USB_DEVREQ_GET_CONFIGURATION = 8,
     52        USB_DEVREQ_SET_CONFIGURATION = 9,
     53        USB_DEVREQ_GET_INTERFACE = 10,
     54        USB_DEVREQ_SET_INTERFACE = 11,
     55        USB_DEVREQ_SYNCH_FRAME = 12,
     56        USB_DEVREQ_LAST_STD
     57} usb_stddevreq_t;
     58
     59/** Device request setup packet.
     60 * The setup packet describes the request.
     61 */
     62typedef struct {
     63        /** Request type.
     64         * The type combines transfer direction, request type and
     65         * intended recipient.
     66         */
     67        uint8_t request_type;
     68        /** Request identification. */
     69        uint8_t request;
     70        /** Main parameter to the request. */
     71        union {
     72                uint16_t value;
     73                /* FIXME: add #ifdefs according to host endianess */
     74                struct {
     75                        uint8_t value_low;
     76                        uint8_t value_high;
     77                };
     78        };
     79        /** Auxiliary parameter to the request.
     80         * Typically, it is offset to something.
     81         */
     82        uint16_t index;
     83        /** Length of extra data. */
     84        uint16_t length;
     85} __attribute__ ((packed)) usb_device_request_setup_packet_t;
     86
    4387int usb_control_request_set(usb_endpoint_pipe_t *,
    4488    usb_request_type_t, usb_request_recipient_t, uint8_t,
  • uspace/lib/usb/src/dp.c

    r83c291d r0f21c0c  
    3737#include <str_error.h>
    3838#include <errno.h>
    39 #include <usb/usbdrv.h>
     39#include <assert.h>
    4040#include <bool.h>
    4141#include <usb/dp.h>
  • uspace/lib/usb/src/recognise.c

    r83c291d r0f21c0c  
    3434 */
    3535#include <sys/types.h>
    36 #include <usb/usbdrv.h>
    3736#include <usb/pipes.h>
    3837#include <usb/recognise.h>
     
    241240 * @return Error code.
    242241 */
    243 int usb_drv_create_match_ids_from_device_descriptor(
    244     match_id_list_t *matches,
    245     const usb_standard_device_descriptor_t *device_descriptor)
     242int usb_device_create_match_ids_from_device_descriptor(
     243    const usb_standard_device_descriptor_t *device_descriptor,
     244    match_id_list_t *matches)
    246245{
    247246        /*
     
    303302        }
    304303
    305         rc = usb_drv_create_match_ids_from_device_descriptor(matches,
    306             &device_descriptor);
     304        rc = usb_device_create_match_ids_from_device_descriptor(
     305            &device_descriptor, matches);
    307306        if (rc != EOK) {
    308307                return rc;
  • uspace/lib/usb/src/request.c

    r83c291d r0f21c0c  
    3434 */
    3535#include <usb/request.h>
    36 #include <usb/devreq.h>
    3736#include <errno.h>
    3837
Note: See TracChangeset for help on using the changeset viewer.