Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752232AbdLKVtS (ORCPT ); Mon, 11 Dec 2017 16:49:18 -0500 Received: from mail-wr0-f169.google.com ([209.85.128.169]:38149 "EHLO mail-wr0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751379AbdLKVtN (ORCPT ); Mon, 11 Dec 2017 16:49:13 -0500 X-Google-Smtp-Source: ACJfBosnaNOkY2B11WCW4yCPY1DywvJcW9uUbIGU1tT33HMTbY20qKkTJf+vJGtwgl8lOpWRlM2NpCdZsom4HvOG9Ew= MIME-Version: 1.0 In-Reply-To: <25BE9D66-9609-42D0-8A83-E15758FA3A1B@holtmann.org> References: <20171116213045.GA17506@wunner.de> <20171116214504.GB17506@wunner.de> <25BE9D66-9609-42D0-8A83-E15758FA3A1B@holtmann.org> From: John Stultz Date: Mon, 11 Dec 2017 13:49:11 -0800 Message-ID: Subject: Re: [PATCH] Bluetooth: hci_serdev: Init hci_uart proto_lock to avoid oops To: Marcel Holtmann Cc: Lukas Wunner , Rob Herring , Johan Hovold , Ronald Tschalaer , Sumit Semwal , "open list:BLUETOOTH DRIVERS" , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1039 Lines: 25 On Thu, Nov 16, 2017 at 10:07 PM, Marcel Holtmann wrote: > Hi Lukas, > >> John Stultz reports a boot time crash with the HiKey board (which uses >> hci_serdev) occurring in hci_uart_tx_wakeup(). That function is >> contained in hci_ldisc.c, but also called from the newer hci_serdev.c. >> It acquires the proto_lock in struct hci_uart and it turns out that we >> forgot to init the lock in the serdev code path, thus causing the crash. >> >> John bisected the crash to commit 67d2f8781b9f ("Bluetooth: hci_ldisc: >> Allow sleeping while proto locks are held"), but the issue was present >> before and the commit merely exposed it. (Perhaps by luck, the crash >> did not occur with rwlocks.) >> >> Init the proto_lock in the serdev code path to avoid the oops. >> [snip] > patch has been applied to bluetooth-next tree. Sorry to be a nuisance if its just a timing thing, but I wanted to follow up on this just to make sure it didn't fall through the cracks, as I noticed w/ -rc3 it hasn't landed yet. thanks -john