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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4DDDFECAAD8 for ; Thu, 22 Sep 2022 21:12:47 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id A037B940007; Thu, 22 Sep 2022 17:12:46 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 9B1536B0072; Thu, 22 Sep 2022 17:12:46 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 82CCC940007; Thu, 22 Sep 2022 17:12:46 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id 6DF1D6B0071 for ; Thu, 22 Sep 2022 17:12:46 -0400 (EDT) Received: from smtpin02.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 4185016032B for ; Thu, 22 Sep 2022 21:12:46 +0000 (UTC) X-FDA: 79940970732.02.A9042E2 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by imf05.hostedemail.com (Postfix) with ESMTP id AF440100003 for ; Thu, 22 Sep 2022 21:12:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1663881164; x=1695417164; h=date:from:to:cc:subject:message-id:mime-version; bh=ZqhUPV9rT2t6UUqHoImf+BoNZ65V4FSIm4ntoLT9OSw=; b=inhcjwggx/BeZ0FfvleTZzNqUwccHUyH87HUsi2TdHPfZ3sIzUnC8DpU 1T7WZboi1SuPHFVNNogF1jBbmMVCTl3ptRouMcMEXitM/thgIYWDu4NRI vqVrA5//MXf6CUmy4nTYbamFFdJ5tejd+GIQdQrrsroRQUNKhyNGkaj3w /R0L9dm18puSocL3HUPJVvv+MLm37hq30HR14XBGcGRoUuumJ0Y+c/vhV M8Hm2I7czml9nk1n4V7CKYOO/F2ZcC3QXXvpSV8lDz3hn4+El5V1VELLK tiAwWZIF3iG2IGaYo5aSmaB4Wv/Qc2uCWoVopaxL1j1PyVt/+0B1VXgPL g==; X-IronPort-AV: E=McAfee;i="6500,9779,10478"; a="283526617" X-IronPort-AV: E=Sophos;i="5.93,337,1654585200"; d="scan'208";a="283526617" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Sep 2022 14:12:43 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.93,337,1654585200"; d="scan'208";a="571133825" Received: from lkp-server01.sh.intel.com (HELO c0a60f19fe7e) ([10.239.97.150]) by orsmga003.jf.intel.com with ESMTP; 22 Sep 2022 14:12:41 -0700 Received: from kbuild by c0a60f19fe7e with local (Exim 4.96) (envelope-from ) id 1obTUv-0004xw-0n; Thu, 22 Sep 2022 21:12:41 +0000 Date: Fri, 23 Sep 2022 05:11:41 +0800 From: kernel test robot To: Mikko Perttunen Cc: kbuild-all@lists.01.org, Linux Memory Management List , Thierry Reding Subject: [linux-next:master 6516/8813] drivers/gpu/drm/tegra/uapi.c:119:51: error: passing argument 2 of 'host1x_memory_context_alloc' from incompatible pointer type Message-ID: <202209230512.dSBGYXPr-lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1663881165; a=rsa-sha256; cv=none; b=dzfZJ2Vj3z3mBNV/K+bunqYkwdQ0yGMqxmlL9L8JpuiC5vAbVmq1cf4IN6uymieckSofE9 brRQwU1LY3mIB2VZJw7ocEK1ILbVuXEovEhG74X/THC7VQOZofIEbBcpUk0fLkzpmfX0RG 6n+tk32cNoX5jAJaKUBM74xTzCSh7Qg= ARC-Authentication-Results: i=1; imf05.hostedemail.com; dkim=none ("invalid DKIM record") header.d=intel.com header.s=Intel header.b=inhcjwgg; spf=pass (imf05.hostedemail.com: domain of lkp@intel.com designates 134.134.136.126 as permitted sender) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1663881165; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding:in-reply-to: references:dkim-signature; bh=yk3aUXqEVCh2rZAYZPa3V8S4y3YJt+ZPGU3hRVUp96Q=; b=AISpKNxn86RPebw36PpLj7qWRR+iNE7c0YuzhrFva9mG7CQYGRGB+MSx9JTsFH/3vrr5tZ iAhIjA3mPHPRJbYTfPaF6FQuBrYAg1I9t/Wd1KEoatpEHgXyN+ZqM//NFJwJ2vZ4VPXb2c I7PDMcuae1TRDQ+ezlycjNy4fl2GjAA= X-Stat-Signature: zsgwh3ukp37q8spish7ygdmsjpa69rsh X-Rspamd-Queue-Id: AF440100003 X-Rspam-User: X-Rspamd-Server: rspam11 Authentication-Results: imf05.hostedemail.com; dkim=none ("invalid DKIM record") header.d=intel.com header.s=Intel header.b=inhcjwgg; spf=pass (imf05.hostedemail.com: domain of lkp@intel.com designates 134.134.136.126 as permitted sender) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com X-HE-Tag: 1663881164-739015 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: 483fed3b5dc8ce3644c83d24240cf5756fb0993e commit: a11092cd032615f72470cd2ec1a4542e0ed72b14 [6516/8813] gpu: host1x: Select context device based on attached IOMMU config: arm-randconfig-r011-20220922 (https://download.01.org/0day-ci/archive/20220923/202209230512.dSBGYXPr-lkp@intel.com/config) compiler: arm-linux-gnueabi-gcc (GCC) 12.1.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=a11092cd032615f72470cd2ec1a4542e0ed72b14 git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git git fetch --no-tags linux-next master git checkout a11092cd032615f72470cd2ec1a4542e0ed72b14 # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash drivers/gpu/drm/tegra/ If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot All errors (new ones prefixed by >>): drivers/gpu/drm/tegra/uapi.c: In function 'tegra_drm_ioctl_channel_open': >> drivers/gpu/drm/tegra/uapi.c:119:51: error: passing argument 2 of 'host1x_memory_context_alloc' from incompatible pointer type [-Werror=incompatible-pointer-types] 119 | host, client->base.dev, get_task_pid(current, PIDTYPE_TGID)); | ~~~~~~~~~~~~^~~~ | | | struct device * In file included from drivers/gpu/drm/tegra/uapi.c:4: include/linux/host1x.h:478:85: note: expected 'struct pid *' but argument is of type 'struct device *' 478 | struct pid *pid) | ~~~~~~~~~~~~^~~ >> drivers/gpu/drm/tegra/uapi.c:118:51: error: too many arguments to function 'host1x_memory_context_alloc' 118 | context->memory_context = host1x_memory_context_alloc( | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ include/linux/host1x.h:477:45: note: declared here 477 | static inline struct host1x_memory_context *host1x_memory_context_alloc(struct host1x *host1x, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ cc1: some warnings being treated as errors vim +/host1x_memory_context_alloc +119 drivers/gpu/drm/tegra/uapi.c 75 76 int tegra_drm_ioctl_channel_open(struct drm_device *drm, void *data, struct drm_file *file) 77 { 78 struct host1x *host = tegra_drm_to_host1x(drm->dev_private); 79 struct tegra_drm_file *fpriv = file->driver_priv; 80 struct tegra_drm *tegra = drm->dev_private; 81 struct drm_tegra_channel_open *args = data; 82 struct tegra_drm_client *client = NULL; 83 struct tegra_drm_context *context; 84 int err; 85 86 if (args->flags) 87 return -EINVAL; 88 89 context = kzalloc(sizeof(*context), GFP_KERNEL); 90 if (!context) 91 return -ENOMEM; 92 93 client = tegra_drm_find_client(tegra, args->host1x_class); 94 if (!client) { 95 err = -ENODEV; 96 goto free; 97 } 98 99 if (client->shared_channel) { 100 context->channel = host1x_channel_get(client->shared_channel); 101 } else { 102 context->channel = host1x_channel_request(&client->base); 103 if (!context->channel) { 104 err = -EBUSY; 105 goto free; 106 } 107 } 108 109 /* Only allocate context if the engine supports context isolation. */ 110 if (device_iommu_mapped(client->base.dev) && client->ops->can_use_memory_ctx) { 111 bool supported; 112 113 err = client->ops->can_use_memory_ctx(client, &supported); 114 if (err) 115 goto put_channel; 116 117 if (supported) > 118 context->memory_context = host1x_memory_context_alloc( > 119 host, client->base.dev, get_task_pid(current, PIDTYPE_TGID)); 120 121 if (IS_ERR(context->memory_context)) { 122 if (PTR_ERR(context->memory_context) != -EOPNOTSUPP) { 123 err = PTR_ERR(context->memory_context); 124 goto put_channel; 125 } else { 126 /* 127 * OK, HW does not support contexts or contexts 128 * are disabled. 129 */ 130 context->memory_context = NULL; 131 } 132 } 133 } 134 135 err = xa_alloc(&fpriv->contexts, &args->context, context, XA_LIMIT(1, U32_MAX), 136 GFP_KERNEL); 137 if (err < 0) 138 goto put_memctx; 139 140 context->client = client; 141 xa_init_flags(&context->mappings, XA_FLAGS_ALLOC1); 142 143 args->version = client->version; 144 args->capabilities = 0; 145 146 if (device_get_dma_attr(client->base.dev) == DEV_DMA_COHERENT) 147 args->capabilities |= DRM_TEGRA_CHANNEL_CAP_CACHE_COHERENT; 148 149 return 0; 150 151 put_memctx: 152 if (context->memory_context) 153 host1x_memory_context_put(context->memory_context); 154 put_channel: 155 host1x_channel_put(context->channel); 156 free: 157 kfree(context); 158 159 return err; 160 } 161 -- 0-DAY CI Kernel Test Service https://01.org/lkp