summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEgbert Eich <eich@suse.de>2014-04-22 13:47:39 +0200
committerEgbert Eich <eich@freedesktop.org>2014-04-30 17:25:35 +0200
commit28f815fe8b56138f32a98e3712b61e930b5e892e (patch)
tree849fa8b3bdb7d1fd47e74bcbab3c300f8441d414 /src
parentf6a2ba02b2ac8c8a8b66902dd3ac5324971a43fe (diff)
Clean up namespace in ast_cursor.c
- Make sure exported functions have 'AST' in their name. This avoids name space conflicts with the server or other drivers. - Place declaration of exported functions in a header file. This ensures that changes to the function type or arguments are followed thru everywhere. Signed-off-by: Egbert Eich <eich@suse.de> Acked-by: Y.C. Chen <yc_chen@aspeedtech.com>
Diffstat (limited to 'src')
-rw-r--r--src/ast.h7
-rw-r--r--src/ast_cursor.c5
-rw-r--r--src/ast_driver.c3
-rw-r--r--src/ast_mode.c5
4 files changed, 9 insertions, 11 deletions
diff --git a/src/ast.h b/src/ast.h
index 20df2e1..707149e 100644
--- a/src/ast.h
+++ b/src/ast.h
@@ -335,6 +335,13 @@ UCHAR *pASTjRequestCMDQ(ASTRecPtr pAST, ULONG ulDataLen);
Bool bASTEnable2D(ScrnInfoPtr pScrn, ASTRecPtr pAST);
void vASTDisable2D(ScrnInfoPtr pScrn, ASTRecPtr pAST);
+/* ast_cursor.c */
+#ifdef HWC
+Bool ASTCursorInit(ScreenPtr pScreen);
+Bool bASTInitHWC(ScrnInfoPtr pScrn, ASTRecPtr pAST);
+void ASTDisableHWC(ScrnInfoPtr pScrn);
+#endif
+
/* Include Files */
#include "ast_mode.h"
#include "ast_vgatool.h"
diff --git a/src/ast_cursor.c b/src/ast_cursor.c
index 7bfa15f..4598daa 100644
--- a/src/ast_cursor.c
+++ b/src/ast_cursor.c
@@ -53,9 +53,6 @@
#ifdef HWC
/* Prototype type declaration */
-Bool ASTCursorInit(ScreenPtr pScreen);
-Bool bInitHWC(ScrnInfoPtr pScrn, ASTRecPtr pAST);
-void ASTDisableHWC(ScrnInfoPtr pScrn);
static void ASTShowCursor(ScrnInfoPtr pScrn);
static void ASTHideCursor(ScrnInfoPtr pScrn);
static void ASTSetCursorPosition(ScrnInfoPtr pScrn, int x, int y);
@@ -111,7 +108,7 @@ ASTCursorInit(ScreenPtr pScreen)
}
-Bool bInitHWC(ScrnInfoPtr pScrn, ASTRecPtr pAST)
+Bool bASTInitHWC(ScrnInfoPtr pScrn, ASTRecPtr pAST)
{
ScreenPtr pScreen;
diff --git a/src/ast_driver.c b/src/ast_driver.c
index 5b02c9e..4fc8b28 100644
--- a/src/ast_driver.c
+++ b/src/ast_driver.c
@@ -69,9 +69,6 @@ extern Bool ASTSetMode(ScrnInfoPtr pScrn, DisplayModePtr mode);
extern Bool ASTAccelInit(ScreenPtr pScreen);
#endif
-extern Bool ASTCursorInit(ScreenPtr pScreen);
-extern void ASTDisableHWC(ScrnInfoPtr pScrn);
-
/* Mandatory functions */
static void ASTIdentify(int flags);
const OptionInfoRec *ASTAvailableOptions(int chipid, int busid);
diff --git a/src/ast_mode.c b/src/ast_mode.c
index 3d06700..9e41bd4 100644
--- a/src/ast_mode.c
+++ b/src/ast_mode.c
@@ -406,9 +406,6 @@ VBIOS_DAC_INFO DAC_VGA[] = {
{ 0x00, 0x00, 0x00 }, { 0x00, 0x00, 0x00 }, { 0x00, 0x00, 0x00 }, { 0x00, 0x00, 0x00 },
};
-/* extern. function */
-extern Bool bInitHWC(ScrnInfoPtr pScrn, ASTRecPtr pAST);
-
/* Prototype type declaration*/
Bool ASTSetMode(ScrnInfoPtr pScrn, DisplayModePtr mode);
Bool bGetAST1000VGAModeInfo(ScrnInfoPtr pScrn, DisplayModePtr mode, PVBIOS_MODE_INFO pVGAModeInfo);
@@ -477,7 +474,7 @@ ASTSetMode(ScrnInfoPtr pScrn, DisplayModePtr mode)
#endif
#ifdef HWC
if (!pAST->noHWC) {
- if (!bInitHWC(pScrn, pAST)) {
+ if (!bASTInitHWC(pScrn, pAST)) {
xf86DrvMsg(pScrn->scrnIndex, X_ERROR,"Init HWC failed\n");
pAST->noHWC = TRUE;
}