From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BB81379DBC; Wed, 21 Feb 2024 13:32:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708522324; cv=none; b=cWGcE4yrlSbywroNEacIf6U3KRRE7qIQnmnLXZchdXh91G5UcByJGfP5OwsQymEBafJC0x95QiAW1oocOUb29OfrTGiYGucXQbwSSZ8Ttf1xg+1pAXxYSYhwwuAAcXDTGuIvwFjmSOQJGsPF+sm5bP9s/4tCZ5bv6Y1bSYl9e0s= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708522324; c=relaxed/simple; bh=20dFILn0zQnyuievY0GwSCvTPn5NxOI8lNILFuFzP/8=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=D15ELWcCiEU+U+1J8HqhiRz808gqHEZEPt/NJF0k0oNrs2/rVehJDVVlEimsSKebM4R2L8X5V1Eihuw41rvZZoEsjKrB8liusr86sTbkPAnymB9Bn3QVeZXMlfbgHj1qyzP62BPZfMGfehIB6h2wz/g2ZBBw7gKrVJs6jypEXy8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=dgV1VvX+; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="dgV1VvX+" Received: by smtp.kernel.org (Postfix) with ESMTPSA id B4ACFC433F1; Wed, 21 Feb 2024 13:32:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1708522322; bh=20dFILn0zQnyuievY0GwSCvTPn5NxOI8lNILFuFzP/8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=dgV1VvX+32GwcAa9fi1l95tID+UcaI025hyKIauuz+EV3MHHlf/7pjEe5UFAvMcaS 9sLrKKgiLYwALRXk2u7sJblSt71Qgdywl4CXkHucRGI5ElmbdfVZ6YY/OdRjJfAz2S nGoIDuvawVCIF1cxq8KRJbQeubp/PxAaLLqLVdZ0= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Stephen Rothwell , Michael Ellerman , Sasha Levin Subject: [PATCH 5.15 132/476] powerpc: pmd_move_must_withdraw() is only needed for CONFIG_TRANSPARENT_HUGEPAGE Date: Wed, 21 Feb 2024 14:03:03 +0100 Message-ID: <20240221130012.842473736@linuxfoundation.org> X-Mailer: git-send-email 2.43.2 In-Reply-To: <20240221130007.738356493@linuxfoundation.org> References: <20240221130007.738356493@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Stephen Rothwell [ Upstream commit 0d555b57ee660d8a871781c0eebf006e855e918d ] The linux-next build of powerpc64 allnoconfig fails with: arch/powerpc/mm/book3s64/pgtable.c:557:5: error: no previous prototype for 'pmd_move_must_withdraw' 557 | int pmd_move_must_withdraw(struct spinlock *new_pmd_ptl, | ^~~~~~~~~~~~~~~~~~~~~~ Caused by commit: c6345dfa6e3e ("Makefile.extrawarn: turn on missing-prototypes globally") Fix it by moving the function definition under CONFIG_TRANSPARENT_HUGEPAGE like the prototype. The function is only called when CONFIG_TRANSPARENT_HUGEPAGE=y. Signed-off-by: Stephen Rothwell [mpe: Flesh out change log from linux-next patch] Signed-off-by: Michael Ellerman Link: https://msgid.link/20231127132809.45c2b398@canb.auug.org.au Signed-off-by: Sasha Levin --- arch/powerpc/mm/book3s64/pgtable.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/powerpc/mm/book3s64/pgtable.c b/arch/powerpc/mm/book3s64/pgtable.c index 9e16c7b1a6c5..da15f28c7b13 100644 --- a/arch/powerpc/mm/book3s64/pgtable.c +++ b/arch/powerpc/mm/book3s64/pgtable.c @@ -459,6 +459,7 @@ void ptep_modify_prot_commit(struct vm_area_struct *vma, unsigned long addr, set_pte_at(vma->vm_mm, addr, ptep, pte); } +#ifdef CONFIG_TRANSPARENT_HUGEPAGE /* * For hash translation mode, we use the deposited table to store hash slot * information and they are stored at PTRS_PER_PMD offset from related pmd @@ -480,6 +481,7 @@ int pmd_move_must_withdraw(struct spinlock *new_pmd_ptl, return true; } +#endif /* * Does the CPU support tlbie? -- 2.43.0