From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Vetter Subject: Re: [PATCH] radeon: Use mdelay() instead of msleep() in atom_op_delay(). Date: Tue, 3 Jan 2012 21:04:53 +0100 Message-ID: <20120103200453.GA4019@phenom.ffwll.local> References: <1325613840-31736-1-git-send-email-michel@daenzer.net> <1325614585.1807.444.camel@thor.local> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mail-we0-f177.google.com (mail-we0-f177.google.com [74.125.82.177]) by gabe.freedesktop.org (Postfix) with ESMTP id F0C7B9F064 for ; Tue, 3 Jan 2012 12:03:40 -0800 (PST) Received: by wera10 with SMTP id a10so10536909wer.36 for ; Tue, 03 Jan 2012 12:03:40 -0800 (PST) Content-Disposition: inline In-Reply-To: <1325614585.1807.444.camel@thor.local> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: Michel =?iso-8859-1?Q?D=E4nzer?= Cc: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org On Tue, Jan 03, 2012 at 07:16:25PM +0100, Michel D=E4nzer wrote: > On Die, 2012-01-03 at 18:09 +0000, Dave Airlie wrote: = > > 2012/1/3 Michel D=E4nzer : > > > From: Michel D=E4nzer > > > > > > It can be called from atomic context, e.g. when switching to console = for panic > > > output. > > > > > > Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=3D43941 > > = > > I wonder how ugly it would be to check for atomic context or not, > = > So do I. :) The comment in include/linux/hardirq.h that ends in 'Do not > use in_atomic() in driver code.' sounds rathery scary... We already use in_atomic checks in similar delay code in drm/i915 for the same reasons. I think the ugly mess that results from the panic notifier calling into kms code is justification enough to neglect the the comment about not using in_atomic in drivers. -Daniel -- = Daniel Vetter Mail: daniel@ffwll.ch Mobile: +41 (0)79 365 57 48