linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: bjorn.andersson@linaro.org
Cc: linux-bluetooth@vger.kernel.org
Subject: [bug report] soc: qcom: smd: Transition client drivers from smd to rpmsg
Date: Tue, 13 Jul 2021 12:53:50 +0300	[thread overview]
Message-ID: <YO1irj8sHBvQ3QqH@mwanda> (raw)

Hello Bjorn Andersson,

The patch 5052de8deff5: "soc: qcom: smd: Transition client drivers
from smd to rpmsg" from Mar 27, 2017, leads to the following static
checker warning:

	drivers/bluetooth/btqcomsmd.c:140 btqcomsmd_probe()
	warn: 'btq->acl_channel' is not an error pointer

drivers/bluetooth/btqcomsmd.c
   125  static int btqcomsmd_probe(struct platform_device *pdev)
   126  {
   127          struct btqcomsmd *btq;
   128          struct hci_dev *hdev;
   129          void *wcnss;
   130          int ret;
   131  
   132          btq = devm_kzalloc(&pdev->dev, sizeof(*btq), GFP_KERNEL);
   133          if (!btq)
   134                  return -ENOMEM;
   135  
   136          wcnss = dev_get_drvdata(pdev->dev.parent);
   137  
   138          btq->acl_channel = qcom_wcnss_open_channel(wcnss, "APPS_RIVA_BT_ACL",
   139                                                     btqcomsmd_acl_callback, btq);
   140          if (IS_ERR(btq->acl_channel))

The qcom_wcnss_open_channel() original returned error pointers on error
but now it returns NULL on error and error pointers if it is disabled in
the .config file.

   141                  return PTR_ERR(btq->acl_channel);
   142  
   143          btq->cmd_channel = qcom_wcnss_open_channel(wcnss, "APPS_RIVA_BT_CMD",
   144                                                     btqcomsmd_cmd_callback, btq);
   145          if (IS_ERR(btq->cmd_channel)) {
   146                  ret = PTR_ERR(btq->cmd_channel);
   147                  goto destroy_acl_channel;
   148          }
   149  

regards,
dan carpenter

                 reply	other threads:[~2021-07-13  9:54 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=YO1irj8sHBvQ3QqH@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=bjorn.andersson@linaro.org \
    --cc=linux-bluetooth@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).