Received: by 10.223.176.5 with SMTP id f5csp982672wra; Fri, 2 Feb 2018 09:13:40 -0800 (PST) X-Google-Smtp-Source: AH8x2266/PM0K5XOYSnjaOpW0JkfWx21t4cFKgo53kzJdRNCrtsV5lWNkDCAEkBQhy4usknYcrSb X-Received: by 2002:a17:902:570f:: with SMTP id k15-v6mr15658480pli.321.1517591620799; Fri, 02 Feb 2018 09:13:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517591620; cv=none; d=google.com; s=arc-20160816; b=feQKZp+/9nug7e75L67Pz1gQtSSaswHE89TC1MUZ4pgl7RQTVkWFy3E/j78bcP/HxX FWs1awQGUmM0hHtn7qLhxkmgLI1fBsPnUADZjWZnCwSJFBpnv7eQglv+EiYEeD6keJro BXMH27fHjmDmZwEaZ4in/H5lAE/yNH3nrnaN1ZhuJSnhvtncS3nqrImNfnMKaTKS2NYU c835lnj8HMQMztZnTc7O82V+eKh4DssNhxwvdgSr34ycLOacOYlysIRNmLF/rAnMXai1 FJVuIGWYkQnxZdDvI5wdH/pOCIH9QkFcsHUd3g9Of8WO5y+1VsB44h/A2/K0CuLodEGp UjXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=EfcsOHrkboi69+FMChtRL9PH4TUiWbG4BYwgYvy4BNI=; b=Ab18cBH4ADnm4U0qsOUct0IHediGyXbFcV641gq2f46eWvlvwqt3ah3wm8DcnsJfz/ g+6LXNCTGq8eNSvXSECz/aWWdJuEYPVmF2NhDlHZO60KJgC5mjw/St+kVstwjdM1epUq d5q7VwY4TJ5YnRZGEAasvqJ6L0+YfLuBQM391BWc1I/YjQQnkUr5fBlWooq0ADW8XCDO BuP8DKqsunxKTvbIPyivTtHWnI2ntjthiffRCbeuZw9URRj3GPSMXDwXN6dV1LQCrHvv 8OsJZpsy8vpRDe5WtfMB7HeIWSvmLiTZjajONoDznAiTBMcL89UHWpcqd9SneHvG/hHQ TqeA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h12-v6si78702plt.241.2018.02.02.09.13.26; Fri, 02 Feb 2018 09:13:40 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753407AbeBBRLm (ORCPT + 99 others); Fri, 2 Feb 2018 12:11:42 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:36702 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752449AbeBBRGJ (ORCPT ); Fri, 2 Feb 2018 12:06:09 -0500 Received: from localhost (LFbn-1-12258-90.w90-92.abo.wanadoo.fr [90.92.71.90]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 7F4C3E3B; Fri, 2 Feb 2018 17:06:08 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hans de Goede , Oliver Neukum Subject: [PATCH 4.9 75/86] USB: cdc-acm: Do not log urb submission errors on disconnect Date: Fri, 2 Feb 2018 17:58:35 +0100 Message-Id: <20180202140829.578778512@linuxfoundation.org> X-Mailer: git-send-email 2.16.1 In-Reply-To: <20180202140822.679101338@linuxfoundation.org> References: <20180202140822.679101338@linuxfoundation.org> User-Agent: quilt/0.65 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Hans de Goede commit f0386c083c2ce85284dc0b419d7b89c8e567c09f upstream. When disconnected sometimes the cdc-acm driver logs errors like these: [20278.039417] cdc_acm 2-2:2.1: urb 9 failed submission with -19 [20278.042924] cdc_acm 2-2:2.1: urb 10 failed submission with -19 [20278.046449] cdc_acm 2-2:2.1: urb 11 failed submission with -19 [20278.049920] cdc_acm 2-2:2.1: urb 12 failed submission with -19 [20278.053442] cdc_acm 2-2:2.1: urb 13 failed submission with -19 [20278.056915] cdc_acm 2-2:2.1: urb 14 failed submission with -19 [20278.060418] cdc_acm 2-2:2.1: urb 15 failed submission with -19 Silence these by not logging errors when the result is -ENODEV. Signed-off-by: Hans de Goede Acked-by: Oliver Neukum Signed-off-by: Greg Kroah-Hartman --- drivers/usb/class/cdc-acm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/usb/class/cdc-acm.c +++ b/drivers/usb/class/cdc-acm.c @@ -375,7 +375,7 @@ static int acm_submit_read_urb(struct ac res = usb_submit_urb(acm->read_urbs[index], mem_flags); if (res) { - if (res != -EPERM) { + if (res != -EPERM && res != -ENODEV) { dev_err(&acm->data->dev, "urb %d failed submission with %d\n", index, res);