[drm:drm-syncobj 4/6] htmldocs: drivers/gpu/drm/drm_syncobj.c:75: warning: No description found for parameter 'file_private'

kbuild test robot fengguang.wu at intel.com
Mon Apr 3 10:49:05 UTC 2017


tree:   git://people.freedesktop.org/~airlied/linux.git drm-syncobj
head:   0c2ce5924ab63ae73c49bef9cf369a5e9d50e79d
commit: 3f58246dcd0bf3579af908c8e0a7a6715d3f51e4 [4/6] drm: add initial sync object interfaces
reproduce: make htmldocs

All warnings (new ones prefixed by >>):

   include/linux/init.h:1: warning: no structured comments found
   kernel/sched/core.c:2085: warning: No description found for parameter 'rf'
   kernel/sched/core.c:2085: warning: Excess function parameter 'cookie' description in 'try_to_wake_up_local'
   include/linux/kthread.h:26: warning: Excess function parameter '...' description in 'kthread_create'
   kernel/sys.c:1: warning: no structured comments found
   include/linux/device.h:969: warning: No description found for parameter 'dma_ops'
   drivers/dma-buf/seqno-fence.c:1: warning: no structured comments found
   include/linux/iio/iio.h:597: warning: No description found for parameter 'trig_readonly'
   include/linux/iio/trigger.h:151: warning: No description found for parameter 'indio_dev'
   include/linux/iio/trigger.h:151: warning: No description found for parameter 'trig'
   include/linux/device.h:970: warning: No description found for parameter 'dma_ops'
   drivers/regulator/core.c:1467: warning: Excess function parameter 'ret' description in 'regulator_dev_lookup'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'open'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'preclose'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'postclose'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'lastclose'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'set_busid'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'irq_handler'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'irq_preinstall'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'irq_postinstall'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'irq_uninstall'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'debugfs_init'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'debugfs_cleanup'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_open_object'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_close_object'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'prime_handle_to_fd'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'prime_fd_to_handle'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_export'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_import'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_pin'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_unpin'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_res_obj'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_get_sg_table'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_import_sg_table'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_vmap'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_vunmap'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_prime_mmap'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'gem_vm_ops'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'major'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'minor'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'patchlevel'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'name'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'desc'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'date'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'driver_features'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'ioctls'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'num_ioctls'
   include/drm/drm_drv.h:439: warning: No description found for parameter 'fops'
   include/drm/drm_color_mgmt.h:1: warning: no structured comments found
   drivers/gpu/drm/drm_fb_cma_helper.c:557: warning: Excess function parameter 'num_crtc' description in 'drm_fbdev_cma_init'
   drivers/gpu/drm/drm_fb_cma_helper.c:558: warning: Excess function parameter 'num_crtc' description in 'drm_fbdev_cma_init'
>> drivers/gpu/drm/drm_syncobj.c:75: warning: No description found for parameter 'file_private'
>> drivers/gpu/drm/drm_syncobj.c:75: warning: No description found for parameter 'handle'
>> drivers/gpu/drm/drm_syncobj.c:75: warning: No description found for parameter 'fence'
>> drivers/gpu/drm/drm_syncobj.c:75: warning: No description found for parameter 'old_fence'
   drivers/gpu/drm/drm_syncobj.c:101: warning: No description found for parameter 'file_private'
   drivers/gpu/drm/drm_syncobj.c:101: warning: No description found for parameter 'handle'
   drivers/gpu/drm/drm_syncobj.c:101: warning: No description found for parameter 'fence'
