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 X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_2 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4F93DC432BE for ; Fri, 23 Jul 2021 17:44:34 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3846560F23 for ; Fri, 23 Jul 2021 17:44:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231633AbhGWREA (ORCPT ); Fri, 23 Jul 2021 13:04:00 -0400 Received: from frasgout.his.huawei.com ([185.176.79.56]:3480 "EHLO frasgout.his.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231462AbhGWRD7 (ORCPT ); Fri, 23 Jul 2021 13:03:59 -0400 Received: from fraeml711-chm.china.huawei.com (unknown [172.18.147.201]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4GWbxd5htXz6H730; Sat, 24 Jul 2021 01:32:53 +0800 (CST) Received: from lhreml710-chm.china.huawei.com (10.201.108.61) by fraeml711-chm.china.huawei.com (10.206.15.60) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Fri, 23 Jul 2021 19:44:31 +0200 Received: from localhost (10.210.170.238) by lhreml710-chm.china.huawei.com (10.201.108.61) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.2176.2; Fri, 23 Jul 2021 18:44:30 +0100 Date: Fri, 23 Jul 2021 18:44:04 +0100 From: Jonathan Cameron To: Mark Brown CC: Puranjay Mohan , , , , , , , , , Subject: Re: [PATCH v2 2/2] iio: accel: Add driver support for ADXL355 Message-ID: <20210723184404.0000001d@Huawei.com> In-Reply-To: <20210723171422.GK5221@sirena.org.uk> References: <20210722062155.32998-1-puranjay12@gmail.com> <20210722062155.32998-3-puranjay12@gmail.com> <20210723181022.000032bd@Huawei.com> <20210723171422.GK5221@sirena.org.uk> Organization: Huawei Technologies Research and Development (UK) Ltd. X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; i686-w64-mingw32) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.210.170.238] X-ClientProxiedBy: lhreml704-chm.china.huawei.com (10.201.108.53) To lhreml710-chm.china.huawei.com (10.201.108.61) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org On Fri, 23 Jul 2021 18:14:22 +0100 Mark Brown wrote: > On Fri, Jul 23, 2021 at 06:10:22PM +0100, Jonathan Cameron wrote: > > > @Mark. This has come up a few times recently. Are we now safe to assume > > that regmap will always copy data when used with SPI and hence we no > > longer need to ensure DMA safe buffers? > > Only for single register I/O, I'd not assume that for things like raw > I/O. Thanks for the confirmation. So in this driver that means we need DMA safe buffers for the regmap_bulk_ calls. Easiest approach is probably to use a __cacheline_aligned buffer at the end of the iio_priv() structure. > > Note that my name is spelt Mark. > I'll blame Friday. Thanks, Jonathan