Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp1676636rwb; Fri, 28 Jul 2023 13:06:50 -0700 (PDT) X-Google-Smtp-Source: APBJJlEkDry3qfgV822xQ3mcr3Jjuu6MiBL02U1oI2xLvxxj7+U6jg0oAL1jy+T5BgoCrgrHWS6B X-Received: by 2002:a17:90a:df95:b0:267:7743:9857 with SMTP id p21-20020a17090adf9500b0026777439857mr2286290pjv.17.1690574810003; Fri, 28 Jul 2023 13:06:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690574809; cv=none; d=google.com; s=arc-20160816; b=y/Ad5u0Acg93bdtCKqbDk61RQEKP6iPEbjv1ST9CGrwiqL2/fs9jQebh/C8IROYj86 AQ2ms4oCRgNh6g3Pp5/keNleLeVjp6jmSbxR6X1FKJmtQBN0X3CV/OzmRx7KhkpPD/E5 Dvcx6q2e44ukP/BkHM5F3fZSs4eQz08B49A1/lLjUVqdeTeULJS0pMjysyMyRwKcZ0HH sN3F7at4Pz9LTCcPXR1njcdfLUAKhqvgvECgqUFM8cx++GRr5O/KcB9LgHHpmCgNqk8Q 2mllNs7GgnXV5DxIWwGvtVcIBpHmKIJKuDQpIKZsB3gbbLoNE/h0jGzvftKtQxgm0OCZ SCwg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:references:subject:cc:to:from :message-id:date:dkim-signature; bh=TICUNswaiy3hGzrdEHOhf450hXdu05dOSqoVSbTxlFE=; fh=3VkAnw2GFeyY/u4dOw3KMhkgjRPAQ49pERzDlOh6PQo=; b=SvTfHZv8rxjgRE6XT8zP9BG3CmtTNchUglYduWC18o1Kvk0YXc61S2SVGnyQwh6Sfp x5pv/pw2hWUw4/DPxfF8WSo61e52fBKBppPoU9uCbPzUY1IjLzImQAgaKUvMrnJvpDdZ jzQO1vWjR0CBaSWnylwpEqGGsQC/is0m5KS5o9ye8w09keVkW+M1kseJz4y47L+juTay oeYanUsSQyQXcdG2mF6Yx3vJRzbg9jIhbI7/xEq3MydJcx6KQBGuaoSZFmsWgusy/1pD MtajZGpf35M+hdZ8ENKRBmKzs3CSDRYB9TRQ+Z/3sC1pdhIzYccSW2TRk3FSKl9E4OSq 08KQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@paul-moore.com header.s=google header.b=dlxe18JZ; 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=paul-moore.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z61-20020a17090a6d4300b0026807ec51b2si3533162pjj.53.2023.07.28.13.06.32; Fri, 28 Jul 2023 13:06:49 -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=@paul-moore.com header.s=google header.b=dlxe18JZ; 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=paul-moore.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235522AbjG1SJi (ORCPT + 99 others); Fri, 28 Jul 2023 14:09:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54536 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235507AbjG1SJf (ORCPT ); Fri, 28 Jul 2023 14:09:35 -0400 Received: from mail-oi1-x229.google.com (mail-oi1-x229.google.com [IPv6:2607:f8b0:4864:20::229]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 021E944B9 for ; Fri, 28 Jul 2023 11:09:24 -0700 (PDT) Received: by mail-oi1-x229.google.com with SMTP id 5614622812f47-3a412653352so1931128b6e.0 for ; Fri, 28 Jul 2023 11:09:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paul-moore.com; s=google; t=1690567764; x=1691172564; h=in-reply-to:references:subject:cc:to:from:message-id:date:from:to :cc:subject:date:message-id:reply-to; bh=TICUNswaiy3hGzrdEHOhf450hXdu05dOSqoVSbTxlFE=; b=dlxe18JZ/R5T/cj1N4po5CDFM75FGKqR/keZ/dp1HTJBAD9IY775A5kPEXok7rd8Ml nsUt2+VbNcGo92PsVz46RSoT9ENiNEFVCCZh8jG4RPxGMF+ZiNNCrCNnV+UmSyqCR2Lh AoechusVVqfWu0eH5X3TF4o/zUEiwK4S68QxbWOgdF8Tu96nRHTagwaOpg4/0/rv9p6q puDKQ52Dd6fTd/6BZsMudZT2Dy3rLUYV5kJ1n/a470bCHsI0rQ0Y5TbzG4WoOqcAQclY 6HF8uEmfoP/AV6q5otaksnjV+v4Pvzk+aymNO16Y3tczN3bqGCEcwuSRj6URwezS4jNE X8XQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690567764; x=1691172564; h=in-reply-to:references:subject:cc:to:from:message-id:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=TICUNswaiy3hGzrdEHOhf450hXdu05dOSqoVSbTxlFE=; b=aXUU2gMnSNZHJuXsy1sXFUGrAx7VHbEZOAYm64abixbK5vQ2QlxrF9dhkIuWLyEWtS tLdk+xp0ATwfZH0AQmeTzo33T8KrdROWmBOormxmuOpZMv3c0uYeNOugJ25SKdvPwVdD MY9RJRRlxieAtX0RBsQUh1h7nn6G3exjrPnVvYVPeSuLrSjS+D1WNSMlYyUznB6b45KR olg8dRnreP1LwhiaD6SvkYIzrINlbPyWSkoaYIbBWaKCa7AaSQdJzu1rs6x6bCJXEb4r NsnIE8CL9ZSMLPwJluEocPlzLbvB3wnIHT/QRBIqdmByqllEmujSLItgSUhjsR9v4yPb ZhIg== X-Gm-Message-State: ABy/qLac1KS9CgcLh70g7V3EAl/5OrCjq6NTpHXMtJfTU5XNDZW+mjGx uU/C/03lrseiJVkCcqFMBv2HJ3xYQ9nMQWZMMw== X-Received: by 2002:a05:6808:19a6:b0:39a:bd0e:449 with SMTP id bj38-20020a05680819a600b0039abd0e0449mr4286448oib.26.1690567763731; Fri, 28 Jul 2023 11:09:23 -0700 (PDT) Received: from localhost ([70.22.175.108]) by smtp.gmail.com with ESMTPSA id r2-20020ac83b42000000b00403c1a19a2bsm1328529qtf.92.2023.07.28.11.09.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Jul 2023 11:09:23 -0700 (PDT) Date: Fri, 28 Jul 2023 14:09:22 -0400 Message-ID: From: Paul Moore To: =?UTF-8?q?Christian=20G=C3=B6ttsche?= , selinux@vger.kernel.org Cc: Stephen Smalley , Eric Paris , Ondrej Mosnacek , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] selinux: move debug functions into debug configuration References: <20230728151932.30160-1-cgzones@googlemail.com> In-Reply-To: <20230728151932.30160-1-cgzones@googlemail.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,PP_MIME_FAKE_ASCII_TEXT, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED autolearn=unavailable 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 On Jul 28, 2023 =?UTF-8?q?Christian=20G=C3=B6ttsche?= wrote: > > avtab_hash_eval() and hashtab_stat() are only used in policydb.c when > the configuration SECURITY_SELINUX_DEBUG is enabled. > > Move the function definitions under that configuration as well and > provide empty definitions in case SECURITY_SELINUX_DEBUG is disabled, to > avoid using #ifdef in the callers. > > Signed-off-by: Christian Göttsche > --- > v2: > - provide empty definitions for !SECURITY_SELINUX_DEBUG > - drop #ifdef in caller > --- > security/selinux/ss/avtab.c | 2 ++ > security/selinux/ss/avtab.h | 7 +++++++ > security/selinux/ss/hashtab.c | 3 ++- > security/selinux/ss/hashtab.h | 6 ++++++ > security/selinux/ss/policydb.c | 5 +++-- > 5 files changed, 20 insertions(+), 3 deletions(-) Merged into selinux/next, thanks! -- paul-moore.com