>> drivers/gpu/drm/drm_syncobj.c:195: warning: Excess function parameter 'dev' description in 'drm_syncobj_open'
>> drivers/gpu/drm/drm_syncobj.c:220: warning: Excess function parameter 'dev' description in 'drm_syncobj_release'
   drivers/gpu/drm/i915/intel_lpe_audio.c:342: warning: No description found for parameter 'pipe'
   drivers/gpu/drm/i915/intel_lpe_audio.c:342: warning: No description found for parameter 'dp_output'
   drivers/gpu/drm/i915/intel_lpe_audio.c:342: warning: No description found for parameter 'link_rate'
   drivers/gpu/drm/i915/intel_lpe_audio.c:343: warning: No description found for parameter 'pipe'
   drivers/gpu/drm/i915/intel_lpe_audio.c:343: warning: No description found for parameter 'dp_output'
   drivers/gpu/drm/i915/intel_lpe_audio.c:343: warning: No description found for parameter 'link_rate'
   drivers/media/dvb-core/dvb_frontend.h:677: warning: No description found for parameter 'refcount'
   Documentation/core-api/assoc_array.rst:13: WARNING: Enumerated list ends without a blank line; unexpected unindent.
   Documentation/doc-guide/sphinx.rst:110: ERROR: Unknown target name: "sphinx c domain".
   kernel/sched/fair.c:7616: WARNING: Inline emphasis start-string without end-string.
   kernel/time/timer.c:1200: ERROR: Unexpected indentation.
   kernel/time/timer.c:1202: ERROR: Unexpected indentation.
   kernel/time/timer.c:1203: WARNING: Block quote ends without a blank line; unexpected unindent.
   include/linux/wait.h:122: WARNING: Block quote ends without a blank line; unexpected unindent.
   include/linux/wait.h:125: ERROR: Unexpected indentation.
   include/linux/wait.h:127: WARNING: Block quote ends without a blank line; unexpected unindent.
   kernel/time/hrtimer.c:990: WARNING: Block quote ends without a blank line; unexpected unindent.
   kernel/signal.c:322: WARNING: Inline literal start-string without end-string.
   include/linux/iio/iio.h:219: ERROR: Unexpected indentation.
   include/linux/iio/iio.h:220: WARNING: Block quote ends without a blank line; unexpected unindent.
   include/linux/iio/iio.h:226: WARNING: Definition list ends without a blank line; unexpected unindent.
   drivers/iio/industrialio-core.c:639: ERROR: Unknown target name: "iio_val".
   drivers/iio/industrialio-core.c:646: ERROR: Unknown target name: "iio_val".
   drivers/message/fusion/mptbase.c:5051: WARNING: Definition list ends without a blank line; unexpected unindent.
   drivers/tty/serial/serial_core.c:1898: WARNING: Definition list ends without a blank line; unexpected unindent.
   include/linux/regulator/driver.h:271: ERROR: Unknown target name: "regulator_regmap_x_voltage".
   include/linux/spi/spi.h:369: ERROR: Unexpected indentation.
   drivers/usb/core/message.c:478: ERROR: Unexpected indentation.
   drivers/usb/core/message.c:479: WARNING: Block quote ends without a blank line; unexpected unindent.
   Documentation/driver-api/usb.rst:623: ERROR: Unknown target name: "usb_type".
   Documentation/driver-api/usb.rst:623: ERROR: Unknown target name: "usb_dir".
   Documentation/driver-api/usb.rst:623: ERROR: Unknown target name: "usb_recip".
   Documentation/driver-api/usb.rst:689: ERROR: Unknown target name: "usbdevfs_urb_type".
   sound/soc/soc-core.c:2670: ERROR: Unknown target name: "snd_soc_daifmt".
   sound/core/jack.c:312: ERROR: Unknown target name: "snd_jack_btn".
   WARNING: dvipng command 'dvipng' cannot be run (needed for math display), check the imgmath_dvipng setting

