Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp6042665ybe; Tue, 10 Sep 2019 12:36:48 -0700 (PDT) X-Google-Smtp-Source: APXvYqwxM9p8R9P3xlLVTI55jm0kOu9jCQqqXK5td+VE7nLQ1Qq2hB9c4+AEAwVHnKJhhJB5EDfz X-Received: by 2002:a17:906:b5a:: with SMTP id v26mr26472125ejg.235.1568144208411; Tue, 10 Sep 2019 12:36:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568144208; cv=none; d=google.com; s=arc-20160816; b=CptRyUVKJPfaHnLRTSh/GnhqDmT8/GehX2m18awrEh0WbO4i6jveNhGDxiyu9bplPw EOk1tV/AasQnXTN+bzPd8vM+V5W37TncRZ7Ik/Ehu5PXC9oGJx3luO/8j8FuxTznBD4o 2aqunhw6/O7GYkfZKSTz3dA/J5qD7dFfLoHAC/mNG6zOUbkc5OYR6ZCkdySOqlrim8+D U2sk5cJGDSM4t/ieBtzI6KF5mA3ESFGaaLJ2EGwtNCjB2lkqVQawJcd5ZCAsLL9Zk7xm nPztuNozyLYiRRKu9byY+z0uqianSNqADSt9VvaewKxdbQ3CkAFUV6UhD/BzyJPFPWXM mIOw== 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:message-id :subject:cc:to:from:date; bh=yCkYklQgD68nfdhq/F9VUb3USeX9HayjGWfaNGOOCn8=; b=tpqXC1C01R7w3/o3DQu0GZRKSqbqzZv9tDJ9rzpcIBkfKKP9UMA8IPJVbDN1uAXsVc zBwITAiCfBajlHNs0x8XWh9U94qYvMiXojQM/h1O26b2cTs+6WrYm3fTlo+Ganz8gTIq 20xVpHw+OzPbuW0MRrzI/ESCpwi8Lg8eMvJXvKC6/M6bpBovTIqE/iXA/RE55NM1169z Egwe7ECkmRIxVatW9QCOObbeLWbchaYbuJcRUDyDEqY93J4IwLXz9p7XbRNqXLjpURUB 0U5D8Xa/F1ZqkjVtfn3xJAp8tUgnUg2OtwWu+im6fX0o3CzbBFKmaR+e1f38mCGRkzML 5JYg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-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 z2si9227109edp.306.2019.09.10.12.36.24; Tue, 10 Sep 2019 12:36:48 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-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-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727734AbfIJTLS (ORCPT + 99 others); Tue, 10 Sep 2019 15:11:18 -0400 Received: from mail2-relais-roc.national.inria.fr ([192.134.164.83]:25645 "EHLO mail2-relais-roc.national.inria.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725797AbfIJTLS (ORCPT ); Tue, 10 Sep 2019 15:11:18 -0400 X-IronPort-AV: E=Sophos;i="5.64,490,1559512800"; d="scan'208";a="401135346" Received: from abo-12-105-68.mrs.modulonet.fr (HELO hadrien) ([85.68.105.12]) by mail2-relais-roc.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Sep 2019 21:11:16 +0200 Date: Tue, 10 Sep 2019 21:11:16 +0200 (CEST) From: Julia Lawall X-X-Sender: jll@hadrien To: amitkarwar@gmail.com, siva8118@gmail.com cc: syzkaller-bugs@googlegroups.com, kvalo@codeaurora.org, davem@davemloft.net, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: syzbot report in rsi_91x_usb.c Message-ID: User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Hello, I spent some time looking at: https://syzkaller.appspot.com/bug?id=c1b6aa968706d9380dcdb98a9f2c338071cc938c which does not yet report that it has been fixed. The problem seems to be in rsi_probe in drivers/net/wireless/rsi/rsi_91x_usb.c. This ends with the following code: status = rsi_rx_urb_submit(adapter, WLAN_EP); if (status) goto err1; if (adapter->priv->coex_mode > 1) { status = rsi_rx_urb_submit(adapter, BT_EP); if (status) goto err1; } return 0; err1: rsi_deinit_usb_interface(adapter); err: rsi_91x_deinit(adapter); The problem seems to be that the first call to rsi_rx_urb_submit succeeds, submitting an urb, and then theh second one fails. Both share adapter, which is used in rsi_rx_done_handler, invoked later as the callback provided with usb_submit_urb. But adapter, and in particular its rsi_dev field, are freed by the rsi_91x_deinit call due to the failure of the second call to rsi_rx_urb_submit. How should this be fixed? thanks, julia