From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Boyd Subject: Re: [PATCH 2/3] soc: qcom: smd: Use __iowrite32_copy() instead of open-coding it Date: Tue, 1 Sep 2015 13:30:19 -0700 Message-ID: <55E60ADB.8050704@codeaurora.org> References: <1441071594-15941-1-git-send-email-sboyd@codeaurora.org> <1441071594-15941-3-git-send-email-sboyd@codeaurora.org> <20150901045945.GC13472@usrtlx11787.corpusers.net> <20150901180353.GB19120@codeaurora.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20150901180353.GB19120@codeaurora.org> Sender: linux-kernel-owner@vger.kernel.org To: Bjorn Andersson Cc: Andy Gross , "linux-kernel@vger.kernel.org" , "linux-arm-msm@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" List-Id: linux-arm-msm@vger.kernel.org On 09/01/2015 11:03 AM, Stephen Boyd wrote: > On 08/31, Bjorn Andersson wrote: >> On Mon 31 Aug 18:39 PDT 2015, Stephen Boyd wrote: >> >>> We already have a function to do this and it silences some sparse >>> warnings along the way. >>> >> Didn't know that, thanks. Do you know why there's no equivalent for >> transfers in the other direction? Should we hack one up to do the same >> simplification in smd_copy_from_fifo()? > Don't know. We can certainly write one although it would be nice > if we had two users. I'll take a look. > Looks like we can convert smd and bcm47xx_nvram over. Also, we need to add it or move the readl_relaxed() to a __raw_readl() in smd_copy_from_fifo() because it's doing byte swapping that we don't want. -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752744AbbIAUa0 (ORCPT ); Tue, 1 Sep 2015 16:30:26 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:40229 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751057AbbIAUaV (ORCPT ); Tue, 1 Sep 2015 16:30:21 -0400 Subject: Re: [PATCH 2/3] soc: qcom: smd: Use __iowrite32_copy() instead of open-coding it To: Bjorn Andersson References: <1441071594-15941-1-git-send-email-sboyd@codeaurora.org> <1441071594-15941-3-git-send-email-sboyd@codeaurora.org> <20150901045945.GC13472@usrtlx11787.corpusers.net> <20150901180353.GB19120@codeaurora.org> Cc: Andy Gross , "linux-kernel@vger.kernel.org" , "linux-arm-msm@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" From: Stephen Boyd X-Enigmail-Draft-Status: N1110 Message-ID: <55E60ADB.8050704@codeaurora.org> Date: Tue, 1 Sep 2015 13:30:19 -0700 User-Agent: Mozilla/5.0 (X11; Linux i686 on x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.0.1 MIME-Version: 1.0 In-Reply-To: <20150901180353.GB19120@codeaurora.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 09/01/2015 11:03 AM, Stephen Boyd wrote: > On 08/31, Bjorn Andersson wrote: >> On Mon 31 Aug 18:39 PDT 2015, Stephen Boyd wrote: >> >>> We already have a function to do this and it silences some sparse >>> warnings along the way. >>> >> Didn't know that, thanks. Do you know why there's no equivalent for >> transfers in the other direction? Should we hack one up to do the same >> simplification in smd_copy_from_fifo()? > Don't know. We can certainly write one although it would be nice > if we had two users. I'll take a look. > Looks like we can convert smd and bcm47xx_nvram over. Also, we need to add it or move the readl_relaxed() to a __raw_readl() in smd_copy_from_fifo() because it's doing byte swapping that we don't want. -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project From mboxrd@z Thu Jan 1 00:00:00 1970 From: sboyd@codeaurora.org (Stephen Boyd) Date: Tue, 1 Sep 2015 13:30:19 -0700 Subject: [PATCH 2/3] soc: qcom: smd: Use __iowrite32_copy() instead of open-coding it In-Reply-To: <20150901180353.GB19120@codeaurora.org> References: <1441071594-15941-1-git-send-email-sboyd@codeaurora.org> <1441071594-15941-3-git-send-email-sboyd@codeaurora.org> <20150901045945.GC13472@usrtlx11787.corpusers.net> <20150901180353.GB19120@codeaurora.org> Message-ID: <55E60ADB.8050704@codeaurora.org> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On 09/01/2015 11:03 AM, Stephen Boyd wrote: > On 08/31, Bjorn Andersson wrote: >> On Mon 31 Aug 18:39 PDT 2015, Stephen Boyd wrote: >> >>> We already have a function to do this and it silences some sparse >>> warnings along the way. >>> >> Didn't know that, thanks. Do you know why there's no equivalent for >> transfers in the other direction? Should we hack one up to do the same >> simplification in smd_copy_from_fifo()? > Don't know. We can certainly write one although it would be nice > if we had two users. I'll take a look. > Looks like we can convert smd and bcm47xx_nvram over. Also, we need to add it or move the readl_relaxed() to a __raw_readl() in smd_copy_from_fifo() because it's doing byte swapping that we don't want. -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project