Commit 2608203d authored by Clemens Ladisch's avatar Clemens Ladisch Committed by Stefan Richter

firewire: ohci: prevent aliasing of locally handled register addresses

We must compute the offset from the CSR register base with the
full 48 address bits to prevent matching with addresses whose
lower 32 bits happen to be equal with one of the specially
handled registers.
Signed-off-by: default avatarClemens Ladisch <clemens@ladisch.de>
Signed-off-by: default avatarStefan Richter <stefanr@s5r6.in-berlin.de>
parent d6372b6e
...@@ -1198,8 +1198,7 @@ static void handle_local_lock(struct fw_ohci *ohci, ...@@ -1198,8 +1198,7 @@ static void handle_local_lock(struct fw_ohci *ohci,
static void handle_local_request(struct context *ctx, struct fw_packet *packet) static void handle_local_request(struct context *ctx, struct fw_packet *packet)
{ {
u64 offset; u64 offset, csr;
u32 csr;
if (ctx == &ctx->ohci->at_request_ctx) { if (ctx == &ctx->ohci->at_request_ctx) {
packet->ack = ACK_PENDING; packet->ack = ACK_PENDING;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment