aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/firewire/fw-card.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/firewire/fw-card.c')
-rw-r--r--drivers/firewire/fw-card.c42
1 files changed, 21 insertions, 21 deletions
diff --git a/drivers/firewire/fw-card.c b/drivers/firewire/fw-card.c
index 74aab9aafd21..b8404ee5314c 100644
--- a/drivers/firewire/fw-card.c
+++ b/drivers/firewire/fw-card.c
@@ -44,20 +44,20 @@ static LIST_HEAD(card_list);
44static LIST_HEAD(descriptor_list); 44static LIST_HEAD(descriptor_list);
45static int descriptor_count; 45static int descriptor_count;
46 46
47#define bib_crc(v) ((v) << 0) 47#define BIB_CRC(v) ((v) << 0)
48#define bib_crc_length(v) ((v) << 16) 48#define BIB_CRC_LENGTH(v) ((v) << 16)
49#define bib_info_length(v) ((v) << 24) 49#define BIB_INFO_LENGTH(v) ((v) << 24)
50 50
51#define bib_link_speed(v) ((v) << 0) 51#define BIB_LINK_SPEED(v) ((v) << 0)
52#define bib_generation(v) ((v) << 4) 52#define BIB_GENERATION(v) ((v) << 4)
53#define bib_max_rom(v) ((v) << 8) 53#define BIB_MAX_ROM(v) ((v) << 8)
54#define bib_max_receive(v) ((v) << 12) 54#define BIB_MAX_RECEIVE(v) ((v) << 12)
55#define bib_cyc_clk_acc(v) ((v) << 16) 55#define BIB_CYC_CLK_ACC(v) ((v) << 16)
56#define bib_pmc ((1) << 27) 56#define BIB_PMC ((1) << 27)
57#define bib_bmc ((1) << 28) 57#define BIB_BMC ((1) << 28)
58#define bib_isc ((1) << 29) 58#define BIB_ISC ((1) << 29)
59#define bib_cmc ((1) << 30) 59#define BIB_CMC ((1) << 30)
60#define bib_imc ((1) << 31) 60#define BIB_IMC ((1) << 31)
61 61
62static u32 * 62static u32 *
63generate_config_rom(struct fw_card *card, size_t *config_rom_length) 63generate_config_rom(struct fw_card *card, size_t *config_rom_length)
@@ -76,15 +76,15 @@ generate_config_rom(struct fw_card *card, size_t *config_rom_length)
76 */ 76 */
77 77
78 memset(config_rom, 0, sizeof config_rom); 78 memset(config_rom, 0, sizeof config_rom);
79 config_rom[0] = bib_crc_length(4) | bib_info_length(4) | bib_crc(0); 79 config_rom[0] = BIB_CRC_LENGTH(4) | BIB_INFO_LENGTH(4) | BIB_CRC(0);
80 config_rom[1] = 0x31333934; 80 config_rom[1] = 0x31333934;
81 81
82 config_rom[2] = 82 config_rom[2] =
83 bib_link_speed(card->link_speed) | 83 BIB_LINK_SPEED(card->link_speed) |
84 bib_generation(card->config_rom_generation++ % 14 + 2) | 84 BIB_GENERATION(card->config_rom_generation++ % 14 + 2) |
85 bib_max_rom(2) | 85 BIB_MAX_ROM(2) |
86 bib_max_receive(card->max_receive) | 86 BIB_MAX_RECEIVE(card->max_receive) |
87 bib_bmc | bib_isc | bib_cmc | bib_imc; 87 BIB_BMC | BIB_ISC | BIB_CMC | BIB_IMC;
88 config_rom[3] = card->guid >> 32; 88 config_rom[3] = card->guid >> 32;
89 config_rom[4] = card->guid; 89 config_rom[4] = card->guid;
90 90
@@ -318,7 +318,7 @@ fw_card_bm_work(struct work_struct *work)
318 */ 318 */
319 spin_unlock_irqrestore(&card->lock, flags); 319 spin_unlock_irqrestore(&card->lock, flags);
320 return; 320 return;
321 } else if (root->config_rom[2] & bib_cmc) { 321 } else if (root->config_rom[2] & BIB_CMC) {
322 /* 322 /*
323 * FIXME: I suppose we should set the cmstr bit in the 323 * FIXME: I suppose we should set the cmstr bit in the
324 * STATE_CLEAR register of this node, as described in 324 * STATE_CLEAR register of this node, as described in