[tty:tty-next 83/86] drivers/tty/serial/stm32-usart.c:740:20: warning: cast from pointer to integer of different size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git tty-next
head:   a3081893cab48df3facff8144d9506610213241a
commit: 3489187204eb75e5635d8836babfd0a18be613f4 [83/86] serial: stm32: adding dma support
config: sparc-allmodconfig (attached as .config)
compiler: sparc64-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
        wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 3489187204eb75e5635d8836babfd0a18be613f4
        # save the attached .config to linux build tree
        make.cross ARCH=sparc 

All warnings (new ones prefixed by >>):

   drivers/tty/serial/stm32-usart.c: In function 'stm32_of_dma_rx_probe':
>> drivers/tty/serial/stm32-usart.c:740:20: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
     config.src_addr = (dma_addr_t)port->membase + ofs->rdr;
                       ^
   drivers/tty/serial/stm32-usart.c: In function 'stm32_of_dma_tx_probe':
   drivers/tty/serial/stm32-usart.c:812:20: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
     config.dst_addr = (dma_addr_t)port->membase + ofs->tdr;
                       ^

vim +740 drivers/tty/serial/stm32-usart.c

   724		/* Request DMA RX channel */
   725		stm32port->rx_ch = dma_request_slave_channel(dev, "rx");
   726		if (!stm32port->rx_ch) {
   727			dev_info(dev, "rx dma alloc failed\n");
   728			return -ENODEV;
   729		}
   730		stm32port->rx_buf = dma_alloc_coherent(&pdev->dev, RX_BUF_L,
   731							 &stm32port->rx_dma_buf,
   732							 GFP_KERNEL);
   733		if (!stm32port->rx_buf) {
   734			ret = -ENOMEM;
   735			goto alloc_err;
   736		}
   737	
   738		/* Configure DMA channel */
   739		memset(&config, 0, sizeof(config));
 > 740		config.src_addr = (dma_addr_t)port->membase + ofs->rdr;
   741		config.src_addr_width = DMA_SLAVE_BUSWIDTH_1_BYTE;
   742	
   743		ret = dmaengine_slave_config(stm32port->rx_ch, &config);
   744		if (ret < 0) {
   745			dev_err(dev, "rx dma channel config failed\n");
   746			ret = -ENODEV;
   747			goto config_err;
   748		}

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

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux