Atomicity in KMS panic notifier

2014-05-07 Thread One Thousand Gnomes
> Imo trying to fix the current mess and making ->set_config work in > atomic contexts is pointless. drm_can_sleep is trying to make that > possible in some ways, and it's horrible since using it means > busy-loops in atomic contexts outside of panic handlers won't get > reported any more. Also the

Atomicity in KMS panic notifier

2014-05-06 Thread Takashi Iwai
At Tue, 6 May 2014 15:53:32 +0200, David Herrmann wrote: > > Hi > > On Tue, May 6, 2014 at 3:38 PM, Takashi Iwai wrote: > > At Tue, 6 May 2014 15:32:21 +0200, > > David Herrmann wrote: > >> fbcon is called through the VT or fbdev layer, which is called by > >> bust_spinlocks(1) via either unblan

Atomicity in KMS panic notifier

2014-05-06 Thread David Herrmann
Hi On Tue, May 6, 2014 at 3:38 PM, Takashi Iwai wrote: > At Tue, 6 May 2014 15:32:21 +0200, > David Herrmann wrote: >> fbcon is called through the VT or fbdev layer, which is called by >> bust_spinlocks(1) via either unblank_screen() or console_unblank(). > > You mean bust_spinlocks(0), right? >

Atomicity in KMS panic notifier

2014-05-06 Thread Takashi Iwai
At Tue, 6 May 2014 15:32:21 +0200, David Herrmann wrote: > > Hi > > On Tue, May 6, 2014 at 3:27 PM, Takashi Iwai wrote: > > At Mon, 5 May 2014 16:52:45 +0200, > > Daniel Vetter wrote: > >> > >> On Mon, May 5, 2014 at 4:48 PM, Takashi Iwai wrote: > >> > > >> > The current problem I see is that t

Atomicity in KMS panic notifier

2014-05-06 Thread David Herrmann
Hi On Tue, May 6, 2014 at 3:27 PM, Takashi Iwai wrote: > At Mon, 5 May 2014 16:52:45 +0200, > Daniel Vetter wrote: >> >> On Mon, May 5, 2014 at 4:48 PM, Takashi Iwai wrote: >> > >> > The current problem I see is that the rest of panic notifier chain >> > won't be called once when we hit the prob

Atomicity in KMS panic notifier

2014-05-06 Thread Takashi Iwai
At Mon, 5 May 2014 16:52:45 +0200, Daniel Vetter wrote: > > On Mon, May 5, 2014 at 4:48 PM, Takashi Iwai wrote: > > > > The current problem I see is that the rest of panic notifier chain > > won't be called once when we hit the problem in KMS notifier. So, > > this bug in KMS influences on the r

Atomicity in KMS panic notifier

2014-05-05 Thread Takashi Iwai
At Mon, 5 May 2014 16:52:45 +0200, Daniel Vetter wrote: > > On Mon, May 5, 2014 at 4:48 PM, Takashi Iwai wrote: > > > > The current problem I see is that the rest of panic notifier chain > > won't be called once when we hit the problem in KMS notifier. So, > > this bug in KMS influences on the r

Atomicity in KMS panic notifier

2014-05-05 Thread Daniel Vetter
On Mon, May 5, 2014 at 4:48 PM, Takashi Iwai wrote: > > The current problem I see is that the rest of panic notifier chain > won't be called once when we hit the problem in KMS notifier. So, > this bug in KMS influences on the rest panic behavior. > > Maybe a hackish solution would be to keep KMS

Atomicity in KMS panic notifier

2014-05-05 Thread Takashi Iwai
At Mon, 5 May 2014 16:29:37 +0200, Daniel Vetter wrote: > > On Mon, May 5, 2014 at 3:02 PM, Takashi Iwai wrote: > > Hi, > > > > while debugging a few reported bugs, I noticed that > > drm_fb_helper_force_kernel_mode() that is called in the KMS panic > > notifier isn't really atomic-safe. It invo

Atomicity in KMS panic notifier

2014-05-05 Thread Daniel Vetter
On Mon, May 5, 2014 at 3:02 PM, Takashi Iwai wrote: > Hi, > > while debugging a few reported bugs, I noticed that > drm_fb_helper_force_kernel_mode() that is called in the KMS panic > notifier isn't really atomic-safe. It invokes crtc's set_config(), > and all implementations seem to involve with

Atomicity in KMS panic notifier

2014-05-05 Thread Takashi Iwai
Hi, while debugging a few reported bugs, I noticed that drm_fb_helper_force_kernel_mode() that is called in the KMS panic notifier isn't really atomic-safe. It invokes crtc's set_config(), and all implementations seem to involve with page allocations (kmalloc with GFP_KERNEL, via some ttm ops, et