Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1 | /* |
Kiet Lam | aa8e15a | 2014-02-11 23:30:06 -0800 | [diff] [blame^] | 2 | * Copyright (c) 2012-2013 Qualcomm Atheros, Inc. |
| 3 | * All Rights Reserved. |
| 4 | * Qualcomm Atheros Confidential and Proprietary. |
Gopichand Nakkala | 92f07d8 | 2013-01-08 21:16:34 -0800 | [diff] [blame] | 5 | */ |
| 6 | /* |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 7 | * Airgo Networks, Inc proprietary. All rights reserved. |
| 8 | * limStaHashApi.c: Provides access functions to get/set values of station hash entry fields. |
| 9 | * Author: Sunit Bhatia |
| 10 | * Date: 09/19/2006 |
| 11 | * History:- |
| 12 | * Date Modified by Modification Information |
| 13 | * |
| 14 | * -------------------------------------------------------------------------- |
| 15 | * |
| 16 | */ |
| 17 | |
| 18 | #include "limStaHashApi.h" |
| 19 | |
| 20 | |
| 21 | /** |
| 22 | * limGetStaHashBssidx() |
| 23 | * |
| 24 | *FUNCTION: |
| 25 | * This function is called to Get the Bss Index of the currently associated Station. |
| 26 | * |
| 27 | *LOGIC: |
| 28 | * |
| 29 | *ASSUMPTIONS: |
| 30 | * NA |
| 31 | * |
| 32 | *NOTE: |
| 33 | * NA |
| 34 | * |
| 35 | * @param pMac pointer to Global Mac structure. |
| 36 | * @param assocId AssocID of the Station. |
| 37 | * @param bssidx pointer to the bss index, which will be returned by the function. |
| 38 | * |
| 39 | * @return success if GET operation is ok, else Failure. |
| 40 | */ |
| 41 | |
| 42 | tSirRetStatus limGetStaHashBssidx(tpAniSirGlobal pMac, tANI_U16 assocId, tANI_U8 *bssidx, tpPESession psessionEntry) |
| 43 | { |
| 44 | tpDphHashNode pSta = dphGetHashEntry(pMac, assocId, &psessionEntry->dph.dphHashTable); |
| 45 | |
| 46 | if (pSta == NULL) |
| 47 | { |
Kiran Kumar Lokere | 5be73a6 | 2013-04-01 18:40:00 -0700 | [diff] [blame] | 48 | PELOGE(limLog(pMac, LOGE, FL("invalid STA %d"), assocId);) |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 49 | return eSIR_LIM_INVALID_STA; |
| 50 | } |
| 51 | |
| 52 | *bssidx = (tANI_U8)pSta->bssId; |
| 53 | return eSIR_SUCCESS; |
| 54 | } |
| 55 | |
| 56 | |
| 57 | |