All of lore.kernel.org
 help / color / mirror / Atom feed
* [android-common:android15-6.1 1/2] drivers/usb/gadget/android_configfs_uevent.c:186:6: warning: no previous prototype for function '__android_set_connected'
@ 2024-03-01 16:55 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-03-01 16:55 UTC (permalink / raw)
  To: cros-kernel-buildreports; +Cc: oe-kbuild-all

tree:   https://android.googlesource.com/kernel/common android15-6.1
head:   79d40fcc7f981896f569f51e4c48058128a710ec
commit: 5e9a404dff899b6f6586f99fb19e90d598ae2d6d [1/2] ANDROID: usb: gadget: configfs: Add Uevent to notify userspace
config: x86_64-allyesconfig (https://download.01.org/0day-ci/archive/20240302/202403020010.XZdplvLP-lkp@intel.com/config)
compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240302/202403020010.XZdplvLP-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202403020010.XZdplvLP-lkp@intel.com/

All warnings (new ones prefixed by >>):

   drivers/usb/gadget/android_configfs_uevent.c:28:7: warning: variable 'configured' set but not used [-Wunused-but-set-variable]
      28 |         bool configured = false;
         |              ^
>> drivers/usb/gadget/android_configfs_uevent.c:186:6: warning: no previous prototype for function '__android_set_connected' [-Wmissing-prototypes]
     186 | void __android_set_connected(struct android_uevent_opts *opts, bool connected)
         |      ^
   drivers/usb/gadget/android_configfs_uevent.c:186:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     186 | void __android_set_connected(struct android_uevent_opts *opts, bool connected)
         | ^
         | static 
>> drivers/usb/gadget/android_configfs_uevent.c:199:6: warning: no previous prototype for function '__android_set_configured' [-Wmissing-prototypes]
     199 | void __android_set_configured(struct android_uevent_opts *opts, bool configured)
         |      ^
   drivers/usb/gadget/android_configfs_uevent.c:199:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     199 | void __android_set_configured(struct android_uevent_opts *opts, bool configured)
         | ^
         | static 
   3 warnings generated.


vim +/__android_set_connected +186 drivers/usb/gadget/android_configfs_uevent.c

   185	
 > 186	void __android_set_connected(struct android_uevent_opts *opts, bool connected)
   187	{
   188		unsigned long flags;
   189	
   190		spin_lock_irqsave(&opts_lock, flags);
   191		// Don't send the uevent if connected state is not changed
   192		if (opts->connected != connected) {
   193			opts->connected = connected;
   194			schedule_work(&opts->work);
   195		}
   196		spin_unlock_irqrestore(&opts_lock, flags);
   197	}
   198	
 > 199	void __android_set_configured(struct android_uevent_opts *opts, bool configured)
   200	{
   201		unsigned long flags;
   202	
   203		spin_lock_irqsave(&opts_lock, flags);
   204		// Don't send the uevent if configure state is not changed
   205		if (opts->configured != configured) {
   206			opts->configured = configured;
   207			schedule_work(&opts->work);
   208		}
   209		spin_unlock_irqrestore(&opts_lock, flags);
   210	}
   211	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-03-01 16:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-01 16:55 [android-common:android15-6.1 1/2] drivers/usb/gadget/android_configfs_uevent.c:186:6: warning: no previous prototype for function '__android_set_connected' kernel test robot

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.