All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild@lists.01.org
Subject: [linux-next:master 1018/14669] drivers/net/wireless/ath/ath11k/qmi.c:1905:17: sparse: expected void
Date: Fri, 09 Oct 2020 20:03:15 +0800	[thread overview]
Message-ID: <202010092013.AHv21aww-lkp@intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 7754 bytes --]

CC: kbuild-all(a)lists.01.org
TO: Govind Singh <govinds@codeaurora.org>
CC: Kalle Valo <kvalo@codeaurora.org>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   d67bc7812221606e1886620a357b13f906814af7
commit: 1ff8ed786d5d8ed6d109affe6d732dfc85a45b2e [1018/14669] ath11k: use remoteproc only with AHB devices
:::::: branch date: 3 hours ago
:::::: commit date: 8 weeks ago
config: openrisc-randconfig-s031-20201009 (attached as .config)
compiler: or1k-linux-gcc (GCC) 9.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.2-219-g1ba7c820-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=1ff8ed786d5d8ed6d109affe6d732dfc85a45b2e
        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 1ff8ed786d5d8ed6d109affe6d732dfc85a45b2e
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=openrisc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>


"sparse warnings: (new ones prefixed by >>)"
   drivers/net/wireless/ath/ath11k/qmi.c:1905:17: sparse: sparse: incorrect type in argument 1 (different address spaces) @@     expected void *addr @@     got void [noderef] <asn:2> *[assigned] bdf_addr @@
>> drivers/net/wireless/ath/ath11k/qmi.c:1905:17: sparse:     expected void *addr
   drivers/net/wireless/ath/ath11k/qmi.c:1905:17: sparse:     got void [noderef] <asn:2> *[assigned] bdf_addr

vim +1905 drivers/net/wireless/ath/ath11k/qmi.c

