[vbox-dev] [PATCH 1/3] VBoxGuest.h: Be consistent in our VBOXGUEST_IOCTL_CODE_ usage
Hans de Goede
hdegoede at redhat.com
Wed Aug 16 09:54:54 UTC 2017
Most ioctl definitions use VBOXGUEST_IOCTL_CODE_ which leads to
the ioctl having the same code on 32 and 64 bit builds. But some ioctls
use VBOXGUEST_IOCTL_CODE (no _ at the end) even though they don't need
and don't have a 32 bit compat counter-part.
This commit changes things to be consistent and use VBOXGUEST_IOCTL_CODE_
for all ioctls which do not have a 32 bit compat counter-part.
Signed-off-by: Hans de Goede <hdegoede at redhat.com>
---
include/VBox/VBoxGuest.h | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/include/VBox/VBoxGuest.h b/include/VBox/VBoxGuest.h
index 743fbb3c..221b1a76 100644
--- a/include/VBox/VBoxGuest.h
+++ b/include/VBox/VBoxGuest.h
@@ -225,7 +225,7 @@ typedef const VBGLBIGREQ *PCVBGLBIGREQ;
/** IOCTL to VBoxGuest to query the VMMDev IO port region start.
* @remarks Ring-0 only. */
-#define VBOXGUEST_IOCTL_GETVMMDEVPORT VBOXGUEST_IOCTL_CODE(1, sizeof(VBoxGuestPortInfo))
+#define VBOXGUEST_IOCTL_GETVMMDEVPORT VBOXGUEST_IOCTL_CODE_(1, sizeof(VBoxGuestPortInfo))
#pragma pack(4)
typedef struct VBoxGuestPortInfo
@@ -334,7 +334,7 @@ typedef struct VBoxGuestChangeBalloonInfo
AssertCompileSize(VBoxGuestChangeBalloonInfo, 16);
/** IOCTL to VBoxGuest to write guest core. */
-#define VBOXGUEST_IOCTL_WRITE_CORE_DUMP VBOXGUEST_IOCTL_CODE(9, sizeof(VBoxGuestWriteCoreDump))
+#define VBOXGUEST_IOCTL_WRITE_CORE_DUMP VBOXGUEST_IOCTL_CODE_(9, sizeof(VBoxGuestWriteCoreDump))
/** Input and output buffer layout of the VBOXGUEST_IOCTL_WRITE_CORE
* request. */
@@ -365,7 +365,7 @@ AssertCompileSize(VBoxGuestWriteCoreDump, 4);
/** IOCTL to VBoxGuest passed from the Kernel Mode driver, but containing a user mode data in VBoxGuestHGCMCallInfo
* the driver received from the UM. Called in the context of the process passing the data.
* @see VBoxGuestHGCMCallInfo */
-# define VBOXGUEST_IOCTL_HGCM_CALL_USERDATA(Size) VBOXGUEST_IOCTL_CODE(21, (Size))
+# define VBOXGUEST_IOCTL_HGCM_CALL_USERDATA(Size) VBOXGUEST_IOCTL_CODE_(21, (Size))
# ifdef RT_ARCH_AMD64
/** @name IOCTL numbers that 32-bit clients, like the Windows OpenGL guest
@@ -395,7 +395,7 @@ AssertCompileSize(VBoxGuestWriteCoreDump, 4);
/** IOCTL to for setting the mouse driver callback. (kernel only) */
/** @note The callback will be called in interrupt context with the VBoxGuest
* device event spinlock held. */
-#define VBOXGUEST_IOCTL_SET_MOUSE_NOTIFY_CALLBACK VBOXGUEST_IOCTL_CODE(31, sizeof(VBoxGuestMouseSetNotifyCallback))
+#define VBOXGUEST_IOCTL_SET_MOUSE_NOTIFY_CALLBACK VBOXGUEST_IOCTL_CODE_(31, sizeof(VBoxGuestMouseSetNotifyCallback))
typedef DECLCALLBACK(void) FNVBOXGUESTMOUSENOTIFY(void *pfnUser);
typedef FNVBOXGUESTMOUSENOTIFY *PFNVBOXGUESTMOUSENOTIFY;
@@ -452,7 +452,7 @@ typedef struct VBoxGuestCapsAquire
* running in different user sessions simultaneously to interfere with each other.
* An r3 client application (like VBoxTray) is responsible for Acquiring/Releasing caps properly as needed.
**/
-#define VBOXGUEST_IOCTL_GUEST_CAPS_ACQUIRE VBOXGUEST_IOCTL_CODE(32, sizeof(VBoxGuestCapsAquire))
+#define VBOXGUEST_IOCTL_GUEST_CAPS_ACQUIRE VBOXGUEST_IOCTL_CODE_(32, sizeof(VBoxGuestCapsAquire))
/** IOCTL to VBoxGuest to set guest capabilities. */
#define VBOXGUEST_IOCTL_SET_GUEST_CAPABILITIES VBOXGUEST_IOCTL_CODE_(33, sizeof(VBoxGuestSetCapabilitiesInfo))
@@ -533,7 +533,7 @@ typedef VBOXGUESTOS2IDCCONNECT *PVBOXGUESTOS2IDCCONNECT;
* This takes no input and it doesn't return anything. Obviously this
* is only recognized if it arrives thru the IDC service EP.
*/
-# define VBOXGUEST_IOCTL_OS2_IDC_DISCONNECT VBOXGUEST_IOCTL_CODE(48, sizeof(uint32_t))
+# define VBOXGUEST_IOCTL_OS2_IDC_DISCONNECT VBOXGUEST_IOCTL_CODE_(48, sizeof(uint32_t))
#endif /* RT_OS_OS2 */
--
2.13.4
More information about the vbox-dev
mailing list