diff options
Diffstat (limited to 'drivers/firewire/fw-card.c')
-rw-r--r-- | drivers/firewire/fw-card.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/firewire/fw-card.c b/drivers/firewire/fw-card.c index f785b1005284..3f8661a52acc 100644 --- a/drivers/firewire/fw-card.c +++ b/drivers/firewire/fw-card.c | |||
@@ -367,9 +367,9 @@ void | |||
367 | fw_card_initialize(struct fw_card *card, const struct fw_card_driver *driver, | 367 | fw_card_initialize(struct fw_card *card, const struct fw_card_driver *driver, |
368 | struct device *device) | 368 | struct device *device) |
369 | { | 369 | { |
370 | static int index; | 370 | static atomic_t index = ATOMIC_INIT(-1); |
371 | 371 | ||
372 | card->index = index++; | 372 | card->index = atomic_inc_return(&index); |
373 | card->driver = driver; | 373 | card->driver = driver; |
374 | card->device = device; | 374 | card->device = device; |
375 | card->current_tlabel = 0; | 375 | card->current_tlabel = 0; |