linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Alexey Kardashevskiy <aik@ozlabs.ru>
To: Paul Mackerras <paulus@ozlabs.org>,
	Michael Ellerman <mpe@ellerman.id.au>
Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org
Subject: Re: [kernel] powerpc: Make vmalloc_to_phys() public
Date: Wed, 27 Jan 2016 14:19:04 +1100	[thread overview]
Message-ID: <56A83728.4090601@ozlabs.ru> (raw)
In-Reply-To: <20160125100609.GA24295@fergus.ozlabs.ibm.com>

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

      reply	other threads:[~2016-01-27  3:19 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-21  7:35 [PATCH kernel] powerpc: Make vmalloc_to_phys() public Alexey Kardashevskiy
2016-01-25  5:46 ` [kernel] " Michael Ellerman
2016-01-25  6:21   ` Anshuman Khandual
2016-01-25 10:06   ` Paul Mackerras
2016-01-27  3:19     ` Alexey Kardashevskiy [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=56A83728.4090601@ozlabs.ru \
    --to=aik@ozlabs.ru \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    --cc=paulus@ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).