Received: by 2002:ac0:e350:0:0:0:0:0 with SMTP id g16csp1958685imn; Mon, 1 Aug 2022 06:19:33 -0700 (PDT) X-Google-Smtp-Source: AA6agR5nr2NBW8ZRnQ+he6QxA8lGQTS+Xbe9GWvH2s72E0a13Ec0gbJOhb8A3r7SiTbGfpIeilaY X-Received: by 2002:a17:907:a063:b0:730:750b:bb62 with SMTP id ia3-20020a170907a06300b00730750bbb62mr4799130ejc.612.1659359973119; Mon, 01 Aug 2022 06:19:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659359973; cv=none; d=google.com; s=arc-20160816; b=iSvLkHV1Xn/FtNdfv6wEe+WHOVEWGu9t+6PdzmPD+8mXcCaXozFOc2IePbhNpMKk7T /77l2FohOxeOu3RZ8yl+OtIq10QDm+fzTziXMWYJGIFk4i1NKpQbO/AmvnAd/H3t6fGf hyyiylpAEaGuCa0/jx2R+RAJRMF3jTxOPKYdsTLFo2JrbU3+mBrVQ6onsCqf2n8TvbXW 6wjqHvWLa0XcDG5waMqKRuB+COxiilatN57UYAJIt/mhHmqr/t7rDXPYrxBI7XxnGr5D NWwofzw+8HDDB+UtClyh9LKnPGEJUD04m6v7/lEes+ZiPkiWEK/Z0QWk9OkGFAIsDh1J HTwQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=tPnL5WPicD36Lfu4smuLKzLUsHaG5PhRfqhgGJSmCFg=; b=ky+d2RcQnbkrVJQMO+xBY/MyC+7sKQeSOog3T3mKAAAeuyQMid9sBU2HPwAe1blNuY pMqV1/65g1R3xjD82yTJj87emp23cqncBUnqfT2GLdR1KZSQHDSSQyEuAj0hOTYSdCuQ LCFEIqHiB3uYP5RxYE4fonywJ2V97cgnHn7YbrMEfnQSELdFUBjjLyRyInk9BV17elMq p4udcGOKea5MU5r5UtQGuP7DKqjJpbU8HmQVojqK2H285UxdPIN28ofyK3sqwjyc+CAZ wIRmWMrvqV977RI8sQOTx/havYklsUQTqyyomkob+mqYG8gWoJgUwguQGYSsLkLz0OKu /UTA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="1vhoft/h"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id nc27-20020a1709071c1b00b0072f3a7e584fsi11712350ejc.958.2022.08.01.06.18.46; Mon, 01 Aug 2022 06:19:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="1vhoft/h"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232747AbiHAMC2 (ORCPT + 99 others); Mon, 1 Aug 2022 08:02:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33192 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232935AbiHAMAf (ORCPT ); Mon, 1 Aug 2022 08:00:35 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 564FE4E601; Mon, 1 Aug 2022 04:52:58 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id D51F4B81171; Mon, 1 Aug 2022 11:52:56 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 427DDC433D6; Mon, 1 Aug 2022 11:52:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1659354775; bh=QdhoJKHWHOYGae7EJTZdGq1HN/BPTPc3s5JJatJcrEw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=1vhoft/hTOHG9sQeGQMcyqYK1zL7MekI+4gS9C6x4hYDFg4y6tH4IE1nuJKPIHrFD Llt8lyhLcaAyu66my58HbRXNakqagyTdCXG5t2TrRguFK3y4nCMfuB1Ntohcb2YEyO nghjOECO0YuIkPvVRs5MUikwFrcFoalO8bzEoQXc= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Lukas Bulwahn , Arnd Bergmann Subject: [PATCH 5.15 08/69] asm-generic: remove a broken and needless ifdef conditional Date: Mon, 1 Aug 2022 13:46:32 +0200 Message-Id: <20220801114134.815320414@linuxfoundation.org> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20220801114134.468284027@linuxfoundation.org> References: <20220801114134.468284027@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Lukas Bulwahn commit e2a619ca0b38f2114347b7078b8a67d72d457a3d upstream. Commit 527701eda5f1 ("lib: Add a generic version of devmem_is_allowed()") introduces the config symbol GENERIC_LIB_DEVMEM_IS_ALLOWED, but then falsely refers to CONFIG_GENERIC_DEVMEM_IS_ALLOWED (note the missing LIB in the reference) in ./include/asm-generic/io.h. Luckily, ./scripts/checkkconfigsymbols.py warns on non-existing configs: GENERIC_DEVMEM_IS_ALLOWED Referencing files: include/asm-generic/io.h The actual fix, though, is simply to not to make this function declaration dependent on any kernel config. For architectures that intend to use the generic version, the arch's 'select GENERIC_LIB_DEVMEM_IS_ALLOWED' will lead to picking the function definition, and for other architectures, this function is simply defined elsewhere. The wrong '#ifndef' on a non-existing config symbol also always had the same effect (although more by mistake than by intent). So, there is no functional change. Remove this broken and needless ifdef conditional. Fixes: 527701eda5f1 ("lib: Add a generic version of devmem_is_allowed()") Signed-off-by: Lukas Bulwahn Signed-off-by: Arnd Bergmann Signed-off-by: Greg Kroah-Hartman --- include/asm-generic/io.h | 2 -- 1 file changed, 2 deletions(-) --- a/include/asm-generic/io.h +++ b/include/asm-generic/io.h @@ -1125,9 +1125,7 @@ static inline void memcpy_toio(volatile } #endif -#ifndef CONFIG_GENERIC_DEVMEM_IS_ALLOWED extern int devmem_is_allowed(unsigned long pfn); -#endif #endif /* __KERNEL__ */