Skip to content

Commit

Permalink
[PATCH] saa7134: mark little endian ptr
Browse files Browse the repository at this point in the history
> -			*ptr = sg_dma_address(list) - list->offset;
> +			*ptr = cpu_to_le32(sg_dma_address(list) - list->offset);

Clearly mark pointers to little-endian things.

Signed-off-by: Alexey Dobriyan <[email protected]>
Acked-by: Gerd Knorr <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Alexey Dobriyan authored and Linus Torvalds committed Jun 24, 2005
1 parent a20758f commit c9c12b7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions drivers/media/video/saa7134/saa7134-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ unsigned long saa7134_buffer_base(struct saa7134_buf *buf)

int saa7134_pgtable_alloc(struct pci_dev *pci, struct saa7134_pgtable *pt)
{
u32 *cpu;
__le32 *cpu;
dma_addr_t dma_addr;

cpu = pci_alloc_consistent(pci, SAA7134_PGTABLE_SIZE, &dma_addr);
Expand All @@ -332,7 +332,7 @@ int saa7134_pgtable_build(struct pci_dev *pci, struct saa7134_pgtable *pt,
struct scatterlist *list, unsigned int length,
unsigned int startpage)
{
u32 *ptr;
__le32 *ptr;
unsigned int i,p;

BUG_ON(NULL == pt || NULL == pt->cpu);
Expand Down
2 changes: 1 addition & 1 deletion drivers/media/video/saa7134/saa7134.h
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ struct saa7134_dma;
/* saa7134 page table */
struct saa7134_pgtable {
unsigned int size;
u32 *cpu;
__le32 *cpu;
dma_addr_t dma;
};

Expand Down

0 comments on commit c9c12b7

Please sign in to comment.