From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753257AbbBXQtW (ORCPT ); Tue, 24 Feb 2015 11:49:22 -0500 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:33145 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752239AbbBXQtU (ORCPT ); Tue, 24 Feb 2015 11:49:20 -0500 Date: Tue, 24 Feb 2015 17:49:15 +0100 From: Pavel Machek To: Dave Airlie Cc: torvalds@linux-foundation.org, linux-kernel@vger.kernel.org, dri-devel@lists.sf.net Subject: Re: [PATCH] vt_buffer: drop console buffer copying optimisations Message-ID: <20150224164914.GA6683@amd> References: <1422504685-7864-1-git-send-email-airlied@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1422504685-7864-1-git-send-email-airlied@redhat.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu 2015-01-29 14:11:25, Dave Airlie wrote: > These two copy to/from VGA memory, however on the Silicon > Motion SMI750 VGA card on a 64-bit system cause console corruption. > > This is due to the hw being buggy and not handling a 64-bit transaction > correctly. > > We could try and create a 32-bit version of these routines, > but I'm not sure the optimisation is worth much today. > > Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1132826 > > Tested-by: Huawei engineering. > Signed-off-by: Dave Airlie Actually... are you sure this is right fix? IOW can gcc do the optimalization behind your back and still break the buggy card? Pavel > diff --git a/include/linux/vt_buffer.h b/include/linux/vt_buffer.h > index 057db7d..f38c10b 100644 > --- a/include/linux/vt_buffer.h > +++ b/include/linux/vt_buffer.h > @@ -21,10 +21,6 @@ > #ifndef VT_BUF_HAVE_RW > #define scr_writew(val, addr) (*(addr) = (val)) > #define scr_readw(addr) (*(addr)) > -#define scr_memcpyw(d, s, c) memcpy(d, s, c) > -#define scr_memmovew(d, s, c) memmove(d, s, c) > -#define VT_BUF_HAVE_MEMCPYW > -#define VT_BUF_HAVE_MEMMOVEW > #endif > > #ifndef VT_BUF_HAVE_MEMSETW -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html