From patchwork Tue Jun 21 09:10:26 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Vetter X-Patchwork-Id: 9189959 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 8F3AB60756 for ; Tue, 21 Jun 2016 09:10:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7CCEB27FBB for ; Tue, 21 Jun 2016 09:10:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 718B327FE4; Tue, 21 Jun 2016 09:10:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DB9FD27FBB for ; Tue, 21 Jun 2016 09:10:56 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 322376E682; Tue, 21 Jun 2016 09:10:47 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lf0-x242.google.com (mail-lf0-x242.google.com [IPv6:2a00:1450:4010:c07::242]) by gabe.freedesktop.org (Postfix) with ESMTPS id A640E6E254 for ; Tue, 21 Jun 2016 09:10:44 +0000 (UTC) Received: by mail-lf0-x242.google.com with SMTP id w130so2053091lfd.2 for ; Tue, 21 Jun 2016 02:10:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=gMgtVBsHvDOKsrtTX6YAL/j16gitdoBLKEYzIrd3lhU=; b=BtE8uBtcmvKtRwCCBM/YQYxGW8OGWxf9kXRLh8mkIqCPDMxE/jywHrFXuTq9fDyAdt jk0RiusiZxSP5bFm4XQ7VsAZbOTZ7sbLL0DpC0mebp7FEAcRTNmVuBGQIZ4KEL1IkzHa v9zKt7nnKhdmVj5NSWOu703BLASkD1pTfo6k8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=gMgtVBsHvDOKsrtTX6YAL/j16gitdoBLKEYzIrd3lhU=; b=cPexsm6ZmtE4k1OygktCLgcwzUWnCSjgvZ7o16kKgqeBkrpYeki+ibAl1JZfSjdU2z ghjVKuCAWeiXjtGicGYphqGht36vkFURdPMCz7oZf9WEEtx9/4d6WO/F8glNVullvcPo tb56i5iYsdfcvQkeyj3c0tR1YsyNBqwxGfwODA4mVA2OQDxnNWhySVwmBQ7aynwBiYsj A+b704c/QQdB4zEYYS9kWJcsI1FNgx+vL7/Lsa12WwVul/EgqLW9M9cSW/fL5LcxI66Q XHs+v/1Rl+yixWg2AQBbD4KBrx8zoxgIk5QXKf//QjsEpg0TemalfHBfBoW0SZGk/7YX bBiQ== X-Gm-Message-State: ALyK8tJIZhxoIl+9XzX0pER1BNFn2jmu474eJSHBCT1XOBAIOjkvj1URB+MoEm0tbuQ+4w== X-Received: by 10.28.86.214 with SMTP id k205mr2149759wmb.17.1466500242439; Tue, 21 Jun 2016 02:10:42 -0700 (PDT) Received: from phenom.ffwll.local ([2a02:168:56b5:0:ac27:b86c:7764:9429]) by smtp.gmail.com with ESMTPSA id v70sm1930380wmf.18.2016.06.21.02.10.41 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 21 Jun 2016 02:10:41 -0700 (PDT) From: Daniel Vetter To: DRI Development Subject: [PATCH 01/10] drm/amd-kfd: Clean up inline handling Date: Tue, 21 Jun 2016 11:10:26 +0200 Message-Id: <1466500235-21282-2-git-send-email-daniel.vetter@ffwll.ch> X-Mailer: git-send-email 2.8.1 In-Reply-To: <1466500235-21282-1-git-send-email-daniel.vetter@ffwll.ch> References: <1466500235-21282-1-git-send-email-daniel.vetter@ffwll.ch> Cc: Daniel Vetter , Intel Graphics Development 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: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP - inline functions need to be static inline, otherwise gcc can opt to not inline and the linker gets unhappy. - no forward decls for inline functions, just include the right headers. Cc: Oded Gabbay Cc: Ben Goz Signed-off-by: Daniel Vetter Reviewed-by: Oded Gabbay --- drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.h | 4 ++-- drivers/gpu/drm/amd/amdkfd/kfd_priv.h | 3 --- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.h b/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.h index ec4036a09f3e..a625b9137da2 100644 --- a/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.h +++ b/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.h @@ -187,12 +187,12 @@ int init_pipelines(struct device_queue_manager *dqm, unsigned int get_first_pipe(struct device_queue_manager *dqm); unsigned int get_pipes_num(struct device_queue_manager *dqm); -extern inline unsigned int get_sh_mem_bases_32(struct kfd_process_device *pdd) +static inline unsigned int get_sh_mem_bases_32(struct kfd_process_device *pdd) { return (pdd->lds_base >> 16) & 0xFF; } -extern inline unsigned int +static inline unsigned int get_sh_mem_bases_nybble_64(struct kfd_process_device *pdd) { return (pdd->lds_base >> 60) & 0x0E; diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_priv.h b/drivers/gpu/drm/amd/amdkfd/kfd_priv.h index d0d5f4baf72d..80113c335966 100644 --- a/drivers/gpu/drm/amd/amdkfd/kfd_priv.h +++ b/drivers/gpu/drm/amd/amdkfd/kfd_priv.h @@ -617,10 +617,7 @@ int kgd2kfd_resume(struct kfd_dev *kfd); int kfd_init_apertures(struct kfd_process *process); /* Queue Context Management */ -inline uint32_t lower_32(uint64_t x); -inline uint32_t upper_32(uint64_t x); struct cik_sdma_rlc_registers *get_sdma_mqd(void *mqd); -inline uint32_t get_sdma_base_addr(struct cik_sdma_rlc_registers *m); int init_queue(struct queue **q, struct queue_properties properties); void uninit_queue(struct queue *q);