Skip to content

Commit 479623f

Browse files
Desnes NunesChristoph Hellwig
authored andcommitted
dma-debug: small dma_debug_entry's comment and variable name updates
Small update on dma_debug_entry's struct commentary and also standardize the usage of 'dma_addr' variable name from debug_dma_map_page() on debug_dma_unmap_page(), and similarly on debug_dma_free_coherent() Signed-off-by: Desnes Nunes <desnesn@redhat.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
1 parent 25a4ce5 commit 479623f

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

kernel/dma/debug.c

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ enum map_err_types {
5353
* struct dma_debug_entry - track a dma_map* or dma_alloc_coherent mapping
5454
* @list: node on pre-allocated free_entries list
5555
* @dev: 'dev' argument to dma_map_{page|single|sg} or dma_alloc_coherent
56+
* @dev_addr: dma address
5657
* @size: length of the mapping
5758
* @type: single, page, sg, coherent
5859
* @direction: enum dma_data_direction
@@ -1262,13 +1263,13 @@ void debug_dma_mapping_error(struct device *dev, dma_addr_t dma_addr)
12621263
}
12631264
EXPORT_SYMBOL(debug_dma_mapping_error);
12641265

1265-
void debug_dma_unmap_page(struct device *dev, dma_addr_t addr,
1266+
void debug_dma_unmap_page(struct device *dev, dma_addr_t dma_addr,
12661267
size_t size, int direction)
12671268
{
12681269
struct dma_debug_entry ref = {
12691270
.type = dma_debug_single,
12701271
.dev = dev,
1271-
.dev_addr = addr,
1272+
.dev_addr = dma_addr,
12721273
.size = size,
12731274
.direction = direction,
12741275
};
@@ -1403,13 +1404,13 @@ void debug_dma_alloc_coherent(struct device *dev, size_t size,
14031404
}
14041405

14051406
void debug_dma_free_coherent(struct device *dev, size_t size,
1406-
void *virt, dma_addr_t addr)
1407+
void *virt, dma_addr_t dma_addr)
14071408
{
14081409
struct dma_debug_entry ref = {
14091410
.type = dma_debug_coherent,
14101411
.dev = dev,
14111412
.offset = offset_in_page(virt),
1412-
.dev_addr = addr,
1413+
.dev_addr = dma_addr,
14131414
.size = size,
14141415
.direction = DMA_BIDIRECTIONAL,
14151416
};

0 commit comments

Comments
 (0)