Date: Thu, 23 Jun 2022 16:08:55 -0300 From: Mitchell Horne <mhorne@freebsd.org> To: John Baldwin <jhb@FreeBSD.org>, src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: Re: git: 36a8572ee8f5 - main - bus_if: provide a default null rescan method Message-ID: <930b6109-191c-5fd4-70d6-2330cfd62adf@freebsd.org> In-Reply-To: <0969015a-c843-5dfc-f967-87c5f693c70f@freebsd.org> References: <202206231816.25NIG5aL014878@gitrepo.freebsd.org> <04bd822f-5edc-56e0-c45f-1f3d88a421d7@FreeBSD.org> <0969015a-c843-5dfc-f967-87c5f693c70f@freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 6/23/22 15:29, Mitchell Horne wrote: > On 6/23/22 15:22, John Baldwin wrote: >> On 6/23/22 11:16 AM, Mitchell Horne wrote: >>> The branch main has been updated by mhorne: >>> >>> URL: >>> https://cgit.FreeBSD.org/src/commit/?id=36a8572ee8f5db7ecb64bedc5738a363ec7cad36 >>> >>> >>> commit 36a8572ee8f5db7ecb64bedc5738a363ec7cad36 >>> Author: Mitchell Horne <mhorne@FreeBSD.org> >>> AuthorDate: 2022-06-21 13:29:53 +0000 >>> Commit: Mitchell Horne <mhorne@FreeBSD.org> >>> CommitDate: 2022-06-23 18:15:10 +0000 >>> >>> bus_if: provide a default null rescan method >>> There is an existing helper method in subr_bus.c, but almost no >>> drivers >>> know to use it. It also returns the same error as an empty method, >>> making it not very useful. Move this to bus_if.m and return a more >>> sensible error code. >>> This gives a slightly more meaningful error message when attempting >>> 'devctl rescan' on buses and devices alike: >>> "Device not configured" --> "Operation not supported by device" >>> Reviewed by: imp >>> MFC after: 1 week >>> Sponsored by: The FreeBSD Foundation >>> Differential Revision: https://reviews.freebsd.org/D35501 >> >> The cardbus.c and ofw_pcibus.c changes are bugs. These drivers >> inherit from >> the PCI bus so inherit the PCI bus method by default. The null rescan >> was on >> purpose as an override of the inherited method. >> >> I'm fine with changing the default to bus_null_rescan, but the method >> needs to >> stay so that subclasses of bus drivers can override it back to null. >> > > I see, understood. I will revert this portion of the patch in a few > minutes. > > Mitchell Should be fixed by 29afffb942b1, but please have a second look. And thanks! Mitchell
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?930b6109-191c-5fd4-70d6-2330cfd62adf>