Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 67425
b: refs/heads/master
c: 0b94a1e
h: refs/heads/master
i:
  67423: 1a706ee
v: v3
  • Loading branch information
Michael Ellerman authored and Paul Mackerras committed Oct 3, 2007
1 parent b32907e commit a261d86
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ca786f83a97d7897b013b1e9b290c9010b69af9b
refs/heads/master: 0b94a1eeeeb3542d046b928ca01fcd4bf0ea7587
2 changes: 1 addition & 1 deletion trunk/arch/powerpc/sysdev/dcr.c
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ u64 of_translate_dcr_address(struct device_node *dev,
dcr_host_t dcr_map(struct device_node *dev, unsigned int dcr_n,
unsigned int dcr_c)
{
dcr_host_t ret = { .token = NULL, .stride = 0 };
dcr_host_t ret = { .token = NULL, .stride = 0, .base = dcr_n };
u64 addr;

pr_debug("dcr_map(%s, 0x%x, 0x%x)\n",
Expand Down
6 changes: 5 additions & 1 deletion trunk/include/asm-powerpc/dcr-mmio.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,11 @@

#include <asm/io.h>

typedef struct { void __iomem *token; unsigned int stride; } dcr_host_t;
typedef struct {
void __iomem *token;
unsigned int stride;
unsigned int base;
} dcr_host_t;

#define DCR_MAP_OK(host) ((host).token != NULL)

Expand Down
6 changes: 4 additions & 2 deletions trunk/include/asm-powerpc/dcr-native.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,13 @@
#ifdef __KERNEL__
#ifndef __ASSEMBLY__

typedef struct {} dcr_host_t;
typedef struct {
unsigned int base;
} dcr_host_t;

#define DCR_MAP_OK(host) (1)

#define dcr_map(dev, dcr_n, dcr_c) ((dcr_host_t){})
#define dcr_map(dev, dcr_n, dcr_c) ((dcr_host_t){ .base = (dcr_n) })
#define dcr_unmap(host, dcr_n, dcr_c) do {} while (0)
#define dcr_read(host, dcr_n) mfdcr(dcr_n)
#define dcr_write(host, dcr_n, value) mtdcr(dcr_n, value)
Expand Down

0 comments on commit a261d86

Please sign in to comment.