From patchwork Tue Jun 27 17:04:06 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dave Martin X-Patchwork-Id: 781289 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3wxsl74Dymz9s5L for ; Wed, 28 Jun 2017 03:06:11 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="X2z1CP+K"; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=cvNjWgt5Z7YDFGzRqPXu3wrFtuCwPvE hKSBO/HUECnYOTIPuBEM+7CPgFnsLvB5DT3Odf8xXEswOmxRMlhubeQ2rhBXJrlQ 7vZj9lDAtBuuYTk2CBFT/xRiSB6ZrkYLRrGwTcYKr4l9XP+otzAivXQZwT8X1XhM d7JSWw/2vpUA= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=BlrbyBblFb3/6QvqjmLKTHcl2zg=; b=X2z1C P+KvoidzeVBwfQkIkNGrI3mSWCuNbNKgwbdnoJHL4FNWFIs6x69J1EjMYsCU6vmP anBTDHVHb5W9yihHhYh/lFmzr4OJhjoPm9hvUo7WLEUbMFFby+Je6S23rF2t902h N2hU0BKeorNC4Oic0Hi6mOvJA2pd1RH1tTgd7w= Received: (qmail 37189 invoked by alias); 27 Jun 2017 17:05:27 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 37107 invoked by uid 89); 27 Jun 2017 17:05:27 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RP_MATCHES_RCVD, SPF_PASS autolearn=ham version=3.3.2 spammy=Hx-spam-relays-external:ESMTPA X-Spam-User: qpsmtpd, 2 recipients X-HELO: foss.arm.com From: Dave Martin To: linux-arm-kernel@lists.infradead.org Cc: Russell King , Edmund Grimley-Evans , libc-alpha@sourceware.org, gdb@sourceware.org Subject: [RFC PATCH v2 1/2] ARM: iwmmxt: Add missing __user annotations to sigframe accessors Date: Tue, 27 Jun 2017 18:04:06 +0100 Message-Id: <1498583067-14178-2-git-send-email-Dave.Martin@arm.com> In-Reply-To: <1498583067-14178-1-git-send-email-Dave.Martin@arm.com> References: <1498583067-14178-1-git-send-email-Dave.Martin@arm.com> preserve_iwmmxt_context() and restore_iwmmxt_context() lack __user accessors on their arguments pointing to the user signal frame. There does not be appear to be a bug here, but this omission is inconsistent with the crunch and vfp sigframe access functions. This patch adds the annotations, for consistency. Signed-off-by: Dave Martin --- arch/arm/kernel/signal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/kernel/signal.c b/arch/arm/kernel/signal.c index 7b8f214..8f06480 100644 --- a/arch/arm/kernel/signal.c +++ b/arch/arm/kernel/signal.c @@ -59,7 +59,7 @@ static int restore_crunch_context(struct crunch_sigframe __user *frame) #ifdef CONFIG_IWMMXT -static int preserve_iwmmxt_context(struct iwmmxt_sigframe *frame) +static int preserve_iwmmxt_context(struct iwmmxt_sigframe __user *frame) { char kbuf[sizeof(*frame) + 8]; struct iwmmxt_sigframe *kframe; @@ -72,7 +72,7 @@ static int preserve_iwmmxt_context(struct iwmmxt_sigframe *frame) return __copy_to_user(frame, kframe, sizeof(*frame)); } -static int restore_iwmmxt_context(struct iwmmxt_sigframe *frame) +static int restore_iwmmxt_context(struct iwmmxt_sigframe __user *frame) { char kbuf[sizeof(*frame) + 8]; struct iwmmxt_sigframe *kframe;