From patchwork Wed Nov 13 12:14:22 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Oliver O'Halloran X-Patchwork-Id: 1194235 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 47Ck8w0gcpz9s7T for ; Wed, 13 Nov 2019 23:15:44 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="hyZoHTan"; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 47Ck8v60t8zF7NQ for ; Wed, 13 Nov 2019 23:15:43 +1100 (AEDT) X-Original-To: skiboot@lists.ozlabs.org Delivered-To: skiboot@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gmail.com (client-ip=2607:f8b0:4864:20::541; helo=mail-pg1-x541.google.com; envelope-from=oohall@gmail.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="hyZoHTan"; dkim-atps=neutral Received: from mail-pg1-x541.google.com (mail-pg1-x541.google.com [IPv6:2607:f8b0:4864:20::541]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 47Ck863J2pzF6vM for ; Wed, 13 Nov 2019 23:15:02 +1100 (AEDT) Received: by mail-pg1-x541.google.com with SMTP id h4so1274478pgv.8 for ; Wed, 13 Nov 2019 04:15:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=822k5Epy3abApFDOTZu4ecH2CXFgELBLfTdDkDS98hQ=; b=hyZoHTan8aXM4sZC1YnZfORs06KAEtqll9EDRxYNt0+zXXe2Ib1kLj8y54WpuKvv6L vRU8zZ3eMqqgma9YpQPp6F3aZzh3hn27T8Zy4NMO2P+XYXgvr2BJw7pOc4DUTGRD+4EL EDsWt6irhEt+6SqwAArcKscKiU9crKoNMtDvfoyiYw6xzBsvV4HuEGTBpZ7CCdQC3BMP 2n/dcBdfkwBS3hUkSAVyIbjV3nrOqZD4LI2KvIMaSWLA75iXYOl/riF8vn2Q7VL/ZW50 xM2N2Qd/ex/p5OHVirMmRxCG7uJ0weUO9XOdpmu6Ptkjp7HT1K1jlCw7WeUanDSwHlYz amIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=822k5Epy3abApFDOTZu4ecH2CXFgELBLfTdDkDS98hQ=; b=tw4jOApasiD2Uenlyh2mR1X6HIRQ5zZeE4Onlwe3jY99Li2LrvzX2Tj7zf9GogVEFq S7HhtOwA3Qykgk3MwzWJLkyTrHWhUZ2VzHXUfwYpKHZg5FiGkIE+JDF3r3cpBtIf1YCa WD7prIgnDgO7Xt0op1i56FlISxRuVYYiX/A47KNyc7XGsAt75S4OwkJxO1azYfWGxZGb C4kGoo+3kI32//jI/OXyCd2YZSh9w7qMivij6E44gxo4AeATGc8xWPIyXZbEVQv4JKLt muNGkeUJXltcuBjif7UCa07nmTKPtv8jmn7iLakqJJYKUCEAfMf0HKIGnc+IAKMygRmj tO+w== X-Gm-Message-State: APjAAAWLgSMxh7Xeqnmgmc1R/GxnBwRFEvCpw9hYO4StXGQ7+PtEUVN0 6XqjEUje2lx32zMrLovZfvULJ13Y0ww= X-Google-Smtp-Source: APXvYqw/5GsUVQOdSyRVetJCLmdv+tqMNvdt+5JdIkMY400vCmZLPkeSRZE80menfz5tA9UuowMhGQ== X-Received: by 2002:a62:2b8b:: with SMTP id r133mr4134082pfr.7.1573647299269; Wed, 13 Nov 2019 04:14:59 -0800 (PST) Received: from 192-168-1-6.tpgi.com.au (14-200-204-163.tpgi.com.au. [14.200.204.163]) by smtp.gmail.com with ESMTPSA id s3sm2461172pjn.21.2019.11.13.04.14.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Nov 2019 04:14:58 -0800 (PST) From: Oliver O'Halloran To: skiboot@lists.ozlabs.org Date: Wed, 13 Nov 2019 23:14:22 +1100 Message-Id: <20191113121422.20503-2-oohall@gmail.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20191113121422.20503-1-oohall@gmail.com> References: <20191113121422.20503-1-oohall@gmail.com> MIME-Version: 1.0 Subject: [Skiboot] [PATCH v2 2/2] tests: Squash __attrconst related warnings X-BeenThere: skiboot@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Mailing list for skiboot development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: skiboot-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Skiboot" Currently we get a warning because in some of the test stub functions: [ HOSTCC ] hw/test/phys-map-test.c In file included from hw/test/phys-map-test.c:8: hw/test/../../core/test/stubs.c:78:1: warning: ‘const’ attribute on function returning ‘void’ [-Wattributes] 78 | { | ^ I'm pretty sure we added that __attrconst to squash a warning with an earlier GCC, then they went an added a warning for the "fix." I love compilers. Signed-off-by: Oliver O'Halloran --- core/test/stubs.c | 4 ++-- hdata/test/stubs.c | 6 ++---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/core/test/stubs.c b/core/test/stubs.c index 38e3d51793dd..2c2992796fb3 100644 --- a/core/test/stubs.c +++ b/core/test/stubs.c @@ -67,14 +67,14 @@ struct cpu_job *__cpu_queue_job(struct cpu_thread *cpu, return NULL; } -void __attrconst cpu_wait_job(struct cpu_job *job, bool free_it) +void cpu_wait_job(struct cpu_job *job, bool free_it) { (void)job; (void)free_it; return; } -void __attrconst cpu_process_local_jobs(void) +void cpu_process_local_jobs(void) { } diff --git a/hdata/test/stubs.c b/hdata/test/stubs.c index 1d924b6c479e..107f94811670 100644 --- a/hdata/test/stubs.c +++ b/hdata/test/stubs.c @@ -105,8 +105,7 @@ struct cpu_job *__cpu_queue_job(struct cpu_thread *cpu, } void cpu_wait_job(struct cpu_job *job, bool free_it); - -void __attrconst cpu_wait_job(struct cpu_job *job, bool free_it) +void cpu_wait_job(struct cpu_job *job, bool free_it) { (void)job; (void)free_it; @@ -114,8 +113,7 @@ void __attrconst cpu_wait_job(struct cpu_job *job, bool free_it) } void cpu_process_local_jobs(void); - -void __attrconst cpu_process_local_jobs(void) +void cpu_process_local_jobs(void) { }