Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
6fc3e934
Commit
6fc3e934
authored
Apr 02, 2004
by
Richard Henderson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[ALPHA] Add pci_dma_mapping_error.
parent
1cc43455
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
20 deletions
+32
-20
include/asm-alpha/pci.h
include/asm-alpha/pci.h
+32
-20
No files found.
include/asm-alpha/pci.h
View file @
6fc3e934
...
...
@@ -85,10 +85,10 @@ extern void *pci_alloc_consistent(struct pci_dev *, size_t, dma_addr_t *);
extern
void
pci_free_consistent
(
struct
pci_dev
*
,
size_t
,
void
*
,
dma_addr_t
);
/* Map a single buffer of the indicate size for PCI DMA in streaming
mode. The 32-bit PCI bus mastering address to use is returned.
Once the device is given the dma address, the device owns this memory
until either
pci_unmap_single or pci_dma_sync_single_for_cpu is performed. */
/* Map a single buffer of the indicate size for PCI DMA in streaming
mode.
The 32-bit PCI bus mastering address to use is returned. Once the device
is given the dma address, the device owns this memory until either
pci_unmap_single or pci_dma_sync_single_for_cpu is performed. */
extern
dma_addr_t
pci_map_single
(
struct
pci_dev
*
,
void
*
,
size_t
,
int
);
...
...
@@ -96,6 +96,14 @@ extern dma_addr_t pci_map_single(struct pci_dev *, void *, size_t, int);
extern
dma_addr_t
pci_map_page
(
struct
pci_dev
*
,
struct
page
*
,
unsigned
long
,
size_t
,
int
);
/* Test for pci_map_single or pci_map_page having generated an error. */
static
inline
int
pci_dma_mapping_error
(
dma_addr_t
dma_addr
)
{
return
dma_addr
==
0
;
}
/* Unmap a single streaming mode DMA translation. The DMA_ADDR and
SIZE must match what was provided for in a previous pci_map_single
call. All other usages are undefined. After this call, reads by
...
...
@@ -153,15 +161,15 @@ extern void pci_unmap_sg(struct pci_dev *, struct scatterlist *, int, int);
the buffer. */
static
inline
void
pci_dma_sync_single_for_cpu
(
struct
pci_dev
*
dev
,
dma_addr_t
dma_addr
,
long
size
,
int
direction
)
pci_dma_sync_single_for_cpu
(
struct
pci_dev
*
dev
,
dma_addr_t
dma_addr
,
long
size
,
int
direction
)
{
/* Nothing to do. */
}
static
inline
void
pci_dma_sync_single_for_device
(
struct
pci_dev
*
dev
,
dma_addr_t
dma_addr
,
long
size
,
int
direction
)
pci_dma_sync_single_for_device
(
struct
pci_dev
*
dev
,
dma_addr_t
dma_addr
,
long
size
,
int
direction
)
{
/* Nothing to do. */
}
...
...
@@ -171,15 +179,15 @@ pci_dma_sync_single_for_device(struct pci_dev *dev, dma_addr_t dma_addr, long si
but for a scatter-gather list, same rules and usage. */
static
inline
void
pci_dma_sync_sg_for_cpu
(
struct
pci_dev
*
dev
,
struct
scatterlist
*
sg
,
int
nents
,
int
direction
)
pci_dma_sync_sg_for_cpu
(
struct
pci_dev
*
dev
,
struct
scatterlist
*
sg
,
int
nents
,
int
direction
)
{
/* Nothing to do. */
}
static
inline
void
pci_dma_sync_sg_for_device
(
struct
pci_dev
*
dev
,
struct
scatterlist
*
sg
,
int
nents
,
int
direction
)
pci_dma_sync_sg_for_device
(
struct
pci_dev
*
dev
,
struct
scatterlist
*
sg
,
int
nents
,
int
direction
)
{
/* Nothing to do. */
}
...
...
@@ -196,29 +204,32 @@ extern int pci_dma_supported(struct pci_dev *hwdev, u64 mask);
extern
int
pci_dac_dma_supported
(
struct
pci_dev
*
hwdev
,
u64
mask
);
/* Convert to/from DAC dma address and struct page. */
extern
dma64_addr_t
pci_dac_page_to_dma
(
struct
pci_dev
*
,
struct
page
*
,
unsigned
long
,
int
);
extern
dma64_addr_t
pci_dac_page_to_dma
(
struct
pci_dev
*
,
struct
page
*
,
unsigned
long
,
int
);
extern
struct
page
*
pci_dac_dma_to_page
(
struct
pci_dev
*
,
dma64_addr_t
);
extern
unsigned
long
pci_dac_dma_to_offset
(
struct
pci_dev
*
,
dma64_addr_t
);
static
inline
void
pci_dac_dma_sync_single_for_cpu
(
struct
pci_dev
*
pdev
,
dma64_addr_t
dma_addr
,
size_t
len
,
int
direction
)
pci_dac_dma_sync_single_for_cpu
(
struct
pci_dev
*
pdev
,
dma64_addr_t
dma_addr
,
size_t
len
,
int
direction
)
{
/* Nothing to do. */
}
static
inline
void
pci_dac_dma_sync_single_for_device
(
struct
pci_dev
*
pdev
,
dma64_addr_t
dma_addr
,
size_t
len
,
int
direction
)
pci_dac_dma_sync_single_for_device
(
struct
pci_dev
*
pdev
,
dma64_addr_t
dma_addr
,
size_t
len
,
int
direction
)
{
/* Nothing to do. */
}
extern
void
pcibios_resource_to_bus
(
struct
pci_dev
*
dev
,
struct
pci_bus_region
*
region
,
struct
resource
*
res
);
extern
void
pcibios_resource_to_bus
(
struct
pci_dev
*
,
struct
pci_bus_region
*
,
struct
resource
*
);
#define pci_domain_nr(bus) ((struct pci_controller *)(bus)->sysdata)->index
static
inline
int
pci_name_bus
(
char
*
name
,
struct
pci_bus
*
bus
)
static
inline
int
pci_name_bus
(
char
*
name
,
struct
pci_bus
*
bus
)
{
struct
pci_controller
*
hose
=
bus
->
sysdata
;
...
...
@@ -230,7 +241,8 @@ static inline int pci_name_bus(char *name, struct pci_bus *bus)
return
0
;
}
static
inline
void
pcibios_add_platform_entries
(
struct
pci_dev
*
dev
)
static
inline
void
pcibios_add_platform_entries
(
struct
pci_dev
*
dev
)
{
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment