1 /* SPDX-License-Identifier: GPL-2.0 */
2 /* Copyright (C) 2018 Google, Inc. */
3 #ifndef __GASKET_IOCTL_H__
4 #define __GASKET_IOCTL_H__
6 #include "gasket_core.h"
8 #include <linux/compiler.h>
11 * Handle Gasket common ioctls.
12 * @filp: Pointer to the ioctl's file.
13 * @cmd: Ioctl command.
14 * @arg: Ioctl argument pointer.
16 * Returns 0 on success and nonzero on failure.
18 long gasket_handle_ioctl(struct file *filp, uint cmd, void __user *argp);
21 * Determines if an ioctl is part of the standard Gasket framework.
22 * @cmd: The ioctl number to handle.
24 * Returns 1 if the ioctl is supported and 0 otherwise.
26 long gasket_is_supported_ioctl(uint cmd);