lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <201901071849.E4VZI7L7%fengguang.wu@intel.com>
Date:   Mon, 7 Jan 2019 18:42:34 +0800
From:   kbuild test robot <lkp@...el.com>
To:     Vivek Gautam <vivek.gautam@...eaurora.org>
Cc:     kbuild-all@...org, sean@...rly.run, airlied@...ux.ie,
        dri-devel@...ts.freedesktop.org, maarten.lankhorst@...ux.intel.com,
        maxime.ripard@...tlin.com, daniel@...ll.ch, robdclark@...il.com,
        jcrouse@...eaurora.org, linux-arm-msm@...r.kernel.org,
        freedreno@...ts.freedesktop.org, linux-kernel@...r.kernel.org,
        Vivek Gautam <vivek.gautam@...eaurora.org>
Subject: Re: [PATCH 1/1] drm/prime: Use sg_dma_len() macro to get sg's length

Hi Vivek,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on linus/master]
[also build test ERROR on v5.0-rc1 next-20190107]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Vivek-Gautam/drm-prime-Use-sg_dma_len-macro-to-get-sg-s-length/20190107-181350
config: x86_64-randconfig-x013-201901 (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All errors (new ones prefixed by >>):

   drivers/gpu/drm/drm_prime.c: In function 'drm_prime_sg_to_page_addr_arrays':
>> drivers/gpu/drm/drm_prime.c:948:9: error: implicit declaration of function 'sg_dma_length'; did you mean 'sg_dma_len'? [-Werror=implicit-function-declaration]
      len = sg_dma_length(sg);
            ^~~~~~~~~~~~~
            sg_dma_len
   cc1: some warnings being treated as errors

vim +948 drivers/gpu/drm/drm_prime.c

   926	
   927	/**
   928	 * drm_prime_sg_to_page_addr_arrays - convert an sg table into a page array
   929	 * @sgt: scatter-gather table to convert
   930	 * @pages: optional array of page pointers to store the page array in
   931	 * @addrs: optional array to store the dma bus address of each page
   932	 * @max_entries: size of both the passed-in arrays
   933	 *
   934	 * Exports an sg table into an array of pages and addresses. This is currently
   935	 * required by the TTM driver in order to do correct fault handling.
   936	 */
   937	int drm_prime_sg_to_page_addr_arrays(struct sg_table *sgt, struct page **pages,
   938					     dma_addr_t *addrs, int max_entries)
   939	{
   940		unsigned count;
   941		struct scatterlist *sg;
   942		struct page *page;
   943		u32 len, index;
   944		dma_addr_t addr;
   945	
   946		index = 0;
   947		for_each_sg(sgt->sgl, sg, sgt->nents, count) {
 > 948			len = sg_dma_length(sg);
   949			page = sg_page(sg);
   950			addr = sg_dma_address(sg);
   951	
   952			while (len > 0) {
   953				if (WARN_ON(index >= max_entries))
   954					return -1;
   955				if (pages)
   956					pages[index] = page;
   957				if (addrs)
   958					addrs[index] = addr;
   959	
   960				page++;
   961				addr += PAGE_SIZE;
   962				len -= PAGE_SIZE;
   963				index++;
   964			}
   965		}
   966		return 0;
   967	}
   968	EXPORT_SYMBOL(drm_prime_sg_to_page_addr_arrays);
   969	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Download attachment ".config.gz" of type "application/gzip" (27069 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