Received: by 10.223.185.116 with SMTP id b49csp2943444wrg; Mon, 5 Mar 2018 11:11:05 -0800 (PST) X-Google-Smtp-Source: AG47ELtLjI+6f8GGJc2ICsArCajYvb7m9plOH0jOyWZsCWITypDIoWDOCOrBOCxnL+46l2A8PMqz X-Received: by 2002:a17:902:599b:: with SMTP id p27-v6mr13545611pli.289.1520277065533; Mon, 05 Mar 2018 11:11:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520277065; cv=none; d=google.com; s=arc-20160816; b=tJeMx2GXxznYM3PkEVfW4u/RQRS5lWx5t8XaFWplPhSIBYS62zARmhu7bb4SJbjF8N ojdPgpa7XodWlR+UxvFbR8oq8UqwPh7pzawB1xLaPqbYbD6gSv8m7VzlYnz2Z+JNSzOa 4IR5/6IoG/LOMdlnlTSZsnrSWgq0OwBJyxRId/jW47uShvdzh9daTT1Nc9k7RTbfvfL9 hoFxHcQg3KIpsBHJza+kZgeO/QJO4RlSUkc3U47k8eqPUvZc2F2HnOlzZiG2LZglkoJM yEtAlq6a5YIzOVxKPQlDRhrAHCM4dT2wv5UUc++i8g6aG+uDl+jv2wGPMPtD88+aaO7+ xtuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:date:cc:to:from:subject:message-id :dkim-signature:arc-authentication-results; bh=NeFzjT7KrwO3+MKpi9NDWElwFEogD9Eh3ezu/PZvWao=; b=kmTIsAV/UmGzxjpJ+LvML91MaxhZYJx6rE4rKroZR3JPfH/vKAknzlu1O2QJCEfYWj me+SmIMz2Qf++kYMzPCnb9+1GkNihaKgr1c+Rw6BbKS7BEqkO0NkXAwGN1coG/kJRKKj +KsfjmqKyADYGHqNmwfdJwG5NDeQGWSdpEqwBC3aqR42hMA0QJnMfl20MXwK+vYgk400 lblpO6WvRg6cPxP72Uv9werSJW4tbEre3gH7g82rRMe8oku6PAnZOuhwtTrmOHMEkoYF dldwmbA2ORciOPqwe9bXCOz8gHYnqSQ+d384oAojxC2OeUllrESMZ1OS5fDaNmmMG4t4 1/DA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Wz9t3kJe; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n12-v6si9645650pls.292.2018.03.05.11.10.51; Mon, 05 Mar 2018 11:11:05 -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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Wz9t3kJe; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753032AbeCETJH (ORCPT + 99 others); Mon, 5 Mar 2018 14:09:07 -0500 Received: from mail-pf0-f174.google.com ([209.85.192.174]:36040 "EHLO mail-pf0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753001AbeCETJE (ORCPT ); Mon, 5 Mar 2018 14:09:04 -0500 Received: by mail-pf0-f174.google.com with SMTP id 68so7617548pfx.3; Mon, 05 Mar 2018 11:09:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:subject:from:to:cc:date:in-reply-to:references :mime-version:content-transfer-encoding; bh=NeFzjT7KrwO3+MKpi9NDWElwFEogD9Eh3ezu/PZvWao=; b=Wz9t3kJeoIW5wGMSAc+AuZtaX29h3hCiMcsbdL2Leu19F0DcHQpr7ko9SIZnE8+XGf G1K8iPzG9MdlXw7jg9zUwqQLE/7c3BXUzi9e3t69rgkDcHzktXBpwqsPpv2KQbHFYN7u lEjktVNzBU0whWUeTyavvSNgJgPD4OezIemiWVBpvDWSeyhGGLCd4sOKear9EOQ9YTIX B5qBAza4lbGQ8PtXbTOrC27vtF3ovia/ULMMliNuKiShTcwWHFeU5IXJdMJFi4Wi1aRV XUn1kSSkobKyMZ5ZnpjowI4oQ9AOw4POWbuV/n2e3Ud8gK5sDv1CLetU+t7V57n+tW1m p8AA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:mime-version:content-transfer-encoding; bh=NeFzjT7KrwO3+MKpi9NDWElwFEogD9Eh3ezu/PZvWao=; b=Y/Ybo3EaE4nechJ0pV0DMa3x6Auxi3G7jxmssMizdAEqTtmKLrrLT5noS6F2LW3CNB 1y5PTHWl30dg9jqq7zTSsKeenwD8ChnKzhpxkYxIAf8YG18K35tXi6e76V5ymm+MX1tH 1OO2AaIbHIQHKDVgVWh1x2mEY3LMDh3GpVLb/PvcQ5Sha1lj07NY6GhgiaP4G6KejzV/ ZMvvyHNCcIwE4IsECyb8GcFZ2KRs3e312he84yw5Ox6A4iQWn0IgPZVZ/rbncv4lCmuC xJaj3BEL6Cr2omX2tYLElRqPO3UUdFhKyWpA4/a1wvl1n5f4jPnz6iORbdIjMQ2NJLpR rtPw== X-Gm-Message-State: APf1xPBHL8CSwJl0C5cwONz8+3J2oKO6qRfZ8lO3BOexOYzj8WWhvvyw nd0T/D/zG/o7/X/URji0jlI= X-Received: by 10.98.141.205 with SMTP id p74mr16267322pfk.211.1520276943887; Mon, 05 Mar 2018 11:09:03 -0800 (PST) Received: from ?IPv6:2a00:79e1:abc:100:641:391c:2715:1239? ([2a00:79e1:abc:100:641:391c:2715:1239]) by smtp.googlemail.com with ESMTPSA id s86sm25447681pfi.4.2018.03.05.11.09.02 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 05 Mar 2018 11:09:02 -0800 (PST) Message-ID: <1520276942.109662.9.camel@gmail.com> Subject: Re: inconsistent lock state with usbnet/asix usb ethernet and xhci From: Eric Dumazet To: Oliver Neukum , Marek Szyprowski Cc: LKML , 'Linux Samsung SOC' , Linux USB Mailing List , netdev@vger.kernel.org, Dean Jenkins Date: Mon, 05 Mar 2018 11:09:02 -0800 In-Reply-To: <1520250367.3990.9.camel@suse.com> References: <1519740421.7296.6.camel@gmail.com> <1519744167.7296.8.camel@gmail.com> <1519744400.7296.10.camel@gmail.com> <1519747675.2649.3.camel@suse.com> <02679502-cf6e-8714-e879-50a922c5d976@samsung.com> <1520250367.3990.9.camel@suse.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.22.6-1+deb9u1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2018-03-05 at 12:46 +0100, Oliver Neukum wrote: > On Mon, 2018-03-05 at 08:45 +0100, Marek Szyprowski wrote: > > Hi Oliver, > > > > On 2018-02-27 17:07, Oliver Neukum wrote: > > > Am Dienstag, den 27.02.2018, 07:13 -0800 schrieb Eric Dumazet: > > > > On Tue, 2018-02-27 at 07:09 -0800, Eric Dumazet wrote: > > > > > > > > > > Note that for this one, it seems we also could perform stats > > > > > updates in > > > > > BH context, since skb is queued via defer_bh() > > > > > > > > > > But simplicity wins I guess. > > > > > > > > Thinking more about this, I am not sure we have any guarantee > > > > that TX > > > > and RX can not run on multiple cpus. > > > > > > > > Using an unique syncp is not going to be safe, even if we make > > > > lockdep > > > > happy enough with the local_irq save/restore. > > > > > > Unfortunately you are right. It is not guaranteed for some > > > hardware. > > > > Does it mean that the fix proposed by Eric is not the proper > > solution? > > For asix it should work, but asix is unlikely to be the only driver > with that issue. 32 bit recieves less testing nowadays. Yes, although the lockdep part could be enforced in 64bit if we really care. I will send a patch using two different sync (one for RX, one for TX)