From patchwork Thu Oct 3 05:47:46 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 2981271 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id EB8ACBFF0C for ; Thu, 3 Oct 2013 05:50:22 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2FFAF2030E for ; Thu, 3 Oct 2013 05:50:22 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 3FC41202FE for ; Thu, 3 Oct 2013 05:50:21 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VRbnA-0003K3-89; Thu, 03 Oct 2013 05:49:40 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1VRbn1-0000aG-7c; Thu, 03 Oct 2013 05:49:31 +0000 Received: from mail-pa0-f51.google.com ([209.85.220.51]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VRbmv-0000Xi-Hc for linux-arm-kernel@lists.infradead.org; Thu, 03 Oct 2013 05:49:26 +0000 Received: by mail-pa0-f51.google.com with SMTP id kp14so2101901pab.10 for ; Wed, 02 Oct 2013 22:49:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=ClEKKE5GPYWXKL7XzydEVdwDH1QmwjjPKJd0ffLv+fU=; b=CGwk/1lkIWI4LcudZv2rqwGQuFoBflUUsOzcCUvEqLGPBprHhpDf/bi+J9fVgTmViE thF4/Kc4+LeBeXlw0xea36vtu7cbxm72jV9X96UufP/8dfU5syySz1ABe/GIIt2vYG3/ 8MVebnSR+2P/4VYzj0N0QxWZ/pkIEB0/mCCW3Yt9Onkn0rMlSDDNGYzfwWXtRwH2G/zt ZzCA52w9NhIYQTslT/pqNlGGJ2Tm43XVSkcMTEX4O05XbnCnmQBSgjw2QS05SKbpQVEu 1JwVl7M8+05NvI/My0LQYW0y87JzV4kKMsfRDgWZa7Ty4YKuSJeX9cRLm89SoTqTEgRG R4og== X-Gm-Message-State: ALoCoQkLv92iBIq3cAAcp2G3FJI8Uhj8weH9Rp/jrFVbhA75QmVXk2krGXKAt5SHDl7L2kJJX/vj X-Received: by 10.68.223.131 with SMTP id qu3mr6683905pbc.4.1380779344229; Wed, 02 Oct 2013 22:49:04 -0700 (PDT) Received: from localhost.localdomain (KD182249095123.au-net.ne.jp. [182.249.95.123]) by mx.google.com with ESMTPSA id qw8sm5769184pbb.27.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 02 Oct 2013 22:49:03 -0700 (PDT) From: AKASHI Takahiro To: catalin.marinas@arm.com, will.deacon@arm.com Subject: [PATCH v2 3/3] asm-generic: syscall_get/set_arguments accept zero for number of arguments Date: Thu, 3 Oct 2013 14:47:46 +0900 Message-Id: <1380779266-11753-4-git-send-email-takahiro.akashi@linaro.org> X-Mailer: git-send-email 1.8.1.2 In-Reply-To: <1380779266-11753-1-git-send-email-takahiro.akashi@linaro.org> References: <1380779266-11753-1-git-send-email-takahiro.akashi@linaro.org> In-Reply-To: <1380605584-22125-git-send-email-takahiro.akashi@linaro.org> References: <1380605584-22125-git-send-email-takahiro.akashi@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20131003_014925_677994_BFAF81FE X-CRM114-Status: GOOD ( 11.95 ) X-Spam-Score: -2.6 (--) Cc: AKASHI Takahiro , linaro-kernel@lists.linaro.org, linux-arm-kernel@lists.infradead.org, mcgrathr@chromium.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP There is a possibility of calling syscall_get_arguments() with zero as 'number of arguments(n)' in ftrace_syscall_enter(). The comments in syscall_get_argumets() as well as syscall_set_arugments() are corrected to clarify that. Signed-off-by: AKASHI Takahiro Acked-by: Will Deacon --- include/asm-generic/syscall.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/asm-generic/syscall.h b/include/asm-generic/syscall.h index 5b09392..49b35ab 100644 --- a/include/asm-generic/syscall.h +++ b/include/asm-generic/syscall.h @@ -106,7 +106,7 @@ void syscall_set_return_value(struct task_struct *task, struct pt_regs *regs, * @task: task of interest, must be blocked * @regs: task_pt_regs() of @task * @i: argument index [0,5] - * @n: number of arguments; n+i must be [1,6]. + * @n: number of arguments; n+i must be [0,6]. * @args: array filled with argument values * * Fetches @n arguments to the system call starting with the @i'th argument @@ -126,7 +126,7 @@ void syscall_get_arguments(struct task_struct *task, struct pt_regs *regs, * @task: task of interest, must be in system call entry tracing * @regs: task_pt_regs() of @task * @i: argument index [0,5] - * @n: number of arguments; n+i must be [1,6]. + * @n: number of arguments; n+i must be [0,6]. * @args: array of argument values to store * * Changes @n arguments to the system call starting with the @i'th argument.