Linux wireless drivers development
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Eugene Krasnikov <k.eugene.e@gmail.com>
Cc: Fengguang Wu <fengguang.wu@intel.com>,
	kbuild-all@01.org, "John W. Linville" <linville@tuxdriver.com>,
	linux-wireless <linux-wireless@vger.kernel.org>,
	wcn36xx <wcn36xx@lists.infradead.org>
Subject: Re: [wireless-next:master 82/98] drivers/net/wireless/ath/wcn36xx/wcn36xx.h:88:24: sparse: incorrect type in assignment (different base types)
Date: Sat, 12 Oct 2013 20:25:56 +0200	[thread overview]
Message-ID: <1381602356.14243.4.camel@jlt4.sipsolutions.net> (raw)
In-Reply-To: <CAFSJ42Y3x9bzKO8jo-n8Vn7ei38FkYVqW5Gog+_pa_j83ZUXhw@mail.gmail.com> (sfid-20131011_223914_611136_4CE5E6C4)

On Fri, 2013-10-11 at 21:39 +0100, Eugene Krasnikov wrote:

> Do you see the same warning? 

Yes

> With the latest sparse i do not see this
> warning. 

$ sparse --version
v0.4.4-133-g5449cfb

> I assume this warning depends on sparse version since with my
> environment it does not pop up. Also from code perspective it looks
> fine. Any ideas?:)

Hard to believe - did you pass the CF= on the command line? I suggest

ccflags-y += -D__CHECK_ENDIAN__

in your Makefile.

Also, code might be fine, but buff_to_be() is still not a good idea
since it breaks all endian annotation.

Also, I suggested to run smatch, I guess you never did:
drivers/net/wireless/ath/wcn36xx/smd.c:1314 wcn36xx_smd_send_beacon() warn: inconsistent returns mutex:&wcn->hal_mutex: locked (1289 [(-12)]) unlocked (1314 [0], 1314 [s32min-(-1),1-s32max])
drivers/net/wireless/ath/wcn36xx/smd.c:1357 wcn36xx_smd_update_proberesp_tmpl() warn: inconsistent returns mutex:&wcn->hal_mutex: locked (1330 [(-7)]) unlocked (1357 [0], 1357 [s32min-(-1),1-s32max])
drivers/net/wireless/ath/wcn36xx/smd.c:1626 wcn36xx_smd_keep_alive_req() warn: inconsistent returns mutex:&wcn->hal_mutex: locked (1609 [(-22)]) unlocked (1626 [0], 1626 [s32min-(-1),1-s32max])
drivers/net/wireless/ath/wcn36xx/smd.c:2041 wcn36xx_smd_rsp_process() error: potential null dereference 'msg_ind'.  (kmalloc returns null)

johannes


  reply	other threads:[~2013-10-12 18:26 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <525720d0.6xVLGLwuRrqxqOBI%fengguang.wu@intel.com>
     [not found] ` <20131011014733.GD11191@localhost>
2013-10-11  7:19   ` [wireless-next:master 82/98] drivers/net/wireless/ath/wcn36xx/wcn36xx.h:88:24: sparse: incorrect type in assignment (different base types) Eugene Krasnikov
2013-10-11  7:24     ` Johannes Berg
2013-10-11 20:39       ` Eugene Krasnikov
2013-10-12 18:25         ` Johannes Berg [this message]
2013-10-12 19:17           ` Eugene Krasnikov

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=1381602356.14243.4.camel@jlt4.sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=fengguang.wu@intel.com \
    --cc=k.eugene.e@gmail.com \
    --cc=kbuild-all@01.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=wcn36xx@lists.infradead.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