⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 libfbx-ati-misc.c

📁 libfxb是linux下只写操作framebuffer的一个轻量级的库。
💻 C
字号:
/* *  libfbx-ati-misc.c -- Miscellaneous routines for ati optimizations *  (C)opyright 2001 U4X Labs * *  Written by: Paul Mundt <lethal@u4xlabs.com> * *  $Id: libfbx-ati-misc.c,v 1.3 2001/03/03 01:34:43 lethal Exp $ * *  	This is the place for all the ati hardware specific *  optimizations for the libfbx system go. * *  See ChangeLog for modifications, CREDITS for credits. * *  All source herein is copyright U4X Labs and its original author.  *  Any code modifications or additions are (C)opyright the original  *  author and U4X Labs respectively. * *  libfbx is free software; you can redistribute it and/or modify it  *  under the terms of the GNU Lesser General Public License as  *  published by the Free Software Foundation; either version 2.1 of  *  the License, or (at your option) any later version. * *  libfbx is distributed in the hope that it will be useful, but  *  WITHOUT ANY WARRANTY; without even the implied warranty of *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the  *  GNU Lesser General Public License for more details. * *  You should have received a copy of the GNU Lesser General Public *  License along with libfbx; if not, write to the Free Software  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 *  USA */#include <libfbx/libfbx-drivers.h>#include <libfbx/drivers/libfbx-ati.h>#define aty_handle_idx(x) if (x >= 0x400) x -= 0x800inline __u8 aty_ld_8(__u32 idx){	aty_handle_idx(idx);	return fb_inb(idx);}inline void aty_st_8(__u32 idx, __u8 val){	aty_handle_idx(idx);	fb_outb(idx, val);}inline __u32 aty_ld_le32(__u32 idx){	aty_handle_idx(idx);	return fb_inl(idx);}inline void aty_st_le32(__u32 idx, __u32 val){	aty_handle_idx(idx);	fb_outl(idx, val);}inline void aty_wait_fifo(__u16 entries){	do {	} while ((aty_ld_le32(FIFO_STAT) & 0xffff) > ((__u32)(0x8000 >> entries)));}inline void aty_wait_idle(){	aty_wait_fifo(16);	do {	} while ((aty_ld_le32(GUI_STAT) & 1) != 0);}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -