From patchwork Sun Sep 27 11:29:01 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stian Halseth X-Patchwork-Id: 2312198 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; secure) header.d=itx.no header.i=@itx.no header.a=rsa-sha256 header.s=mx.itx.no header.b=mYKLOotG; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=ozlabs.org (client-ip=150.107.74.76; helo=mail.ozlabs.org; envelope-from=srs0=yr1z=ht=vger.kernel.org=sparclinux+bounces-8092-patchwork-incoming=ozlabs.org@ozlabs.org; receiver=patchwork.ozlabs.org) Received: from mail.ozlabs.org (gandalf.ozlabs.org [150.107.74.76]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4htHdW6WP4z1xyt for ; Mon, 28 Sep 2026 07:29:35 +1000 (AEST) Received: from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by gandalf.ozlabs.org (Postfix) with ESMTP id 4htHd021ylz4wHf for ; Mon, 28 Sep 2026 07:29:08 +1000 (AEST) Received: by gandalf.ozlabs.org (Postfix) id 4htHd02052z4wD3; Mon, 28 Sep 2026 07:29:08 +1000 (AEST) Delivered-To: patchwork-incoming@ozlabs.org Authentication-Results: gandalf.ozlabs.org; arc=pass smtp.remote-ip=172.234.253.10 arc.chain=subspace.kernel.org ARC-Seal: i=2; a=rsa-sha256; d=ozlabs.org; s=201707; t=1790544548; cv=pass; b=qZGYIH1uqIHCGJBh5pRVepXNPQe6LLYem6T55fllqJYQ/pElWCsmw0ecwT5q8uyyXBO3nBjy9PEN2bZ0HCUm284KmsrO6uiT5RtVyH35zc1cXC1z6AJI9loGsdNRdvuVvDK39r0NAqnZCRVgBGVs86CXWU0m5GUa5wao/V7UEfIDUVDBAejEW0RCHUq1+mxii3wugxM7zZD9YunYuk4OtLkwj+WlsCdIYCuau7MzqZQnwpYTs1yHDMADSuc0EeXEFjh8XV0353YnO8UuIIugWL4ahj6Vsmqm6Cwc/8bSnYnyjSbEC3OoYj8eaah4ErxAqiPHuWF+hFGRWAd8eO9Luw== ARC-Message-Signature: i=2; a=rsa-sha256; d=ozlabs.org; s=201707; t=1790544548; c=relaxed/relaxed; bh=48HM4bSYyLxI5mQ/j1bJS2K0qEiIi3K5cN3OT/yJ0AA=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=DTr0xVn9diIoFOZB8vnugfcWTPYjkK2GydaxYp91PUbNOND5Rq1SzZYF2AEU/9dsVGkKodal8Wjb4fFjbggFuimFGjUFXPB3pxJOPDNXk7lvhz65R1qSFtyLufBZztiCWmGMzEBlKFYM/bz56aMHoyvlB7QiWFoLl620A5EIGVRgY0R1q8HSuRwe01f7LYQInbk3u0rlYZh8ahzKP5/MPXdkKzXftrJA7bR65e9nT+ZmX9qjpyBNABega8cdl16uHSGTVraFlMl5CmpRznhA1eP72oS8slTCNrR/B1t/aDFSY/Car5CLJ6E4sdo0HgbKPCrxLPwvbAxHd04KnfDCSQ== ARC-Authentication-Results: i=2; gandalf.ozlabs.org; dmarc=pass (p=reject dis=none) header.from=itx.no; dkim=pass (1024-bit key; secure) header.d=itx.no header.i=@itx.no header.a=rsa-sha256 header.s=mx.itx.no header.b=mYKLOotG; dkim-atps=neutral; spf=pass (client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=sparclinux+bounces-8092-patchwork-incoming=ozlabs.org@vger.kernel.org; receiver=ozlabs.org) smtp.mailfrom=vger.kernel.org Authentication-Results: gandalf.ozlabs.org; dmarc=pass (p=reject dis=none) header.from=itx.no Authentication-Results: gandalf.ozlabs.org; dkim=pass (1024-bit key; secure) header.d=itx.no header.i=@itx.no header.a=rsa-sha256 header.s=mx.itx.no header.b=mYKLOotG; dkim-atps=neutral Authentication-Results: gandalf.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=sparclinux+bounces-8092-patchwork-incoming=ozlabs.org@vger.kernel.org; receiver=ozlabs.org) Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (No client certificate requested) by gandalf.ozlabs.org (Postfix) with ESMTPS id 4htHcw5vQXz4wHf for ; Mon, 28 Sep 2026 07:29:04 +1000 (AEST) Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.90.174.1]) by sea.lore.kernel.org (Postfix) with ESMTP id 4EACD2FBEA for ; Sun, 27 Sep 2026 21:29:27 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 50C303C3F70; Sun, 27 Sep 2026 21:29:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=itx.no header.i=@itx.no header.b="mYKLOotG" X-Original-To: sparclinux@vger.kernel.org Received: from mx.itxnorge.no (itx-kvm-14.itxnorge.no [91.189.121.228]) (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 D239C3C1D79; Sun, 27 Sep 2026 21:29:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.189.121.228 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790544566; cv=none; b=F/Nz77rfPe04+53h8Kl1R0CNFJOoFr6EqQ2nE4jmdzFdyEyWABtDYWE4UL0VwaK3zNAitAbLzy5C/pjr8+Aup2Qhq7P2OuaUP+G8Iq1A2iMQYBmm4vzWYVgh/9Ji1Lc3mRpycJO3ncpvzT+1e9wFLlk/NMxBW0MQzhkTMxwgb+8= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790544566; c=relaxed/simple; bh=bBKmg9pfb9+mY+zGrrcQx1bEdEyz6obAHAVPXKZ1bYg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=F/x6+JF2vu8gE9/L3+lRIpHxjL9NqRC5JZR4T64ody3VJg1rJMnDxhWpw5N8lYmpx2i3odxGBEWLOpNi9LKfEOCKm4WDxTEMGPCEI/rbMb3h0lJsQAYcdFckzWVY55pmhbRL42fHrEttc5SW9jYTvv7+THmfy7rb3/G+3E1M2eI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=itx.no; spf=pass smtp.mailfrom=itx.no; dkim=pass (1024-bit key) header.d=itx.no header.i=@itx.no header.b=mYKLOotG; arc=none smtp.client-ip=91.189.121.228 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=itx.no Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=itx.no From: Stian Halseth DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=itx.no; s=mx.itx.no; t=1790544556; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=48HM4bSYyLxI5mQ/j1bJS2K0qEiIi3K5cN3OT/yJ0AA=; b=mYKLOotG91oDjmjKbbI3m6qjn40AHrLh3CFuTuebw/p49etBsJvknYMNw9GaYiQPSGAtdl F7FGAgRvUhMuCQcth4Ymu3JM0dj5xEIGW9rpLbtcqk1NjNivaYeqvSj5ZsWln7p5wPQ8gQ WK02V9NLpFphJ5NFJ/x1Fp2BQnl1LKY= To: andreas@gaisler.com, davem@davemloft.net, sparclinux@vger.kernel.org Cc: Stian Halseth , linux-kernel@vger.kernel.org, david.laight.linux@gmail.com, glaubitz@physik.fu-berlin.de, thuth@redhat.com, regressions@lists.linux.dev, nroach44@nroach44.id.au, kaloz@kernel.org, unixpro1970@gmail.com Subject: [PATCH v3 2/2] sparc64: remove dead THREAD_SIZE branches for non-8K pages Date: Sun, 27 Sep 2026 23:29:01 +0200 Message-ID: <20260927212913.3237082-2-stian@itx.no> In-Reply-To: <20260927212913.3237082-1-stian@itx.no> References: <20260927204912.3667-1-kaloz@kernel.org> <20260927212913.3237082-1-stian@itx.no> Precedence: bulk X-Mailing-List: sparclinux@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DMARC_PASS,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=disabled version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on gandalf.ozlabs.org Commit 15b9350a177b ("sparc64: Only support 4MB huge pages and 8KB base pages.") made 8K the only base page size, so PAGE_SHIFT is always 13 here and the else branches have been dead since. Remove them. Fixes: 15b9350a177b ("sparc64: Only support 4MB huge pages and 8KB base pages.") Suggested-by: Andreas Larsson Signed-off-by: Stian Halseth Reviewed-by: Andreas Larsson --- arch/sparc/include/asm/thread_info_64.h | 10 ---------- 1 file changed, 10 deletions(-) -- 2.53.0 diff --git a/arch/sparc/include/asm/thread_info_64.h b/arch/sparc/include/asm/thread_info_64.h --- a/arch/sparc/include/asm/thread_info_64.h +++ b/arch/sparc/include/asm/thread_info_64.h @@ -99,13 +99,8 @@ #define FAULT_CODE_BLKCOMMIT 0x10 /* Use blk-commit ASI in copy_page */ #define FAULT_CODE_BAD_RA 0x20 /* Bad RA for sun4v */ -#if PAGE_SHIFT == 13 #define THREAD_SIZE (4*PAGE_SIZE) #define THREAD_SHIFT (PAGE_SHIFT + 2) -#else /* PAGE_SHIFT == 13 */ -#define THREAD_SIZE PAGE_SIZE -#define THREAD_SHIFT PAGE_SHIFT -#endif /* PAGE_SHIFT == 13 */ /* * macros/functions for gaining access to the thread information structure @@ -128,11 +123,7 @@ #endif /* thread information allocation */ -#if PAGE_SHIFT == 13 #define THREAD_SIZE_ORDER 2 -#else /* PAGE_SHIFT == 13 */ -#define THREAD_SIZE_ORDER 0 -#endif /* PAGE_SHIFT == 13 */ #define __thread_flag_byte_ptr(ti) \ ((unsigned char *)(&((ti)->flags)))