public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [pdx86-platform-drivers-x86:for-next 56/92] drivers/platform/surface/surface_aggregator_tabletsw.c:425:9: sparse: sparse: restricted __le32 degrades to integer
@ 2022-07-17  7:04 kernel test robot
  0 siblings, 0 replies; 2+ messages in thread
From: kernel test robot @ 2022-07-17  7:04 UTC (permalink / raw)
  To: Maximilian Luz; +Cc: kbuild-all, Andy Shevchenko, Hans de Goede, linux-kernel

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git for-next
head:   5c8b3f11565e64366d53295e8004edaa1fcf1ec9
commit: 9f794056db5bb1e1add83ed553b6aec57298358c [56/92] platform/surface: Add KIP/POS tablet-mode switch driver
config: x86_64-allmodconfig (https://download.01.org/0day-ci/archive/20220717/202207171459.4Xx3ULcF-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.4-39-gce1a6720-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/commit/?id=9f794056db5bb1e1add83ed553b6aec57298358c
        git remote add pdx86-platform-drivers-x86 https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git
        git fetch --no-tags pdx86-platform-drivers-x86 for-next
        git checkout 9f794056db5bb1e1add83ed553b6aec57298358c
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/misc/lkdtm/ drivers/platform/surface/ drivers/platform/x86/intel/ kernel/trace/

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


sparse warnings: (new ones prefixed by >>)
>> drivers/platform/surface/surface_aggregator_tabletsw.c:425:9: sparse: sparse: restricted __le32 degrades to integer

vim +425 drivers/platform/surface/surface_aggregator_tabletsw.c

   403	
   404	static int ssam_pos_get_source(struct ssam_tablet_sw *sw, u32 *source_id)
   405	{
   406		struct ssam_sources_list sources = {};
   407		int status;
   408	
   409		status = ssam_pos_get_sources_list(sw, &sources);
   410		if (status)
   411			return status;
   412	
   413		if (sources.count == 0) {
   414			dev_err(&sw->sdev->dev, "no posture sources found\n");
   415			return -ENODEV;
   416		}
   417	
   418		/*
   419		 * We currently don't know what to do with more than one posture
   420		 * source. At the moment, only one source seems to be used/provided.
   421		 * The WARN_ON() here should hopefully let us know quickly once there
   422		 * is a device that provides multiple sources, at which point we can
   423		 * then try to figure out how to handle them.
   424		 */
 > 425		WARN_ON(sources.count > 1);
   426	
   427		*source_id = get_unaligned_le32(&sources.id[0]);
   428		return 0;
   429	}
   430	

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [pdx86-platform-drivers-x86:for-next 56/92] drivers/platform/surface/surface_aggregator_tabletsw.c:425:9: sparse: sparse: restricted __le32 degrades to integer
@ 2022-07-17 14:00 kernel test robot
  0 siblings, 0 replies; 2+ messages in thread
From: kernel test robot @ 2022-07-17 14:00 UTC (permalink / raw)
  To: Maximilian Luz; +Cc: kbuild-all, Andy Shevchenko, Hans de Goede, linux-kernel

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git for-next
head:   5c8b3f11565e64366d53295e8004edaa1fcf1ec9
commit: 9f794056db5bb1e1add83ed553b6aec57298358c [56/92] platform/surface: Add KIP/POS tablet-mode switch driver
config: x86_64-allmodconfig (https://download.01.org/0day-ci/archive/20220717/202207172113.nx0S1Njc-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.4-39-gce1a6720-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/commit/?id=9f794056db5bb1e1add83ed553b6aec57298358c
        git remote add pdx86-platform-drivers-x86 https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git
        git fetch --no-tags pdx86-platform-drivers-x86 for-next
        git checkout 9f794056db5bb1e1add83ed553b6aec57298358c
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/misc/lkdtm/ drivers/platform/surface/ drivers/platform/x86/intel/ kernel/trace/

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


sparse warnings: (new ones prefixed by >>)
>> drivers/platform/surface/surface_aggregator_tabletsw.c:425:9: sparse: sparse: restricted __le32 degrades to integer

vim +425 drivers/platform/surface/surface_aggregator_tabletsw.c

   403	
   404	static int ssam_pos_get_source(struct ssam_tablet_sw *sw, u32 *source_id)
   405	{
   406		struct ssam_sources_list sources = {};
   407		int status;
   408	
   409		status = ssam_pos_get_sources_list(sw, &sources);
   410		if (status)
   411			return status;
   412	
   413		if (sources.count == 0) {
   414			dev_err(&sw->sdev->dev, "no posture sources found\n");
   415			return -ENODEV;
   416		}
   417	
   418		/*
   419		 * We currently don't know what to do with more than one posture
   420		 * source. At the moment, only one source seems to be used/provided.
   421		 * The WARN_ON() here should hopefully let us know quickly once there
   422		 * is a device that provides multiple sources, at which point we can
   423		 * then try to figure out how to handle them.
   424		 */
 > 425		WARN_ON(sources.count > 1);
   426	
   427		*source_id = get_unaligned_le32(&sources.id[0]);
   428		return 0;
   429	}
   430	

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-07-17 14:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-17  7:04 [pdx86-platform-drivers-x86:for-next 56/92] drivers/platform/surface/surface_aggregator_tabletsw.c:425:9: sparse: sparse: restricted __le32 degrades to integer kernel test robot
  -- strict thread matches above, loose matches on Subject: below --
2022-07-17 14:00 kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox