Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp9268554ybi; Wed, 10 Jul 2019 07:27:42 -0700 (PDT) X-Google-Smtp-Source: APXvYqzyPScZXoBBb357/WWzZQ7F7TeBfjApwPg9++yIHk+vR/f67AcfCg8qwlvd1Vnug1du1tHb X-Received: by 2002:a17:90a:1a0d:: with SMTP id 13mr6938494pjk.99.1562768862237; Wed, 10 Jul 2019 07:27:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562768862; cv=none; d=google.com; s=arc-20160816; b=voS0pXwr/E8PsASq30fQF4ZuqDjKy87h6cXasx9eNi+xoIRj9VM3pTEagppJTKbWvk lShEBZaB/fJTbRlLyeWob20mKwqVT5QGvivvReOBgu2zN3t/Jwv7QfmRBirM59/s2GNt Yxz4Y0RWZGKEmACssxVuT32+4GVgpSUaR7BpSouMJd2xlH/oJGhmAdp8sj/A+8MXgBEV N0oA3Nap+t5vZAZIvsEi8lDNnvC7h6czOky4zK7bGkFiVMEAjzB6fGD/B9c9LXKukZki 4TOeCcouFIUdMbSMkFEAD1I0P+oW+LflaXmn0iizE2/G1Cp5f7A3MPvv1c6eTmtuX4W3 Dp4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:mail-followup-to :message-id:subject:cc:to:from:date:dkim-signature; bh=nv9p/G+s9XtbbbTHB54r/CSbDNWoOb77fcrWutVfYq8=; b=uA68rVROozq19IWyBJ9HPRqeL+LVjpFaoAJ96rJdC7z4PbnB3+zafbJRtSS7paoPRw RdHmmeL0osAN/f/Iqsx6TUopzzxeg+LbtyS36dIz+UYwPLIfBdEYCFFvDBrYuRCSLdzu XfqeDeU9Xd0vt+L7eUrV9H3SC5qy6wES0A1iwAHhYkYW8+ALMVwYNVsKHeyN5ey+DEi1 uJrI4WGwfmPc77dao43hFQDpCVv1BKzuM2BcjToQLSwUSn4OdcwRieJuGbv9Ob9UkpKS r92Z3eqFr5Es9typ3tPA7nrwHPK2Hvc4CnRKwl5M0P+IAx8UaRVsyOO1NFDdupGAL1KB /YEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=eBMeHMKy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i17si2338212pju.96.2019.07.10.07.27.25; Wed, 10 Jul 2019 07:27:42 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=eBMeHMKy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727896AbfGJO0o (ORCPT + 99 others); Wed, 10 Jul 2019 10:26:44 -0400 Received: from mail-lf1-f41.google.com ([209.85.167.41]:46904 "EHLO mail-lf1-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727154AbfGJO0n (ORCPT ); Wed, 10 Jul 2019 10:26:43 -0400 Received: by mail-lf1-f41.google.com with SMTP id z15so1722596lfh.13 for ; Wed, 10 Jul 2019 07:26:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-disposition:in-reply-to:user-agent; bh=nv9p/G+s9XtbbbTHB54r/CSbDNWoOb77fcrWutVfYq8=; b=eBMeHMKybkIEBqDr6w99KrnEXGyDkPz9sItt1EtsmxnQD7Gnwk4wtQy03KZnCF+86K q9+1vvKZxI6oR64bYdA05nmnBZ9riEKWeLM6dPEP0dzyNPXobbRLxHqxAq18KGQBFY7q HpQs4KXs5sVRXuRO0XnOmYQK8bqn8MR27ymwxrBKRpTxTUlPjcqnpeiMhlc/d+75lYKH 7ibShzSop6ZSjxPWxWZH3zkjsH/pr5kFYze0THExtPDeoEnl++fzgOQHMeGIaYwTSPGg NRaF2ROCpDiEqJZtIbCH7PQend6jhJOY5fgAS+XFw52G4OB6MACNOv376QT/lD9zDojV aSZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id :mail-followup-to:references:mime-version:content-disposition :in-reply-to:user-agent; bh=nv9p/G+s9XtbbbTHB54r/CSbDNWoOb77fcrWutVfYq8=; b=k+c/D3LT6hay0RhxQjIjD5Urbhl8028x80JUhTaXVr4ZpJoCs6PzGdTP6BBpqsJUxz K0lA8QtraYm8cPeK6AcKunDIH57wmuZhPbScx175RmwLEdegepkezJ8EFHnglAbsQNxZ hiDJJQgppyVV1UgifckokEzSLq3TrRgImOjGsmiVY3SsbC+iNHL6gJIhz4klQaTemRtv RYdB64+37pWK290M3DDIVQdgILf8pJxkn2r6xlINegbM/qr/LFqIFG96FVGUuVuNEgpg GrrajmiWt9WeXKzBzfmyjfdGH5iGwJf6syOVbOXhbEXU78fxMx+IgnQsqyl+iBbD031i 13VA== X-Gm-Message-State: APjAAAWOy5F27VEdot95IH2EnrwCpj8z07iNclm+QhJwHJU537UqUnv3 POtulzRFnupP8C4gUJQOufs34Q== X-Received: by 2002:a19:4f42:: with SMTP id a2mr14942041lfk.23.1562768801531; Wed, 10 Jul 2019 07:26:41 -0700 (PDT) Received: from khorivan (59-201-94-178.pool.ukrtel.net. [178.94.201.59]) by smtp.gmail.com with ESMTPSA id n24sm501910ljc.25.2019.07.10.07.26.40 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 10 Jul 2019 07:26:41 -0700 (PDT) Date: Wed, 10 Jul 2019 17:26:39 +0300 From: Ivan Khoronzhuk To: Arnd Bergmann Cc: "David S. Miller" , Grygorii Strashko , Andrew Lunn , Ilias Apalodimas , linux-omap@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] [net-next] davinci_cpdma: don't cast dma_addr_t to pointer Message-ID: <20190710142637.GA5375@khorivan> Mail-Followup-To: Arnd Bergmann , "David S. Miller" , Grygorii Strashko , Andrew Lunn , Ilias Apalodimas , linux-omap@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20190710080106.24237-1-arnd@arndb.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <20190710080106.24237-1-arnd@arndb.de> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 10, 2019 at 10:00:33AM +0200, Arnd Bergmann wrote: >dma_addr_t may be 64-bit wide on 32-bit architectures, so it is not >valid to cast between it and a pointer: > >drivers/net/ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_submit_si': >drivers/net/ethernet/ti/davinci_cpdma.c:1047:12: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast] >drivers/net/ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_idle_submit_mapped': >drivers/net/ethernet/ti/davinci_cpdma.c:1114:12: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] >drivers/net/ethernet/ti/davinci_cpdma.c: In function 'cpdma_chan_submit_mapped': >drivers/net/ethernet/ti/davinci_cpdma.c:1164:12: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] > >Solve this by using two separate members in 'struct submit_info'. >Since this avoids the use of the 'flag' member, the structure does >not even grow in typical configurations. > >Fixes: 6670acacd59e ("net: ethernet: ti: davinci_cpdma: add dma mapped submit") >Signed-off-by: Arnd Bergmann Despite "flags" could be used for smth else (who knows), looks ok. Reviewed-by: Ivan Khoronzhuk -- Regards, Ivan Khoronzhuk