brintos

brintos / linux-shallow public Read only

0
0
Text · 1.2 KiB · af1c14c Raw
57 lines · c
1/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */2/*3 * Copyright (C) 2012 Russell King4 *  With inspiration from the i915 driver5 *6 * This program is free software; you can redistribute it and/or modify7 * it under the terms of the GNU General Public License version 2 as8 * published by the Free Software Foundation.9 */10#ifndef DRM_ARMADA_IOCTL_H11#define DRM_ARMADA_IOCTL_H12 13#include "drm.h"14 15#if defined(__cplusplus)16extern "C" {17#endif18 19#define DRM_ARMADA_GEM_CREATE		0x0020#define DRM_ARMADA_GEM_MMAP		0x0221#define DRM_ARMADA_GEM_PWRITE		0x0322 23#define ARMADA_IOCTL(dir, name, str) \24	DRM_##dir(DRM_COMMAND_BASE + DRM_ARMADA_##name, struct drm_armada_##str)25 26struct drm_armada_gem_create {27	__u32 handle;28	__u32 size;29};30#define DRM_IOCTL_ARMADA_GEM_CREATE \31	ARMADA_IOCTL(IOWR, GEM_CREATE, gem_create)32 33struct drm_armada_gem_mmap {34	__u32 handle;35	__u32 pad;36	__u64 offset;37	__u64 size;38	__u64 addr;39};40#define DRM_IOCTL_ARMADA_GEM_MMAP \41	ARMADA_IOCTL(IOWR, GEM_MMAP, gem_mmap)42 43struct drm_armada_gem_pwrite {44	__u64 ptr;45	__u32 handle;46	__u32 offset;47	__u32 size;48};49#define DRM_IOCTL_ARMADA_GEM_PWRITE \50	ARMADA_IOCTL(IOW, GEM_PWRITE, gem_pwrite)51 52#if defined(__cplusplus)53}54#endif55 56#endif57