From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752423AbbGPGCP (ORCPT ); Thu, 16 Jul 2015 02:02:15 -0400 Received: from kvm5.telegraphics.com.au ([98.124.60.144]:60695 "EHLO kvm5.telegraphics.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751300AbbGPGCN (ORCPT ); Thu, 16 Jul 2015 02:02:13 -0400 Date: Thu, 16 Jul 2015 16:01:41 +1000 (AEST) From: Finn Thain To: Benjamin Herrenschmidt cc: linux-kernel@vger.kernel.org, linux-m68k@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, Paul Mackerras , Michael Ellerman , Arnd Bergmann , Greg Kroah-Hartman , Jean-Christophe Plagniol-Villard , Tomi Valkeinen , linux-fbdev@vger.kernel.org Subject: Re: [RFC v4 17/25] powerpc, fbdev: Use arch_nvram_ops methods instead of nvram_read_byte() and nvram_write_byte() In-Reply-To: Message-ID: References: <20150712102527.356151908@telegraphics.com.au> <20150712102531.505897278@telegraphics.com.au> <1436874720.3948.252.camel@kernel.crashing.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 15 Jul 2015, I wrote: > On Tue, 14 Jul 2015, Benjamin Herrenschmidt wrote: > > > Maybe we should have a dedicated accessor for "mac_xpram" ... > > ... I can see how to implement XPRAM for matroxfb and imsttfb I'll have to retract that. The video mode and color mode settings used by the PowerMac framebuffer drivers don't exist in the PRAM portion of NVRAM. Addresses 0x140F and 0x1410 are found in the partition reserved by Apple for "Name Registry properties", according to Designing PCI Cards and Drivers for Power Macintosh Computers. There is no equivalent on m68k Macs, AFAIK. This is NVRAM partition 2 on my beige g3, which begins at 0x1400. I'm not sure that this is true on New World PowerMacs, and I suspect that the framebuffer drivers should be calling pmac_get_partition() to determine the offset of the beginning of the Name Registry partition. The arch_nvram_ops methods don't deal with structures like partitions. They treat the entire 8 KiB as unstructured, because that's how /dev/nvram treats it. -- From mboxrd@z Thu Jan 1 00:00:00 1970 From: Finn Thain Date: Thu, 16 Jul 2015 06:01:41 +0000 Subject: Re: [RFC v4 17/25] powerpc, fbdev: Use arch_nvram_ops methods instead of nvram_read_byte() and nvram Message-Id: List-Id: References: <20150712102527.356151908@telegraphics.com.au> <20150712102531.505897278@telegraphics.com.au> <1436874720.3948.252.camel@kernel.crashing.org> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Benjamin Herrenschmidt Cc: linux-kernel@vger.kernel.org, linux-m68k@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, Paul Mackerras , Michael Ellerman , Arnd Bergmann , Greg Kroah-Hartman , Jean-Christophe Plagniol-Villard , Tomi Valkeinen , linux-fbdev@vger.kernel.org On Wed, 15 Jul 2015, I wrote: > On Tue, 14 Jul 2015, Benjamin Herrenschmidt wrote: > > > Maybe we should have a dedicated accessor for "mac_xpram" ... > > ... I can see how to implement XPRAM for matroxfb and imsttfb I'll have to retract that. The video mode and color mode settings used by the PowerMac framebuffer drivers don't exist in the PRAM portion of NVRAM. Addresses 0x140F and 0x1410 are found in the partition reserved by Apple for "Name Registry properties", according to Designing PCI Cards and Drivers for Power Macintosh Computers. There is no equivalent on m68k Macs, AFAIK. This is NVRAM partition 2 on my beige g3, which begins at 0x1400. I'm not sure that this is true on New World PowerMacs, and I suspect that the framebuffer drivers should be calling pmac_get_partition() to determine the offset of the beginning of the Name Registry partition. The arch_nvram_ops methods don't deal with structures like partitions. They treat the entire 8 KiB as unstructured, because that's how /dev/nvram treats it. --