Changeset ca2d142 in mainline for uspace/srv/net/messages.h


Ignore:
Timestamp:
2010-02-18T10:00:30Z (14 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
e326edc
Parents:
b8da2a3 (diff), 91478aa (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:

Merge from the networking branch.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/net/messages.h

    rb8da2a3 rca2d142  
    459459}
    460460
    461 /** Returns the device packet dimensions for sending.
    462  *  @param[in] phone The service module phone.
    463  *  @param[in] message The service specific message.
    464  *  @param[in] device_id The device identifier.
    465  *  @param[out] addr_len The minimum reserved address length.
    466  *  @param[out] prefix The minimum reserved prefix size.
    467  *  @param[out] content The maximum content size.
    468  *  @param[out] suffix The minimum reserved suffix size.
    469  *  @returns EOK on success.
     461/** Returns the device packet dimension for sending.
     462 *  @param[in] phone The service module phone.
     463 *  @param[in] message The service specific message.
     464 *  @param[in] device_id The device identifier.
     465 *  @param[out] packet_dimension The packet dimension.
     466 *  @returns EOK on success.
     467 *  @returns EBADMEM if the packet_dimension parameter is NULL.
    470468 *  @returns Other error codes as defined for the specific service message.
    471469 */
    472 static inline int       generic_packet_size_req( int phone, int message, device_id_t device_id, size_t * addr_len, size_t * prefix, size_t * content, size_t * suffix ){
    473         return ( int ) async_req_1_4( phone, ( ipcarg_t ) message, ( ipcarg_t ) device_id, ( ipcarg_t * ) addr_len, ( ipcarg_t * ) prefix, ( ipcarg_t * ) content, ( ipcarg_t * ) suffix );
     470static inline int       generic_packet_size_req( int phone, int message, device_id_t device_id, packet_dimension_ref packet_dimension ){
     471        ipcarg_t        result;
     472        ipcarg_t        prefix;
     473        ipcarg_t        content;
     474        ipcarg_t        suffix;
     475        ipcarg_t        addr_len;
     476
     477        if( ! packet_dimension ) return EBADMEM;
     478        result = async_req_1_4( phone, ( ipcarg_t ) message, ( ipcarg_t ) device_id, & addr_len, & prefix, & content, & suffix );
     479        packet_dimension->prefix = ( size_t ) prefix;
     480        packet_dimension->content = ( size_t ) content;
     481        packet_dimension->suffix = ( size_t ) suffix;
     482        packet_dimension->addr_len = ( size_t ) addr_len;
     483        return ( int ) result;
    474484}
    475485
Note: See TracChangeset for help on using the changeset viewer.