Received: by 2002:ab2:7b86:0:b0:1f7:5705:b850 with SMTP id q6csp97589lqh; Fri, 3 May 2024 14:47:47 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCW+3IA6rkduAiEcJM0ZwrBp/OOpLniZ/NR1dr+j8SWkiuWnNdaxuDZhNDbcMdmJso+JFHBwlEoSTgh3VO/KlCDW5qCbyCVK/dMXM21NbQ== X-Google-Smtp-Source: AGHT+IFw/KmedNdJRehiJW9Au4VFk6gyruSUFvg0oYUXa7/HA6xciqm5rGKnAas2Me9jr8vzU8K5 X-Received: by 2002:a05:622a:1106:b0:43a:f443:d126 with SMTP id e6-20020a05622a110600b0043af443d126mr4392991qty.48.1714772866819; Fri, 03 May 2024 14:47:46 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714772866; cv=pass; d=google.com; s=arc-20160816; b=og2jvZlmz5W8WreMDC2pomeS24iXRQ3af+4ma67SkggU0cg+JXGtXdvgWvLlLSc3FR HYXmkURZiyZXnxXd4leWRzvztx+uUr7NwnRVyD0K6G/cjXsT+WXEzPQ2MTVvhzbszdSw NV3XvvgihklUdoDIFfcMZ68rpV+LIzasbmi6clRKWNPW8xAInTeJ6pzaceDbwTO7vrzd jVnG3Koa9FvH+L55jGK7+rrpBJrugB2OxE0B3/XwgMUl9b2pYx+Wfx3+XyfjISoAi8MU GQ1aIQqg9dfeFG+tlwLDK5Pp6mVURe9eKKEGqwO7pRDAIxYS8m4NKyvXbAjfNVHFdWr1 s3qQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:dkim-signature:dkim-signature:date; bh=rm+oVconEb8YVTlSeJTiM2JoTmuBUcCQK7KwBej9OiE=; fh=m0l5F+cZUM1aJm4XxMEh77/HUdXmAyZ3iLyVxWf8yRg=; b=1IbsPkWsDd10tDczPNV6TEaSHxvlqyj5q6dYe8uxfADAFGsg0y2xOTpxgSy200hJNl RYFYDjF6CQoyY9OKNqOayyYUTJafbV46blTl4nZG11TuGnVItYbWr8Qx74ygdi5kIj9i FTzk1xVks5MRheEXWJcjmDnYraOAJfYZ0MTrSwsg+ql5hVIp5lOjfRKxxlt1IiURudZZ pqs4XPD1YiUalY6SsLbNFBfA1Y+XXqQb/n8vcHyQVimgBxs5s2/NI9GrDDB8XCDPZtgs SYzgU3y4gAcaDx+wnaQv3EIM2AqQe81ue0/0+ZXLcI3Lr0Fb7zoeX2rYIENJNUdzUP/b HM/g==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=IeBg60tK; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-168315-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-168315-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id f37-20020a05622a1a2500b0043a1899c8e0si4285721qtb.339.2024.05.03.14.47.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 May 2024 14:47:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-168315-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=IeBg60tK; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-168315-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-168315-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id F1A801C23BE7 for ; Fri, 3 May 2024 21:47:40 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8C6CB74420; Fri, 3 May 2024 21:42:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="IeBg60tK"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="lw4CfQAw" Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5ABA654903; Fri, 3 May 2024 21:42:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714772522; cv=none; b=Js6fBIZBvpsTVpmBYU1p5h7vVXIWY4srRMJOeb9r9uKZG/R8uT6cWh0VeG+2/LwlZIaKjI/eoG/h6MCKEOI3iwuTvGhgD+KKWeN9MqsM4xKlS2XIRP4P0yZ8wnCvw1xMR0GLZ4dchp8DIjTEBxy4E/ALefevc8FP4td3c8p26bA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714772522; c=relaxed/simple; bh=HQm+V3Biee53no+YJeqbhU4w8NB6wtn8SA4D32s6iXc=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=je/tRnM3p4Va1NcoPCYpddwJFiJl+c8tLKdvuwfvPbaeMPyxB9gxgNojPkLb6LBl620YdMYC+DcuXXOJq1y/b8xc6gTQJLfd5WJ7mxEu2lgnLyNmxwgclvACtGzwZ07nzI54vkxgkYIp6XShEovVuEr9CHdE+RnFdRqyAxT6LtY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=IeBg60tK; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=lw4CfQAw; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Date: Fri, 3 May 2024 23:41:52 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1714772519; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=rm+oVconEb8YVTlSeJTiM2JoTmuBUcCQK7KwBej9OiE=; b=IeBg60tKkbm9N/BcYYvVbK1kBVYcQ4JKONUl83wDZljZal3E87dNJ05FtGtG1qBrmc9xNP 8LBhKCXHSuSDvxXQPqjrY6QnYwpv7CxMNcbJhFnWyXqvKyCJTXwXDTSnI0XJFpopF2IiW4 9DCPQN59gYMwdU7Dka5RhGZbRuQjow1L9bW4WlxhzsV+Z9qzyFucnw12SgcL4Z7ce90HoR 7BLQVQOw4ffoQP/8XtuXUIsJ8m+3UsWxWLw/HwFfoTo0fCcwSs/sgMpn9QlOOu1/dAcv3F QprKPIKC8doHpn7bwV3k6lI7AsU/N1nRC8XhdBVS10K0Q0wS1m93yZcOkS9gCg== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1714772519; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=rm+oVconEb8YVTlSeJTiM2JoTmuBUcCQK7KwBej9OiE=; b=lw4CfQAwSHiG9TSRGDDHaMyDeOm7T38Eei/usvVBJ+Yk0AisxpKsszaEomJnere1BenYKx ROo4CvmJzV4UdSAg== From: Nam Cao To: Bjorn Helgaas Cc: Bjorn Helgaas , Yinghai Lu , Greg Kroah-Hartman , Rajesh Shah , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org, Lukas Wunner Subject: Re: [PATCH 2/4] PCI: pciehp: bail out if pci_hp_add_bridge() fails Message-ID: <20240503214152.p902TB4a@linutronix.de> References: <401e4044e05d52e4243ca7faa65d5ec8b19526b8.1714762038.git.namcao@linutronix.de> <20240503212341.GA1604125@bhelgaas> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240503212341.GA1604125@bhelgaas> On Fri, May 03, 2024 at 04:23:41PM -0500, Bjorn Helgaas wrote: > On Fri, May 03, 2024 at 09:23:20PM +0200, Nam Cao wrote: > > If there is no bus number available for the downstream bus of the > > hot-plugged bridge, pci_hp_add_bridge() will fail. The driver proceeds > > regardless, and the kernel crashes. > > > > Abort if pci_hp_add_bridge() fails. > > Thanks for this and for the details in the cover letter. The cover > letter doesn't get directly preserved and connected to the git commit, > so please include some of the details here in the commit log. > > I don't think we need *everything* from the cover letter; just enough > of the messages to show what went wrong and how the kernel crashed, so > somebody who trips over this can connect the crash with this fix. And > the timestamps are not relevant, so you can strip them out. The qemu > repro case is useful too, thanks for that! > > Same for the shpchp patch. > > And use "git log --oneline drivers/pci/hotplug/pciehp_pci.c" and match > the formatting (in particular, the capitalization) of your subject > lines. Thanks for the detailed instructions. I will send v2 next week. Best regards, Nam