From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by sourceware.org (Postfix) with ESMTPS id 65DC9386FC37 for ; Wed, 19 May 2021 10:46:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 65DC9386FC37 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tdevries@suse.de X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 84573AE63; Wed, 19 May 2021 10:46:17 +0000 (UTC) Date: Wed, 19 May 2021 12:46:16 +0200 From: Tom de Vries To: gdb-patches@sourceware.org, andrew.burgess@embecosm.com, vapier@gentoo.org Subject: [PATCH] sim: ppc: fix some more Wunused-function warnings Message-ID: <20210519104614.GA9251@delia> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) X-Spam-Status: No, score=-12.2 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_STATUS, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 May 2021 10:46:19 -0000 Hi, When compiling with --enable-werror and CFLAGS="-O0 -g -Wall", we run into: ... In file included from src/sim/ppc/cpu.h:26:0, from src/sim/ppc/mon.c:25, from src/sim/ppc/inline.c:64, from idecode.c:26: src/sim/ppc/device.h:788:8: error: 'device_event_queue_deschedule' \ declared 'static' but never defined [-Werror=unused-function] (void) device_event_queue_deschedule ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ... This seems to be caused by the fact that the function is declared using INLINE_EVENT instead of INLINE_DEVICE. Fix this and a similar error in the same file. Any comments? Thanks, - Tom sim: ppc: fix some more Wunused-function warnings --- sim/ppc/device.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sim/ppc/device.h b/sim/ppc/device.h index 6fd198de70d..353358761b5 100644 --- a/sim/ppc/device.h +++ b/sim/ppc/device.h @@ -784,12 +784,12 @@ INLINE_DEVICE\ device_event_handler *handler, void *data); -INLINE_EVENTS\ +INLINE_DEVICE\ (void) device_event_queue_deschedule (device *me, event_entry_tag event_to_remove); -INLINE_EVENTS\ +INLINE_DEVICE\ (signed64) device_event_queue_time (device *me);