All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Chen, Rong A" <rong.a.chen@intel.com>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: kernel test robot <lkp@intel.com>,
	oe-kbuild-all@lists.linux.dev,
	Linux Memory Management List <linux-mm@kvack.org>
Subject: Re: [linux-next:master 11969/13282] drivers/net/thunderbolt.c:733:47: sparse: sparse: restricted __le32 degrades to integer
Date: Thu, 8 Dec 2022 17:03:17 +0800	[thread overview]
Message-ID: <814dd916-42dc-a6c2-37d6-dc5227cdfc5a@intel.com> (raw)
In-Reply-To: <Y5GkipQqVz9WVGtq@smile.fi.intel.com>



On 12/8/2022 4:47 PM, Andy Shevchenko wrote:
> On Thu, Dec 08, 2022 at 03:04:52PM +0800, Chen, Rong A wrote:
>> On 12/6/2022 11:07 PM, Andy Shevchenko wrote:
>>> On Tue, Dec 06, 2022 at 02:40:16PM +0800, kernel test robot wrote:
>>>> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
>>>> head:   5d562c48a21eeb029a8fd3f18e1b31fd83660474
>>>> commit: a479f9264bddfd0c266615b83f784222eccf9b91 [11969/13282] net: thunderbolt: Use bitwise types in the struct thunderbolt_ip_frame_header
>>>> config: openrisc-randconfig-s041-20221205
>>>> compiler: or1k-linux-gcc (GCC) 12.1.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.4-39-gce1a6720-dirty
>>>>           # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=a479f9264bddfd0c266615b83f784222eccf9b91
>>>>           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 a479f9264bddfd0c266615b83f784222eccf9b91
>>>>           # save the config file
>>>>           mkdir build_dir && cp config build_dir/.config
>>>>           COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=openrisc SHELL=/bin/bash drivers/net/ drivers/nvme/target/
>>>>
>>>> If you fix the issue, kindly add following tag where applicable
>>>> | Reported-by: kernel test robot <lkp@intel.com>
>>>
>>> Yes, it's expected. The change flip-flopped the warnings. As a result the
>>> amount of warnings has been reduced from 17 to 9.
>>
>> Hi Andy,
>>
>> Sorry for the inconvenience, we'll add it to our ignore list.
> 
> Ideally you should have compared the warnings before and after the change and
> tell something like warnings number dropped or increased to N (arbitrary
> number, should be real one based on the parser's output) and leave new warnings
> to be produced.

Hi Andy,

Thanks for your advice, We have similar logic under internal reviewing 
to avoid such false positive.

Best Regards,
Rong Chen


> 
>>> (wsum warning is not counted in the above statistics)
> 
> And this warning is still in place, so it shouldn't be reflected in the
> statistics.
> 
>>>> sparse warnings: (new ones prefixed by >>)
>>>>>> drivers/net/thunderbolt.c:733:47: sparse: sparse: restricted __le32 degrades to integer
>>>>>> drivers/net/thunderbolt.c:741:47: sparse: sparse: restricted __le16 degrades to integer
>>>>      drivers/net/thunderbolt.c:742:44: sparse: sparse: restricted __le16 degrades to integer
>>>>>> drivers/net/thunderbolt.c:838:40: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le32 [usertype] frame_size @@     got unsigned int [assigned] [usertype] frame_size @@
>>>>      drivers/net/thunderbolt.c:838:40: sparse:     expected restricted __le32 [usertype] frame_size
>>>>      drivers/net/thunderbolt.c:838:40: sparse:     got unsigned int [assigned] [usertype] frame_size
>>>>>> drivers/net/thunderbolt.c:839:41: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le32 [usertype] frame_count @@     got unsigned int [usertype] @@
>>>>      drivers/net/thunderbolt.c:839:41: sparse:     expected restricted __le32 [usertype] frame_count
>>>>      drivers/net/thunderbolt.c:839:41: sparse:     got unsigned int [usertype]
>>>>>> drivers/net/thunderbolt.c:840:41: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 [usertype] frame_index @@     got unsigned short [usertype] @@
>>>>      drivers/net/thunderbolt.c:840:41: sparse:     expected restricted __le16 [usertype] frame_index
>>>>      drivers/net/thunderbolt.c:840:41: sparse:     got unsigned short [usertype]
>>>>>> drivers/net/thunderbolt.c:841:38: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le16 [usertype] frame_id @@     got unsigned short [usertype] @@
>>>>      drivers/net/thunderbolt.c:841:38: sparse:     expected restricted __le16 [usertype] frame_id
>>>>      drivers/net/thunderbolt.c:841:38: sparse:     got unsigned short [usertype]
>>>>      drivers/net/thunderbolt.c:842:62: sparse: sparse: restricted __le32 degrades to integer
>>>>      drivers/net/thunderbolt.c:842:35: sparse: sparse: restricted __le16 degrades to integer
>>>>      drivers/net/thunderbolt.c:953:23: sparse: sparse: incorrect type in initializer (different base types) @@     expected restricted __wsum [usertype] wsum @@     got restricted __be32 [usertype] @@
>>>>      drivers/net/thunderbolt.c:953:23: sparse:     expected restricted __wsum [usertype] wsum
>>>>      drivers/net/thunderbolt.c:953:23: sparse:     got restricted __be32 [usertype]
>>>
> 

      reply	other threads:[~2022-12-08  9:04 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-06  6:40 [linux-next:master 11969/13282] drivers/net/thunderbolt.c:733:47: sparse: sparse: restricted __le32 degrades to integer kernel test robot
2022-12-06 15:07 ` Andy Shevchenko
2022-12-08  7:04   ` Chen, Rong A
2022-12-08  8:47     ` Andy Shevchenko
2022-12-08  9:03       ` Chen, Rong A [this message]

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=814dd916-42dc-a6c2-37d6-dc5227cdfc5a@intel.com \
    --to=rong.a.chen@intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=linux-mm@kvack.org \
    --cc=lkp@intel.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    /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.