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=-1.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 6D5FDC433E0 for ; Tue, 30 Jun 2020 14:26:13 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 38BBD20672 for ; Tue, 30 Jun 2020 14:26:13 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="2Rm6avFE"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="Qq+285UL" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 38BBD20672 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=1/vGXHn4rNiDaVb93JLDupNxSfcMg6tB6X6dKCoXBlM=; b=2Rm6avFEGoc4BcGHzMw1Lgj6f dd4xhhiuH+1j4HYneEDf/d0/5t0h+vs54TNhCBDgL5qIrCV6YrChZXJuBS/J04+O7TZpA3UtGBHMc 1V2Dj2S0PgdTDGydFcps7A1cs3p8n8GvbZPlLjr+MctDFqvN2Ca+0W9DJb0NQnQErviN2Y3RgeYI7 FVIqOyOmOE7e79Q0fWorhrfBKngXoVXseINOnsP6RUwPFhQ07e1d+UDTzj3oAh40g1TiLAydptekj TVpK/HekcYGxrM8bpOYsp+8gx9V063EA4thvfya68gi1gcvNElYHFiq/BvTEbmTeM+dz2aB4Csucn pAaqK3pyw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jqHBc-00033O-HZ; Tue, 30 Jun 2020 14:24:36 +0000 Received: from mail.kernel.org ([198.145.29.99]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jqHBZ-00032P-Da; Tue, 30 Jun 2020 14:24:34 +0000 Received: from localhost (unknown [122.182.251.219]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 41D7720672; Tue, 30 Jun 2020 14:24:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1593527072; bh=ge1JjR8yCKRp2SCQdixfwB2tfDCzu96qp1bblnzo3MY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Qq+285ULYVSVmGGKvuGr5XnuXZMuyUROGjNId+dkUNPMw5K1hiSmZev8R46Ydkia1 Ljkn6bPbDnvHp5z/eiHxGVXQCKTpv/cMXe+gndtgIWRYRL44My8agPHpLIyzAS2MYt WrmY7cIyTsbSSEnixH18uvI9PlcMgxoTMDvdf11A= Date: Tue, 30 Jun 2020 19:54:27 +0530 From: Vinod Koul To: Amit Tomer Subject: Re: [PATCH v4 02/10] dmaengine: Actions: Add support for S700 DMA engine Message-ID: <20200630142427.GP2599@vkoul-mobl> References: <1591697830-16311-1-git-send-email-amittomer25@gmail.com> <1591697830-16311-3-git-send-email-amittomer25@gmail.com> <20200624061529.GF2324254@vkoul-mobl> <20200629095207.GG2599@vkoul-mobl> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Andre Przywara , linux-actions@lists.infradead.org, linux-kernel@vger.kernel.org, cristian.ciocaltea@gmail.com, Manivannan Sadhasivam , dmaengine@vger.kernel.org, dan.j.williams@intel.com, Andreas =?iso-8859-1?Q?F=E4rber?= , linux-arm-kernel Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 30-06-20, 15:17, Amit Tomer wrote: > Hi Vinod, > > On Mon, Jun 29, 2020 at 3:22 PM Vinod Koul wrote: > > > If you use of_device_get_match_data() you will not fall into this :) > > But again, of_device_get_match_data() returns void *, and we need > "uintptr_t" in order to type cast it properly (at-least without > warning). Not really, you can cast from void * to you own structure.. btw why do you need uintptr_t? > > Also, while looking around found the similar warning for other file > where it uses " of_device_get_match_data()" > drivers/pci/controller/pcie-iproc-platform.c:56:15: warning: cast to > smaller integer type 'enum iproc_pcie_type' from 'const void *' > [-Wvoid-pointer-to-enum-cast] > pcie->type = (enum iproc_pcie_type) of_device_get_match_data(dev); The problem is a pointer to enum conversion :) I think the right way would be to do would be below soc_type = (enum foo)of_device_get_match_data(dev); or soc_type = (unsigned long) of_device_get_match_data(dev); which I think should be fine in gcc, but possibly give you above warning in clang.. but i thought that was fixed in clang https://reviews.llvm.org/D75758 Thanks -- ~Vinod _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel