18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: MIT */ 28c2ecf20Sopenharmony_ci/* Copyright (C) 2006-2017 Oracle Corporation */ 38c2ecf20Sopenharmony_ci 48c2ecf20Sopenharmony_ci#ifndef __HGSMI_CH_SETUP_H__ 58c2ecf20Sopenharmony_ci#define __HGSMI_CH_SETUP_H__ 68c2ecf20Sopenharmony_ci 78c2ecf20Sopenharmony_ci/* 88c2ecf20Sopenharmony_ci * Tell the host the location of hgsmi_host_flags structure, where the host 98c2ecf20Sopenharmony_ci * can write information about pending buffers, etc, and which can be quickly 108c2ecf20Sopenharmony_ci * polled by the guest without a need to port IO. 118c2ecf20Sopenharmony_ci */ 128c2ecf20Sopenharmony_ci#define HGSMI_CC_HOST_FLAGS_LOCATION 0 138c2ecf20Sopenharmony_ci 148c2ecf20Sopenharmony_cistruct hgsmi_buffer_location { 158c2ecf20Sopenharmony_ci u32 buf_location; 168c2ecf20Sopenharmony_ci u32 buf_len; 178c2ecf20Sopenharmony_ci} __packed; 188c2ecf20Sopenharmony_ci 198c2ecf20Sopenharmony_ci/* HGSMI setup and configuration data structures. */ 208c2ecf20Sopenharmony_ci 218c2ecf20Sopenharmony_ci#define HGSMIHOSTFLAGS_COMMANDS_PENDING 0x01u 228c2ecf20Sopenharmony_ci#define HGSMIHOSTFLAGS_IRQ 0x02u 238c2ecf20Sopenharmony_ci#define HGSMIHOSTFLAGS_VSYNC 0x10u 248c2ecf20Sopenharmony_ci#define HGSMIHOSTFLAGS_HOTPLUG 0x20u 258c2ecf20Sopenharmony_ci#define HGSMIHOSTFLAGS_CURSOR_CAPABILITIES 0x40u 268c2ecf20Sopenharmony_ci 278c2ecf20Sopenharmony_cistruct hgsmi_host_flags { 288c2ecf20Sopenharmony_ci u32 host_flags; 298c2ecf20Sopenharmony_ci u32 reserved[3]; 308c2ecf20Sopenharmony_ci} __packed; 318c2ecf20Sopenharmony_ci 328c2ecf20Sopenharmony_ci#endif 33