Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754168AbbFJIuH (ORCPT ); Wed, 10 Jun 2015 04:50:07 -0400 Received: from www.osadl.org ([62.245.132.105]:33378 "EHLO www.osadl.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753778AbbFJIuA (ORCPT ); Wed, 10 Jun 2015 04:50:00 -0400 From: Nicholas Mc Guire To: Russell King Cc: Marek Szyprowski , Arnd Bergmann , Will Deacon , Catalin Marinas , Stefano Stabellini , Thierry Reding , linux-kernel@vger.kernel.org, Nicholas Mc Guire Subject: [PATCH] dma-mapping: harmonize definition of DMA_ERROR_CODE Date: Wed, 10 Jun 2015 10:41:34 +0200 Message-Id: <1433925694-12865-1-git-send-email-hofrat@osadl.org> X-Mailer: git-send-email 1.7.10.4 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1573 Lines: 44 All architectures except arm that define DMA_ERROR_CODE are casting it to (dma_addr_t) - as it is always compared to dma_addr_t in arm as well this could be harmonized. Signed-off-by: Nicholas Mc Guire --- This also fixes the build warning in ./arch/arm/include/asm/dma-mapping.h: In function 'dma_mapping_error': ./arch/arm/include/asm/dma-mapping.h:176:18: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] While it fixes this build warning it causes another build warning - so from that perspective its not much of an improvement - never the less having this harmonized with all other archs makes sense I think. Patch was compile tested with exynos_defconfig Patch is against 4.1-rc7 (localversion-next is -next-20150609) arch/arm/include/asm/dma-mapping.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/include/asm/dma-mapping.h b/arch/arm/include/asm/dma-mapping.h index b52101d..68e41e8 100644 --- a/arch/arm/include/asm/dma-mapping.h +++ b/arch/arm/include/asm/dma-mapping.h @@ -14,7 +14,7 @@ #include #include -#define DMA_ERROR_CODE (~0) +#define DMA_ERROR_CODE (~(dma_addr_t)0x0) extern struct dma_map_ops arm_dma_ops; extern struct dma_map_ops arm_coherent_dma_ops; -- 1.7.10.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/