Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 151487
b: refs/heads/master
c: 3dcdc50
h: refs/heads/master
i:
  151485: cd056b7
  151483: 9837c61
  151479: 63a3b35
  151471: 31dfed8
  151455: b1ba93d
  151423: ede0faa
v: v3
  • Loading branch information
Stefan Richter committed Jun 5, 2009
1 parent 901422f commit a49d363
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 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: e41f8d709c31b42129a34305a99d29c38aff75c4
refs/heads/master: 3dcdc50079bc2c9dbc6524518976353f743f7ec8
7 changes: 4 additions & 3 deletions trunk/drivers/firewire/fw-ohci.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
#include <linux/pci.h>
#include <linux/spinlock.h>

#include <asm/atomic.h>
#include <asm/page.h>
#include <asm/system.h>

Expand Down Expand Up @@ -178,7 +179,7 @@ struct fw_ohci {
int node_id;
int generation;
int request_generation; /* for timestamping incoming requests */
u32 bus_seconds;
atomic_t bus_seconds;

bool use_dualbuffer;
bool old_uninorth;
Expand Down Expand Up @@ -1434,7 +1435,7 @@ static irqreturn_t irq_handler(int irq, void *data)
if (event & OHCI1394_cycle64Seconds) {
cycle_time = reg_read(ohci, OHCI1394_IsochronousCycleTimer);
if ((cycle_time & 0x80000000) == 0)
ohci->bus_seconds++;
atomic_inc(&ohci->bus_seconds);
}

return IRQ_HANDLED;
Expand Down Expand Up @@ -1770,7 +1771,7 @@ static u64 ohci_get_bus_time(struct fw_card *card)
u64 bus_time;

cycle_time = reg_read(ohci, OHCI1394_IsochronousCycleTimer);
bus_time = ((u64) ohci->bus_seconds << 32) | cycle_time;
bus_time = ((u64)atomic_read(&ohci->bus_seconds) << 32) | cycle_time;

return bus_time;
}
Expand Down

0 comments on commit a49d363

Please sign in to comment.