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 ACDB01D6AA for ; Thu, 4 Dec 2025 10:34:31 +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=1764844471; cv=none; b=IPi8B+Mm9ZtfA1KcGtROBwdpblclAzrayfZ+/BGUqf1af/SQq7keDBO4E8TOGCamP8LaCC4p5+pc7A7dfVxPJcxU24SgSx/KnNNytyQ4K8QLeooCLjzgEr0qyFysimFHrrgLxoWDKFuRBLWbU5XIBC1gKJoH0G+lKzzXTe6h2FA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764844471; c=relaxed/simple; bh=9fIl0Nc3fq8oA7vLceVddLBUKc6eKPFKzK6/oiJIcA8=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=ZyLGFhErUgTn7zX4ySSCeg1O7Oktdk3Yc6u+jKfhKDCNktNZEQSE6lUE3biVNOTJyCEDjknEnhmtHUBgLoE3W5sHLEzZgHcJ8p4u+SIiRc8Xt1xlMMSOpJMvlmytAh0y1RHF4GsfIIUpG6+v1jMv8IYjrufNtqtmDLUqkdtgJiE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=KmUkPc4c; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="KmUkPc4c" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1F92BC4CEFB; Thu, 4 Dec 2025 10:34:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1764844471; bh=9fIl0Nc3fq8oA7vLceVddLBUKc6eKPFKzK6/oiJIcA8=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=KmUkPc4ci2T2TIC7hVVmPg7QcDWfUF7A7vjx4SXZd5APHYI6p0EPA06UBSC50WVqc /s+JLtrUlskFkUdrCqubXPPWEu5KXhJTFwrbHojtY5JwrsOwAGZ4NdeV7PeflZ0TYs L3Mz2gMd+iBDZkgF2m6PMUnmAphl96Zvcv0F3qrAs/gxAw0PD7I9Rmsa9+1U8BOd3f EJ3h80r6wOkGvhGP7O9wt91WJ/WWkZGkDNMwF/5Jto53QfXvsKW5+0y94+nQL+M5NA BVcCB9XMrOqiqreetMRPvdYyS6BUi++wGc9KW4M1vtA1UoBjjTay792aXNHHgmyE+m kOEr2FN/chDSQ== Message-ID: <93782526-c198-4590-b96b-c4f630b8ecbb@kernel.org> Date: Thu, 4 Dec 2025 11:34:24 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] [v2] mm: shmem: avoid build warning for CONFIG_SHMEM=n To: Arnd Bergmann , Hugh Dickins , Andrew Morton , Pratyush Yadav , "Mike Rapoport (Microsoft)" , Pasha Tatashin Cc: Arnd Bergmann , Baolin Wang , Kairui Song , Christian Brauner , Lorenzo Stoakes , Kemeng Shi , Guo Weikang , linux-mm@kvack.org, linux-kernel@vger.kernel.org References: <20251204102905.1048000-1-arnd@kernel.org> From: "David Hildenbrand (Red Hat)" Content-Language: en-US In-Reply-To: <20251204102905.1048000-1-arnd@kernel.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 12/4/25 11:28, Arnd Bergmann wrote: > From: Arnd Bergmann > > The newly added 'flags' variable is unused and causes a warning if > CONFIG_SHMEM is disabled, since the shmem_acct_size() macro it is passed > into does nothing: > > mm/shmem.c: In function '__shmem_file_setup': > mm/shmem.c:5816:23: error: unused variable 'flags' [-Werror=unused-variable] > 5816 | unsigned long flags = (vm_flags & VM_NORESERVE) ? SHMEM_F_NORESERVE : 0; > | ^~~~~ > > Replace the two macros with equivalent inline functions tto get the > argument checking. > > Fixes: 6ff1610ced56 ("mm: shmem: use SHMEM_F_* flags instead of VM_* flags") That's still not upstream, right? $ git tag --contains 6ff1610ced56 mm-everything-2025-11-29-19-43 mm-everything-2025-12-03-23-49 next-20251201 next-20251203 next-20251204 So we can likely just squash it into the problematic commit before proceeding with it? Thanks Arnd! -- Cheers David