From patchwork Mon Jul 29 21:31:16 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stultz X-Patchwork-Id: 18650 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qc0-f197.google.com (mail-qc0-f197.google.com [209.85.216.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id E8A162486F for ; Mon, 29 Jul 2013 21:31:39 +0000 (UTC) Received: by mail-qc0-f197.google.com with SMTP id m15sf1633266qcq.0 for ; Mon, 29 Jul 2013 14:31:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-beenthere:x-forwarded-to:x-forwarded-for :delivered-to:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references:x-gm-message-state:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-google-group-id:list-post:list-help:list-archive:list-unsubscribe; bh=8NTRXQbt6IJND81aJSZuvqQR8c9OeNOdCFtu3IDDqTI=; b=Ffpdaw7Mq7dlKDpbpgKBnP6s+5QpuUK1++vCDIMaL7U5nWGDr9DqEtJ+Kb0eF40p6H GL849cM9+y8irUUu1kJnJCcGuL7q8x9UFx0GrfXRPXOSzAb5Vhi48G9xZxdPth3WcBPP ZxLcA8HloRZlVVtP5wKx0AX7LGMU6V2cMKb6tkMEng3HfIBdfjU3w4bjnfHNXK20XLZB GhdTfqrk7bDFMO4oRwmkTvKy9PcXl9yylmUmdtWdHeOx3NkBINiKG9pWq/TV3E1s4c6e FgQ5b6XII5IZGqn3Ut7+I6fhaNPSeMs1z7EcVGE59Ts+UDulompIdx1OMMlmBnh6e3Vx 4kXA== X-Received: by 10.236.123.173 with SMTP id v33mr31250620yhh.31.1375133499550; Mon, 29 Jul 2013 14:31:39 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.50.167 with SMTP id d7ls2283946qeo.25.gmail; Mon, 29 Jul 2013 14:31:39 -0700 (PDT) X-Received: by 10.220.249.7 with SMTP id mi7mr9139437vcb.72.1375133499364; Mon, 29 Jul 2013 14:31:39 -0700 (PDT) Received: from mail-vb0-f48.google.com (mail-vb0-f48.google.com [209.85.212.48]) by mx.google.com with ESMTPS id s17si3552067vcu.14.2013.07.29.14.31.39 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 29 Jul 2013 14:31:39 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.212.48 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.212.48; Received: by mail-vb0-f48.google.com with SMTP id w15so3260365vbf.35 for ; Mon, 29 Jul 2013 14:31:39 -0700 (PDT) X-Received: by 10.221.47.193 with SMTP id ut1mr9009416vcb.8.1375133499272; Mon, 29 Jul 2013 14:31:39 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.221.11.8 with SMTP id pc8csp138457vcb; Mon, 29 Jul 2013 14:31:38 -0700 (PDT) X-Received: by 10.68.12.97 with SMTP id x1mr2705828pbb.150.1375133498433; Mon, 29 Jul 2013 14:31:38 -0700 (PDT) Received: from mail-pb0-f47.google.com (mail-pb0-f47.google.com [209.85.160.47]) by mx.google.com with ESMTPS id ph3si46654963pbc.164.2013.07.29.14.31.38 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 29 Jul 2013 14:31:38 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.160.47 is neither permitted nor denied by best guess record for domain of john.stultz@linaro.org) client-ip=209.85.160.47; Received: by mail-pb0-f47.google.com with SMTP id rr13so5146487pbb.6 for ; Mon, 29 Jul 2013 14:31:38 -0700 (PDT) X-Received: by 10.69.14.165 with SMTP id fh5mr40311428pbd.81.1375133497970; Mon, 29 Jul 2013 14:31:37 -0700 (PDT) Received: from localhost.localdomain (c-67-170-153-23.hsd1.or.comcast.net. [67.170.153.23]) by mx.google.com with ESMTPSA id om2sm21331095pbc.30.2013.07.29.14.31.36 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 29 Jul 2013 14:31:37 -0700 (PDT) From: John Stultz To: Dhaval Giani Cc: John Stultz Subject: [PATCH 3/7] volatile-test: Fix build warnings Date: Mon, 29 Jul 2013 14:31:16 -0700 Message-Id: <1375133480-5597-4-git-send-email-john.stultz@linaro.org> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: <1375133480-5597-1-git-send-email-john.stultz@linaro.org> References: <1375133480-5597-1-git-send-email-john.stultz@linaro.org> X-Gm-Message-State: ALoCoQnUaI32KedeX7brD0AgOmk78RzYxOCNoyTRsmn3MPy/VqkGDvpLduF70PsbwSn40SNyBsUs X-Original-Sender: john.stultz@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.212.48 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Fix unused variable warnings. Signed-off-by: John Stultz --- volatile-test-signal.c | 2 -- volatile-test.c | 5 +---- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/volatile-test-signal.c b/volatile-test-signal.c index 8c60451..df2068f 100644 --- a/volatile-test-signal.c +++ b/volatile-test-signal.c @@ -121,7 +121,6 @@ int main(int argc, char *argv[]) int i, purged; char* file; int fd; - int is_file = 0; //signal(SIGBUS, signal_handler_sigbusy //sigaction(SIGBUS, sigaction_sigbusy, NULL); register_signal_handler(); @@ -129,7 +128,6 @@ int main(int argc, char *argv[]) file = argv[1]; fd = open(file, O_RDWR); vaddr = mmap(0, FULLSIZE, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0); - is_file = 1; } else { is_anon = 1; vaddr = malloc(FULLSIZE); diff --git a/volatile-test.c b/volatile-test.c index e23b55c..e148e19 100644 --- a/volatile-test.c +++ b/volatile-test.c @@ -83,12 +83,10 @@ int main(int argc, char *argv[]) int i, purged; char* file; int fd; - int is_file = 0; if (argc > 1) { file = argv[1]; fd = open(file, O_RDWR); vaddr = mmap(0, FULLSIZE, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0); - is_file = 1; } else { is_anon = 1; vaddr = malloc(FULLSIZE); @@ -116,8 +114,7 @@ int main(int argc, char *argv[]) // printf("%c\n", vaddr[i*CHUNK]); for(i=0; i < CHUNKNUM; ) { - int ret; - ret = mnovolatile(vaddr + (i*CHUNK), CHUNK, &purged); + mnovolatile(vaddr + (i*CHUNK), CHUNK, &purged); i+=2; }