Changeset a76b01b4 in mainline for uspace/lib/usbhost/src


Ignore:
Timestamp:
2012-02-24T19:11:23Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
a2bd8822
Parents:
76fbd9a
Message:

libus*: remove optical separators

Location:
uspace/lib/usbhost/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usbhost/src/endpoint.c

    r76fbd9a ra76b01b4  
    7272        return instance;
    7373}
    74 /*----------------------------------------------------------------------------*/
     74
    7575/** Properly dispose of endpoint_t structure.
    7676 * @param instance endpoint_t structure.
     
    8484        free(instance);
    8585}
    86 /*----------------------------------------------------------------------------*/
     86
    8787/** Set device specific data and hooks.
    8888 * @param instance endpoint_t structure.
     
    101101        fibril_mutex_unlock(&instance->guard);
    102102}
    103 /*----------------------------------------------------------------------------*/
     103
    104104/** Clear device specific data and hooks.
    105105 * @param instance endpoint_t structure.
     
    115115        fibril_mutex_unlock(&instance->guard);
    116116}
    117 /*----------------------------------------------------------------------------*/
     117
    118118/** Mark the endpoint as active and block access for further fibrils.
    119119 * @param instance endpoint_t structure.
     
    128128        fibril_mutex_unlock(&instance->guard);
    129129}
    130 /*----------------------------------------------------------------------------*/
     130
    131131/** Mark the endpoint as inactive and allow access for further fibrils.
    132132 * @param instance endpoint_t structure.
     
    140140        fibril_condvar_signal(&instance->avail);
    141141}
    142 /*----------------------------------------------------------------------------*/
     142
    143143/** Get the value of toggle bit.
    144144 * @param instance endpoint_t structure.
     
    156156        return ret;
    157157}
    158 /*----------------------------------------------------------------------------*/
     158
    159159/** Set the value of toggle bit.
    160160 * @param instance endpoint_t structure.
  • uspace/lib/usbhost/src/iface.c

    r76fbd9a ra76b01b4  
    9898        return ret;
    9999}
    100 /*----------------------------------------------------------------------------*/
     100
    101101/** Calls ep_add_hook upon endpoint registration.
    102102 * @param ep Endpoint to be registered.
     
    113113        return EOK;
    114114}
    115 /*----------------------------------------------------------------------------*/
     115
    116116/** Calls ep_remove_hook upon endpoint removal.
    117117 * @param ep Endpoint to be unregistered.
     
    126126                hcd->ep_remove_hook(hcd, ep);
    127127}
    128 /*----------------------------------------------------------------------------*/
     128
    129129/** Calls ep_remove_hook upon endpoint removal. Prints warning.
    130130 * @param ep Endpoint to be unregistered.
     
    141141                hcd->ep_remove_hook(hcd, ep);
    142142}
    143 /*----------------------------------------------------------------------------*/
     143
    144144/** Request address interface function.
    145145 *
     
    164164            &hcd->dev_manager, address, strict, speed);
    165165}
    166 /*----------------------------------------------------------------------------*/
     166
    167167/** Bind address interface function.
    168168 *
     
    183183            &hcd->dev_manager, address, handle);
    184184}
    185 /*----------------------------------------------------------------------------*/
     185
    186186/** Find device handle by address interface function.
    187187 *
     
    200200            &hcd->dev_manager, address, handle, NULL);
    201201}
    202 /*----------------------------------------------------------------------------*/
     202
    203203/** Release address interface function.
    204204 *
     
    218218        return EOK;
    219219}
    220 /*----------------------------------------------------------------------------*/
     220
    221221/** Register endpoint interface function.
    222222 * @param fun DDF function.
     
    254254            register_helper, hcd);
    255255}
    256 /*----------------------------------------------------------------------------*/
     256
    257257/** Unregister endpoint interface function.
    258258 * @param fun DDF function.
     
    274274            endpoint, direction, unregister_helper, hcd);
    275275}
    276 /*----------------------------------------------------------------------------*/
     276
    277277/** Inbound communication interface function.
    278278 * @param fun DDF function.
     
    292292            setup_data, callback, NULL, arg, "READ");
    293293}
    294 /*----------------------------------------------------------------------------*/
     294
    295295/** Outbound communication interface function.
    296296 * @param fun DDF function.
     
    310310            setup_data, NULL, callback, arg, "WRITE");
    311311}
    312 /*----------------------------------------------------------------------------*/
     312
    313313/** usbhc Interface implementation using hcd_t from libusbhost library. */
    314314usbhc_iface_t hcd_iface = {
  • uspace/lib/usbhost/src/usb_device_manager.c

    r76fbd9a ra76b01b4  
    6161        return new_address;
    6262}
    63 /*----------------------------------------------------------------------------*/
     63
    6464/** Initialize device manager structure.
    6565 *
     
    8282        fibril_mutex_initialize(&instance->guard);
    8383}
    84 /*----------------------------------------------------------------------------*/
     84
    8585/** Request USB address.
    8686 * @param instance usb_device_manager
     
    124124        return EOK;
    125125}
    126 /*----------------------------------------------------------------------------*/
     126
    127127/** Bind USB address to devman handle.
    128128 *
     
    156156        return EOK;
    157157}
    158 /*----------------------------------------------------------------------------*/
     158
    159159/** Release used USB address.
    160160 *
     
    182182        return EOK;
    183183}
    184 /*----------------------------------------------------------------------------*/
     184
    185185/** Find USB address associated with the device.
    186186 *
     
    205205        return ENOENT;
    206206}
    207 /*----------------------------------------------------------------------------*/
     207
    208208/** Find devman handle and speed assigned to USB address.
    209209 *
  • uspace/lib/usbhost/src/usb_endpoint_manager.c

    r76fbd9a ra76b01b4  
    6161            && (address == ep->address);
    6262}
    63 /*----------------------------------------------------------------------------*/
     63
    6464/** Get list that holds endpoints for given address.
    6565 * @param instance usb_endpoint_manager structure, non-null.
     
    7373        return &instance->endpoint_lists[addr % ENDPOINT_LIST_COUNT];
    7474}
    75 /*----------------------------------------------------------------------------*/
     75
    7676/** Internal search function, works on locked structure.
    7777 * @param instance usb_endpoint_manager structure, non-null.
     
    9797        return NULL;
    9898}
    99 /*----------------------------------------------------------------------------*/
     99
    100100/** Calculate bandwidth that needs to be reserved for communication with EP.
    101101 * Calculation follows USB 1.1 specification.
     
    145145        }
    146146}
    147 /*----------------------------------------------------------------------------*/
     147
    148148/** Initialize to default state.
    149149 * You need to provide valid bw_count function if you plan to use
     
    168168        return EOK;
    169169}
    170 /*----------------------------------------------------------------------------*/
     170
    171171/** Check setup packet data for signs of toggle reset.
    172172 *
     
    227227        }
    228228}
    229 /*----------------------------------------------------------------------------*/
     229
    230230/** Register endpoint structure.
    231231 * Checks for duplicates.
     
    262262        return EOK;
    263263}
    264 /*----------------------------------------------------------------------------*/
     264
    265265/** Unregister endpoint structure.
    266266 * Checks for duplicates.
     
    286286        return EOK;
    287287}
    288 /*----------------------------------------------------------------------------*/
     288
    289289/** Find endpoint_t representing the given communication route.
    290290 * @param instance usb_endpoint_manager, non-null.
     
    301301        return ep;
    302302}
    303 /*----------------------------------------------------------------------------*/
     303
    304304/** Create and register new endpoint_t structure.
    305305 * @param instance usb_endpoint_manager structure, non-null.
     
    364364        return EOK;
    365365}
    366 /*----------------------------------------------------------------------------*/
     366
    367367/** Unregister and destroy endpoint_t structure representing given route.
    368368 * @param instance usb_endpoint_manager structure, non-null.
     
    395395        return EOK;
    396396}
    397 /*----------------------------------------------------------------------------*/
     397
    398398/** Unregister and destroy all endpoints using given address.
    399399 * @param instance usb_endpoint_manager structure, non-null.
  • uspace/lib/usbhost/src/usb_transfer_batch.c

    r76fbd9a ra76b01b4  
    9696        return instance;
    9797}
    98 /*----------------------------------------------------------------------------*/
     98
    9999/** Correctly dispose all used data structures.
    100100 *
     
    116116        free(instance);
    117117}
    118 /*----------------------------------------------------------------------------*/
     118
    119119/** Prepare data and call the right callback.
    120120 *
Note: See TracChangeset for help on using the changeset viewer.