Received: by 2002:a25:ef43:0:0:0:0:0 with SMTP id w3csp1655184ybm; Sat, 30 May 2020 16:21:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzgVjECn/uUxhRUn/Pz+Z0jIOfLr5o2vs6uFE3vQw4uUGKEDRnkwt5C4OlF5Mp6DjPK6pL8 X-Received: by 2002:aa7:d0c5:: with SMTP id u5mr14599062edo.51.1590880891500; Sat, 30 May 2020 16:21:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590880891; cv=none; d=google.com; s=arc-20160816; b=OYhsdH5wZCIb0agS17zT4wV5iuPToPvmHKFlT2UzQdjHFofteN3z83aoVbefNW/HFX jozufAHotFrjeyrmoRLvkBwcZrbbprxBvz0UeQ48q1AT7Wkn3vnJkX4Q+2kdHoQdZDiL l3GS573g0mJ69kf7gjP1LKJf3xuRtSQ/GSxbJsn22tTpO71/+r/JEiSs5ewVoidu7Kvv 2CqtLqq3XlpEd6G3AEY9tkFPawn9HhY+ZoOBLa6fzGZSNdJkXczGxLBcwT93bfuf/arf yIEklFbShkWx0i5r4C1i0P33mD7TyyyNovnO6GhF4PG4uAddO0N375BBvFf6jC4Kx5RP BG5g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:subject:from:references:in-reply-to :message-id:cc:to; bh=1zcX0Oo97V6bfEaSHzwROqq8ZGGEO6DKjomc+E4Xsng=; b=zuV5tn6vV3ed7VY7J7kwzA3BxwYAmWbWXHvFWHAG0m0Qr7PyXDsPNCr7YRRXi4oVHA LBKo2iq4UsSdHdCZy0BULoNBm6hErylXVeKDkNpvJXivsFXAov4vWz3GqPYJk+8LJeR+ up8IAI8jxWRTjHhYA2x5g3FLQ2xS/rxP/kafWxd/YqQzKkibd70IqrgYY4mbQL6pICVB gjKfUYYsaguTyGg06h6WpBOtDoyodv7hi0aG5bC/gD0UbSSYd3mdsz75byMWD+rCW/qj HtyxsAuNefCXN1URXtv1R/d8rIlu52MT93eE0PiO6gvF98euVIc2+pr/CxKMziqHZP16 u2uw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o18si6348112eju.33.2020.05.30.16.21.08; Sat, 30 May 2020 16:21:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729564AbgE3XQa (ORCPT + 99 others); Sat, 30 May 2020 19:16:30 -0400 Received: from kvm5.telegraphics.com.au ([98.124.60.144]:51084 "EHLO kvm5.telegraphics.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729562AbgE3XQ3 (ORCPT ); Sat, 30 May 2020 19:16:29 -0400 Received: by kvm5.telegraphics.com.au (Postfix, from userid 502) id C614B27F1F; Sat, 30 May 2020 19:16:28 -0400 (EDT) To: Geert Uytterhoeven Cc: Joshua Thompson , linux-m68k@lists.linux-m68k.org, linux-kernel@vger.kernel.org Message-Id: <8e35df4d193b082cb6285b1f30c949ff7e30e99e.1590880333.git.fthain@telegraphics.com.au> In-Reply-To: References: From: Finn Thain Subject: [PATCH 3/4] m68k/mac: Don't send uninitialized data in IOP message reply Date: Sun, 31 May 2020 09:12:13 +1000 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Clear the message reply before calling iop_complete(). This code path is not normally executed but should that happen let's arrange for consistent behaviour from the IOP. Cc: Joshua Thompson Tested-by: Stan Johnson Signed-off-by: Finn Thain --- arch/m68k/mac/iop.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/m68k/mac/iop.c b/arch/m68k/mac/iop.c index 5fc3b59ba811..8d6946edf2c8 100644 --- a/arch/m68k/mac/iop.c +++ b/arch/m68k/mac/iop.c @@ -449,6 +449,7 @@ static void iop_handle_recv(uint iop_num, uint chan) iop_pr_debug("unclaimed message on iop_num %d chan %d\n", iop_num, chan); iop_pr_debug("%*ph\n", IOP_MSG_LEN, msg->message); + memset(msg->reply, 0, IOP_MSG_LEN); iop_complete_message(msg); } } -- 2.26.2