All of lore.kernel.org
 help / color / mirror / Atom feed
* arm64: virt_to_page() does not return right page for a kernel image address
@ 2017-01-04  5:49 Pratyush Anand
  2017-01-04 11:11 ` Mark Rutland
  2017-01-04 12:13 ` Catalin Marinas
  0 siblings, 2 replies; 10+ messages in thread
From: Pratyush Anand @ 2017-01-04  5:49 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

I noticed that on arm64 kmap_atomic() does not return correct address
corresponding to a page located in data section. It causes crash in
kdump kernel with v29 kdump patches. crash happens in a newly
implemented crypto test [1], and the same test fails(even though it
does not crash) in 1st kernel as well.

Further debugging showed that the physical address returned by
virt_to_phys(kaddr)  and virt_to_phys(kmap_atomic(virt_to_page(kaddr))
+ offset_in_page(kaddr)) are not same.

Mark Rutland thinks(IRC :#armlinux) that _virt_to_pgoff *only* handles
linear addresses, and not kernel image addresses. However, we have to
ask if it should?

Meanwhile, I reverted commit [2] and then everything worked fine
*atleast* in my case. But, I am not sure if that could be the right
and best solution.

Opinion?

~Pratyush

[1]
commit d7db7a882debaffc78f91aabedee973aa1f73390
Author: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Date:   Fri Oct 21 13:19:54 2016 +0100

    crypto: acomp - update testmgr with support for acomp

[2]commit 9f2875912dac35d9272a82ea9eec9e5884b42cd2
Author: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Date:   Wed Mar 30 16:46:01 2016 +0200

    arm64: mm: restrict virt_to_page() to the linear mapping

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2017-01-05 10:57 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-04  5:49 arm64: virt_to_page() does not return right page for a kernel image address Pratyush Anand
2017-01-04 11:11 ` Mark Rutland
2017-01-04 11:58   ` Pratyush Anand
2017-01-04 12:06     ` Mark Rutland
2017-01-04 12:23       ` Pratyush Anand
2017-01-04 13:24         ` Ard Biesheuvel
2017-01-04 14:03           ` Pratyush Anand
2017-01-04 12:13 ` Catalin Marinas
2017-01-04 18:39   ` Laura Abbott
2017-01-05 10:57     ` Catalin Marinas

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.