d5c65159f28953 Kalle Valo      2019-11-23  1838  
d5c65159f28953 Kalle Valo      2019-11-23  1839  static int ath11k_qmi_load_bdf(struct ath11k_base *ab)
d5c65159f28953 Kalle Valo      2019-11-23  1840  {
d5c65159f28953 Kalle Valo      2019-11-23  1841  	struct qmi_wlanfw_bdf_download_req_msg_v01 *req;
d5c65159f28953 Kalle Valo      2019-11-23  1842  	struct qmi_wlanfw_bdf_download_resp_msg_v01 resp;
d5c65159f28953 Kalle Valo      2019-11-23  1843  	struct qmi_txn txn = {};
d5c65159f28953 Kalle Valo      2019-11-23  1844  	void __iomem *bdf_addr = NULL;
d5c65159f28953 Kalle Valo      2019-11-23  1845  	int type, ret;
d5c65159f28953 Kalle Valo      2019-11-23  1846  
d5c65159f28953 Kalle Valo      2019-11-23  1847  	req = kzalloc(sizeof(*req), GFP_KERNEL);
d5c65159f28953 Kalle Valo      2019-11-23  1848  	if (!req)
d5c65159f28953 Kalle Valo      2019-11-23  1849  		return -ENOMEM;
d5c65159f28953 Kalle Valo      2019-11-23  1850  	memset(&resp, 0, sizeof(resp));
d5c65159f28953 Kalle Valo      2019-11-23  1851  
3b94ae4c62db0b Anilkumar Kolli 2020-06-16  1852  	bdf_addr = ioremap(ab->hw_params.bdf_addr, ATH11K_QMI_BDF_MAX_SIZE);
d5c65159f28953 Kalle Valo      2019-11-23  1853  	if (!bdf_addr) {
d5c65159f28953 Kalle Valo      2019-11-23  1854  		ath11k_warn(ab, "qmi ioremap error for BDF\n");
d5c65159f28953 Kalle Valo      2019-11-23  1855  		ret = -EIO;
d5c65159f28953 Kalle Valo      2019-11-23  1856  		goto out;
d5c65159f28953 Kalle Valo      2019-11-23  1857  	}
d5c65159f28953 Kalle Valo      2019-11-23  1858  
d5c65159f28953 Kalle Valo      2019-11-23  1859  	for (type = 0; type < ATH11K_QMI_MAX_FILE_TYPE; type++) {
d5c65159f28953 Kalle Valo      2019-11-23  1860  		req->valid = 1;
d5c65159f28953 Kalle Valo      2019-11-23  1861  		req->file_id_valid = 1;
d5c65159f28953 Kalle Valo      2019-11-23  1862  		req->file_id = ab->qmi.target.board_id;
d5c65159f28953 Kalle Valo      2019-11-23  1863  		req->total_size_valid = 1;
d5c65159f28953 Kalle Valo      2019-11-23  1864  		req->seg_id_valid = 1;
d5c65159f28953 Kalle Valo      2019-11-23  1865  		req->seg_id = type;
d5c65159f28953 Kalle Valo      2019-11-23  1866  		req->data_valid = 0;
d5c65159f28953 Kalle Valo      2019-11-23  1867  		req->data_len = ATH11K_QMI_MAX_BDF_FILE_NAME_SIZE;
d5c65159f28953 Kalle Valo      2019-11-23  1868  		req->bdf_type = 0;
d5c65159f28953 Kalle Valo      2019-11-23  1869  		req->bdf_type_valid = 0;
d5c65159f28953 Kalle Valo      2019-11-23  1870  		req->end_valid = 1;
d5c65159f28953 Kalle Valo      2019-11-23  1871  		req->end = 1;
d5c65159f28953 Kalle Valo      2019-11-23  1872  
d5c65159f28953 Kalle Valo      2019-11-23  1873  		ret = ath11k_qmi_prepare_bdf_download(ab, type, req, bdf_addr);
d5c65159f28953 Kalle Valo      2019-11-23  1874  		if (ret < 0)
d5c65159f28953 Kalle Valo      2019-11-23  1875  			goto out_qmi_bdf;
d5c65159f28953 Kalle Valo      2019-11-23  1876  
d5c65159f28953 Kalle Valo      2019-11-23  1877  		ret = qmi_txn_init(&ab->qmi.handle, &txn,
d5c65159f28953 Kalle Valo      2019-11-23  1878  				   qmi_wlanfw_bdf_download_resp_msg_v01_ei,
d5c65159f28953 Kalle Valo      2019-11-23  1879  				   &resp);
d5c65159f28953 Kalle Valo      2019-11-23  1880  		if (ret < 0)
d5c65159f28953 Kalle Valo      2019-11-23  1881  			goto out_qmi_bdf;
d5c65159f28953 Kalle Valo      2019-11-23  1882  
d5c65159f28953 Kalle Valo      2019-11-23  1883  		ret = qmi_send_request(&ab->qmi.handle, NULL, &txn,
d5c65159f28953 Kalle Valo      2019-11-23  1884  				       QMI_WLANFW_BDF_DOWNLOAD_REQ_V01,
d5c65159f28953 Kalle Valo      2019-11-23  1885  				       QMI_WLANFW_BDF_DOWNLOAD_REQ_MSG_V01_MAX_LEN,
d5c65159f28953 Kalle Valo      2019-11-23  1886  				       qmi_wlanfw_bdf_download_req_msg_v01_ei, req);
d5c65159f28953 Kalle Valo      2019-11-23  1887  		if (ret < 0) {
d5c65159f28953 Kalle Valo      2019-11-23  1888  			qmi_txn_cancel(&txn);
d5c65159f28953 Kalle Valo      2019-11-23  1889  			goto out_qmi_bdf;
d5c65159f28953 Kalle Valo      2019-11-23  1890  		}
d5c65159f28953 Kalle Valo      2019-11-23  1891  
d5c65159f28953 Kalle Valo      2019-11-23  1892  		ret = qmi_txn_wait(&txn, msecs_to_jiffies(ATH11K_QMI_WLANFW_TIMEOUT_MS));
d5c65159f28953 Kalle Valo      2019-11-23  1893  		if (ret < 0)
d5c65159f28953 Kalle Valo      2019-11-23  1894  			goto out_qmi_bdf;
d5c65159f28953 Kalle Valo      2019-11-23  1895  
d5c65159f28953 Kalle Valo      2019-11-23  1896  		if (resp.resp.result != QMI_RESULT_SUCCESS_V01) {
d5c65159f28953 Kalle Valo      2019-11-23  1897  			ath11k_warn(ab, "qmi BDF download failed, result: %d, err: %d\n",
d5c65159f28953 Kalle Valo      2019-11-23  1898  				    resp.resp.result, resp.resp.error);
d5c65159f28953 Kalle Valo      2019-11-23  1899  			ret = -EINVAL;
d5c65159f28953 Kalle Valo      2019-11-23  1900  			goto out_qmi_bdf;
d5c65159f28953 Kalle Valo      2019-11-23  1901  		}
d5c65159f28953 Kalle Valo      2019-11-23  1902  	}
d5c65159f28953 Kalle Valo      2019-11-23  1903  
d5c65159f28953 Kalle Valo      2019-11-23  1904  out_qmi_bdf:
d5c65159f28953 Kalle Valo      2019-11-23 @1905  	iounmap(bdf_addr);
d5c65159f28953 Kalle Valo      2019-11-23  1906  out:
d5c65159f28953 Kalle Valo      2019-11-23  1907  	kfree(req);
d5c65159f28953 Kalle Valo      2019-11-23  1908  	return ret;
d5c65159f28953 Kalle Valo      2019-11-23  1909  }
d5c65159f28953 Kalle Valo      2019-11-23  1910  

:::::: The code@line 1905 was first introduced by commit
:::::: d5c65159f2895379e11ca13f62feabe93278985d ath11k: driver for Qualcomm IEEE 802.11ax devices

:::::: TO: Kalle Valo <kvalo@codeaurora.org>
:::::: CC: Kalle Valo <kvalo@codeaurora.org>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 29135 bytes --]

                 reply	other threads:[~2020-10-09 12:03 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202010092013.AHv21aww-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.