axonram: Fix bug in direct_access

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>
This commit is contained in:
Matthew Wilcox 2015-01-07 18:04:18 +02:00 committed by Jens Axboe
parent 78e367a360
commit 91117a2024
1 changed files with 1 additions and 1 deletions

View File

@ -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;
}