diff options
Diffstat (limited to 'linux-core/savage_drv.h')
| -rw-r--r-- | linux-core/savage_drv.h | 45 | 
1 files changed, 45 insertions, 0 deletions
| diff --git a/linux-core/savage_drv.h b/linux-core/savage_drv.h index 4cb59fea..755ed2e9 100644 --- a/linux-core/savage_drv.h +++ b/linux-core/savage_drv.h @@ -24,4 +24,49 @@  #ifndef __SAVAGE_DRV_H__  #define __SAVAGE_DRV_H__ +/* these chip tags should match the ones in the 2D driver in savage_regs.h. */ +enum savage_family { +    S3_UNKNOWN = 0, +    S3_SAVAGE3D, +    S3_SAVAGE_MX, +    S3_SAVAGE4, +    S3_PROSAVAGE, +    S3_TWISTER, +    S3_PROSAVAGEDDR, +    S3_SUPERSAVAGE, +    S3_SAVAGE2000, +    S3_LAST +}; + +#define S3_SAVAGE3D_SERIES(chip)  ((chip>=S3_SAVAGE3D) && (chip<=S3_SAVAGE_MX)) + +#define S3_SAVAGE4_SERIES(chip)  ((chip==S3_SAVAGE4)            \ +                                  || (chip==S3_PROSAVAGE)       \ +                                  || (chip==S3_TWISTER)         \ +                                  || (chip==S3_PROSAVAGEDDR)) + +#define	S3_SAVAGE_MOBILE_SERIES(chip)	((chip==S3_SAVAGE_MX) || (chip==S3_SUPERSAVAGE)) + +#define S3_SAVAGE_SERIES(chip)    ((chip>=S3_SAVAGE3D) && (chip<=S3_SAVAGE2000)) + +#define S3_MOBILE_TWISTER_SERIES(chip)   ((chip==S3_TWISTER)    \ +                                          ||(chip==S3_PROSAVAGEDDR)) + +/* flags */ +#define SAVAGE_IS_AGP 1 + +typedef struct drm_savage_private { +	drm_savage_sarea_t *sarea_priv; + +	enum savage_family chipset; +	unsigned flags; +	 +} drm_savage_private_t; + +#define SAVAGE_FB_SIZE_S3	0x01000000  /*  16MB */ +#define SAVAGE_FB_SIZE_S4	0x02000000  /*  32MB */ +#define SAVAGE_MMIO_SIZE        0x00080000  /* 512kB */ +#define SAVAGE_APERTURE_OFFSET  0x02000000  /*  32MB */ +#define SAVAGE_APERTURE_SIZE    0x05000000  /* 5 tiled surfaces, 16MB each */ +  #endif /* end #ifndef __SAVAGE_DRV_ */ | 
