software/drivers/sd8887/src/wlan/mapp/mlanconfig/mlanconfig.c
/**
 *  @brief Get the current status of the WMM Queues
 *
 *  Command: mlanconfig mlanX qstatus
 *
 *  Retrieve the following information for each AC if wmm is enabled:
 *        - WMM IE ACM Required
 *        - Firmware Flow Required
 *        - Firmware Flow Established
 *        - Firmware Queue Enabled
 *
 *  @param argc     number of arguments
 *  @param argv     A pointer to arguments array
 *
 *  @return         MLAN_STATUS_SUCCESS--success, otherwise--fail
 */
@brief Get the current status of the WMM Queues
Command: mlanconfig mlanX qstatus

Retrieve the following information for each AC if wmm is enabled:
- WMM IE ACM Required
- Firmware Flow Required
- Firmware Flow Established
- Firmware Queue Enabled

@param argc     number of arguments
@param argv     A pointer to arguments array


@brief Get the current status of the WMM Queues Command : mlanconfig mlanX qstatus Retrieve the following information for each AC if wmm is enabled : - WMM IE ACM Required - Firmware Flow Required - Firmware Flow Established - Firmware Queue Enabled @param argc number of arguments @param argv A pointer to arguments array
static int
process_wmm_qstatus(int argc, char *argv[])
{
	int ioctl_val, subioctl_val;
	struct iwreq iwr;
	wlan_ioctl_wmm_queue_status_t qstatus;
	mlan_wmm_ac_e acVal;
	if (get_priv_ioctl("qstatus",
			   &ioctl_val, &subioctl_val) == MLAN_STATUS_FAILURE) {
		return -EOPNOTSUPP;
	}
	memset(&qstatus, 0x00, sizeof(qstatus));
	strncpy(iwr.ifr_name, dev_name, IFNAMSIZ - 1);
	iwr.u.data.flags = subioctl_val;
	iwr.u.data.pointer = (caddr_t) & qstatus;
	iwr.u.data.length = (sizeof(qstatus));
	if (ioctl(sockfd, ioctl_val, &iwr) < 0) {
		perror("mlanconfig: qstatus ioctl");
		return -EFAULT;
	}
	for (acVal = WMM_AC_BK; acVal <= WMM_AC_VO; acVal++) {
		switch (acVal) {
		case WMM_AC_BK:
			printf("BK: ");
			break;
		case WMM_AC_BE:
			printf("BE: ");
			break;
		case WMM_AC_VI:
			printf("VI: ");
			break;
		case WMM_AC_VO:
			printf("VO: ");
			break;
		default:
			printf("??: ");
		}
		printf("ACM[%c], FlowReq[%c], FlowCreated[%c], Enabled[%c],"
		       " DE[%c], TE[%c]\n",
		       (qstatus.acStatus[acVal].wmmAcm ? 'X' : ' '),
		       (qstatus.acStatus[acVal].flowRequired ? 'X' : ' '),
		       (qstatus.acStatus[acVal].flowCreated ? 'X' : ' '),
		       (qstatus.acStatus[acVal].disabled ? ' ' : 'X'),
		       (qstatus.acStatus[acVal].deliveryEnabled ? 'X' : ' '),
		       (qstatus.acStatus[acVal].triggerEnabled ? 'X' : ' '));
	}
	return MLAN_STATUS_SUCCESS;
}
static int process_wmm_qstatus ( int argc , char * argv [ ] ) { int ioctl_val , subioctl_val ; struct iwreq iwr ; wlan_ioctl_wmm_queue_status_t qstatus ; mlan_wmm_ac_e acVal ; if ( get_priv_ioctl ( " " , & ioctl_val , & subioctl_val ) == MLAN_STATUS_FAILURE ) { return - EOPNOTSUPP ; } memset ( & qstatus , 0x00 , sizeof ( qstatus ) ) ; strncpy ( iwr . ifr_name , dev_name , IFNAMSIZ - 1 ) ; iwr . u . data . flags = subioctl_val ; iwr . u . data . pointer = ( caddr_t ) & qstatus ; iwr . u . data . length = ( sizeof ( qstatus ) ) ; if ( ioctl ( sockfd , ioctl_val , & iwr ) < 0 ) { perror ( " " ) ; return - EFAULT ; } for ( acVal = WMM_AC_BK ; acVal <= WMM_AC_VO ; acVal ++ ) { switch ( acVal ) { case WMM_AC_BK : printf ( " " ) ; break ; case WMM_AC_BE : printf ( " " ) ; break ; case WMM_AC_VI : printf ( " " ) ; break ; case WMM_AC_VO : printf ( " " ) ; break ; default : printf ( " " ) ; } printf ( " " " \n " , ( qstatus . acStatus [ acVal ] . wmmAcm ? ' ' : ' ' ) , ( qstatus . acStatus [ acVal ] . flowRequired ? ' ' : ' ' ) , ( qstatus . acStatus [ acVal ] . flowCreated ? ' ' : ' ' ) , ( qstatus . acStatus [ acVal ] . disabled ? ' ' : ' ' ) , ( qstatus . acStatus [ acVal ] . deliveryEnabled ? ' ' : ' ' ) , ( qstatus . acStatus [ acVal ] . triggerEnabled ? ' ' : ' ' ) ) ; } return MLAN_STATUS_SUCCESS ; }
@brief Get the current status of the WMM Queues
  Command: mlanconfig mlanX qstatus
@brief Get the current status of the WMM Queues Command : mlanconfig mlanX qstatus