Skip to content

Commit

Permalink
axonram: Fix bug in direct_access
Browse files Browse the repository at this point in the history
The 'pfn' returned by axonram was completely bogus, and has been since
2008.

Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Reviewed-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: stable@vger.kernel.org
Signed-off-by: Jens Axboe <axboe@fb.com>
  • Loading branch information
Matthew Wilcox authored and Jens Axboe committed Jan 14, 2015
1 parent 78e367a commit 91117a2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/powerpc/sysdev/axonram.c
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ axon_ram_direct_access(struct block_device *device, sector_t sector,
}

*kaddr = (void *)(bank->ph_addr + offset);
*pfn = virt_to_phys(kaddr) >> PAGE_SHIFT;
*pfn = virt_to_phys(*kaddr) >> PAGE_SHIFT;

return 0;
}
Expand Down

0 comments on commit 91117a2

Please sign in to comment.