aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ieee1394/csr.h
diff options
context:
space:
mode:
authorStefan Richter <stefanr@s5r6.in-berlin.de>2006-07-03 12:02:28 -0400
committerBen Collins <bcollins@ubuntu.com>2006-07-03 12:02:28 -0400
commite1d118f16dca0f54faba3e8dd5b6adbbf7ac68c8 (patch)
treefffc9d2b1fbe3fe6bb55758e2a6951ad9c581e63 /drivers/ieee1394/csr.h
parent2b01b80b944b3abf623c8acc2b5537a85b5ebd3c (diff)
[PATCH] ieee1394: coding style and comment fixes in midlayer header files
Adjust tabulators, line wraps, empty lines, and comment style. Update comments in ieee1394_transactions.h and highlevel.h. Fix typo in comment in csr.h. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Ben Collins <bcollins@ubuntu.com>
Diffstat (limited to 'drivers/ieee1394/csr.h')
-rw-r--r--drivers/ieee1394/csr.h98
1 files changed, 49 insertions, 49 deletions
diff --git a/drivers/ieee1394/csr.h b/drivers/ieee1394/csr.h
index ea9aa4f53ab6..0655596f25d3 100644
--- a/drivers/ieee1394/csr.h
+++ b/drivers/ieee1394/csr.h
@@ -8,68 +8,68 @@
8 8
9#include "csr1212.h" 9#include "csr1212.h"
10 10
11#define CSR_REGISTER_BASE 0xfffff0000000ULL 11#define CSR_REGISTER_BASE 0xfffff0000000ULL
12 12
13/* register offsets relative to CSR_REGISTER_BASE */ 13/* register offsets relative to CSR_REGISTER_BASE */
14#define CSR_STATE_CLEAR 0x0 14#define CSR_STATE_CLEAR 0x0
15#define CSR_STATE_SET 0x4 15#define CSR_STATE_SET 0x4
16#define CSR_NODE_IDS 0x8 16#define CSR_NODE_IDS 0x8
17#define CSR_RESET_START 0xc 17#define CSR_RESET_START 0xc
18#define CSR_SPLIT_TIMEOUT_HI 0x18 18#define CSR_SPLIT_TIMEOUT_HI 0x18
19#define CSR_SPLIT_TIMEOUT_LO 0x1c 19#define CSR_SPLIT_TIMEOUT_LO 0x1c
20#define CSR_CYCLE_TIME 0x200 20#define CSR_CYCLE_TIME 0x200
21#define CSR_BUS_TIME 0x204 21#define CSR_BUS_TIME 0x204
22#define CSR_BUSY_TIMEOUT 0x210 22#define CSR_BUSY_TIMEOUT 0x210
23#define CSR_BUS_MANAGER_ID 0x21c 23#define CSR_BUS_MANAGER_ID 0x21c
24#define CSR_BANDWIDTH_AVAILABLE 0x220 24#define CSR_BANDWIDTH_AVAILABLE 0x220
25#define CSR_CHANNELS_AVAILABLE 0x224 25#define CSR_CHANNELS_AVAILABLE 0x224
26#define CSR_CHANNELS_AVAILABLE_HI 0x224 26#define CSR_CHANNELS_AVAILABLE_HI 0x224
27#define CSR_CHANNELS_AVAILABLE_LO 0x228 27#define CSR_CHANNELS_AVAILABLE_LO 0x228
28#define CSR_BROADCAST_CHANNEL 0x234 28#define CSR_BROADCAST_CHANNEL 0x234
29#define CSR_CONFIG_ROM 0x400 29#define CSR_CONFIG_ROM 0x400
30#define CSR_CONFIG_ROM_END 0x800 30#define CSR_CONFIG_ROM_END 0x800
31#define CSR_FCP_COMMAND 0xB00 31#define CSR_FCP_COMMAND 0xB00
32#define CSR_FCP_RESPONSE 0xD00 32#define CSR_FCP_RESPONSE 0xD00
33#define CSR_FCP_END 0xF00 33#define CSR_FCP_END 0xF00
34#define CSR_TOPOLOGY_MAP 0x1000 34#define CSR_TOPOLOGY_MAP 0x1000
35#define CSR_TOPOLOGY_MAP_END 0x1400 35#define CSR_TOPOLOGY_MAP_END 0x1400
36#define CSR_SPEED_MAP 0x2000 36#define CSR_SPEED_MAP 0x2000
37#define CSR_SPEED_MAP_END 0x3000 37#define CSR_SPEED_MAP_END 0x3000
38 38
39/* IEEE 1394 bus specific Configuration ROM Key IDs */ 39/* IEEE 1394 bus specific Configuration ROM Key IDs */
40#define IEEE1394_KV_ID_POWER_REQUIREMENTS (0x30) 40#define IEEE1394_KV_ID_POWER_REQUIREMENTS (0x30)
41 41
42/* IEEE 1394 Bus Inforamation Block specifics */ 42/* IEEE 1394 Bus Information Block specifics */
43#define CSR_BUS_INFO_SIZE (5 * sizeof(quadlet_t)) 43#define CSR_BUS_INFO_SIZE (5 * sizeof(quadlet_t))
44 44
45#define CSR_IRMC_SHIFT 31 45#define CSR_IRMC_SHIFT 31
46#define CSR_CMC_SHIFT 30 46#define CSR_CMC_SHIFT 30
47#define CSR_ISC_SHIFT 29 47#define CSR_ISC_SHIFT 29
48#define CSR_BMC_SHIFT 28 48#define CSR_BMC_SHIFT 28
49#define CSR_PMC_SHIFT 27 49#define CSR_PMC_SHIFT 27
50#define CSR_CYC_CLK_ACC_SHIFT 16 50#define CSR_CYC_CLK_ACC_SHIFT 16
51#define CSR_MAX_REC_SHIFT 12 51#define CSR_MAX_REC_SHIFT 12
52#define CSR_MAX_ROM_SHIFT 8 52#define CSR_MAX_ROM_SHIFT 8
53#define CSR_GENERATION_SHIFT 4 53#define CSR_GENERATION_SHIFT 4
54 54
55#define CSR_SET_BUS_INFO_GENERATION(csr, gen) \ 55#define CSR_SET_BUS_INFO_GENERATION(csr, gen) \
56 ((csr)->bus_info_data[2] = \ 56 ((csr)->bus_info_data[2] = \
57 cpu_to_be32((be32_to_cpu((csr)->bus_info_data[2]) & \ 57 cpu_to_be32((be32_to_cpu((csr)->bus_info_data[2]) & \
58 ~(0xf << CSR_GENERATION_SHIFT)) | \ 58 ~(0xf << CSR_GENERATION_SHIFT)) | \
59 (gen) << CSR_GENERATION_SHIFT)) 59 (gen) << CSR_GENERATION_SHIFT))
60 60
61struct csr_control { 61struct csr_control {
62 spinlock_t lock; 62 spinlock_t lock;
63 63
64 quadlet_t state; 64 quadlet_t state;
65 quadlet_t node_ids; 65 quadlet_t node_ids;
66 quadlet_t split_timeout_hi, split_timeout_lo; 66 quadlet_t split_timeout_hi, split_timeout_lo;
67 unsigned long expire; // Calculated from split_timeout 67 unsigned long expire; /* Calculated from split_timeout */
68 quadlet_t cycle_time; 68 quadlet_t cycle_time;
69 quadlet_t bus_time; 69 quadlet_t bus_time;
70 quadlet_t bus_manager_id; 70 quadlet_t bus_manager_id;
71 quadlet_t bandwidth_available; 71 quadlet_t bandwidth_available;
72 quadlet_t channels_available_hi, channels_available_lo; 72 quadlet_t channels_available_hi, channels_available_lo;
73 quadlet_t broadcast_channel; 73 quadlet_t broadcast_channel;
74 74
75 /* Bus Info */ 75 /* Bus Info */
@@ -84,8 +84,8 @@ struct csr_control {
84 84
85 struct csr1212_csr *rom; 85 struct csr1212_csr *rom;
86 86
87 quadlet_t topology_map[256]; 87 quadlet_t topology_map[256];
88 quadlet_t speed_map[1024]; 88 quadlet_t speed_map[1024];
89}; 89};
90 90
91extern struct csr1212_bus_ops csr_bus_ops; 91extern struct csr1212_bus_ops csr_bus_ops;