From mboxrd@z Thu Jan 1 00:00:00 1970 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CC228C433F5 for ; Fri, 15 Apr 2022 04:47:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1349442AbiDOEuD (ORCPT ); Fri, 15 Apr 2022 00:50:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37102 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232067AbiDOEuC (ORCPT ); Fri, 15 Apr 2022 00:50:02 -0400 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6BBA2674CB for ; Thu, 14 Apr 2022 21:47:35 -0700 (PDT) Received: by verein.lst.de (Postfix, from userid 2407) id E28C868BFE; Fri, 15 Apr 2022 06:47:31 +0200 (CEST) Date: Fri, 15 Apr 2022 06:47:31 +0200 From: Christoph Hellwig To: Jason Gunthorpe Cc: Alex Williamson , Cornelia Huck , kvm@vger.kernel.org, Paolo Bonzini , Eric Auger , Christoph Hellwig , Yi Liu Subject: Re: [PATCH 02/10] kvm/vfio: Reduce the scope of PPC #ifdefs Message-ID: <20220415044731.GB22209@lst.de> References: <0-v1-33906a626da1+16b0-vfio_kvm_no_group_jgg@nvidia.com> <2-v1-33906a626da1+16b0-vfio_kvm_no_group_jgg@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2-v1-33906a626da1+16b0-vfio_kvm_no_group_jgg@nvidia.com> User-Agent: Mutt/1.5.17 (2007-11-01) Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org On Thu, Apr 14, 2022 at 03:46:01PM -0300, Jason Gunthorpe wrote: > Use IS_ENABLED and static inlines instead of just ifdef'ing away all the > PPC code. This allows it to be compile tested on all platforms and makes > it easier to maintain. That's even uglier than what we had. I'd rather have a new vfio_ppc.c to implement it, then you can stubs for it in the header (or IS_ENABLED if you really want) but we don't need stubs for ppc-specific arch functionality in a consumer of it.