🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: cn.bbs.comp.program
1 messages
1 total messages Started by gege Thu, 01 Jan 1998 00:00
Re: �����c code �л��PNP���ϵ��ڴ���ր
#2283
Author: gege
Date: Thu, 01 Jan 1998 00:00
38 lines
1709 bytes
��лָ�㣡�������ԡ�
��˵��
 ��� 1. PCI specification
          2.  NTDDK  document
��֪���δ�Ѱ�ң�
�����ij�档

�� �� jazzman.bbs@bbs.sjtu.edu.cn (��ʿ��) �Ĵ������ᵽ: ��
: �����PCI����һЩԴ����
: ��������PCI���ģ��ҵ�֮�󣬴�
: configuration space ���
: base address M/IO
: ��� 1. PCI specification
:          2.  NTDDK  document
: #define       PCI_ADDRESS             0x0cf8
: #define       PCI_DATA                0x0cfc
: int   PCI_BUS_PRESENT(void)
: {
:       static  done=FALSE;
:       ULONG   i;
:       USHORT  j;
:       if (done) return TRUE;
:       // try Mechanism first
:       for (i=0x80000000;i<0x80010000;i+=0x00000800)
:       {
:               outpd(PCI_ADDRESS,i);
:               if (inpw(PCI_DATA)==0xffff)     continue;
:               outpd(PCI_ADDRESS,i+0x08);
:               if (inpw(PCI_DATA+2)!=0x0600)   continue;               // not Host Bridge
:               done=TRUE;
:               return  TRUE;
:       }

v

--
�� ��Դ:���ɰ��ļ�BBSվ bbs.njtu.edu.cn��[IP: 202.112.147.245]
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads