From patchwork Fri May 22 02:34:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 187122 Delivered-To: patch@linaro.org Received: by 2002:a92:5b0a:0:0:0:0:0 with SMTP id p10csp2103662ilb; Thu, 21 May 2020 19:38:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx73jcgce8b+wFGiH/chviz4PEqxhbpzZTn5kdUt04zr17dR0I/d1mJkHI0mRzxBmp0vWy5 X-Received: by 2002:a37:7086:: with SMTP id l128mr12583374qkc.61.1590115089976; Thu, 21 May 2020 19:38:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590115089; cv=none; d=google.com; s=arc-20160816; b=mAR5yTCkMzGRfhJRUfZoFcZDSq7gz1f0FcfG8kyLp+uHhUFJpoPTzrejqzkwqKqTxt y1DKTuFcC2QGE8gK454sNzb/ZkF+ulgEvhpLj4wpNODbNWQ0FMMGco6DoME/pPu3lQjz naGaPx++iXBCv4X5yqtXQ66OmnVms5KMBfN6GA4UtOkhWRdcmTZtSiWpGbOKk4g7xHhy jM43ku8DBdj4JHLFfEAscLQmDNPN6FlDodbIKhIGEKJ722GDBAVA9ImH0ZJZQQS1+pLj 0REM5Lrwc+mNMq7XKf9gYQFDMxz9/PJBhR7BFFeEd5PoypdyALHIlhGZtuOuLyqCHWsV 4LNg== 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=CpTMXKHcoiytZRid5gwjf0q94Tx9HJK5chSS8lZYa0c=; b=DI7Y/X55yhxXFAR2ijzWucGwxqXlPG63B47gTj+cBSgCzj/pW5vRPvS6Z566ZTGKwi KujRi49sneRLHWOkZNCTqUw2f3NP6uKAx4AKfKJ26ydqY0EgsJByAO/2tijtfhUUVq5Y lyX+06O4Oj2iKphstkuVQFROpteOfArG87D8HM1Fao+AKf2HRRup/4JYSQgb8ozoT+no vg+VMyTSZ1CVRj2gEbeIM/aVnHCDrEqyMNn6itOqnPXfTuUF9SEuFSCPAGce4a9obuv0 llti67q4gf68oFibPmCymaz6PI8csewiusttoVDrS4qv3YwiJ60ZA/V02pXLG1TmoXik StNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=GeKIMm9L; 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 j17si358837qki.243.2020.05.21.19.38.09 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 21 May 2020 19:38:09 -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=GeKIMm9L; 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]:59652 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jbxZZ-0002IZ-FL for patch@linaro.org; Thu, 21 May 2020 22:38:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48190) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jbxWO-0002F3-4N for qemu-devel@nongnu.org; Thu, 21 May 2020 22:34:52 -0400 Received: from mail-pl1-x644.google.com ([2607:f8b0:4864:20::644]:45078) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jbxWN-00056N-A6 for qemu-devel@nongnu.org; Thu, 21 May 2020 22:34:51 -0400 Received: by mail-pl1-x644.google.com with SMTP id u22so3800078plq.12 for ; Thu, 21 May 2020 19:34:50 -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=CpTMXKHcoiytZRid5gwjf0q94Tx9HJK5chSS8lZYa0c=; b=GeKIMm9LF31aLach7PhMa4JuTyVQ84YVnwA6UrIdpVF4hJCo3uo8D2tmNJG/AG6YNq 2QxTq8MfklRNjSYR8+Z4KwqbHTcBDi4dQOBJ9LLfs4m7kwai/Kpn4FaQtx0xJZkj73L7 hVFJKdkPE5d5nxtYIWauEHlhKhlU9UCN4efgC97wrWI0W5iZTdlLJK1q0pb6aMYjsAxU wqW3fBGpuJFohfytqvhxS4wjqDhNN+Ytb2DwzwrhHVrvQ46y2RYHSW0LGumBsyySz/t+ Q9MsLO+Q1VLj90bUlYqGoqFFP8N1IFotq7etyfQod3OAavYuB9Kf66AncMwfRRlD/9kn 9Uyg== 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=CpTMXKHcoiytZRid5gwjf0q94Tx9HJK5chSS8lZYa0c=; b=UdOUX4K50eusC1sLJsy5MM7SlGbYJV7xYS/pjfzvBq7wFIhU0SqoMg7ghLxqeulb3w cs/MF/wO+snqsJCjN3gAhevTu+/ZW1/ElS/sDNk7xz457p593sqtfxtdiuPdwEkVU32A 3VZ6X8oy7lkqZdxqWZVoeAl6F4rBokNn0cSqAf24M0TFzeSIXbRfQXNIZ9Il87/hXnyL /gnw3RePT4TIWAq2z3TwMpHk6pps4xBD+s5jWusGwtMUt4hXWFhvv21Qxqo71dDXU9qK 5FNa7TGOtOPJxGuduWK2YxSz3UdBqAp3/mofuOCG87evOYSzJD0MP0tPFbp8A2o8T61T z5Gg== X-Gm-Message-State: AOAM5311f6m0a1pzW5BkBH3aVrjw/aPo1VBwl36R0edRL30Db8zWAmqc 7EN48WzbJerul/jK1O5hO1GbEaN7RD4= X-Received: by 2002:a17:90a:fc8b:: with SMTP id ci11mr1786607pjb.40.1590114889697; Thu, 21 May 2020 19:34:49 -0700 (PDT) Received: from localhost.localdomain (174-21-143-238.tukw.qwest.net. [174.21.143.238]) by smtp.gmail.com with ESMTPSA id gt10sm5443755pjb.30.2020.05.21.19.34.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 May 2020 19:34:48 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH v3 06/25] Make some risu.c symbols static Date: Thu, 21 May 2020 19:34:21 -0700 Message-Id: <20200522023440.26261-7-richard.henderson@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200522023440.26261-1-richard.henderson@linaro.org> References: <20200522023440.26261-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::644; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x644.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: alex.bennee@linaro.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" These are unused in other translation units. Reviewed-by: Alex Bennée Signed-off-by: Richard Henderson --- risu.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) -- 2.20.1 diff --git a/risu.c b/risu.c index 26dc116..ab17c71 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 ] "