On Sun, Jan 23, 2022 at 02:40:21PM -0700, Thomas Frohwein wrote:
> On Sun, Jan 23, 2022 at 10:19:24AM +1100, Jonathan Gray wrote:
> > On Fri, Jan 21, 2022 at 03:31:14PM -0700, Thomas Frohwein wrote:
> > > On Fri, Jan 21, 2022 at 07:54:29PM +1100, Jonathan Gray wrote:
> > > > On Thu, Jan 20, 2022 at 04:08:28PM -0700, Thomas Frohwein wrote:
> > > > > On Fri, Jan 21, 2022 at 12:22:49AM +1100, Jonathan Gray wrote:
> > > > > > On Wed, Jan 19, 2022 at 11:04:26PM -0800, [email protected]
> > > > > > wrote:
> > > > > [...]
> > > > > > > The backtrace is kinda nonsensical, showing a copyout() call with
> > > > > > > no
> > > > > > > predecessor, but maybe that's just from copy*() not setting up a
> > > > > > > proper
> > > > > > > frame? However, that's not a change. Neither has there been any
> > > > > > > change
> > > > > > > in the pmap layer in multiple months. The areas of concern IMO
> > > > > > > are DRM
> > > > > > > and (because it was the last thing mentioned) iwm, but the former
> > > > > > > seems
> > > > > > > _much_ more likely.
> > > > > >
> > > > > > Booting bsd.mp with inteldrm disabled works?
> > > > >
> > > > > yes, boots and uses llvmpipe after I disable inteldrm*
> > > >
> > > > this fixes sleeping with a mtx held found with kern.pool_debug=2
> > > > which may help
> > >
> > > thanks, however no change after I built MP kernel and installed it. Still
> > > the
> > > same pmap error that I posted in the original bug report.
> >
> > Can you try a kernel with this diff and 'option WITNESS' uncommented
> > in sys/arch/amd64/conf/GENERIC.MP ?
>
> I built a kernel with this after updating the CVS checkout. To my
> surprise, MP kernel now boots fine and I don't see any of the WITNESS
> messages that I was expecting. Looked through dmesg, /var/log/messages,
> even Xorg.0.log. I'm positive that I built the kernel on the previous
> try and installed it correctly. I checked the dmesg at the time that it
> showed the locally built kernel and it did.
if you revert the previous and try this does it still boot?
Index: sys/dev/pci/drm/drm_linux.c
===================================================================
RCS file: /cvs/src/sys/dev/pci/drm/drm_linux.c,v
retrieving revision 1.89
diff -u -p -r1.89 drm_linux.c
--- sys/dev/pci/drm/drm_linux.c 21 Jan 2022 23:49:36 -0000 1.89
+++ sys/dev/pci/drm/drm_linux.c 24 Jan 2022 10:33:43 -0000
@@ -753,7 +753,7 @@ idr_alloc(struct idr *idr, void *ptr, in
{
int flags = (gfp_mask & GFP_NOWAIT) ? PR_NOWAIT : PR_WAITOK;
struct idr_entry *id;
- int begin;
+ int begin, s;
KERNEL_ASSERT_LOCKED();
@@ -761,7 +761,9 @@ idr_alloc(struct idr *idr, void *ptr, in
id = idr_entry_cache;
idr_entry_cache = NULL;
} else {
+ s = splsched();
id = pool_get(&idr_pool, flags);
+ splx(s);
if (id == NULL)
return -ENOMEM;
}