From patchwork Mon Jun 11 17:46:47 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Huth X-Patchwork-Id: 10458561 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 7E2DE6020F for ; Mon, 11 Jun 2018 17:46:56 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5CE7628571 for ; Mon, 11 Jun 2018 17:46:56 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5117028574; Mon, 11 Jun 2018 17:46:56 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0928E28571 for ; Mon, 11 Jun 2018 17:46:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932292AbeFKRqx (ORCPT ); Mon, 11 Jun 2018 13:46:53 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:38720 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752122AbeFKRqx (ORCPT ); Mon, 11 Jun 2018 13:46:53 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D6852406E897; Mon, 11 Jun 2018 17:46:52 +0000 (UTC) Received: from thh440s.redhat.com (ovpn-116-112.ams2.redhat.com [10.36.116.112]) by smtp.corp.redhat.com (Postfix) with ESMTP id C083A100294C; Mon, 11 Jun 2018 17:46:48 +0000 (UTC) From: Thomas Huth To: kvm@vger.kernel.org, David Hildenbrand Cc: frankja@linux.ibm.com Subject: [kvm-unit-tests PATCH] s390x: Make s390x tests compilable with -Wmissing-prototypes and -Wstrict-prototypes Date: Mon, 11 Jun 2018 19:46:47 +0200 Message-Id: <1528739207-29963-1-git-send-email-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.7]); Mon, 11 Jun 2018 17:46:52 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.7]); Mon, 11 Jun 2018 17:46:52 +0000 (UTC) for IP:'10.11.54.3' DOMAIN:'int-mx03.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'thuth@redhat.com' RCPT:'' Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Provide prototypes where needed and avoid prototypes that do not specify the function parameters. Signed-off-by: Thomas Huth Reviewed-by: David Hildenbrand --- lib/s390x/io.c | 6 ++++-- s390x/gs.c | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/s390x/io.c b/lib/s390x/io.c index eb4d171..17d5fc7 100644 --- a/lib/s390x/io.c +++ b/lib/s390x/io.c @@ -21,6 +21,8 @@ uint8_t stfl_bytes[NR_STFL_BYTES] __attribute__((aligned(8))); static struct spinlock lock; +void setup(void); + void puts(const char *s) { spin_lock(&lock); @@ -28,7 +30,7 @@ void puts(const char *s) spin_unlock(&lock); } -static void sigp_stop() +static void sigp_stop(void) { register unsigned long status asm ("1") = 0; register unsigned long cpu asm ("2") = 0; @@ -38,7 +40,7 @@ static void sigp_stop() : "+d" (status) : "d" (cpu), "d" (5) : "cc"); } -void setup() +void setup(void) { setup_args_progname(ipl_args); setup_facilities(); diff --git a/s390x/gs.c b/s390x/gs.c index b9b19dd..0cba5dd 100644 --- a/s390x/gs.c +++ b/s390x/gs.c @@ -64,6 +64,8 @@ static struct gs_cb gs_cb; static struct gs_epl gs_epl; static unsigned long gs_area = 0x2000000; +void gs_handler(struct gs_cb *this_cb); + static inline void load_gs_cb(struct gs_cb *gs_cb) { asm volatile(".insn rxy,0xe3000000004d,0,%0" : : "Q" (*gs_cb));