From patchwork Fri Nov 30 17:06:00 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Logan Gunthorpe X-Patchwork-Id: 10706851 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 76BE913A4 for ; Fri, 30 Nov 2018 17:06:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 62AEB304E5 for ; Fri, 30 Nov 2018 17:06:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 56F35304ED; Fri, 30 Nov 2018 17:06:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B2B46304E5 for ; Fri, 30 Nov 2018 17:06:28 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id CC3426B5945; Fri, 30 Nov 2018 12:06:16 -0500 (EST) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id A2FF26B5944; Fri, 30 Nov 2018 12:06:16 -0500 (EST) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 835FF6B5943; Fri, 30 Nov 2018 12:06:16 -0500 (EST) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-it1-f200.google.com (mail-it1-f200.google.com [209.85.166.200]) by kanga.kvack.org (Postfix) with ESMTP id 47A206B5949 for ; Fri, 30 Nov 2018 12:06:16 -0500 (EST) Received: by mail-it1-f200.google.com with SMTP id p66so7498623itc.0 for ; Fri, 30 Nov 2018 09:06:16 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-original-authentication-results:x-gm-message-state:from:to:cc :date:message-id:mime-version:content-transfer-encoding:subject; bh=yqTJJLnWBjXR2lmRbGB6oqRKmd7yJH1Id17eEXhwy5s=; b=M/f3us3cgrDzuQVp/E96b8e1TuzXu4nQFul1uZapmcTTqiCclmtLxTLKpTLgP2FazF ADmw/0X0q3wohJkRmsrCtwasL6TcEPJ5hjKQ5odcSBotHUYzSfmDjBm2IGrDgQOAdYNs IRrBlIDUJVPdiSEPCsde9glW/Bh/mxAFBKvfZuSXXbR35s+EBsGIsqljzWCvhn+7ozt5 Rj7F2BTMWeFZ7VoC3ginAvAlSrLOqxe6Kj0q6OWRI6gQUoqx73MW6m/GxZhkO2mxfMUV /vb/B43yC86CROF0QrNtZmNsINaWdZa3Q0TLGf9ZqJzeRw7Gt3Qb1ynryA9QtrRzvP2K fyJg== X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of gunthorp@deltatee.com designates 207.54.116.67 as permitted sender) smtp.mailfrom=gunthorp@deltatee.com X-Gm-Message-State: AA+aEWaXkzZg4pht98w4ewAqUsjWInSOQ1psv02V6QCaHCCRoBfxUEN0 HsGlZ1ck93X4xf56MqtRK6B2hcw9clcPoGwXqn4nby37rT9U8Jqm08TWiwLTfvukB9ma2Fl3pDB oi3tdTSg0qGjeNa0asleyK4fjNnArHfh9lc9D52QefeekM4qYJAbOkqM+MUc/c9BO9Q== X-Received: by 2002:a5d:944d:: with SMTP id x13mr1576291ior.282.1543597576035; Fri, 30 Nov 2018 09:06:16 -0800 (PST) X-Google-Smtp-Source: AFSGD/W/Tx4i0qGdunYZ3Jg7FyvIXnCGRljshqMbE13KbV0okgFMvIN/qMZydutsKyJ3Y6cEmAGb X-Received: by 2002:a5d:944d:: with SMTP id x13mr1576229ior.282.1543597574842; Fri, 30 Nov 2018 09:06:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543597574; cv=none; d=google.com; s=arc-20160816; b=UqYcIockzLR/DU5frXF2niJR92Z461cRC9uLnmcnxe2ehWFAdfjwIeg7lA5AG1wkmM AlHl6EDCQp/JGjIa++P/Dp49bUY95+sprqzL+xjhzqHCVoRd7q5bkPjaXkxiaxTHgL+j 7CP8g6Nqf2IF7clSBG6TPb/nETGm+OEhlMmBT6s6V2fDbp9Med98kqk6OT4PJaAgG6Wa ldzaWAaB1CNf+l7ZIRMde0yN9R70GJxIsqPK1aKYe9rSNAS1JLU0qncpq1V0dUfLPApP 9a4uOD16if9yT1OXPuozCPvtDVpn6agLwDKUHQkh8ho1bApgZsiQ9T2qL+aFETKZmL3g 6ogg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=subject:content-transfer-encoding:mime-version:message-id:date:cc :to:from; bh=yqTJJLnWBjXR2lmRbGB6oqRKmd7yJH1Id17eEXhwy5s=; b=k6obASLp17VcSuL+/Vf0zp1h7SLsyinRtXR0nhpJ/MsylJZYLNuGQvl1vzbjGa4/+N ZixEQQQ/I84ElAm0fM+/RA1c4LDm1y6iAe9nPfLxdojg2mg7RevNLHSNOEMg2+/x1oFM HO0VaruJrZDs1h4qJAcy7Zac+V6vktRo2e/20EViFHMEzIKzp+8a2h86XPDwg6olAIqp BPxSLrSJYP5DgCaFuHxPxE42d0D5CboE6yZKFIOLcraX9pfLdNAbuW2uzF602/A0Y3Td kHW8kxLKVppYoXKXTmlQf8nPTodHpCgGtqTSXHjV6LECFPu4gRsUvRdy8UTGuX4XWwNN DvCw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of gunthorp@deltatee.com designates 207.54.116.67 as permitted sender) smtp.mailfrom=gunthorp@deltatee.com Received: from ale.deltatee.com (ale.deltatee.com. [207.54.116.67]) by mx.google.com with ESMTPS id y12si3193533iob.32.2018.11.30.09.06.14 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 30 Nov 2018 09:06:14 -0800 (PST) Received-SPF: pass (google.com: domain of gunthorp@deltatee.com designates 207.54.116.67 as permitted sender) client-ip=207.54.116.67; Authentication-Results: mx.google.com; spf=pass (google.com: domain of gunthorp@deltatee.com designates 207.54.116.67 as permitted sender) smtp.mailfrom=gunthorp@deltatee.com Received: from cgy1-donard.priv.deltatee.com ([172.16.1.31]) by ale.deltatee.com with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1gSmEz-0000ql-3E; Fri, 30 Nov 2018 10:06:10 -0700 Received: from gunthorp by cgy1-donard.priv.deltatee.com with local (Exim 4.89) (envelope-from ) id 1gSmEx-0004V4-9z; Fri, 30 Nov 2018 10:06:07 -0700 From: Logan Gunthorpe To: linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, linux-ntb@googlegroups.com, linux-crypto@vger.kernel.org, linux-mm@kvack.org, Andrew Morton Cc: Arnd Bergmann , Greg Kroah-Hartman , Andy Shevchenko , =?utf-8?q?Horia_Geant=C4=83?= , Logan Gunthorpe Date: Fri, 30 Nov 2018 10:06:00 -0700 Message-Id: <20181130170606.17252-1-logang@deltatee.com> X-Mailer: git-send-email 2.19.0 MIME-Version: 1.0 X-SA-Exim-Connect-IP: 172.16.1.31 X-SA-Exim-Rcpt-To: linux-ntb@googlegroups.com, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, linux-crypto@vger.kernel.org, linux-mm@kvack.org, akpm@linux-foundation.org, arnd@arndb.de, gregkh@linuxfoundation.org, andy.shevchenko@gmail.com, horia.geanta@nxp.com, logang@deltatee.com X-SA-Exim-Mail-From: gunthorp@deltatee.com Subject: [PATCH v24 0/6] Add io{read|write}64 to io-64-atomic headers X-SA-Exim-Version: 4.2.1 (built Tue, 02 Aug 2016 21:08:31 +0000) X-SA-Exim-Scanned: Yes (on ale.deltatee.com) X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: X-Virus-Scanned: ClamAV using ClamSMTP This is resend number 5. In June, Andrew picked this up and it was in linux-next for a couple weeks. There were a couple problems that were identified and solved back then and I'd like to get the ball rolling again. Andrew, can you please pick this set up again so it can get into linux-next? Or let me know if there's something else I should do. I've been try to get this in for 15 months and I'm getting a bit tired of submitting it repeatedly with no responses. Thanks, Logan --- Changes since v23: - Rebased onto v4.20-rc4 (No Changes) Changes since v22: - Rebased onto v4.20-rc1 (No Changes) Changes since v21: - Rebased onto v4.19-rc6 (No Changes) Changes since v20: - Rebased onto v4.19-rc3 (No Changes) Changes since v19: - Rebased onto v4.19-rc1 (No Changes) Changes since v18: - Dropped the CAAM patch as it was subtly wrong and broke when people tested it in linux-next. Seeing the code is much trickier than it appears, we'll leave it to its maintainers to clean it up, should they chose. - Restored the ioread64/iowrite64 extern prototypes as despite appearing to be unusued, they are in fact used in a rare corner case by the caam driver on 64bit powerpc. This was reported by Guenter testing on linux-next. - Rebased onto v4.18-rc4 (No Changes) Changes since v17: - Rebased onto v4.18-rc1 (No Changes) Changes since v16: - Rebased onto v4.17-rc4 (No Changes) Changes since v15: - Rebased onto v4.17-rc1, dropping the powerpc patches which were picked up by Michael Changes since v14: - Rebased onto v4.16-rc7 - Replace the first two patches so that instead of correcting the endianness annotations we change to using writeX() and readX() with swabX() calls. This makes the big-endian functions more symmetric with the little-endian versions (with respect to barriers that are not included in the raw functions). As a side effect, it also fixes the kbuild warnings that the first two patches tried to address. Changes since v13: - Changed the subject of patch 0001 to correct a nit pointed out by Luc Changes since v12: - Rebased onto v4.16-rc6 - Split patch 0001 into two and reworked the commit log as requested by Luc Van Oostenryck Changes since v11: - Rebased onto v4.16-rc5 - Added a patch (0001) to fix some old and new sparse warnings that the kbuild robot warned about this cycle. The latest version of sparse was required to reproduce these. - Added a patch (0002) to add io{read|write}64 to parisc which the kbuild robot also found errors for this cycle Changes since v10: - Rebased onto v4.16-rc4, this droped the drm/tilcdc patch which was picked up by that tree and is already in 4.16. Changes since v9: - Rebased onto v4.15-rc6 - Fixed a couple of issues in the new version of the CAAM patch as pointed out by Horia Changes since v8: - Rebased onto v4.15-rc2, as a result rewrote patch 7 seeing someone did some similar cleanup in that area. - Added a patch to clean up the Switchtec NTB driver which landed in v4.15-rc1 Changes since v7: - Fix minor nits from Andy Shevchenko - Rebased onto v4.14-rc1 Changes since v6: ** none ** Changes since v5: - Added a fix to the tilcdc driver to ensure it doesn't use the non-atomic operation. (This includes adding io{read|write}64[be]_is_nonatomic defines). Changes since v4: - Add functions so the powerpc implementation of iomap.c compiles. (As noticed by Horia) Changes since v3: - I noticed powerpc didn't use the appropriate functions seeing readq/writeq were not defined when iomap.h was included. Thus I've included a patch to adjust this - Fixed some mistakes with a couple of the defines in io-64-nonatomic* headers - Fixed a typo noticed by Horia. (earlier versions were drastically different) -- Logan Gunthorpe (6): iomap: Use non-raw io functions for io{read|write}XXbe parisc: iomap: introduce io{read|write}64 iomap: introduce io{read|write}64_{lo_hi|hi_lo} io-64-nonatomic: add io{read|write}64[be]{_lo_hi|_hi_lo} macros ntb: ntb_hw_intel: use io-64-nonatomic instead of in-driver hacks ntb: ntb_hw_switchtec: Cleanup 64bit IO defines to use the common header arch/parisc/include/asm/io.h | 9 ++ arch/parisc/lib/iomap.c | 64 +++++++++++ arch/powerpc/include/asm/io.h | 2 + drivers/ntb/hw/intel/ntb_hw_intel.h | 30 +----- drivers/ntb/hw/mscc/ntb_hw_switchtec.c | 36 +------ include/asm-generic/iomap.h | 22 ++++ include/linux/io-64-nonatomic-hi-lo.h | 64 +++++++++++ include/linux/io-64-nonatomic-lo-hi.h | 64 +++++++++++ lib/iomap.c | 140 ++++++++++++++++++++++++- 9 files changed, 366 insertions(+), 65 deletions(-) -- 2.19.0