From 9e4b783d519cfefdba1d56117b77ac929c1b7050 Mon Sep 17 00:00:00 2001 From: meijian Date: Wed, 22 Nov 2023 20:41:31 +0800 Subject: [PATCH] [wireless][header] Normalize IOCTL id Signed-off-by: meijian --- include/nuttx/wireless/wireless.h | 31 ++++++++++----- include/nuttx/wireless/wireless_priv.h | 54 -------------------------- 2 files changed, 21 insertions(+), 64 deletions(-) delete mode 100644 include/nuttx/wireless/wireless_priv.h diff --git a/include/nuttx/wireless/wireless.h b/include/nuttx/wireless/wireless.h index 53b16e333d345..2aadd94c765ef 100644 --- a/include/nuttx/wireless/wireless.h +++ b/include/nuttx/wireless/wireless.h @@ -140,16 +140,6 @@ #define SIOCSIWPMKSA _WLIOC(0x0036) /* PMKSA cache operation */ -/* Country code extension */ - -#define SIOCSIWCOUNTRY _WLIOC(0x0037) /* Set country code */ -#define SIOCGIWCOUNTRY _WLIOC(0x0038) /* Get country code */ - -/* WIFI / BT coexist type */ - -#define SIOCSIWPTAPRIO _WLIOC(0x0039) /* Set PTA priority type */ -#define SIOCGIWPTAPRIO _WLIOC(0x003a) /* Get PTA priority type */ - /* -------------------- DEV PRIVATE IOCTL LIST -------------------- */ /* These 32 ioctl are wireless device private, for 16 commands. @@ -159,6 +149,27 @@ */ #define SIOCIWFIRSTPRIV _WLIOC(0x00e0) + +/* DTIM extension */ + +#define SIOCSIWDTIM (SIOCIWFIRSTPRIV + 0) /* Set DTIM interval time */ +#define SIOCGIWDTIM (SIOCIWFIRSTPRIV + 1) /* Get DTIM interval time */ + +/* power save mode extension */ + +#define SIOCSIWPWSAVE (SIOCIWFIRSTPRIV + 2) /* Set power save mode */ +#define SIOCGIWPWSAVE (SIOCIWFIRSTPRIV + 3) /* Get power save mode */ + +/* Country code extension */ + +#define SIOCSIWCOUNTRY (SIOCIWFIRSTPRIV + 4) /* Set country code */ +#define SIOCGIWCOUNTRY (SIOCIWFIRSTPRIV + 5) /* Get country code */ + +/* WIFI / BT coexist type */ + +#define SIOCSIWPTAPRIO (SIOCIWFIRSTPRIV + 6) /* Set PTA priority type */ +#define SIOCGIWPTAPRIO (SIOCIWFIRSTPRIV + 7) /* Get PTA priority type */ + #define SIOCIWLASTPRIV _WLIOC(0x00ff) /* ------------------------- IOCTL STUFF ------------------------- */ diff --git a/include/nuttx/wireless/wireless_priv.h b/include/nuttx/wireless/wireless_priv.h deleted file mode 100644 index 2c4d7c93b7371..0000000000000 --- a/include/nuttx/wireless/wireless_priv.h +++ /dev/null @@ -1,54 +0,0 @@ -/************************************************************************************ - * include/nuttx/wireless/wireless_priv.h - * Wireless network private IOCTL commands - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. The - * ASF licenses this file to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the - * License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations - * under the License. - * - ************************************************************************************/ - -/* This file includes private definitions to be used in all wireless network drivers - * (when applicable). - */ - -#ifndef __INCLUDE_NUTTX_WIRELESS_WIRELESS_PRIV_H -#define __INCLUDE_NUTTX_WIRELESS_WIRELESS_PRIV_H - -/************************************************************************************ - * Included Files - ************************************************************************************/ - -#include - -/************************************************************************************ - * Pre-processor Definitions - ************************************************************************************/ - -/* Network Driver Private IOCTL Commands ********************************************/ - -/* The Private IOCTL Commands should be definded as SIOCSIWXXXX and SIOCGIWXXXX - * SIOCSIWXXXX : set params (even number) - * SIOCGIWXXXX : get params (odd number) - * - * NOTE: The range of Private IOCTL Commands is - * form SIOCIWFIRSTPRIV to SIOCIWLASTPRIV - */ - -#define SIOCSIWDTIM (SIOCIWFIRSTPRIV + 0) /* Set DTIM interval time */ -#define SIOCGIWDTIM (SIOCIWFIRSTPRIV + 1) /* Get DTIM interval time */ -#define SIOCSIWPWSAVE (SIOCIWFIRSTPRIV + 2) /* Set power save mode */ -#define SIOCGIWPWSAVE (SIOCIWFIRSTPRIV + 3) /* Get power save mode */ - -#endif /* __INCLUDE_NUTTX_WIRELESS_WIRELESS_PRIV_H */