From patchwork Tue Apr 28 18:25:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 226862 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3935FC83004 for ; Tue, 28 Apr 2020 18:43:51 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 171EB20730 for ; Tue, 28 Apr 2020 18:43:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1588099431; bh=aA6z5Im+fckIqDKy07hv31qtqVKsbkx6P9lhSktTShc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=dWv0VcqQzuYso+v3jUSvfGQPoX90sEWJLGAMRridSkxkNJaVDUiMqhWc0a7gnPLON s60mkG64njfbTP2ZVGyUxRXyBpoQuDTuUnh+2izvIBqBrahOeNLJPT3gm+MPEmCV0Z 5Q/ZjEqOzvrFMAGs+fZJZAgni+dFHrAkMXtW/VRE= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730802AbgD1Snu (ORCPT ); Tue, 28 Apr 2020 14:43:50 -0400 Received: from mail.kernel.org ([198.145.29.99]:36486 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731278AbgD1Sns (ORCPT ); Tue, 28 Apr 2020 14:43:48 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 53CE420730; Tue, 28 Apr 2020 18:43:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1588099427; bh=aA6z5Im+fckIqDKy07hv31qtqVKsbkx6P9lhSktTShc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ad0e4e2gSOfp1gLFzwiwXvHyItMxvXmqzS6ignJOiafIR1LkSDA2AMAJvsSUoPPU3 kQUQVTbgMecsb8+UU043BrHFDwicYc0jgpAjSdv+oiCXOxOn6T69aGNXkuSa4/Qidg Bjr8om+R1pVAdgPEP6LovFbt8n4wLJjbz6FdxHVU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Oliver Neukum Subject: [PATCH 5.4 147/168] UAS: no use logging any details in case of ENODEV Date: Tue, 28 Apr 2020 20:25:21 +0200 Message-Id: <20200428182250.173811338@linuxfoundation.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200428182231.704304409@linuxfoundation.org> References: <20200428182231.704304409@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Oliver Neukum commit 5963dec98dc52d52476390485f07a29c30c6a582 upstream. Once a device is gone, the internal state does not matter anymore. There is no need to spam the logs. Signed-off-by: Oliver Neukum Cc: stable Fixes: 326349f824619 ("uas: add dead request list") Link: https://lore.kernel.org/r/20200415141750.811-1-oneukum@suse.com Signed-off-by: Greg Kroah-Hartman --- drivers/usb/storage/uas.c | 3 +++ 1 file changed, 3 insertions(+) --- a/drivers/usb/storage/uas.c +++ b/drivers/usb/storage/uas.c @@ -190,6 +190,9 @@ static void uas_log_cmd_state(struct scs struct uas_cmd_info *ci = (void *)&cmnd->SCp; struct uas_cmd_info *cmdinfo = (void *)&cmnd->SCp; + if (status == -ENODEV) /* too late */ + return; + scmd_printk(KERN_INFO, cmnd, "%s %d uas-tag %d inflight:%s%s%s%s%s%s%s%s%s%s%s%s ", prefix, status, cmdinfo->uas_tag,