vim +/file_private +75 drivers/gpu/drm/drm_syncobj.c

    69	 */
    70	int drm_syncobj_swap_fences(struct drm_file *file_private,
    71				    uint32_t handle,
    72				    struct dma_fence *fence,
    73				    struct dma_fence **old_fence)
    74	{
  > 75		struct sync_file *sync_file = drm_syncobj_file_lookup(file_private, handle);
    76	
    77		if (!sync_file)
    78			return -EINVAL;
    79	
    80		*old_fence = sync_file_replace_fence(sync_file, fence);
    81		if (*old_fence)
    82			return -EINVAL;
    83		return 0;
    84	}
    85	EXPORT_SYMBOL(drm_syncobj_swap_fences);
    86	
    87	/**
    88	 * drm_syncobj_replace_fence - lookup and replace fence in a sync object.
    89	 * @file_private - drm file private pointer.
    90	 * @handle - syncobj handle to lookup
    91	 * @fence - fence to install in sync file.
    92	 * Returns: 0 on success or -EINVAL on error
    93	 *
    94	 * This looks up a sync object and replaces the fence on it, freeing
    95	 * the old one.
    96	 */
    97	int drm_syncobj_replace_fence(struct drm_file *file_private,
    98				      u32 handle,
    99				      struct dma_fence *fence)
   100	{
   101		struct dma_fence *old_fence;
   102		int r;
   103	
   104		r = drm_syncobj_swap_fences(file_private, handle, fence, &old_fence);
   105		if (r)
   106			return r;
   107		dma_fence_put(old_fence);
   108		return 0;
   109	}
   110	EXPORT_SYMBOL(drm_syncobj_replace_fence);
   111	
   112	static int drm_syncobj_create(struct drm_file *file_private,
   113					  unsigned type,
   114					  unsigned flags, u32 *handle)
   115	{
   116		struct sync_file *sync_file = sync_file_alloc();
   117		int ret;
   118	
   119		idr_preload(GFP_KERNEL);
   120		spin_lock(&file_private->syncobj_table_lock);
   121		ret = idr_alloc(&file_private->syncobj_idr, sync_file, 1, 0, GFP_NOWAIT);
   122		spin_unlock(&file_private->syncobj_table_lock);
   123	
   124		idr_preload_end();
   125	
   126		if (ret < 0)
   127			return ret;
   128	
   129		*handle = ret;
   130		return 0;
   131	}
   132	
   133	static void drm_syncobj_destroy(struct drm_file *file_private,
   134					u32 handle)
   135	{
   136		struct sync_file *sync_file = drm_syncobj_file_lookup(file_private, handle);
   137		if (!sync_file)
   138			return;
   139	
   140		spin_lock(&file_private->syncobj_table_lock);
   141		idr_remove(&file_private->syncobj_idr, handle);
   142		spin_unlock(&file_private->syncobj_table_lock);
   143	
   144		fput(sync_file->file);
   145	}
   146	
   147	static int drm_syncobj_handle_to_fd(struct drm_file *file_private,
   148					    u32 handle, int *fd)
   149	{
   150		struct sync_file *sync_file = drm_syncobj_file_lookup(file_private, handle);
   151		int ret;
   152		if (!sync_file)
   153			return -EINVAL;
   154	
   155		ret = get_unused_fd_flags(O_CLOEXEC);
   156		if (ret < 0)
   157			return ret;
   158		fd_install(ret, sync_file->file);
   159		*fd = ret;
   160		return 0;
   161	}
   162	
   163	static int drm_syncobj_fd_to_handle(struct drm_file *file_private,
   164					    int fd, u32 *handle)
   165	{
   166		struct sync_file *sync_file = sync_file_fdget(fd);
   167		int ret;
   168		if (!sync_file)
   169			return -EINVAL;
   170		idr_preload(GFP_KERNEL);
   171		spin_lock(&file_private->syncobj_table_lock);
   172		ret = idr_alloc(&file_private->syncobj_idr, sync_file, 1, 0, GFP_NOWAIT);
   173		spin_unlock(&file_private->syncobj_table_lock);
   174		idr_preload_end();
   175	
   176		if (ret < 0) {
   177			fput(sync_file->file);
   178			return ret;
   179		}
   180		*handle = ret;
   181		return 0;
   182	}
   183	
   184	/**
   185	 * drm_syncobj_open - initalizes syncobj file-private structures at devnode open time
   186	 * @dev: drm_device which is being opened by userspace
   187	 * @file_private: drm file-private structure to set up
   188	 *
   189	 * Called at device open time, sets up the structure for handling refcounting
   190	 * of sync objects.
   191	 */
   192	void
   193	drm_syncobj_open(struct drm_file *file_private)
   194	{
 > 195		idr_init(&file_private->syncobj_idr);
   196		spin_lock_init(&file_private->syncobj_table_lock);
   197	}
   198	
   199	static int
   200	drm_syncobj_release_handle(int id, void *ptr, void *data)
   201	{
   202		struct sync_file *sync_file = ptr;
   203	
   204		fput(sync_file->file);
   205		return 0;
   206	}
   207	
   208	/**
   209	 * drm_syncobj_release - release file-private sync object resources
   210	 * @dev: drm_device which is being closed by userspace
   211	 * @file_private: drm file-private structure to clean up
   212	 *
   213	 * Called at close time when the filp is going away.
   214	 *
   215	 * Releases any remaining references on objects by this filp.
   216	 */
   217	void
   218	drm_syncobj_release(struct drm_file *file_private)
   219	{
 > 220		idr_for_each(&file_private->syncobj_idr,
   221			     &drm_syncobj_release_handle, file_private);
   222		idr_destroy(&file_private->syncobj_idr);
   223	}

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 6576 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20170403/336787d7/attachment-0001.gz>


More information about the dri-devel mailing list