Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp4197308ybc; Fri, 15 Nov 2019 00:08:04 -0800 (PST) X-Google-Smtp-Source: APXvYqy6/+pKu5/gaaudElJKCOYnb/9jfd3DspuULwexLqD8UdMw+rylfhf6T3x4OTBZTfUjTgwn X-Received: by 2002:a17:906:d793:: with SMTP id pj19mr12007775ejb.303.1573805283889; Fri, 15 Nov 2019 00:08:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573805283; cv=none; d=google.com; s=arc-20160816; b=LesebmmR5JjcbqJJQhUlmkpv2nG0A1j5q3l3utepShm4DIM4suUQZ2z0o2k6thudql KSKFpR2KxLHdDHL2RypsT1GAUa2QAn2Zib+YUB6vSSwK2UAk/CCtcaUqEHyVoYVk3nwt p06wsHEE/KRVcta0UGltaKlrTMZPdhN75h6kruRl+dM4EQvsGFjlX3OsHw45Lvl8gvYk uHsT9BLaYZPcx2Bg9/PeOJA81UsnwXO2GMSXOfFHW0Krc98ATNuHGM+h+dOSdNRiXAId zrhtgE9LGM55jVkWSTpdjad5giZvh7hT6p8yh8vTS/tJw15RDwApUrceHnEGnG6FT9kV JiUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:references:message-id :content-transfer-encoding:cc:date:in-reply-to:from:subject :mime-version; bh=T+4BwxA9ATERqN7TjdJlrDRZYFnT4P1audMVNyRQS7c=; b=p6uPBflxh6sdag7BPjpZYjWVQ/OTq0vjvTyM1TIbZObTUK9Zb21vFuDWXb6XrTwynF Opo04hIss/+yUZKfkb97AXSj2wEhQEUhIrIeklJeQzvQkAJW3H2/wZ6L6AfsmhRT5Eb7 cIVjI9KpTV7CYTLNNzcB3z4mVDX18s3Zy3E3rcyOv45kOr9WwcS2oFYjW3VsQEqA0jgo TL43dckLJYRd/PaxqnlW/ySKWqRPquKDeYo8JoDVeQz5IkqJywfrOeGc3ftbxgK6BrJb Q75kNdp5lk5LGz208CtPRExYozxEewrf30XZW2Sou1oyHXwi411OvU+K0wrHqVSfuS8/ rFJw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-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 z31si6269633ede.236.2019.11.15.00.07.38; Fri, 15 Nov 2019 00:08:03 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-bluetooth-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-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726983AbfKOIHe (ORCPT + 99 others); Fri, 15 Nov 2019 03:07:34 -0500 Received: from coyote.holtmann.net ([212.227.132.17]:44001 "EHLO mail.holtmann.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726196AbfKOIHe (ORCPT ); Fri, 15 Nov 2019 03:07:34 -0500 Received: from marcel-macbook.fritz.box (p4FF9F0D1.dip0.t-ipconnect.de [79.249.240.209]) by mail.holtmann.org (Postfix) with ESMTPSA id 3395DCED16; Fri, 15 Nov 2019 09:16:39 +0100 (CET) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 13.0 \(3601.0.10\)) Subject: Re: [PATCH] btusb: fix PM leak in error case of setup From: Marcel Holtmann In-Reply-To: <20191114150118.5237-1-oneukum@suse.com> Date: Fri, 15 Nov 2019 09:07:33 +0100 Cc: ytkim@qca.qualcomm.com, Johan Hedberg , linux-bluetooth@vger.kernel.org Content-Transfer-Encoding: 7bit Message-Id: References: <20191114150118.5237-1-oneukum@suse.com> To: Oliver Neukum X-Mailer: Apple Mail (2.3601.0.10) Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Hi Oliver, > If setup() fails a reference for runtime PM has already > been taken. Proper use of the error handling in btusb_open()is needed. > You cannot just return. > > Fixes: ace31982585a3 ("Bluetooth: btusb: Add setup callback for chip > init on USB") > Signed-off-by: Oliver Neukum > --- > drivers/bluetooth/btusb.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) patch has been applied to bluetooth-next tree. Regards Marcel