From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50541) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XuLVV-0000TG-PG for qemu-devel@nongnu.org; Fri, 28 Nov 2014 08:22:50 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XuLVQ-00030a-MR for qemu-devel@nongnu.org; Fri, 28 Nov 2014 08:22:45 -0500 Received: from mx1.redhat.com ([209.132.183.28]:45927) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XuLVQ-00030V-Es for qemu-devel@nongnu.org; Fri, 28 Nov 2014 08:22:40 -0500 Message-ID: <54787715.6030407@redhat.com> Date: Fri, 28 Nov 2014 14:22:29 +0100 From: Laszlo Ersek MIME-Version: 1.0 References: <1417177604-21194-1-git-send-email-lersek@redhat.com> <4081425.dh6XptxTnn@wuerfel> In-Reply-To: <4081425.dh6XptxTnn@wuerfel> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [kernel PATCH] devicetree: document ARM bindings for QEMU's Firmware Config interface List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Arnd Bergmann Cc: peter.maydell@linaro.org, qemu-devel@nongnu.org, devicetree@vger.kernel.org On 11/28/14 13:59, Arnd Bergmann wrote: > On Friday 28 November 2014 13:26:44 Laszlo Ersek wrote: >> +Example: >> + >> +/ { >> + #size-cells = <0x2>; >> + #address-cells = <0x2>; >> + >> + fw-cfg@9020000 { >> + reg = <0x0 0x9020000 0x0 0x2 0x0 0x9020002 0x0 0x1>; >> + compatible = "fw-cfg,mmio"; >> + }; >> +}; >> > > "fw-cfg" is not a valid vendor string. Are you emulating an actual piece > of hardware here or is this something that comes from qemu? It's a made up name. > How about using "qemu,fwcfg" as the compatible string, and documenting > "qemu" as an official vendor string in Documentation/devicetree/bindings/vendor-prefixes.txt I can do that, certainly, but I'm not sure if that implies other QEMU devices should follow suit. For example, the virtio-mmio transports that qemu advertises have the "compatible" property "virtio,mmio". "virtio" is not a vendor prefix either (according to the above text file). Here's the full list of compatible strings from the generated DTB: compatible = "arm,cortex-a15"; compatible = "arm,armv7-timer"; compatible = "arm,cortex-a15-gic"; compatible = "arm,pl011", "arm,primecell"; compatible = "arm,pl031", "arm,primecell"; compatible = "arm,psci-0.2", "arm,psci"; compatible = "cfi-flash"; compatible = "fixed-clock"; compatible = "fw-cfg,mmio"; compatible = "virtio,mmio"; compatible = "linux,dummy-virt"; According to , "cfi-flash" and "fixed-clock" don't even have the correct format (there's no comma separating from ). > We don't normally list contiguous registers separately. Maybe just round > up to one page and make the register property > > reg = <0x0 0x9020000 0x0 0x1000>; The registers are not necessarily placed shoulder to shoulder (it's not a requirement in the QEMU source). > Finally, isn't there also an interrupt associated with this virtual device? No, there is not. Thanks Laszlo