Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp1285862pxb; Fri, 21 Jan 2022 14:22:42 -0800 (PST) X-Google-Smtp-Source: ABdhPJzAdF3w49CAToCatjxz9S8HCQ221aJ26D3+/ZYUFMkMOoUUqFRy8CxXmbdCexbqrhQlzofZ X-Received: by 2002:a17:903:124c:b0:149:b16d:917e with SMTP id u12-20020a170903124c00b00149b16d917emr5573374plh.91.1642803762456; Fri, 21 Jan 2022 14:22:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1642803762; cv=none; d=google.com; s=arc-20160816; b=M7PNrH9VInFeVvCQipbHw5zmmIhhbaSYfXTRfR4hKGQRVrfKrRnk3L42etNpGEHLcb R11aP4lPZeFvAos6lnRr14PbSid+4VXLRGXAjMIJlR1OF/kt873MWHR0FlqAjSpBu89C rGL3ujS7EArk8uUns8BJ0jZhsuEUd4VbBto86454/89l8Y+FEmIr+orxPHbvqe3Vk4CS oyv+I/uVbF6lTE5C3+kKwZW6K4sirDuH5TUM7s6xEYsiLz6dthJ44QSEn4fszyXyEfra zjxvumo/ztWvgRJL9lRKMIxBgaTrc34BKRg9tflQ2B+hm6VpZ9MNz0VDngzmC0ZM3q8m yZ8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=SOXit3zb9lb3Zx/uwfBsERKzJ8tRmlK7dI5nbml9u0A=; b=vpH0HA7Gko9lDN4baOoQlWj3p42D60RBMzeVZniRVwf/ewiAGCP4uS7miKPWSL208t yrTMVUM9SuGlNTexBmEU/S5ylx1rSKZfLB6iqVT6b9WlG2rCH7gQIT20eQq+UrcV7OPp c9pWh9DLylieEOGxVUCnfhki5HgsKacVkru86jJpSaCD8wQSUfpxh7+fMlNmn06k/9vS nuUWeFzLemKab3czrX2XXc3+NwKm9xxjKNY9SQvO5hM4eqT8wLGObfTUqtfj4qowEKzT q6G+sk0mvCgqj9sY1w7mfcPbM0xfe1SSBJBPovXoVhJN/SeeR3N1vTDPcoe9m6A7trYH 7tmQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=PfevTEkV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d9si7655329pgb.583.2022.01.21.14.22.30; Fri, 21 Jan 2022 14:22:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=PfevTEkV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376738AbiATPiH (ORCPT + 99 others); Thu, 20 Jan 2022 10:38:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48236 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346185AbiATPiG (ORCPT ); Thu, 20 Jan 2022 10:38:06 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BEC6BC061574 for ; Thu, 20 Jan 2022 07:38:06 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 2BC7260AD6 for ; Thu, 20 Jan 2022 15:38:06 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DE6F8C340E0; Thu, 20 Jan 2022 15:38:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1642693085; bh=t/67havVcIKUwmQL5G1hyKJG22hHt2hgG4Ka9kHQlxY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=PfevTEkVcq2aTVvhC76gc+AxnkoLf5zunslu8PJ47UyUYEllK/PHwn9Spviq/rrWc zoksMha/2byIAS1XKsUhOfU8AvCuXIHFPqdBolNlpno1q9FloKud6mUSbqpixM7VX6 kxbtX+IG0K9kGctRR9P5v37R1n8qOEGMm7thvBpQ= Date: Thu, 20 Jan 2022 16:38:02 +0100 From: Greg Kroah-Hartman To: Soenke Huster Cc: "Rafael J. Wysocki" , linux-kernel@vger.kernel.org Subject: Re: [PATCH] driver core: fix null pointer deref in device_find_child Message-ID: References: <20220120150246.6216-1-soenke.huster@eknoes.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220120150246.6216-1-soenke.huster@eknoes.de> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 20, 2022 at 04:02:46PM +0100, Soenke Huster wrote: > Similar to device_for_each_child, device_find_child should not ooops > if parent->p is NULL. While fuzzing the Bluetooth subsystem, I got a null > pointer dereference in next_device, which is prevented by this change. > > Buglink: https://bugzilla.kernel.org/show_bug.cgi?id=215497 > Signed-off-by: Soenke Huster > --- > I found this while fuzzing the bluetooth subsystem and reported this bug > in bugzilla. As I feel more like a kernelnewbie, I am not sure whether > this needs to be patched in driver core, or is just an issue of the > bluetooth subsystem itself. If the latter is the case: sorry for the > spam! bluetooth should be fixed, this is an indication that something is using a stale pointer and this would be the least of the problems here. thanks, greg k-h