[PATCH V5 30/31] powerpc/mm: Move THP headers around

Denis Kirjanov kda at linux-powerpc.org
Wed Nov 25 00:58:55 AEDT 2015


On 11/24/15, Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com> wrote:
> Denis Kirjanov <kda at linux-powerpc.org> writes:
>
>> On 11/23/15, Aneesh Kumar K.V <aneesh.kumar at linux.vnet.ibm.com> wrote:
>>> We support THP only with book3s_64 and 64K page size. Move
>>> THP details to hash64-64k.h to clarify the same.
> ...
>
>>> -static inline void hpte_do_hugepage_flush(struct mm_struct *mm,
>>> -					  unsigned long addr, pmd_t *pmdp,
>>> -					  unsigned long old_pmd)
>>> -{
>>> -
>>> -	WARN(1, "%s called with THP disabled\n", __func__);
>> We can't reach this function with huge pages disabled, right?
>> Would it be better to use WARN_ON_ONCE?
>
> Shouldn't matter, if should never get called and if we get called, them
> something is really wrong, and mostly need a kernel fix. This will only
> happen during devel mistakes.

Ok, we can put the BUG() macro then, but as I know Linus doesn't like it :)
So WARN() is fine I think

>
> -aneesh
>
>


More information about the Linuxppc-dev mailing list