提交 e4147abe 编写于 作者: B Bill Pemberton 提交者: Greg Kroah-Hartman

Staging: xgifb: Remove XGI_HW_DEVICE_INFO and PXGI_HW_DEVICE_INFO typedefs

Signed-off-by: NBill Pemberton <wfp5p@virginia.edu>
Cc: Arnaud Patard <apatard@mandriva.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 1d9f9a9b
......@@ -248,9 +248,6 @@ MODULE_DEVICE_TABLE(pci, xgifb_pci_table);
#define BRI_DRAM_SIZE_32MB 0x04
#define BRI_DRAM_SIZE_64MB 0x05
#define HW_DEVICE_EXTENSION XGI_HW_DEVICE_INFO
#define PHW_DEVICE_EXTENSION PXGI_HW_DEVICE_INFO
#define SR_BUFFER_SIZE 5
#define CR_BUFFER_SIZE 5
......@@ -376,7 +373,7 @@ unsigned char XGIfb_detectedlcda = 0xff;
/* XGIfb_info XGIfbinfo; */
/* TW: Hardware extension; contains data on hardware */
HW_DEVICE_EXTENSION XGIhw_ext;
struct xgi_hw_device_info XGIhw_ext;
/* TW: XGI private structure */
VB_DEVICE_INFO XGI_Pr;
......@@ -812,9 +809,9 @@ static int XGIfb_ioctl(struct fb_info *info, unsigned int cmd,
/*
extern int XGIfb_mode_rate_to_dclock(VB_DEVICE_INFO *XGI_Pr,
PXGI_HW_DEVICE_INFO HwDeviceExtension,
struct xgi_hw_device_info *HwDeviceExtension,
unsigned char modeno, unsigned char rateindex);
extern int XGIfb_mode_rate_to_ddata(VB_DEVICE_INFO *XGI_Pr, PXGI_HW_DEVICE_INFO HwDeviceExtension,
extern int XGIfb_mode_rate_to_ddata(VB_DEVICE_INFO *XGI_Pr, struct xgi_hw_device_info *HwDeviceExtension,
unsigned char modeno, unsigned char rateindex,
unsigned int *left_margin, unsigned int *right_margin,
unsigned int *upper_margin, unsigned int *lower_margin,
......@@ -881,20 +878,22 @@ static XGI_OH *XGIfb_poh_free(unsigned long base);
static void XGIfb_free_node(XGI_OH *poh);
/* Internal routines to access PCI configuration space */
unsigned char XGIfb_query_VGA_config_space(PXGI_HW_DEVICE_INFO pXGIhw_ext,
unsigned long offset, unsigned long set, unsigned long *value);
unsigned char XGIfb_query_VGA_config_space(struct xgi_hw_device_info *pXGIhw_ext,
unsigned long offset,
unsigned long set,
unsigned long *value);
//BOOLEAN XGIfb_query_north_bridge_space(PXGI_HW_DEVICE_INFO pXGIhw_ext,
// unsigned long offset, unsigned long set, unsigned long *value);
/* Routines from init.c/init301.c */
extern void InitTo330Pointer(unsigned char, PVB_DEVICE_INFO pVBInfo);
extern unsigned char XGIInitNew(PXGI_HW_DEVICE_INFO HwDeviceExtension);
extern unsigned char XGISetModeNew(PXGI_HW_DEVICE_INFO HwDeviceExtension,
unsigned short ModeNo);
extern unsigned char XGIInitNew(struct xgi_hw_device_info *HwDeviceExtension);
extern unsigned char XGISetModeNew(struct xgi_hw_device_info *HwDeviceExtension,
unsigned short ModeNo);
//extern void XGI_SetEnableDstn(VB_DEVICE_INFO *XGI_Pr);
extern void XGI_LongWait(VB_DEVICE_INFO *XGI_Pr);
extern unsigned short XGI_GetRatePtrCRT2(PXGI_HW_DEVICE_INFO pXGIHWDE,
extern unsigned short XGI_GetRatePtrCRT2(struct xgi_hw_device_info *pXGIHWDE,
unsigned short ModeNo,
unsigned short ModeIdIndex,
PVB_DEVICE_INFO pVBInfo);
......
......@@ -162,7 +162,7 @@ struct video_info xgi_video_info;
/* --------------- Hardware Access Routines -------------------------- */
int
XGIfb_mode_rate_to_dclock(VB_DEVICE_INFO *XGI_Pr, PXGI_HW_DEVICE_INFO HwDeviceExtension,
XGIfb_mode_rate_to_dclock(VB_DEVICE_INFO *XGI_Pr, struct xgi_hw_device_info *HwDeviceExtension,
unsigned char modeno, unsigned char rateindex)
{
unsigned short ModeNo = modeno;
......@@ -197,7 +197,7 @@ XGIfb_mode_rate_to_dclock(VB_DEVICE_INFO *XGI_Pr, PXGI_HW_DEVICE_INFO HwDeviceEx
}
int
XGIfb_mode_rate_to_ddata(VB_DEVICE_INFO *XGI_Pr, PXGI_HW_DEVICE_INFO HwDeviceExtension,
XGIfb_mode_rate_to_ddata(VB_DEVICE_INFO *XGI_Pr, struct xgi_hw_device_info *HwDeviceExtension,
unsigned char modeno, unsigned char rateindex,
u32 *left_margin, u32 *right_margin,
u32 *upper_margin, u32 *lower_margin,
......@@ -416,7 +416,7 @@ u32 XGIfb_get_reg3(u16 port)
/* ------------ Interface for init & mode switching code ------------- */
unsigned char
XGIfb_query_VGA_config_space(PXGI_HW_DEVICE_INFO pXGIhw_ext,
XGIfb_query_VGA_config_space(struct xgi_hw_device_info *pXGIhw_ext,
unsigned long offset, unsigned long set, unsigned long *value)
{
static struct pci_dev *pdev = NULL;
......@@ -450,7 +450,7 @@ XGIfb_query_VGA_config_space(PXGI_HW_DEVICE_INFO pXGIhw_ext,
return 1;
}
/*unsigned char XGIfb_query_north_bridge_space(PXGI_HW_DEVICE_INFO pXGIhw_ext,
/*unsigned char XGIfb_query_north_bridge_space(struct xgi_hw_device_info *pXGIhw_ext,
unsigned long offset, unsigned long set, unsigned long *value)
{
static struct pci_dev *pdev = NULL;
......@@ -2881,7 +2881,7 @@ int __devinit xgifb_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
XGIfb_registered = 0;
memset(&XGIhw_ext, 0, sizeof(HW_DEVICE_EXTENSION));
memset(&XGIhw_ext, 0, sizeof(struct xgi_hw_device_info));
fb_info = framebuffer_alloc(sizeof(struct fb_info), &pdev->dev);
if(!fb_info) return -ENOMEM;
......
......@@ -14,18 +14,18 @@ extern unsigned char XGI330_OutputSelect;
extern unsigned short XGI330_RGBSenseData2;
extern unsigned short XGI330_YCSenseData2;
extern unsigned short XGI330_VideoSenseData2;
void XGI_GetSenseStatus( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo );
void XGI_GetSenseStatus(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo);
unsigned char XGINew_GetPanelID(PVB_DEVICE_INFO pVBInfo);
unsigned short XGINew_SenseLCD(PXGI_HW_DEVICE_INFO,
unsigned short XGINew_SenseLCD(struct xgi_hw_device_info *,
PVB_DEVICE_INFO pVBInfo);
unsigned char XGINew_GetLCDDDCInfo(PXGI_HW_DEVICE_INFO HwDeviceExtension,
unsigned char XGINew_GetLCDDDCInfo(struct xgi_hw_device_info *HwDeviceExtension,
PVB_DEVICE_INFO pVBInfo);
void XGISetDPMS(PXGI_HW_DEVICE_INFO pXGIHWDE,
void XGISetDPMS(struct xgi_hw_device_info *pXGIHWDE,
unsigned long VESA_POWER_STATE);
unsigned char XGINew_BridgeIsEnable(PXGI_HW_DEVICE_INFO, PVB_DEVICE_INFO pVBInfo);
unsigned char XGINew_BridgeIsEnable(struct xgi_hw_device_info *, PVB_DEVICE_INFO pVBInfo);
unsigned char XGINew_Sense(unsigned short tempbx, unsigned short tempcx,
PVB_DEVICE_INFO pVBInfo);
unsigned char XGINew_SenseHiTV(PXGI_HW_DEVICE_INFO HwDeviceExtension,
unsigned char XGINew_SenseHiTV(struct xgi_hw_device_info *HwDeviceExtension,
PVB_DEVICE_INFO pVBInfo);
/**************************************************************
......@@ -135,7 +135,7 @@ unsigned char XGINew_Sense(unsigned short tempbx,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGISetDPMS(PXGI_HW_DEVICE_INFO pXGIHWDE,
void XGISetDPMS(struct xgi_hw_device_info *pXGIHWDE,
unsigned long VESA_POWER_STATE)
{
unsigned short ModeNo, ModeIdIndex;
......@@ -359,7 +359,7 @@ void XGISetDPMS(PXGI_HW_DEVICE_INFO pXGIHWDE,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGI_GetSenseStatus( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo)
void XGI_GetSenseStatus(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short tempax = 0 , tempbx , tempcx , temp ,
P2reg0 = 0 , SenseModeNo = 0 , OutputSelect = *pVBInfo->pOutputSelect ,
......@@ -558,7 +558,7 @@ void XGI_GetSenseStatus( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
unsigned short XGINew_SenseLCD(PXGI_HW_DEVICE_INFO HwDeviceExtension,
unsigned short XGINew_SenseLCD(struct xgi_hw_device_info *HwDeviceExtension,
PVB_DEVICE_INFO pVBInfo)
{
/* unsigned short SoftSetting ; */
......@@ -582,7 +582,7 @@ unsigned short XGINew_SenseLCD(PXGI_HW_DEVICE_INFO HwDeviceExtension,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
unsigned char XGINew_GetLCDDDCInfo( PXGI_HW_DEVICE_INFO HwDeviceExtension,PVB_DEVICE_INFO pVBInfo)
unsigned char XGINew_GetLCDDDCInfo(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short temp ;
......@@ -708,7 +708,7 @@ unsigned char XGINew_GetPanelID(PVB_DEVICE_INFO pVBInfo )
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
unsigned char XGINew_BridgeIsEnable( PXGI_HW_DEVICE_INFO HwDeviceExtension ,PVB_DEVICE_INFO pVBInfo)
unsigned char XGINew_BridgeIsEnable(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short flag ;
......@@ -735,7 +735,7 @@ unsigned char XGINew_BridgeIsEnable( PXGI_HW_DEVICE_INFO HwDeviceExtension ,PVB_
/* Output : */
/* Description : */
/* ------------------------------------------------------ */
unsigned char XGINew_SenseHiTV( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo )
unsigned char XGINew_SenseHiTV(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short tempbx , tempcx , temp , i , tempch;
......@@ -998,7 +998,7 @@ void XGI_XG21Fun14Sub73( PVB_DEVICE_INFO pVBInfo , PX86_REGS pBiosArguments )
}
void XGI_XG21Fun14( PXGI_HW_DEVICE_INFO pXGIHWDE, PX86_REGS pBiosArguments)
void XGI_XG21Fun14(struct xgi_hw_device_info *pXGIHWDE, PX86_REGS pBiosArguments)
{
VB_DEVICE_INFO VBINF;
PVB_DEVICE_INFO pVBInfo = &VBINF;
......
......@@ -21,14 +21,14 @@ typedef union _X86_REGS {
struct BYTEREGS h;
} X86_REGS, *PX86_REGS;
extern void XGI_XG21Fun14( PXGI_HW_DEVICE_INFO pXGIHWDE, PX86_REGS pBiosArguments);
extern void XGISetDPMS(PXGI_HW_DEVICE_INFO pXGIHWDE,
extern void XGI_XG21Fun14(struct xgi_hw_device_info *pXGIHWDE, PX86_REGS pBiosArguments);
extern void XGISetDPMS(struct xgi_hw_device_info *pXGIHWDE,
unsigned long VESA_POWER_STATE);
extern void XGI_GetSenseStatus( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo );
extern void XGINew_SetModeScratch ( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo ) ;
extern void XGI_GetSenseStatus(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo);
extern void XGINew_SetModeScratch(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo) ;
extern void ReadVBIOSTablData(unsigned char ChipType,
PVB_DEVICE_INFO pVBInfo);
extern unsigned short XGINew_SenseLCD(PXGI_HW_DEVICE_INFO,
extern unsigned short XGINew_SenseLCD(struct xgi_hw_device_info *,
PVB_DEVICE_INFO pVBInfo);
#endif
......@@ -72,38 +72,38 @@ unsigned short XGINew_DDRDRAM_TYPE20[12][5] = {
{ 2, 12, 9, 8, 0x35},
{ 2, 12, 8, 4, 0x31} };
void XGINew_SetDRAMSize_340(PXGI_HW_DEVICE_INFO, PVB_DEVICE_INFO);
void XGINew_SetDRAMSize_310(PXGI_HW_DEVICE_INFO, PVB_DEVICE_INFO);
void XGINew_SetMemoryClock(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
void XGINew_SetDRAMSize_340(struct xgi_hw_device_info *, PVB_DEVICE_INFO);
void XGINew_SetDRAMSize_310(struct xgi_hw_device_info *, PVB_DEVICE_INFO);
void XGINew_SetMemoryClock(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
void XGINew_SetDRAMModeRegister(PVB_DEVICE_INFO );
void XGINew_SetDRAMModeRegister340( PXGI_HW_DEVICE_INFO HwDeviceExtension );
void XGINew_SetDRAMDefaultRegister340(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void XGINew_SetDRAMModeRegister340(struct xgi_hw_device_info *HwDeviceExtension);
void XGINew_SetDRAMDefaultRegister340(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long, PVB_DEVICE_INFO);
unsigned char XGINew_GetXG20DRAMType(PXGI_HW_DEVICE_INFO HwDeviceExtension,
unsigned char XGINew_GetXG20DRAMType(struct xgi_hw_device_info *HwDeviceExtension,
PVB_DEVICE_INFO pVBInfo);
unsigned char XGIInitNew(PXGI_HW_DEVICE_INFO HwDeviceExtension);
unsigned char XGIInitNew(struct xgi_hw_device_info *HwDeviceExtension);
int XGINew_DDRSizing340( PXGI_HW_DEVICE_INFO, PVB_DEVICE_INFO );
void XGINew_DisableRefresh( PXGI_HW_DEVICE_INFO ,PVB_DEVICE_INFO) ;
int XGINew_DDRSizing340(struct xgi_hw_device_info *, PVB_DEVICE_INFO);
void XGINew_DisableRefresh(struct xgi_hw_device_info *, PVB_DEVICE_INFO) ;
void XGINew_CheckBusWidth_310( PVB_DEVICE_INFO) ;
int XGINew_SDRSizing(PVB_DEVICE_INFO);
int XGINew_DDRSizing( PVB_DEVICE_INFO );
void XGINew_EnableRefresh( PXGI_HW_DEVICE_INFO, PVB_DEVICE_INFO);
void XGINew_EnableRefresh(struct xgi_hw_device_info *, PVB_DEVICE_INFO);
int XGINew_RAMType; /*int ModeIDOffset,StandTable,CRT1Table,ScreenOffset,REFIndex;*/
unsigned long UNIROM; /* UNIROM */
unsigned char ChkLFB(PVB_DEVICE_INFO);
void XGINew_Delay15us(unsigned long);
void SetPowerConsume(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void SetPowerConsume(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long XGI_P3d4Port);
void ReadVBIOSTablData(unsigned char ChipType, PVB_DEVICE_INFO pVBInfo);
void XGINew_DDR1x_MRS_XG20(unsigned long P3c4, PVB_DEVICE_INFO pVBInfo);
void XGINew_SetDRAMModeRegister_XG20( PXGI_HW_DEVICE_INFO HwDeviceExtension );
void XGINew_SetDRAMModeRegister_XG27( PXGI_HW_DEVICE_INFO HwDeviceExtension );
void XGINew_ChkSenseStatus ( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo ) ;
void XGINew_SetModeScratch ( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo ) ;
void XGINew_GetXG21Sense(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO pVBInfo) ;
void XGINew_SetDRAMModeRegister_XG20(struct xgi_hw_device_info *HwDeviceExtension);
void XGINew_SetDRAMModeRegister_XG27(struct xgi_hw_device_info *HwDeviceExtension);
void XGINew_ChkSenseStatus(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo) ;
void XGINew_SetModeScratch(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo) ;
void XGINew_GetXG21Sense(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo) ;
unsigned char GetXG21FPBits(PVB_DEVICE_INFO pVBInfo);
void XGINew_GetXG27Sense(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO pVBInfo) ;
void XGINew_GetXG27Sense(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo) ;
unsigned char GetXG27FPBits(PVB_DEVICE_INFO pVBInfo);
void DelayUS(unsigned long MicroSeconds)
......@@ -118,7 +118,7 @@ void DelayUS(unsigned long MicroSeconds)
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
unsigned char XGIInitNew(PXGI_HW_DEVICE_INFO HwDeviceExtension)
unsigned char XGIInitNew(struct xgi_hw_device_info *HwDeviceExtension)
{
VB_DEVICE_INFO VBINF;
......@@ -546,7 +546,7 @@ return 1;
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
unsigned char XGINew_GetXG20DRAMType(PXGI_HW_DEVICE_INFO HwDeviceExtension,
unsigned char XGINew_GetXG20DRAMType(struct xgi_hw_device_info *HwDeviceExtension,
PVB_DEVICE_INFO pVBInfo)
{
unsigned char data, temp;
......@@ -740,7 +740,7 @@ void XGINew_DDR2x_MRS_340(unsigned long P3c4 , PVB_DEVICE_INFO pVBInfo)
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_DDRII_Bootup_XG27(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void XGINew_DDRII_Bootup_XG27(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long P3c4, PVB_DEVICE_INFO pVBInfo)
{
unsigned long P3d4 = P3c4 + 0x10 ;
......@@ -819,7 +819,7 @@ void XGINew_DDRII_Bootup_XG27(PXGI_HW_DEVICE_INFO HwDeviceExtension,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_DDR2_MRS_XG20(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void XGINew_DDR2_MRS_XG20(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long P3c4, PVB_DEVICE_INFO pVBInfo)
{
unsigned long P3d4 = P3c4 + 0x10 ;
......@@ -872,7 +872,7 @@ void XGINew_DDR2_MRS_XG20(PXGI_HW_DEVICE_INFO HwDeviceExtension,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_DDR2_MRS_XG27(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void XGINew_DDR2_MRS_XG27(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long P3c4, PVB_DEVICE_INFO pVBInfo)
{
unsigned long P3d4 = P3c4 + 0x10 ;
......@@ -951,7 +951,7 @@ void XGINew_DDR2_MRS_XG27(PXGI_HW_DEVICE_INFO HwDeviceExtension,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_DDR1x_DefaultRegister(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void XGINew_DDR1x_DefaultRegister(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long Port, PVB_DEVICE_INFO pVBInfo)
{
unsigned long P3d4 = Port ,
......@@ -1012,7 +1012,7 @@ void XGINew_DDR1x_DefaultRegister(PXGI_HW_DEVICE_INFO HwDeviceExtension,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_DDR2x_DefaultRegister(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void XGINew_DDR2x_DefaultRegister(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long Port, PVB_DEVICE_INFO pVBInfo)
{
unsigned long P3d4 = Port ,
......@@ -1064,7 +1064,7 @@ void XGINew_DDR2x_DefaultRegister(PXGI_HW_DEVICE_INFO HwDeviceExtension,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_DDR2_DefaultRegister(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void XGINew_DDR2_DefaultRegister(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long Port, PVB_DEVICE_INFO pVBInfo)
{
unsigned long P3d4 = Port ,
......@@ -1103,7 +1103,7 @@ void XGINew_DDR2_DefaultRegister(PXGI_HW_DEVICE_INFO HwDeviceExtension,
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_SetDRAMDefaultRegister340(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void XGINew_SetDRAMDefaultRegister340(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long Port, PVB_DEVICE_INFO pVBInfo)
{
unsigned char temp, temp1, temp2, temp3 ,
......@@ -1315,7 +1315,7 @@ void XGINew_DDR_MRS(PVB_DEVICE_INFO pVBInfo)
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_VerifyMclk( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo)
void XGINew_VerifyMclk(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned char *pVideoMemory = pVBInfo->FBAddr ;
unsigned char i, j ;
......@@ -1361,7 +1361,7 @@ void XGINew_VerifyMclk( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_SetDRAMSize_340( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo)
void XGINew_SetDRAMSize_340(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short data ;
......@@ -1390,7 +1390,7 @@ void XGINew_SetDRAMSize_340( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_SetDRAMSize_310( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo)
void XGINew_SetDRAMSize_310(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short data ;
pVBInfo->ROMAddr = HwDeviceExtension->pjVirtualRomBase ,
......@@ -1454,7 +1454,7 @@ void XGINew_SetDRAMSize_310( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_SetDRAMModeRegister340( PXGI_HW_DEVICE_INFO HwDeviceExtension )
void XGINew_SetDRAMModeRegister340(struct xgi_hw_device_info *HwDeviceExtension)
{
unsigned char data ;
VB_DEVICE_INFO VBINF;
......@@ -1528,7 +1528,7 @@ void XGINew_SetDRAMModeRegister( PVB_DEVICE_INFO pVBInfo)
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_DisableRefresh( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo)
void XGINew_DisableRefresh(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short data ;
......@@ -1546,7 +1546,7 @@ void XGINew_DisableRefresh( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_I
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_EnableRefresh( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo)
void XGINew_EnableRefresh(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
XGINew_SetReg1( pVBInfo->P3c4 , 0x1B , pVBInfo->SR15[ 3 ][ XGINew_RAMType ] ) ; /* SR1B */
......@@ -2228,7 +2228,7 @@ unsigned char XGINew_CheckFrequence(PVB_DEVICE_INFO pVBInfo)
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_CheckChannel( PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
void XGINew_CheckChannel(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned char data;
......@@ -2509,7 +2509,7 @@ void XGINew_CheckChannel( PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
int XGINew_DDRSizing340( PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
int XGINew_DDRSizing340(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
int i ;
unsigned short memsize , addr ;
......@@ -2595,7 +2595,7 @@ int XGINew_DDRSizing(PVB_DEVICE_INFO pVBInfo)
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_SetMemoryClock( PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
void XGINew_SetMemoryClock(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
......@@ -2644,7 +2644,7 @@ unsigned char ChkLFB(PVB_DEVICE_INFO pVBInfo)
/* in second chip, assume CR A1 D[6]="1" in this case */
/* output : none */
/* --------------------------------------------------------------------- */
void SetPowerConsume(PXGI_HW_DEVICE_INFO HwDeviceExtension,
void SetPowerConsume(struct xgi_hw_device_info *HwDeviceExtension,
unsigned long XGI_P3d4Port)
{
unsigned long lTemp ;
......@@ -2673,7 +2673,7 @@ void SetPowerConsume(PXGI_HW_DEVICE_INFO HwDeviceExtension,
}
void XGINew_InitVBIOSData(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
void XGINew_InitVBIOSData(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
/* unsigned long ROMAddr = (unsigned long)HwDeviceExtension->pjVirtualRomBase; */
......@@ -2828,7 +2828,7 @@ void XGINew_DDR1x_MRS_XG20(unsigned long P3c4, PVB_DEVICE_INFO pVBInfo)
/* Output : */
/* Description : */
/* --------------------------------------------------------------------- */
void XGINew_SetDRAMModeRegister_XG20( PXGI_HW_DEVICE_INFO HwDeviceExtension )
void XGINew_SetDRAMModeRegister_XG20(struct xgi_hw_device_info *HwDeviceExtension)
{
VB_DEVICE_INFO VBINF;
PVB_DEVICE_INFO pVBInfo = &VBINF;
......@@ -2867,7 +2867,7 @@ void XGINew_SetDRAMModeRegister_XG20( PXGI_HW_DEVICE_INFO HwDeviceExtension )
XGINew_SetReg1( pVBInfo->P3c4 , 0x1B , 0x03 ) ;
}
void XGINew_SetDRAMModeRegister_XG27( PXGI_HW_DEVICE_INFO HwDeviceExtension )
void XGINew_SetDRAMModeRegister_XG27(struct xgi_hw_device_info *HwDeviceExtension)
{
VB_DEVICE_INFO VBINF;
PVB_DEVICE_INFO pVBInfo = &VBINF;
......@@ -2909,7 +2909,7 @@ void XGINew_SetDRAMModeRegister_XG27( PXGI_HW_DEVICE_INFO HwDeviceExtension )
}
/*
void XGINew_SetDRAMModeRegister_XG27( PXGI_HW_DEVICE_INFO HwDeviceExtension )
void XGINew_SetDRAMModeRegister_XG27(struct xgi_hw_device_info *HwDeviceExtension)
{
unsigned char data ;
......@@ -2956,7 +2956,7 @@ void XGINew_SetDRAMModeRegister_XG27( PXGI_HW_DEVICE_INFO HwDeviceExtension )
/* Output : */
/* Description : */
/* -------------------------------------------------------- */
void XGINew_ChkSenseStatus ( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo)
void XGINew_ChkSenseStatus(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short tempbx = 0, temp, tempcx, CR3CData;
......@@ -3017,7 +3017,7 @@ void XGINew_ChkSenseStatus ( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_
/* Output : */
/* Description : */
/* -------------------------------------------------------- */
void XGINew_SetModeScratch ( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_INFO pVBInfo )
void XGINew_SetModeScratch(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned short temp , tempcl = 0 , tempch = 0 , CR31Data , CR38Data;
......@@ -3114,7 +3114,7 @@ void XGINew_SetModeScratch ( PXGI_HW_DEVICE_INFO HwDeviceExtension , PVB_DEVICE_
/* Output : */
/* Description : */
/* -------------------------------------------------------- */
void XGINew_GetXG21Sense(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
void XGINew_GetXG21Sense(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned char Temp;
volatile unsigned char *pVideoMemory = (unsigned char *)pVBInfo->ROMAddr;
......@@ -3156,7 +3156,7 @@ void XGINew_GetXG21Sense(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO
/* Output : */
/* Description : */
/* -------------------------------------------------------- */
void XGINew_GetXG27Sense(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
void XGINew_GetXG27Sense(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO pVBInfo)
{
unsigned char Temp, bCR4A;
......
#ifndef _VBINIT_
#define _VBINIT_
extern unsigned char XGIInitNew( PXGI_HW_DEVICE_INFO HwDeviceExtension ) ;
extern unsigned char XGIInitNew(struct xgi_hw_device_info *HwDeviceExtension) ;
extern XGI21_LVDSCapStruct XGI21_LCDCapList[13];
#endif
......
此差异已折叠。
......@@ -2,31 +2,33 @@
#define _VBSETMODE_
extern void InitTo330Pointer(unsigned char, PVB_DEVICE_INFO);
extern void XGI_UnLockCRT2(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
extern void XGI_LockCRT2(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
extern void XGI_UnLockCRT2(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern void XGI_LockCRT2(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern void XGI_LongWait( PVB_DEVICE_INFO );
extern void XGI_SetCRT2ModeRegs(unsigned short ModeNo,PXGI_HW_DEVICE_INFO, PVB_DEVICE_INFO );
extern void XGI_DisableBridge(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
extern void XGI_EnableBridge(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
extern void XGI_DisplayOff( PXGI_HW_DEVICE_INFO, PVB_DEVICE_INFO );
extern void XGI_DisplayOn( PXGI_HW_DEVICE_INFO, PVB_DEVICE_INFO );
extern void XGI_SetCRT2ModeRegs(unsigned short ModeNo,
struct xgi_hw_device_info *,
PVB_DEVICE_INFO);
extern void XGI_DisableBridge(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern void XGI_EnableBridge(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern void XGI_DisplayOff(struct xgi_hw_device_info *, PVB_DEVICE_INFO);
extern void XGI_DisplayOn(struct xgi_hw_device_info *, PVB_DEVICE_INFO);
extern void XGI_GetVBType(PVB_DEVICE_INFO);
extern void XGI_SenseCRT1(PVB_DEVICE_INFO );
extern void XGI_GetVGAType(PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
extern void XGI_GetVBInfo(unsigned short ModeNo,unsigned short ModeIdIndex,PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
extern void XGI_GetVGAType(struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern void XGI_GetVBInfo(unsigned short ModeNo, unsigned short ModeIdIndex, struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern void XGI_GetTVInfo(unsigned short ModeNo,unsigned short ModeIdIndex, PVB_DEVICE_INFO );
extern void XGI_SetCRT1Offset(unsigned short ModeNo,unsigned short ModeIdIndex,unsigned short RefreshRateTableIndex,PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
extern void XGI_SetLCDAGroup(unsigned short ModeNo,unsigned short ModeIdIndex,PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO );
extern void XGI_SetCRT1Offset(unsigned short ModeNo, unsigned short ModeIdIndex, unsigned short RefreshRateTableIndex, struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern void XGI_SetLCDAGroup(unsigned short ModeNo, unsigned short ModeIdIndex, struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern void XGI_WaitDisply( PVB_DEVICE_INFO );
extern unsigned short XGI_GetResInfo(unsigned short ModeNo,unsigned short ModeIdIndex, PVB_DEVICE_INFO pVBInfo);
extern unsigned char XGISetModeNew( PXGI_HW_DEVICE_INFO HwDeviceExtension , unsigned short ModeNo ) ;
extern unsigned char XGISetModeNew(struct xgi_hw_device_info *HwDeviceExtension, unsigned short ModeNo) ;
extern unsigned char XGI_SearchModeID( unsigned short ModeNo,unsigned short *ModeIdIndex, PVB_DEVICE_INFO );
extern unsigned char XGI_GetLCDInfo(unsigned short ModeNo,unsigned short ModeIdIndex,PVB_DEVICE_INFO );
extern unsigned char XGI_BridgeIsOn( PVB_DEVICE_INFO );
extern unsigned char XGI_SetCRT2Group301(unsigned short ModeNo, PXGI_HW_DEVICE_INFO HwDeviceExtension, PVB_DEVICE_INFO);
extern unsigned short XGI_GetRatePtrCRT2( PXGI_HW_DEVICE_INFO pXGIHWDE, unsigned short ModeNo,unsigned short ModeIdIndex, PVB_DEVICE_INFO );
extern unsigned char XGI_SetCRT2Group301(unsigned short ModeNo, struct xgi_hw_device_info *HwDeviceExtension, PVB_DEVICE_INFO);
extern unsigned short XGI_GetRatePtrCRT2(struct xgi_hw_device_info *pXGIHWDE, unsigned short ModeNo, unsigned short ModeIdIndex, PVB_DEVICE_INFO);
extern void XGI_SetXG21FPBits(PVB_DEVICE_INFO pVBInfo);
extern void XGI_SetXG27FPBits(PVB_DEVICE_INFO pVBInfo);
......
......@@ -58,14 +58,7 @@ struct XGI_DSReg
unsigned char jVal;
};
#ifndef XGI_HW_DEVICE_INFO
typedef struct _XGI_HW_DEVICE_INFO XGI_HW_DEVICE_INFO, *PXGI_HW_DEVICE_INFO;
typedef unsigned char (*PXGI_QUERYSPACE) (PXGI_HW_DEVICE_INFO, unsigned long, unsigned long, unsigned long *);
struct _XGI_HW_DEVICE_INFO
struct xgi_hw_device_info
{
unsigned long ulExternalChip; /* NO VB or other video bridge*/
/* if ujVBChipID = VB_CHIP_UNKNOWN, */
......@@ -124,18 +117,18 @@ struct _XGI_HW_DEVICE_INFO
/* end data :(idx, val) = (FF, FF) */
/* Note : restore cR registers if */
/* bSkipDramSizing = 1 */
/*
#endif
*/
PXGI_QUERYSPACE pQueryVGAConfigSpace;
unsigned char(*pQueryVGAConfigSpace)(struct xgi_hw_device_info *,
unsigned long, unsigned long,
unsigned long *);
PXGI_QUERYSPACE pQueryNorthBridgeSpace;
unsigned char(*pQueryNorthBridgeSpace)(struct xgi_hw_device_info *,
unsigned long, unsigned long,
unsigned long *);
unsigned char szVBIOSVer[VBIOS_VER_MAX_LENGTH];
};
#endif
/* Addtional IOCTL for communication xgifb <> X driver */
/* If changing this, xgifb.h must also be changed (for xgifb) */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册