Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1318581

Re: [kernel] powerpc: Make vmalloc_to_phys() public

From Alexey Kardashevskiy <aik@ozlabs.ru>
Newsgroups linux.kernel
Subject Re: [kernel] powerpc: Make vmalloc_to_phys() public
Date 2016-01-27 04:30 +0100
Message-ID <qVoXU-5Jw-1@gated-at.bofh.it> (permalink)
References <qTi0x-20y-1@gated-at.bofh.it> <qUIci-7Me-3@gated-at.bofh.it> <qUMfW-2lm-45@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 01/25/2016 09:06 PM, Paul Mackerras wrote:
> On Mon, Jan 25, 2016 at 04:46:03PM +1100, Michael Ellerman wrote:
>> On Thu, 2016-21-01 at 07:35:08 UTC, Alexey Kardashevskiy wrote:
>>> This makes vmalloc_to_phys() public as there will be another user
>>> (in-kernel VFIO acceleration) for it soon.
>>>
>>> As a part of future little optimization, this changes the helper to call
>>> vmalloc_to_pfn() instead of vmalloc_to_page() as the size of the
>>> struct page may not be power-of-two aligned which will make gcc use
>>> multiply instructions instead of shifts.
>>
>> You should also mention why you need to export it, presumably because whatever
>> new user you have in mind can be built as a module.
>
> If I remember correctly, it's the *existing* user in hv-24x7.c that
> needs the export.

No, CONFIG_HV_PERF_CTRS (which controls hv-24x7.c) is "bool" so today 
hv-24x7.c cannot compile as a module.

This exports the vmalloc_to_phys() symbol as a new user is going to be KVM 
which can compile as a module.


-- 
Alexey

Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

[PATCH kernel] powerpc: Make vmalloc_to_phys() public Alexey Kardashevskiy <aik@ozlabs.ru> - 2016-01-21 08:40 +0100
  Re: [kernel] powerpc: Make vmalloc_to_phys() public Michael Ellerman <mpe@ellerman.id.au> - 2016-01-25 06:50 +0100
    Re: [kernel] powerpc: Make vmalloc_to_phys() public Anshuman Khandual <khandual@linux.vnet.ibm.com> - 2016-01-25 07:30 +0100
    Re: [kernel] powerpc: Make vmalloc_to_phys() public Paul Mackerras <paulus@ozlabs.org> - 2016-01-25 11:10 +0100
      Re: [kernel] powerpc: Make vmalloc_to_phys() public Alexey Kardashevskiy <aik@ozlabs.ru> - 2016-01-27 04:30 +0100

csiph-web