wlan_bearer/wlanldd/wlan_common/umac_common/inc/UmacProtocolStackSideUmac.h
changeset 0 c40eb8fe8501
equal deleted inserted replaced
-1:000000000000 0:c40eb8fe8501
       
     1 /*
       
     2 * Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the License "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:   Declaration of the MWlanProtocolStackSideUmac class.
       
    15 *
       
    16 */
       
    17 
       
    18 /*
       
    19 * %version: 9 %
       
    20 */
       
    21 
       
    22 #ifndef WLANPROTOCOLSTACKSIDEUMAC_H
       
    23 #define WLANPROTOCOLSTACKSIDEUMAC_H
       
    24 
       
    25 struct TMacAddress;
       
    26 class TDataBuffer;
       
    27 
       
    28 /**
       
    29 *  
       
    30 */
       
    31 class MWlanProtocolStackSideUmac
       
    32     {
       
    33 public:
       
    34 
       
    35     virtual ~MWlanProtocolStackSideUmac() {};
       
    36 
       
    37     virtual const TMacAddress& StationId() const = 0;
       
    38 
       
    39     /**
       
    40     * Triggers the setting of the Tx offset for every frame type which can be
       
    41     * transmitted
       
    42     */
       
    43     virtual void SetTxOffset() = 0;
       
    44 
       
    45     /**
       
    46     * Transmit a protocol stack frame
       
    47     * 
       
    48     * The frame to be sent needs to be in 802.3 format
       
    49     * @param aDataBuffer meta header of the frame to be transmitted
       
    50     * @param aMore ETrue if another frame is also ready to be transmitted
       
    51     *              EFalse otherwise
       
    52     */
       
    53     virtual void TxProtocolStackData( 
       
    54         TDataBuffer& aDataBuffer,
       
    55         TBool aMore ) = 0;
       
    56 
       
    57     /**
       
    58     * Gets the WLAN vendor needs for extra space (bytes) in frame buffers
       
    59     *  
       
    60     * @param aRxOffset How much extra space needs to be reserved
       
    61     *        in the Rx buffer before every Rx frame that is received from the
       
    62     *        WHA layer.
       
    63     * @param aTxHeaderSpace How much extra space needs to be reserved
       
    64     *        in the Tx buffer before every Tx frame that is given to the 
       
    65     *        WHA layer.
       
    66     * @param aTxTrailerSpace How much extra space needs to be reserved
       
    67     *        in the Tx buffer after every Tx frame that is given to the 
       
    68     *        WHA layer.
       
    69     */
       
    70     virtual void GetFrameExtraSpaceForVendor( 
       
    71         TUint8& aRxOffset,
       
    72         TUint8& aTxHeaderSpace,
       
    73         TUint8& aTxTrailerSpace ) const = 0 ;
       
    74 
       
    75     /**
       
    76      * Is protocol stack side transmission permitted
       
    77      * UMAC adaptation needs to call this method every time before calling
       
    78      * TxProtocolStackData() to check if it is allowed to call that
       
    79      * method!
       
    80      *
       
    81      * @param aTxQueueState If the return value is ETrue, the state 
       
    82      *        (full / not full) of every WHA transmit queue. Otherwise, not
       
    83      *        valid.
       
    84      *        Note! A frame shall not be submitted to a full queue - even if
       
    85      *        the return value would be ETrue
       
    86      * @return ETrue if Tx frame submission is permitted
       
    87      *         EFalse if Tx frame submission is not permitted
       
    88      */
       
    89     virtual TBool TxPermitted( TWhaTxQueueState& aTxQueueState ) const = 0;    
       
    90 
       
    91     /**
       
    92      * Is user data Tx enabled
       
    93      *
       
    94      * @return ETrue if user data Tx is enabled
       
    95      *         EFalse if user data Tx is not enabled
       
    96      */
       
    97     virtual TBool UserDataTxEnabled() const = 0;
       
    98     };
       
    99 
       
   100 #endif      // WLANPROTOCOLSTACKSIDEUMAC_H