All of lore.kernel.org
 help / color / mirror / Atom feed
* [superna9999:amlogic/v5.9/s400-mipi-dsi 12/16] drivers/gpu/drm/drm_bridge.c:181:43: warning: format specifies type 'unsigned int' but the argument has type 'struct drm_encoder
@ 2020-07-31 23:21 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2020-07-31 23:21 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 6121 bytes --]

tree:   https://github.com/superna9999/linux amlogic/v5.9/s400-mipi-dsi
head:   4cbe7065356e7e68a59a0787bc4a4a3ca9375065
commit: 87c65f7a5406d7484a6e9aeab87b275f29542aed [12/16] drm: bridge: debug
config: x86_64-randconfig-a001-20200731 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project c23ae3f18ee3ff11671f4c62ffc66d150b1bcdc2)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install x86_64 cross compiling tool for clang build
        # apt-get install binutils-x86-64-linux-gnu
        git checkout 87c65f7a5406d7484a6e9aeab87b275f29542aed
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64 

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

All warnings (new ones prefixed by >>):

>> drivers/gpu/drm/drm_bridge.c:181:43: warning: format specifies type 'unsigned int' but the argument has type 'struct drm_encoder *' [-Wformat]
           pr_info("%s %08x %08x %08x\n", __func__, encoder, bridge, previous);
                       ~~~~                         ^~~~~~~
   include/linux/printk.h:368:34: note: expanded from macro 'pr_info'
           printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
                                   ~~~     ^~~~~~~~~~~
>> drivers/gpu/drm/drm_bridge.c:181:52: warning: format specifies type 'unsigned int' but the argument has type 'struct drm_bridge *' [-Wformat]
           pr_info("%s %08x %08x %08x\n", __func__, encoder, bridge, previous);
                            ~~~~                             ^~~~~~
   include/linux/printk.h:368:34: note: expanded from macro 'pr_info'
           printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
                                   ~~~     ^~~~~~~~~~~
   drivers/gpu/drm/drm_bridge.c:181:60: warning: format specifies type 'unsigned int' but the argument has type 'struct drm_bridge *' [-Wformat]
           pr_info("%s %08x %08x %08x\n", __func__, encoder, bridge, previous);
                                 ~~~~                                ^~~~~~~~
   include/linux/printk.h:368:34: note: expanded from macro 'pr_info'
           printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
                                   ~~~     ^~~~~~~~~~~
>> drivers/gpu/drm/drm_bridge.c:201:45: warning: variable 'ret' is uninitialized when used here [-Wuninitialized]
                   pr_info("%s:%d %d\n", __func__, __LINE__, ret);
                                                             ^~~
   include/linux/printk.h:368:34: note: expanded from macro 'pr_info'
           printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
                                           ^~~~~~~~~~~
   drivers/gpu/drm/drm_bridge.c:179:9: note: initialize the variable 'ret' to silence this warning
           int ret;
                  ^
                   = 0
   4 warnings generated.

vim +181 drivers/gpu/drm/drm_bridge.c

   151	
   152	/**
   153	 * drm_bridge_attach - attach the bridge to an encoder's chain
   154	 *
   155	 * @encoder: DRM encoder
   156	 * @bridge: bridge to attach
   157	 * @previous: previous bridge in the chain (optional)
   158	 * @flags: DRM_BRIDGE_ATTACH_* flags
   159	 *
   160	 * Called by a kms driver to link the bridge to an encoder's chain. The previous
   161	 * argument specifies the previous bridge in the chain. If NULL, the bridge is
   162	 * linked directly at the encoder's output. Otherwise it is linked at the
   163	 * previous bridge's output.
   164	 *
   165	 * If non-NULL the previous bridge must be already attached by a call to this
   166	 * function.
   167	 *
   168	 * Note that bridges attached to encoders are auto-detached during encoder
   169	 * cleanup in drm_encoder_cleanup(), so drm_bridge_attach() should generally
   170	 * *not* be balanced with a drm_bridge_detach() in driver code.
   171	 *
   172	 * RETURNS:
   173	 * Zero on success, error code on failure
   174	 */
   175	int drm_bridge_attach(struct drm_encoder *encoder, struct drm_bridge *bridge,
   176			      struct drm_bridge *previous,
   177			      enum drm_bridge_attach_flags flags)
   178	{
   179		int ret;
   180	
 > 181		pr_info("%s %08x %08x %08x\n", __func__, encoder, bridge, previous);
   182	
   183		if (!encoder || !bridge)
   184			return -EINVAL;
   185	
   186		if (previous && (!previous->dev || previous->encoder != encoder))
   187			return -EINVAL;
   188	
   189		if (bridge->dev)
   190			return -EBUSY;
   191	
   192		bridge->dev = encoder->dev;
   193		bridge->encoder = encoder;
   194	
   195		if (previous)
   196			list_add(&bridge->chain_node, &previous->chain_node);
   197		else
   198			list_add(&bridge->chain_node, &encoder->bridge_chain);
   199	
   200		if (bridge->funcs->attach) {
 > 201			pr_info("%s:%d %d\n", __func__, __LINE__, ret);
   202			ret = bridge->funcs->attach(bridge, flags);
   203			if (ret < 0)
   204				goto err_reset_bridge;
   205		}
   206	
   207		if (bridge->funcs->atomic_reset) {
   208			struct drm_bridge_state *state;
   209	
   210			state = bridge->funcs->atomic_reset(bridge);
   211			if (IS_ERR(state)) {
   212				ret = PTR_ERR(state);
   213				goto err_detach_bridge;
   214			}
   215	
   216			drm_atomic_private_obj_init(bridge->dev, &bridge->base,
   217						    &state->base,
   218						    &drm_bridge_priv_state_funcs);
   219		}
   220	
   221		return 0;
   222	
   223	err_detach_bridge:
   224		if (bridge->funcs->detach)
   225			bridge->funcs->detach(bridge);
   226	
   227	err_reset_bridge:
   228		bridge->dev = NULL;
   229		bridge->encoder = NULL;
   230		list_del(&bridge->chain_node);
   231		return ret;
   232	}
   233	EXPORT_SYMBOL(drm_bridge_attach);
   234	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 33141 bytes --]

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

only message in thread, other threads:[~2020-07-31 23:21 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-07-31 23:21 [superna9999:amlogic/v5.9/s400-mipi-dsi 12/16] drivers/gpu/drm/drm_bridge.c:181:43: warning: format specifies type 'unsigned int' but the argument has type 'struct drm_encoder 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.