Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 8C39CC433EF for ; Tue, 26 Apr 2022 01:36:40 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.313384.530889 (Exim 4.92) (envelope-from ) id 1njA7k-0005ZC-Dh; Tue, 26 Apr 2022 01:36:16 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 313384.530889; Tue, 26 Apr 2022 01:36:16 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1njA7k-0005Z5-9O; Tue, 26 Apr 2022 01:36:16 +0000 Received: by outflank-mailman (input) for mailman id 313384; Tue, 26 Apr 2022 01:36:15 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1njA7j-0005Yz-7J for xen-devel@lists.xenproject.org; Tue, 26 Apr 2022 01:36:15 +0000 Received: from mailhost.m5p.com (mailhost.m5p.com [74.104.188.4]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 3f9e5054-c501-11ec-8fc2-03012f2f19d4; Tue, 26 Apr 2022 03:36:11 +0200 (CEST) Received: from m5p.com (mailhost.m5p.com [IPv6:2001:470:1f07:15ff:0:0:0:f7]) by mailhost.m5p.com (8.16.1/8.15.2) with ESMTPS id 23Q1ZnqI032875 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Mon, 25 Apr 2022 21:35:55 -0400 (EDT) (envelope-from ehem@m5p.com) Received: (from ehem@localhost) by m5p.com (8.16.1/8.15.2/Submit) id 23Q1ZmND032874; Mon, 25 Apr 2022 18:35:48 -0700 (PDT) (envelope-from ehem) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 3f9e5054-c501-11ec-8fc2-03012f2f19d4 Date: Mon, 25 Apr 2022 18:35:48 -0700 From: Elliott Mitchell To: Julien Grall Cc: Stefano Stabellini , xen-devel@lists.xenproject.org, Jan Beulich Subject: Re: OS Headers hypercall.h/hypervisor.h Message-ID: References: <701a0bdc-a8d3-06c3-7e40-e741dfa45361@xen.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: I dislike the adding yet more junk into the global namespace, so I had opted for use of inline functions. The approach of adding underscores to globals though does generally work. I took a look at the file arch/x86/include/asm/xen/hypercall.h in the Linux kernel. The only explicitly listed author is Keir A Fraser and has the GPLv2 or MIT license like most of the Xen headers. Clearly though there was a heavy rewrite by Jeremy Fitzhardinge at e74359028d54. Interestingly, the current header doesn't need much adjustment to work for with Xen/ARM. The registers have distinct names, ARM doesn't clobber as many registers and the instruction for the hypercall is different. Yet since these are all isolated as distinct macros, adding ARM support would be easy. What I really need is advice for the direction the project of getting FreeBSD operational on Xen/ARM should take. Should I use Stefano Stabellini's hypercall.S file? Should I try to merge headers together and share the main body of the hypercall.h header? I like merging things due to less work in the long term, just I'm concerned there is a trap waiting for me if I go this direction. -- (\___(\___(\______ --=> 8-) EHM <=-- ______/)___/)___/) \BS ( | ehem+sigmsg@m5p.com PGP 87145445 | ) / \_CS\ | _____ -O #include O- _____ | / _/ 8A19\___\_|_/58D2 7E3D DDF4 7BA6 <-PGP-> 41D1 B375 37D0 8714\_|_/___/5445