From patchwork Tue May 19 02:53:44 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 186905 Delivered-To: patch@linaro.org Received: by 2002:a92:5b0a:0:0:0:0:0 with SMTP id p10csp3446391ilb; Mon, 18 May 2020 19:54:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzjR27yGzKv1MjqMInL/YP1TelRWM8a2a09orcZNiz4FsFmC7tuPtknmN6aMTuVeXV74MPK X-Received: by 2002:ac8:45d5:: with SMTP id e21mr15326752qto.336.1589856865954; Mon, 18 May 2020 19:54:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589856865; cv=none; d=google.com; s=arc-20160816; b=EJ+LxJYSbdoduN593e7+Aj/yJ/v1mIq5hbPl1/E2cj41WcGs+mOTDc1x22td7wYYwW VfPM3a6yD8q1TVvuOU2fGFE6R5oC79ows7tBhMdZkrZSjY+mPePWYStefdBQZmghZ5Ic ByIBg6pyLRLYNFgBA/W+vMu1VC/kjTdH0T/cDnKPU6bENTHbFewYCj/B2ytYRHMpreNz YBKNNKfOdm9Fa76mAYNcQ8/lRWDMHhgwJ95OasZl6CVe9O7JsNgEms3R15c4Hm1K3xcr 1lox/7X6UxRH/HYP2SQGafdWakoVj2lkBbNiz8In89jdFR0ty9wmqCCl7GotgGVyi1U5 ctlw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=g+TVWgWDZ8IS/kHh58SBa/DlK1/0pDXOV4De7Fp0uPY=; b=BbqxIWH9bg7HC5P1h59C1Pf2PqmUS/ZSMEgjUBt7+HAuHP6nbc0bm74cfkAHcf01YU zlknaHEHZ5UfZsQK0strb8QYxieDW/k4DVbRSwVpeJnA5Mv6xddN4+Wi+CNBoT1Fb9+s vBnaIQOnB1DbXOIIjigpnYcKEWmj+uUFpj02VlYSK03WOlLoOdg7+6tnAZq9Bmp2wpGx 7O6HaOYvOi6ja/5HJ4dOi+08fpSQmrGvHP+XHY5lHtefng3Lj34sBA0vgnNYDC+QT1+v OjkmUfWuVkBY/AYbh33+bxKYulAPiLcv/pGD80vIPGYs+OGWn6ij+hwio0pMFOlX/pR5 26Vg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ArXsA2Ra; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id l10si6884880qtf.108.2020.05.18.19.54.25 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 18 May 2020 19:54:25 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ArXsA2Ra; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:55134 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jasOf-0005NL-C0 for patch@linaro.org; Mon, 18 May 2020 22:54:25 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:46824) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jasON-0005HG-QE for qemu-devel@nongnu.org; Mon, 18 May 2020 22:54:07 -0400 Received: from mail-pj1-x1031.google.com ([2607:f8b0:4864:20::1031]:39353) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jasOM-0002Q0-V2 for qemu-devel@nongnu.org; Mon, 18 May 2020 22:54:07 -0400 Received: by mail-pj1-x1031.google.com with SMTP id n15so714445pjt.4 for ; Mon, 18 May 2020 19:54:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=g+TVWgWDZ8IS/kHh58SBa/DlK1/0pDXOV4De7Fp0uPY=; b=ArXsA2Rao8ftzq6X3V6uaru9KibGQ2RCqIoi28zZccff4i0Ejkl8CdGXSZALFz7BYf frn1rg2yv/zJIJUCHp9C/HP+N6ntKqClWMD+BJHi+wb+FuSXjomtdNTT4Ic0JHSkaQ8r v2hIvirLQG/VyflOa0OeDKsGKgs+yvn+l/ITkqFHwsCoR1Y8vMbehAwhkEeGrY0NURae amwyz/YUFIxIVePbIsntFNAp2wvzJpePeUv3pxgNR6BmNLQQ0nJZN9csxBhMT/h+lq6G NxrRY7uLvb/TWzuYFs72OT3e6FKrLMV09wN9ebgXahrQj6zVIemvkV5BJLCNQL/C8KKV Q5rw== 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=g+TVWgWDZ8IS/kHh58SBa/DlK1/0pDXOV4De7Fp0uPY=; b=rD3tlXUslys9HdxvyM3uPCsMz6Y+asEXqlKkmS40FhSFHanyjwlInCzQvojcR3X43V 9hcvXaMq+qEN+JrMO3p7jOpKeqgvZP5I8MJryFVEWF3nYhjcJzJPOOLvhOjrdpTK/4D8 WGbBXYQ9sgCIDWqx0TUwfab3pMO4cb14LbcAJBMjiZJABnk4fDioRn5MPEoREtVGQ0mr Zr9epIElTbxKVdSSoEI0mI9wJz8U43N/EXomI0xB0B2PQ0MdQap+4IHhtxtB9wFMiCYB zXwTlZYYOHpknwz50sKk2reujugWMGQyG/l09XQ0HSm5DANEDGY8+SWoeM/bv/ZWWMt+ VOBw== X-Gm-Message-State: AOAM532rUqvb0pexDT8cm0j6m1a15fMiwPoP9y6MzoudZJhgH3mAe2w3 /8iJspeIYkz71jN1nVLYqHt4tjxNu9M= X-Received: by 2002:a17:90a:246d:: with SMTP id h100mr2435084pje.21.1589856845228; Mon, 18 May 2020 19:54:05 -0700 (PDT) Received: from localhost.localdomain (174-21-143-238.tukw.qwest.net. [174.21.143.238]) by smtp.gmail.com with ESMTPSA id a2sm8772418pgh.57.2020.05.18.19.54.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 May 2020 19:54:04 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [RISU v2 06/17] Make some risu.c symbols static Date: Mon, 18 May 2020 19:53:44 -0700 Message-Id: <20200519025355.4420-7-richard.henderson@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200519025355.4420-1-richard.henderson@linaro.org> References: <20200519025355.4420-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::1031; envelope-from=richard.henderson@linaro.org; helo=mail-pj1-x1031.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: peter.maydell@linaro.org, alex.bennee@linaro.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" These are unused in other translation units. Signed-off-by: Richard Henderson --- risu.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) -- 2.20.1 Reviewed-by: Alex Bennée diff --git a/risu.c b/risu.c index 979341c..24ada8f 100644 --- a/risu.c +++ b/risu.c @@ -31,18 +31,18 @@ void *memblock; static int comm_fd; -bool trace; -size_t signal_count; +static bool trace; +static size_t signal_count; #ifdef HAVE_ZLIB #include -gzFile gz_trace_file; +static gzFile gz_trace_file; #define TRACE_TYPE "compressed" #else #define TRACE_TYPE "uncompressed" #endif -sigjmp_buf jmpbuf; +static sigjmp_buf jmpbuf; #define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0])) @@ -113,7 +113,7 @@ void respond_trace(int r) } } -void master_sigill(int sig, siginfo_t *si, void *uc) +static void master_sigill(int sig, siginfo_t *si, void *uc) { int r; signal_count++; @@ -135,7 +135,7 @@ void master_sigill(int sig, siginfo_t *si, void *uc) } } -void apprentice_sigill(int sig, siginfo_t *si, void *uc) +static void apprentice_sigill(int sig, siginfo_t *si, void *uc) { int r; signal_count++; @@ -180,9 +180,9 @@ static void set_sigill_handler(void (*fn) (int, siginfo_t *, void *)) typedef void entrypoint_fn(void); uintptr_t image_start_address; -entrypoint_fn *image_start; +static entrypoint_fn *image_start; -void load_image(const char *imgfile) +static void load_image(const char *imgfile) { /* Load image file into memory as executable */ struct stat st; @@ -214,7 +214,7 @@ void load_image(const char *imgfile) image_start_address = (uintptr_t) addr; } -int master(void) +static int master(void) { if (sigsetjmp(jmpbuf, 1)) { #ifdef HAVE_ZLIB @@ -240,7 +240,7 @@ int master(void) return EXIT_FAILURE; } -int apprentice(void) +static int apprentice(void) { if (sigsetjmp(jmpbuf, 1)) { #ifdef HAVE_ZLIB @@ -261,9 +261,9 @@ int apprentice(void) return EXIT_FAILURE; } -int ismaster; +static int ismaster; -void usage(void) +static void usage(void) { fprintf(stderr, "Usage: risu [--master] [--host ] [--port ] "