efb.h revision 1450
/*
*/
#ifndef _EFB_H
#define _EFB_H
#include <sys/visual_io.h>
#include "drm_sunmod.h"
#include <sys/gfx_common.h>
#include "efb_vis.h"
#include "efb_reg.h"
#define EFB_CMAP_ENTRIES 256
#define EFB_VRT_MASK 0x0000001f
/* Power */
#define EFB_PM_BOARD 0 /* component 0 : board */
/* Power levels */
#define EFB_PWR_UNKNOWN (-1)
#define EFB_PWR_OFF 0
#define EFB_PWR_SUSP 1
#define EFB_PWR_STDBY 2
#define EFB_PWR_ON 3
typedef struct efb_private efb_private_t;
typedef struct efb_context efb_context_t;
typedef struct efb_mapinfo efb_mapinfo_t;
struct efb_mapinfo {
};
struct efb_context {
void *mappings;
struct drm_radeon_driver_file_fields *md;
};
struct efb_private {
int w[2];
int h[2];
int depth[2];
int stride[2];
int power_level[3];
int primary_stream;
struct gfx_video_mode videomode;
struct video_state {
/* DAC registers */
void *cur_ctx;
#if VIS_CONS_REV > 2
struct efb_consinfo consinfo;
int setting_videomode;
#endif
};
extern int efb_attach(drm_device_t *);
extern void efb_detach(drm_device_t *);
extern int efb_map_registers(drm_device_t *);
extern void efb_unmap_registers(drm_device_t *);
extern void efb_getsize(efb_private_t *);
extern void efb_cmap_write(efb_private_t *, int);
extern void efb_cmap_read(efb_private_t *, int, int, int);
extern int efb_wait_fifo(efb_private_t *, int, const char *, int);
extern int efb_wait_idle(efb_private_t *, const char *, int);
extern int efb_wait_host_data(efb_private_t *, const char *, int);
extern void efb_termemu_callback(drm_device_t *);
extern void * efb_devmap_set_callbacks(int);
efb_context_t *ctx);
extern void efb_ctx_wait(efb_private_t *);
#endif /* _EFB_H */