From patchwork Tue Jan 12 21:23:51 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?TWFyZWsgT2zFocOhaw==?= X-Patchwork-Id: 8021011 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 5E052BEEE5 for ; Tue, 12 Jan 2016 21:24:11 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 97E13203B4 for ; Tue, 12 Jan 2016 21:24:10 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id C785720416 for ; Tue, 12 Jan 2016 21:24:09 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2C72072135; Tue, 12 Jan 2016 13:24:09 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm0-f66.google.com (mail-wm0-f66.google.com [74.125.82.66]) by gabe.freedesktop.org (Postfix) with ESMTPS id BB73F72063 for ; Tue, 12 Jan 2016 13:24:07 -0800 (PST) Received: by mail-wm0-f66.google.com with SMTP id b14so33529133wmb.1 for ; Tue, 12 Jan 2016 13:24:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-type:content-transfer-encoding; bh=VdB099vTWICZFStHGPkaj6QlmxmyOiGqTxTrJK8476U=; b=FbiBFAYXD1kdEtNmKC7E3MF7aCScwB7/xlTat0QdJ0tUVUSsiEEu6Xaiam/cR9SUkQ KPkH1S3pMLCuLJvBO6WBwq9yB87Ba3JaPkkxjlnTUf1yoLq3EXswbIUbW/YkIY9J4rQ4 Z4PMNstNO9gAoJrRgtxSuBKc08ob9Hy4d4Ves1lfUHqX/3hFa49UukrT36K7rNNkf6Cq 6aMUKtP0O/815bM8m2Tuzv3jaFHkv/3r6fUck1IaewkGlSnPnSHAzqRJ4n3g78meBI04 d/7wSdz/PgFPH8luc6UBVtmAVejsEkvPJ1KjvE+l1AOQXQHvAvRiIATGP5xAHJJAkGye ABig== X-Received: by 10.28.227.67 with SMTP id a64mr21456436wmh.74.1452633846289; Tue, 12 Jan 2016 13:24:06 -0800 (PST) Received: from heaven.amd.com (ip-89-103-110-3.net.upcbroadband.cz. [89.103.110.3]) by smtp.gmail.com with ESMTPSA id n5sm19291001wmf.3.2016.01.12.13.24.05 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 12 Jan 2016 13:24:05 -0800 (PST) From: =?UTF-8?q?Marek=20Ol=C5=A1=C3=A1k?= To: dri-devel@lists.freedesktop.org Subject: [PATCH 05/10] amdgpu: Cast pointer to uintptr_t for assignment to unsigned integer Date: Tue, 12 Jan 2016 22:23:51 +0100 Message-Id: <1452633836-26855-6-git-send-email-maraeo@gmail.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1452633836-26855-1-git-send-email-maraeo@gmail.com> References: <1452633836-26855-1-git-send-email-maraeo@gmail.com> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Michel Dänzer CC amdgpu_bo.lo ../../amdgpu/amdgpu_bo.c: In function 'amdgpu_create_bo_from_user_mem': ../../amdgpu/amdgpu_bo.c:539:12: warning: assignment makes integer from pointer without a cast [-Wint-conversion] args.addr = cpu; ^ Reviewed-by: Jammy Zhou --- amdgpu/amdgpu_bo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/amdgpu/amdgpu_bo.c b/amdgpu/amdgpu_bo.c index 61db58c..2ae1c18 100644 --- a/amdgpu/amdgpu_bo.c +++ b/amdgpu/amdgpu_bo.c @@ -538,7 +538,7 @@ int amdgpu_create_bo_from_user_mem(amdgpu_device_handle dev, struct amdgpu_bo *bo; struct drm_amdgpu_gem_userptr args; - args.addr = cpu; + args.addr = (uintptr_t)cpu; args.flags = AMDGPU_GEM_USERPTR_ANONONLY | AMDGPU_GEM_USERPTR_REGISTER; args.size = size; r = drmCommandWriteRead(dev->fd, DRM_AMDGPU_GEM_USERPTR,