Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
osv
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Verlässliche Systemsoftware
projects
osv
Commits
c0caeeb2
Commit
c0caeeb2
authored
12 years ago
by
Dor Laor
Browse files
Options
Downloads
Patches
Plain Diff
Add PCI header file with in/out functions
parent
c4f4c689
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
arch/x64/pci.hh
+43
-0
43 additions, 0 deletions
arch/x64/pci.hh
with
43 additions
and
0 deletions
arch/x64/pci.hh
0 → 100644
+
43
−
0
View file @
c0caeeb2
#ifndef ARCH_X86_PCI_H
#define ARCH_X86_PCI_H
#include
<stdint.h>
#include
"arch/x64/processor.hh"
namespace
pci
{
typedef
unsigned
long
ulong
;
typedef
uint8_t
u8
;
typedef
uint16_t
u16
;
typedef
uint32_t
u32
;
typedef
uint64_t
u64
;
inline
u8
inb
(
u16
port
)
{
return
processor
::
x86
::
inb
(
port
);
}
inline
u16
inw
(
u16
port
)
{
return
processor
::
x86
::
inw
(
port
);
}
inline
u32
inl
(
u16
port
)
{
return
processor
::
x86
::
inl
(
port
);
}
inline
void
outb
(
u8
val
,
u16
port
)
{
processor
::
x86
::
outb
(
val
,
port
);
}
inline
void
outw
(
u16
val
,
u16
port
)
{
processor
::
x86
::
outw
(
val
,
port
);
}
inline
void
outl
(
u32
val
,
u16
port
)
{
processor
::
x86
::
outl
(
val
,
port
);
}
};
#endif
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment