From: David Miller <davem@davemloft.net>
To: nitin.m.gupta@oracle.com
Cc: mike.kravetz@oracle.com, akpm@linux-foundation.org,
julian.calaby@gmail.com, hughd@google.com,
adam.buchbinder@gmail.com, minchan@kernel.org,
kirill.shutemov@linux.intel.com, sfr@canb.auug.org.au,
paul.gortmaker@windriver.com, chris.hyser@oracle.com,
atish.patra@oracle.com, mhocko@suse.com, toshi.kani@hpe.com,
sparclinux@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] sparc64: Multi-page size support
Date: Sun, 20 Nov 2016 16:42:35 -0500 (EST) [thread overview]
Message-ID: <20161120.164235.41564426914943042.davem@davemloft.net> (raw)
In-Reply-To: <1476313187-105065-1-git-send-email-nitin.m.gupta@oracle.com>
From: Nitin Gupta <nitin.m.gupta@oracle.com>
Date: Wed, 12 Oct 2016 15:58:11 -0700
> @@ -117,26 +117,11 @@ tsb_miss_page_table_walk_sun4v_fastpath:
> /* Valid PTE is now in %g5. */
>
> #if defined(CONFIG_HUGETLB_PAGE) || defined(CONFIG_TRANSPARENT_HUGEPAGE)
> -661: sethi %uhi(_PAGE_SZALL_4U), %g7
> +661: sethi %uhi(_PAGE_PMD_HUGE), %g7
> sllx %g7, 32, %g7
This "661" label only exists for the sake of the code patching
reference, but if you are removing the code patching then this
label should thus be removed too.
> @@ -161,34 +270,51 @@ void set_huge_pte_at(struct mm_struct *mm, unsigned long addr,
> pte_t *ptep, pte_t entry)
> {
> pte_t orig;
> + unsigned long size = huge_tte_to_size(entry);
> + unsigned int i, nptes = size >> PMD_SHIFT;
> + unsigned int hugepage_shift;
Please always order local variables from longest to shortest line.
> pte_t huge_ptep_get_and_clear(struct mm_struct *mm, unsigned long addr,
> pte_t *ptep)
> {
> pte_t entry;
> + unsigned long size;
> + unsigned int i, nptes, hugepage_shift;
Likewise.
> +#ifdef CONFIG_HUGETLB_PAGE
> +static int __init setup_hugepagesz(char *string)
> +{
> + int rc = 0;
> + unsigned long long hugepage_size;
> + unsigned int hugepage_shift;
> + unsigned short hv_pgsz_idx;
> + unsigned int hv_pgsz_mask;
Likewise.
> +#if defined(CONFIG_HUGETLB_PAGE) || defined(CONFIG_TRANSPARENT_HUGEPAGE)
> +static void __flush_huge_tsb_one_entry(unsigned long tsb, unsigned long v,
> + unsigned long hash_shift,
> + unsigned long nentries,
> + unsigned int hugepage_shift)
> +{
> + unsigned int i;
> + unsigned int hpage_entries = 1 << (hugepage_shift - REAL_HPAGE_SHIFT);
Likewise.
prev parent reply other threads:[~2016-11-20 21:42 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-12 22:58 Nitin Gupta
2016-11-20 21:42 ` David Miller [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=20161120.164235.41564426914943042.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=adam.buchbinder@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=atish.patra@oracle.com \
--cc=chris.hyser@oracle.com \
--cc=hughd@google.com \
--cc=julian.calaby@gmail.com \
--cc=kirill.shutemov@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mhocko@suse.com \
--cc=mike.kravetz@oracle.com \
--cc=minchan@kernel.org \
--cc=nitin.m.gupta@oracle.com \
--cc=paul.gortmaker@windriver.com \
--cc=sfr@canb.auug.org.au \
--cc=sparclinux@vger.kernel.org \
--cc=toshi.kani@hpe.com \
/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
all inboxes | Powered by JetHome®