Changeset 3cc55b47 in mainline for uspace/drv/bus/usb/usbmast/main.c


Ignore:
Timestamp:
2013-08-01T15:11:20Z (11 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
fdec59b
Parents:
ec6766a
Message:

usbmast: Set bulk pipes before probing the device

Fixes usbmast segfault

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/usbmast/main.c

    rec6766a r3cc55b47  
    5252#define NAME "usbmast"
    5353
    54 #define GET_BULK_IN(dev) ((dev)->pipes[BULK_IN_EP].pipe)
    55 #define GET_BULK_OUT(dev) ((dev)->pipes[BULK_OUT_EP].pipe)
    56 
    5754static const usb_endpoint_description_t bulk_in_ep = {
    5855        .transfer_type = USB_TRANSFER_BULK,
     
    184181        }
    185182
     183        mdev->bulk_in_pipe = &epm_in->pipe;
     184        mdev->bulk_out_pipe = &epm_out->pipe;
    186185        for (i = 0; i < mdev->lun_count; i++) {
    187186                rc = usbmast_fun_create(mdev, i);
     
    189188                        goto error;
    190189        }
    191         mdev->bulk_in_pipe = &epm_in->pipe;
    192         mdev->bulk_out_pipe = &epm_out->pipe;
    193190
    194191        return EOK;
Note: See TracChangeset for help on using the changeset viewer.