Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp1919589iog; Sun, 26 Jun 2022 01:37:57 -0700 (PDT) X-Google-Smtp-Source: AGRyM1sNa5Ubez1PoWuq7qXQ+pgecyjMPXRlmUT6QzO38JizGTJtKrVaoHGch0y0P46TI0TPF4ui X-Received: by 2002:a05:6402:b48:b0:435:728c:d127 with SMTP id bx8-20020a0564020b4800b00435728cd127mr9634696edb.392.1656232677228; Sun, 26 Jun 2022 01:37:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656232677; cv=none; d=google.com; s=arc-20160816; b=demNw9QMX5oA44cirEg/27+oQKzipY9n4JPQD+Z5S5WwC+x5QyxdGcUrds+C9cHo/t c9seexvux2bFJkkcSBb0c/zxYxyVlvvaOle0Zr7RoRuljnVO7yyn9FGbVpPd3jedFj8R MGxxhIZ1GuVhHVyOvliFJuYInskkGBTWPgtZ2HcCNCrvZICHTgmRNiazb+MRNopO2Xsi rXM3rIbSoha4IE68N3iEtVubl1jQzCadr/K2mrB/FgXP9Qc9KZct5Lkdi7nAWNj0Omma 4sGNEELvu/M7oHybxcqa3rlowhqqSnhtp5ulYz7KQTZfYoTlwNZFQ5D/rnt5WDdWbSBJ DdWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=6DTz5ZSjtuXemHRbcIQkszM25Azwq/Ri8Y+8p3W24tM=; b=Lj0vbkTcHA2BfUOYqzAq/ei33vLR6jenOqQosQjZLITZA/SN2u2zP06PiBgZxsfNU5 fwBt6NBLhhDGeHo/v1B1E1QDqjpxdx+CQyrJwzEuZ+0ummBJj80WwEHt+JE/CUxy9bEj 6ol/gXj/grNiR376sN8r2jwv583ir+Qlam3xHimbwtiMfdihYp5+BjDhCvMQDJPpuz3E O/WNKwPDnyp4EZxgLlkf7kPrWiHNAHeus7e7/FjUtqpigfTlu8iyJTHI0J3aNAyIB9EL uFOyspM1yiq/pKsQsgl7jKaWMdNZH1cPClRy/15tueB3UpzuiFbvhtQXfHbgflVMUS5t yeKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=f6yc1RaN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c15-20020a05640227cf00b0043783a7f05bsi1790228ede.207.2022.06.26.01.37.32; Sun, 26 Jun 2022 01:37:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=f6yc1RaN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232981AbiFZIg3 (ORCPT + 99 others); Sun, 26 Jun 2022 04:36:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59736 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229508AbiFZIg2 (ORCPT ); Sun, 26 Jun 2022 04:36:28 -0400 Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C77431054B; Sun, 26 Jun 2022 01:36:25 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sin.source.kernel.org (Postfix) with ESMTPS id 11B25CE0FC4; Sun, 26 Jun 2022 08:36:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 41580C341D8; Sun, 26 Jun 2022 08:36:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1656232582; bh=juR3pWHFZdE8Vf6QGsSTJiJ2f3ZwildJoxwQZWNpG/E=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=f6yc1RaNJwQq5dElIkyuYvUvwHkvBLBi9KqlHP2ZC+oxWcerSMGK3hkxIM7cIAAT/ TtueQ33cy4/n0Uda61TReBytE65eLfQrezytZmtm7bX//WKI/yOT60iTP49ZEIOPSW 6z1NOCnw36qsukMeObt289BsjK4np0rxC1P8TL2Fy3MIi0PXPCcxYI0ThEmMrCWGfS UrkYBYjapcfJFTuf2LfH5cpnGXFFNt0wE6A6XBDTb085dl806k7RyMDAUO+JHUYTkX Au2xvaXvS/pK8PTQWyJuWsS1hRHbV8q3oa+eOltOLdGmLNGlNuBwPHqKBVX/LvLixJ OvRvGfKxK4K+w== Received: by mail-yb1-f174.google.com with SMTP id h187so9569940ybg.0; Sun, 26 Jun 2022 01:36:22 -0700 (PDT) X-Gm-Message-State: AJIora+WE7CBSMpN5yeJ0ShnL/3L5tQrerlTtqlFOGQtN7+wOCgkBfb9 CrGeHkihKKllOOy0iR/ubsfNxVTQV7l50KK79Pc= X-Received: by 2002:a25:8b8b:0:b0:669:b37d:f9cd with SMTP id j11-20020a258b8b000000b00669b37df9cdmr7722013ybl.394.1656232581073; Sun, 26 Jun 2022 01:36:21 -0700 (PDT) MIME-Version: 1.0 References: <20220617125750.728590-1-arnd@kernel.org> <20220617125750.728590-4-arnd@kernel.org> <6ba86afe-bf9f-1aca-7af1-d0d348d75ffc@gmail.com> <6d1d88ee-1cf6-c735-1e6d-bafd2096e322@gmail.com> In-Reply-To: <6d1d88ee-1cf6-c735-1e6d-bafd2096e322@gmail.com> From: Arnd Bergmann Date: Sun, 26 Jun 2022 10:36:02 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 3/3] arch/*/: remove CONFIG_VIRT_TO_BUS To: Michael Schmitz Cc: linux-scsi , Linux Kernel Mailing List , Arnd Bergmann , Jakub Kicinski , Christoph Hellwig , Marek Szyprowski , Robin Murphy , "open list:IOMMU DRIVERS" , Khalid Aziz , "Maciej W . Rozycki" , Matt Wang , Miquel van Smoorenburg , Mark Salyzyn , linuxppc-dev , linux-arch , alpha , linux-m68k , Parisc List , Denis Efremov , Geert Uytterhoeven , Michael Ellerman Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org (On Sun, Jun 26, 2022 at 7:21 AM Michael Schmitz wrote: > > The same could be done for the two vme drivers (scsi/mvme147.c > > and ethernet/82596.c), which do the cache management but > > apparently don't need swiotlb bounce buffering. > > > > Rewriting the drivers to modern APIs is of course non-trivial, > > and if you want a shortcut here, I would suggest introducing > > platform specific helpers similar to isa_virt_to_bus() and call > > them amiga_virt_to_bus() and vme_virt_to_bus, respectively. > > I don't think Amiga and m68k VME differ at all in that respect, so might > just call it m68k_virt_to_bus() for now. > > > Putting these into a platform specific header file at least helps > > clarify that both the helper functions and the drivers using them > > are non-portable. > > There are no platform specific header files other than asm/amigahw.h and > asm/mvme147hw.h, currently only holding register address definitions. > Would it be OK to add m68k_virt_to_bus() in there if it can't remain in > asm/virtconvert.h, Geert? In that case, I would just leave it under the current name and not change m68k at all. I don't like the m68k_virt_to_bus() name because there is not anything CPU specific in what it does, and keeping it in a common header does nothing to prevent it from being used on other platforms either. > >> 32bit powerpc is a different matter though. > > > > It's similar, but unrelated. The two apple ethernet drivers > > (bmac and mace) can again either get changed to use the > > dma-mapping interfaces, or get a custom pmac_virt_to_bus()/ > > pmac_bus_to_virt() helper. > > Hmmm - I see Finn had done the DMA API conversion on macmace.c which > might give some hints on what to do about mace.c ... no idea about > bmac.c though. And again, haven't got hardware to test, so custom > helpers is it, then. Ok. Arnd