Re: [PATCH 09/28] nios2: Page table management

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi!

> This patch adds support for page table management.
> 
> Signed-off-by: Ley Foon Tan <lftan@xxxxxxxxxx>

> +/*
> + * Initialize a new pgd / pmd table with invalid pointers.
> + */
> +static void pgd_init(pgd_t *pgd)
> +{
> +	unsigned long *p = (unsigned long *) pgd;
> +	int i;
> +
> +	for (i = 0; i < USER_PTRS_PER_PGD; i += 8) {
> +		p[i + 0] = (unsigned long) invalid_pte_table;
> +		p[i + 1] = (unsigned long) invalid_pte_table;
> +		p[i + 2] = (unsigned long) invalid_pte_table;
> +		p[i + 3] = (unsigned long) invalid_pte_table;
> +		p[i + 4] = (unsigned long) invalid_pte_table;
> +		p[i + 5] = (unsigned long) invalid_pte_table;
> +		p[i + 6] = (unsigned long) invalid_pte_table;
> +		p[i + 7] = (unsigned long) invalid_pte_table;
> +	}

Umm. Manual loop unrolling. Does it really improve performance? Is the
code hot enough to warrant the uglyness?

								Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux