Message ID | 1544552063-8857-2-git-send-email-uma.shankar@intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Add Colorspace connector property interface | expand |
Hi Uma, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on drm-intel/for-linux-next] [also build test WARNING on v4.20-rc6 next-20181214] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Uma-Shankar/drm-Add-colorspace-connector-property/20181212-114922 base: git://anongit.freedesktop.org/drm-intel for-linux-next reproduce: make htmldocs All warnings (new ones prefixed by >>): include/net/mac80211.h:477: warning: cannot understand function prototype: 'struct ieee80211_ftm_responder_params ' include/net/mac80211.h:477: warning: cannot understand function prototype: 'struct ieee80211_ftm_responder_params ' include/net/mac80211.h:477: warning: cannot understand function prototype: 'struct ieee80211_ftm_responder_params ' include/net/mac80211.h:477: warning: cannot understand function prototype: 'struct ieee80211_ftm_responder_params ' include/net/mac80211.h:477: warning: cannot understand function prototype: 'struct ieee80211_ftm_responder_params ' net/mac80211/sta_info.h:588: warning: Function parameter or member 'rx_stats_avg' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'rx_stats_avg.signal' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'rx_stats_avg.chain_signal' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.filtered' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.retry_failed' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.retry_count' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.lost_packets' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.last_tdls_pkt_time' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.msdu_retries' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.msdu_failed' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.last_ack' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.last_ack_signal' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.ack_signal_filled' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'status_stats.avg_ack_signal' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'tx_stats.packets' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'tx_stats.bytes' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'tx_stats.last_rate' not described in 'sta_info' net/mac80211/sta_info.h:588: warning: Function parameter or member 'tx_stats.msdu' not described in 'sta_info' kernel/rcu/tree.c:685: warning: Excess function parameter 'irq' description in 'rcu_nmi_exit' include/linux/dma-buf.h:304: warning: Function parameter or member 'cb_excl.cb' not described in 'dma_buf' include/linux/dma-buf.h:304: warning: Function parameter or member 'cb_excl.poll' not described in 'dma_buf' include/linux/dma-buf.h:304: warning: Function parameter or member 'cb_excl.active' not described in 'dma_buf' include/linux/dma-buf.h:304: warning: Function parameter or member 'cb_shared.cb' not described in 'dma_buf' include/linux/dma-buf.h:304: warning: Function parameter or member 'cb_shared.poll' not described in 'dma_buf' include/linux/dma-buf.h:304: warning: Function parameter or member 'cb_shared.active' not described in 'dma_buf' include/linux/dma-fence-array.h:54: warning: Function parameter or member 'work' not described in 'dma_fence_array' include/linux/gpio/driver.h:375: warning: Function parameter or member 'init_valid_mask' not described in 'gpio_chip' include/linux/iio/hw-consumer.h:1: warning: no structured comments found include/linux/input/sparse-keymap.h:46: warning: Function parameter or member 'sw' not described in 'key_entry' include/linux/regulator/driver.h:227: warning: Function parameter or member 'resume' not described in 'regulator_ops' arch/s390/include/asm/cio.h:245: warning: Function parameter or member 'esw.esw0' not described in 'irb' arch/s390/include/asm/cio.h:245: warning: Function parameter or member 'esw.esw1' not described in 'irb' arch/s390/include/asm/cio.h:245: warning: Function parameter or member 'esw.esw2' not described in 'irb' arch/s390/include/asm/cio.h:245: warning: Function parameter or member 'esw.esw3' not described in 'irb' arch/s390/include/asm/cio.h:245: warning: Function parameter or member 'esw.eadm' not described in 'irb' drivers/slimbus/stream.c:1: warning: no structured comments found include/linux/spi/spi.h:177: warning: Function parameter or member 'driver_override' not described in 'spi_device' drivers/target/target_core_device.c:1: warning: no structured comments found drivers/usb/typec/bus.c:1: warning: no structured comments found drivers/usb/typec/class.c:1: warning: no structured comments found include/linux/w1.h:281: warning: Function parameter or member 'of_match_table' not described in 'w1_family' fs/direct-io.c:257: warning: Excess function parameter 'offset' description in 'dio_complete' fs/file_table.c:1: warning: no structured comments found fs/libfs.c:477: warning: Excess function parameter 'available' description in 'simple_write_end' fs/posix_acl.c:646: warning: Function parameter or member 'inode' not described in 'posix_acl_update_mode' fs/posix_acl.c:646: warning: Function parameter or member 'mode_p' not described in 'posix_acl_update_mode' fs/posix_acl.c:646: warning: Function parameter or member 'acl' not described in 'posix_acl_update_mode' drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c:183: warning: Function parameter or member 'blockable' not described in 'amdgpu_mn_read_lock' drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c:254: warning: Function parameter or member 'blockable' not described in 'amdgpu_mn_invalidate_range_start_gfx' drivers/gpu/drm/amd/amdgpu/amdgpu_mn.c:302: warning: Function parameter or member 'blockable' not described in 'amdgpu_mn_invalidate_range_start_hsa' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:382: warning: cannot understand function prototype: 'struct amdgpu_vm_pt_cursor ' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:383: warning: cannot understand function prototype: 'struct amdgpu_vm_pt_cursor ' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:555: warning: Function parameter or member 'adev' not described in 'for_each_amdgpu_vm_pt_leaf' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:555: warning: Function parameter or member 'vm' not described in 'for_each_amdgpu_vm_pt_leaf' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:555: warning: Function parameter or member 'start' not described in 'for_each_amdgpu_vm_pt_leaf' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:555: warning: Function parameter or member 'end' not described in 'for_each_amdgpu_vm_pt_leaf' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:555: warning: Function parameter or member 'cursor' not described in 'for_each_amdgpu_vm_pt_leaf' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:603: warning: Function parameter or member 'adev' not described in 'for_each_amdgpu_vm_pt_dfs_safe' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:603: warning: Function parameter or member 'vm' not described in 'for_each_amdgpu_vm_pt_dfs_safe' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:603: warning: Function parameter or member 'cursor' not described in 'for_each_amdgpu_vm_pt_dfs_safe' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:603: warning: Function parameter or member 'entry' not described in 'for_each_amdgpu_vm_pt_dfs_safe' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:848: warning: Function parameter or member 'level' not described in 'amdgpu_vm_bo_param' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1356: warning: Function parameter or member 'params' not described in 'amdgpu_vm_update_func' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1356: warning: Function parameter or member 'bo' not described in 'amdgpu_vm_update_func' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1356: warning: Function parameter or member 'pe' not described in 'amdgpu_vm_update_func' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1356: warning: Function parameter or member 'addr' not described in 'amdgpu_vm_update_func' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1356: warning: Function parameter or member 'count' not described in 'amdgpu_vm_update_func' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1356: warning: Function parameter or member 'incr' not described in 'amdgpu_vm_update_func' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1356: warning: Function parameter or member 'flags' not described in 'amdgpu_vm_update_func' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1523: warning: Function parameter or member 'params' not described in 'amdgpu_vm_update_huge' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1523: warning: Function parameter or member 'bo' not described in 'amdgpu_vm_update_huge' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1523: warning: Function parameter or member 'level' not described in 'amdgpu_vm_update_huge' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1523: warning: Function parameter or member 'pe' not described in 'amdgpu_vm_update_huge' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1523: warning: Function parameter or member 'addr' not described in 'amdgpu_vm_update_huge' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1523: warning: Function parameter or member 'count' not described in 'amdgpu_vm_update_huge' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1523: warning: Function parameter or member 'incr' not described in 'amdgpu_vm_update_huge' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:1523: warning: Function parameter or member 'flags' not described in 'amdgpu_vm_update_huge' drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c:3098: warning: Function parameter or member 'pasid' not described in 'amdgpu_vm_make_compute' drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h:128: warning: Incorrect use of kernel-doc format: * @atomic_obj drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h:195: warning: Function parameter or member 'atomic_obj' not described in 'amdgpu_display_manager' drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h:195: warning: Function parameter or member 'atomic_obj_lock' not described in 'amdgpu_display_manager' drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h:195: warning: Function parameter or member 'backlight_link' not described in 'amdgpu_display_manager' drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h:195: warning: Function parameter or member 'backlight_caps' not described in 'amdgpu_display_manager' drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h:195: warning: Function parameter or member 'freesync_module' not described in 'amdgpu_display_manager' drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h:195: warning: Function parameter or member 'fw_dmcu' not described in 'amdgpu_display_manager' drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h:195: warning: Function parameter or member 'dmcu_fw_version' not described in 'amdgpu_display_manager' drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c:1: warning: no structured comments found include/drm/drm_drv.h:618: warning: Function parameter or member 'gem_prime_pin' not described in 'drm_driver' include/drm/drm_drv.h:618: warning: Function parameter or member 'gem_prime_unpin' not described in 'drm_driver' include/drm/drm_drv.h:618: warning: Function parameter or member 'gem_prime_res_obj' not described in 'drm_driver' include/drm/drm_drv.h:618: warning: Function parameter or member 'gem_prime_get_sg_table' not described in 'drm_driver' include/drm/drm_drv.h:618: warning: Function parameter or member 'gem_prime_import_sg_table' not described in 'drm_driver' include/drm/drm_drv.h:618: warning: Function parameter or member 'gem_prime_vmap' not described in 'drm_driver' include/drm/drm_drv.h:618: warning: Function parameter or member 'gem_prime_vunmap' not described in 'drm_driver' include/drm/drm_drv.h:618: warning: Function parameter or member 'gem_prime_mmap' not described in 'drm_driver' >> drivers/gpu/drm/drm_connector.c:1570: warning: Function parameter or member 'props' not described in 'drm_mode_create_colorspace_property' >> drivers/gpu/drm/drm_connector.c:1570: warning: Function parameter or member 'num_values' not described in 'drm_mode_create_colorspace_property' drivers/gpu/drm/drm_damage_helper.c:271: warning: Excess function parameter 'new_state' description in 'drm_atomic_helper_damage_iter_init' drivers/gpu/drm/drm_damage_helper.c:272: warning: Function parameter or member 'state' not described in 'drm_atomic_helper_damage_iter_init' drivers/gpu/drm/drm_damage_helper.c:272: warning: Excess function parameter 'new_state' description in 'drm_atomic_helper_damage_iter_init' include/drm/drm_atomic_state_helper.h:1: warning: no structured comments found drivers/gpu/drm/drm_dp_helper.c:1362: warning: Function parameter or member 'dsc_dpcd' not described in 'drm_dp_dsc_sink_max_slice_count' drivers/gpu/drm/drm_dp_helper.c:1362: warning: Function parameter or member 'is_edp' not described in 'drm_dp_dsc_sink_max_slice_count' drivers/gpu/drm/i915/i915_vma.h:49: warning: cannot understand function prototype: 'struct i915_vma ' drivers/gpu/drm/i915/i915_vma.h:1: warning: no structured comments found drivers/gpu/drm/i915/intel_guc_fwif.h:536: warning: cannot understand function prototype: 'struct guc_log_buffer_state ' drivers/gpu/drm/i915/i915_trace.h:1: warning: no structured comments found include/linux/skbuff.h:862: warning: Function parameter or member 'dev_scratch' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'list' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'ip_defrag_offset' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'skb_mstamp_ns' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member '__cloned_offset' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'head_frag' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member '__pkt_type_offset' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'encapsulation' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'encap_hdr_csum' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'csum_valid' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'csum_complete_sw' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'csum_level' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'inner_protocol_type' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'remcsum_offload' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'offload_fwd_mark' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'offload_mr_fwd_mark' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'sender_cpu' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'reserved_tailroom' not described in 'sk_buff' include/linux/skbuff.h:862: warning: Function parameter or member 'inner_ipproto' not described in 'sk_buff' include/net/sock.h:238: warning: Function parameter or member 'skc_addrpair' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_portpair' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_ipv6only' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_net_refcnt' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_v6_daddr' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_v6_rcv_saddr' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_cookie' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_listener' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_tw_dr' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_rcv_wnd' not described in 'sock_common' include/net/sock.h:238: warning: Function parameter or member 'skc_tw_rcv_nxt' not described in 'sock_common' include/net/sock.h:509: warning: Function parameter or member 'sk_backlog.rmem_alloc' not described in 'sock' include/net/sock.h:509: warning: Function parameter or member 'sk_backlog.len' not described in 'sock' include/net/sock.h:509: warning: Function parameter or member 'sk_backlog.head' not described in 'sock' include/net/sock.h:509: warning: Function parameter or member 'sk_backlog.tail' not described in 'sock' include/net/sock.h:509: warning: Function parameter or member 'sk_wq_raw' not described in 'sock' include/net/sock.h:509: warning: Function parameter or member 'tcp_rtx_queue' not described in 'sock' include/net/sock.h:509: warning: Function parameter or member 'sk_route_forced_caps' not described in 'sock' include/net/sock.h:509: warning: Function parameter or member 'sk_txtime_report_errors' not described in 'sock' include/net/sock.h:509: warning: Function parameter or member 'sk_validate_xmit_skb' not described in 'sock' include/linux/netdevice.h:2052: warning: Function parameter or member 'adj_list.upper' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'adj_list.lower' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'gso_partial_features' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'switchdev_ops' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'l3mdev_ops' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'xfrmdev_ops' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'tlsdev_ops' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'name_assign_type' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'ieee802154_ptr' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'mpls_ptr' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'xdp_prog' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'gro_flush_timeout' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'nf_hooks_ingress' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member '____cacheline_aligned_in_smp' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'qdisc_hash' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'xps_cpus_map' not described in 'net_device' include/linux/netdevice.h:2052: warning: Function parameter or member 'xps_rxqs_map' not described in 'net_device' include/linux/phylink.h:56: warning: Function parameter or member '__ETHTOOL_DECLARE_LINK_MODE_MASK(advertising' not described in 'phylink_link_state' include/linux/phylink.h:56: warning: Function parameter or member '__ETHTOOL_DECLARE_LINK_MODE_MASK(lp_advertising' not described in 'phylink_link_state' Documentation/admin-guide/cgroup-v2.rst:1507: WARNING: Block quote ends without a blank line; unexpected unindent. Documentation/admin-guide/cgroup-v2.rst:1509: WARNING: Block quote ends without a blank line; unexpected unindent. Documentation/admin-guide/cgroup-v2.rst:1510: WARNING: Block quote ends without a blank line; unexpected unindent. include/net/mac80211.h:1211: ERROR: Unexpected indentation. include/net/mac80211.h:1218: WARNING: Block quote ends without a blank line; unexpected unindent. include/linux/wait.h:110: WARNING: Block quote ends without a blank line; unexpected unindent. include/linux/wait.h:113: ERROR: Unexpected indentation. include/linux/wait.h:115: WARNING: Block quote ends without a blank line; unexpected unindent. kernel/time/hrtimer.c:1129: WARNING: Block quote ends without a blank line; unexpected unindent. kernel/signal.c:344: WARNING: Inline literal start-string without end-string. include/linux/kernel.h:137: WARNING: Inline interpreted text or phrase reference start-string without end-string. include/uapi/linux/firewire-cdev.h:312: WARNING: Inline literal start-string without end-string. Documentation/driver-api/gpio/board.rst:209: ERROR: Unexpected indentation. drivers/ata/libata-core.c:5958: ERROR: Unknown target name: "hw". drivers/message/fusion/mptbase.c:5057: WARNING: Definition list ends without a blank line; unexpected unindent. drivers/tty/serial/serial_core.c:1938: WARNING: Definition list ends without a blank line; unexpected unindent. include/linux/mtd/rawnand.h:1189: WARNING: Inline strong start-string without end-string. include/linux/mtd/rawnand.h:1191: WARNING: Inline strong start-string without end-string. include/linux/regulator/driver.h:286: ERROR: Unknown target name: "regulator_regmap_x_voltage". Documentation/driver-api/soundwire/locking.rst:50: ERROR: Inconsistent literal block quoting. Documentation/driver-api/soundwire/locking.rst:51: WARNING: Line block ends without a blank line. Documentation/driver-api/soundwire/locking.rst:55: WARNING: Inline substitution_reference start-string without end-string. Documentation/driver-api/soundwire/locking.rst:56: WARNING: Line block ends without a blank line. include/linux/spi/spi.h:365: ERROR: Unexpected indentation. Documentation/driver-api/usb/typec_bus.rst:76: WARNING: Definition list ends without a blank line; unexpected unindent. block/bio.c:883: WARNING: Inline emphasis start-string without end-string. fs/posix_acl.c:635: WARNING: Inline emphasis start-string without end-string. drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c:1575: WARNING: Inline emphasis start-string without end-string. drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c:1577: WARNING: Inline emphasis start-string without end-string. include/drm/drm_drv.h:664: ERROR: Unknown target name: "driver". Documentation/laptops/lg-laptop.rst:2: WARNING: Explicit markup ends without a blank line; unexpected unindent. Documentation/laptops/lg-laptop.rst:16: ERROR: Unexpected indentation. vim +1570 drivers/gpu/drm/drm_connector.c 1550 1551 /** 1552 * drm_mode_create_colorspace_property - create colorspace property 1553 * Colorspace: 1554 * This property helps select a suitable colorspace based on the sink 1555 * capability. Modern sink devices support wider gamut like BT2020. 1556 * This helps switch to BT2020 mode if the BT2020 encoded video stream 1557 * is being played by the user, same for any other colorspace. 1558 * @connector: connector to set property on. 1559 * 1560 * Called by a driver the first time it's needed, must be attached to desired 1561 * connectors. 1562 * 1563 * Returns: 1564 * Zero on success, negative errno on failure. 1565 */ 1566 int drm_mode_create_colorspace_property(struct drm_connector *connector, 1567 const struct drm_prop_enum_list *props, 1568 int num_values) 1569 { > 1570 struct drm_device *dev = connector->dev; 1571 struct drm_property *prop; 1572 1573 prop = drm_property_create_enum(dev, DRM_MODE_PROP_ENUM, 1574 "Colorspace", 1575 props, num_values); 1576 if (!prop) 1577 return -ENOMEM; 1578 1579 connector->colorspace_property = prop; 1580 1581 return 0; 1582 } 1583 EXPORT_SYMBOL(drm_mode_create_colorspace_property); 1584 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation
Regards Shashank On 12/11/2018 11:44 PM, Uma Shankar wrote: > This patch adds a colorspace connector property, enabling > userspace to switch to various supported colorspaces. > This will help enable BT2020 along with other colorspaces. > > v2: Addressed Maarten and Ville's review comments. Enhanced > the colorspace enum to incorporate both HDMI and DP supported > colorspaces. Also, added a default option for colorspace. > > v3: Removed Adobe references from enum definitions as per > Ville, Hans Verkuil and Jonas Karlman suggestions. Changed > Default to an unset state where driver will assign the colorspace > is not chosen by user, suggested by Ville and Maarten. Addressed > other misc review comments from Maarten. Split the changes to > have separate colorspace property for DP and HDMI. > > v4: Addressed Chris and Ville's review comments, and created a > common colorspace property for DP and HDMI, filtered the list > based on the colorspaces supported by the respective protocol > standard. > > v5: Made the property creation helper accept enum list based on > platform capabilties as suggested by Shashank. Consolidated HDMI > and DP property creation in the common helper. > > Signed-off-by: Uma Shankar <uma.shankar@intel.com> > --- > drivers/gpu/drm/drm_atomic_uapi.c | 4 ++ > drivers/gpu/drm/drm_connector.c | 82 +++++++++++++++++++++++++++++++++++++++ > include/drm/drm_connector.h | 17 ++++++++ > include/uapi/drm/drm_mode.h | 33 ++++++++++++++++ > 4 files changed, 136 insertions(+) > > diff --git a/drivers/gpu/drm/drm_atomic_uapi.c b/drivers/gpu/drm/drm_atomic_uapi.c > index 86ac339..9df7520 100644 > --- a/drivers/gpu/drm/drm_atomic_uapi.c > +++ b/drivers/gpu/drm/drm_atomic_uapi.c > @@ -729,6 +729,8 @@ static int drm_atomic_connector_set_property(struct drm_connector *connector, > return -EINVAL; > } > state->content_protection = val; > + } else if (property == connector->colorspace_property) { > + state->colorspace = val; > } else if (property == config->writeback_fb_id_property) { > struct drm_framebuffer *fb = drm_framebuffer_lookup(dev, NULL, val); > int ret = drm_atomic_set_writeback_fb_for_connector(state, fb); > @@ -797,6 +799,8 @@ static int drm_atomic_connector_set_property(struct drm_connector *connector, > *val = state->picture_aspect_ratio; > } else if (property == config->content_type_property) { > *val = state->content_type; > + } else if (property == connector->colorspace_property) { > + *val = state->colorspace; > } else if (property == connector->scaling_mode_property) { > *val = state->scaling_mode; > } else if (property == connector->content_protection_property) { > diff --git a/drivers/gpu/drm/drm_connector.c b/drivers/gpu/drm/drm_connector.c > index fa9baac..46928f7 100644 > --- a/drivers/gpu/drm/drm_connector.c > +++ b/drivers/gpu/drm/drm_connector.c > @@ -826,6 +826,54 @@ int drm_display_info_set_bus_formats(struct drm_display_info *info, > }; > DRM_ENUM_NAME_FN(drm_get_content_protection_name, drm_cp_enum_list) > > +/* List of HDMI Colorspaces supported */ > +static const struct drm_prop_enum_list hdmi_colorspace[] = { Should we call this list hdmi_colorspaces :) ? > + /* For Default case, driver will set the colorspace */ > + { COLORIMETRY_DEFAULT, "Default" }, > + /* Standard Definition Colorimetry based on CEA 861 */ > + { COLORIMETRY_ITU_601, "ITU_601" }, > + { COLORIMETRY_ITU_709, "ITU_709" }, > + /* Standard Definition Colorimetry based on IEC 61966-2-4 */ > + { COLORIMETRY_XV_YCC_601, "XV_YCC_601" }, > + /* High Definition Colorimetry based on IEC 61966-2-4 */ > + { COLORIMETRY_XV_YCC_709, "XV_YCC_709" }, > + /* Colorimetry based on IEC 61966-2-1/Amendment 1 */ > + { COLORIMETRY_S_YCC_601, "S_YCC_601" }, > + /* Colorimetry based on IEC 61966-2-5 [33] */ > + { COLORIMETRY_OPYCC_601, "opYCC_601" }, > + /* Colorimetry based on IEC 61966-2-5 */ > + { COLORIMETRY_OPRGB, "opRGB" }, > + /* Colorimetry based on ITU-R BT.2020 */ > + { COLORIMETRY_BT2020_RGB, "BT2020_RGB" }, > + /* Colorimetry based on ITU-R BT.2020 */ > + { COLORIMETRY_BT2020_YCC, "BT2020_YCC" }, > + /* Colorimetry based on ITU-R BT.2020 */ > + { COLORIMETRY_BT2020_CYCC, "BT2020_CYCC" }, > +}; > + > +/* List of DP Colorspaces supported */ Same here for dp_colorspaces ? > +static const struct drm_prop_enum_list dp_colorspace[] = { > + /* For Default case, driver will set the colorspace */ > + { COLORIMETRY_DEFAULT, "Default" }, > + /* Standard Definition Colorimetry based on CEA 861 */ > + { COLORIMETRY_ITU_601, "ITU_601" }, > + { COLORIMETRY_ITU_709, "ITU_709" }, > + /* Standard Definition Colorimetry based on IEC 61966-2-4 */ > + { COLORIMETRY_XV_YCC_601, "XV_YCC_601" }, > + /* High Definition Colorimetry based on IEC 61966-2-4 */ > + { COLORIMETRY_XV_YCC_709, "XV_YCC_709" }, > + /* Colorimetry based on IEC 61966-2-5 */ > + { COLORIMETRY_OPRGB, "opRGB" }, > + /* DP MSA Colorimetry */ > + { DP_COLORIMETRY_Y_CBCR_ITU_601, "YCBCR_ITU_601" }, > + { DP_COLORIMETRY_Y_CBCR_ITU_709, "YCBCR_ITU_709" }, > + { DP_COLORIMETRY_SRGB, "sRGB" }, > + { DP_COLORIMETRY_RGB_WIDE_GAMUT, "RGB Wide Gamut" }, > + { DP_COLORIMETRY_SCRGB, "scRGB" }, > + { DP_COLORIMETRY_DCI_P3, "DCI-P3" }, > + { DP_COLORIMETRY_CUSTOM_COLOR_PROFILE, "Custom Profile" }, > +}; > + > /** > * DOC: standard connector properties > * > @@ -1402,6 +1450,40 @@ int drm_mode_create_aspect_ratio_property(struct drm_device *dev) > EXPORT_SYMBOL(drm_mode_create_aspect_ratio_property); > > /** > + * drm_mode_create_colorspace_property - create colorspace property > + * Colorspace: > + * This property helps select a suitable colorspace based on the sink > + * capability. Modern sink devices support wider gamut like BT2020. > + * This helps switch to BT2020 mode if the BT2020 encoded video stream > + * is being played by the user, same for any other colorspace. I might be wrong, but is this alignment correct as per the property documentation style ? > + * @connector: connector to set property on. > + * > + * Called by a driver the first time it's needed, must be attached to desired > + * connectors. > + * > + * Returns: > + * Zero on success, negative errno on failure. > + */ > +int drm_mode_create_colorspace_property(struct drm_connector *connector, > + const struct drm_prop_enum_list *props, > + int num_values) > +{ > + struct drm_device *dev = connector->dev; > + struct drm_property *prop; > + > + prop = drm_property_create_enum(dev, DRM_MODE_PROP_ENUM, > + "Colorspace", > + props, num_values); > + if (!prop) > + return -ENOMEM; > + > + connector->colorspace_property = prop; > + > + return 0; > +} > +EXPORT_SYMBOL(drm_mode_create_colorspace_property); > + > +/** > * drm_mode_create_content_type_property - create content type property > * @dev: DRM device > * > diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h > index 665b9ca..fa840db 100644 > --- a/include/drm/drm_connector.h > +++ b/include/drm/drm_connector.h > @@ -31,6 +31,7 @@ > #include <drm/drm_util.h> > > #include <uapi/drm/drm_mode.h> > +#include <drm/drm_property.h> > > struct drm_connector_helper_funcs; > struct drm_modeset_acquire_ctx; > @@ -497,6 +498,13 @@ struct drm_connector_state { > unsigned int content_protection; > > /** > + * @colorspace: Connector property to request colorspace Please fix this documentation, This is not a property, this is just a state variable to hold the requested property value until next atomic commit. > + * change on Sink. This is most commonly used to switch to > + * wider color gamuts like BT2020. > + */ > + enum absolute_colorimetry_list colorspace; > + > + /** > * @writeback_job: Writeback job for writeback connectors > * > * Holds the framebuffer and out-fence for a writeback connector. As > @@ -978,6 +986,12 @@ struct drm_connector { > struct drm_property *content_protection_property; > > /** > + * @colorspace_property: Connector property to set the suitable > + * colorspace supported by the sink. > + */ > + struct drm_property *colorspace_property; Yep, this is the actual property :) > + > + /** > * @path_blob_ptr: > * > * DRM blob property data for the DP MST path property. This should only > @@ -1248,6 +1262,9 @@ int drm_connector_attach_scaling_mode_property(struct drm_connector *connector, > int drm_connector_attach_content_protection_property( > struct drm_connector *connector); > int drm_mode_create_aspect_ratio_property(struct drm_device *dev); > +int drm_mode_create_colorspace_property(struct drm_connector *connector, > + const struct drm_prop_enum_list *props, > + int num_values); > int drm_mode_create_content_type_property(struct drm_device *dev); > void drm_hdmi_avi_infoframe_content_type(struct hdmi_avi_infoframe *frame, > const struct drm_connector_state *conn_state); > diff --git a/include/uapi/drm/drm_mode.h b/include/uapi/drm/drm_mode.h > index d3e0fe3..42efab8 100644 > --- a/include/uapi/drm/drm_mode.h > +++ b/include/uapi/drm/drm_mode.h > @@ -210,6 +210,39 @@ > #define DRM_MODE_CONTENT_PROTECTION_DESIRED 1 > #define DRM_MODE_CONTENT_PROTECTION_ENABLED 2 > > +/* > + * This is a consolidated colorimetry list supported by HDMI and > + * DP protocol standard. The respective connectors will register > + * a property with the subset of this list (supported by that > + * respective protocol). Userspace will set the colorspace through > + * a colorspace property which will be created and exposed to > + * userspace. > + */ > +enum absolute_colorimetry_list { > + /* For Default case, driver will set the colorspace */ > + COLORIMETRY_DEFAULT = 0, > + /* CEA 861 Normal Colorimetry options */ > + COLORIMETRY_ITU_601, > + COLORIMETRY_ITU_709, > + /* CEA 861 Extended Colorimetry Options */ > + COLORIMETRY_XV_YCC_601, > + COLORIMETRY_XV_YCC_709, > + COLORIMETRY_S_YCC_601, > + COLORIMETRY_OPYCC_601, > + COLORIMETRY_OPRGB, > + COLORIMETRY_BT2020_RGB, > + COLORIMETRY_BT2020_YCC, > + COLORIMETRY_BT2020_CYCC, > + /* DP MSA Colorimetry Options */ > + DP_COLORIMETRY_Y_CBCR_ITU_601, > + DP_COLORIMETRY_Y_CBCR_ITU_709, > + DP_COLORIMETRY_SRGB, > + DP_COLORIMETRY_RGB_WIDE_GAMUT, > + DP_COLORIMETRY_SCRGB, > + DP_COLORIMETRY_DCI_P3, > + DP_COLORIMETRY_CUSTOM_COLOR_PROFILE, > +}; > + > struct drm_mode_modeinfo { > __u32 clock; > __u16 hdisplay; With given minor comments dealt with, please feel free to use: Reviewed-by: Shashank Sharma <shashank.sharma@intel.com>
>-----Original Message----- >From: dri-devel [mailto:dri-devel-bounces@lists.freedesktop.org] On Behalf Of >Sharma, Shashank >Sent: Thursday, December 20, 2018 5:28 PM >To: Shankar, Uma <uma.shankar@intel.com>; intel-gfx@lists.freedesktop.org; >dri-devel@lists.freedesktop.org >Cc: hansverk@cisco.com; Syrjala, Ville <ville.syrjala@intel.com>; Lankhorst, >Maarten <maarten.lankhorst@intel.com>; jonas@kwiboo.se >Subject: Re: [v5 1/2] drm: Add colorspace connector property > >Regards > >Shashank > > >On 12/11/2018 11:44 PM, Uma Shankar wrote: >> This patch adds a colorspace connector property, enabling userspace to >> switch to various supported colorspaces. >> This will help enable BT2020 along with other colorspaces. >> >> v2: Addressed Maarten and Ville's review comments. Enhanced the >> colorspace enum to incorporate both HDMI and DP supported colorspaces. >> Also, added a default option for colorspace. >> >> v3: Removed Adobe references from enum definitions as per Ville, Hans >> Verkuil and Jonas Karlman suggestions. Changed Default to an unset >> state where driver will assign the colorspace is not chosen by user, >> suggested by Ville and Maarten. Addressed other misc review comments >> from Maarten. Split the changes to have separate colorspace property >> for DP and HDMI. >> >> v4: Addressed Chris and Ville's review comments, and created a common >> colorspace property for DP and HDMI, filtered the list based on the >> colorspaces supported by the respective protocol standard. >> >> v5: Made the property creation helper accept enum list based on >> platform capabilties as suggested by Shashank. Consolidated HDMI and >> DP property creation in the common helper. >> >> Signed-off-by: Uma Shankar <uma.shankar@intel.com> >> --- >> drivers/gpu/drm/drm_atomic_uapi.c | 4 ++ >> drivers/gpu/drm/drm_connector.c | 82 >+++++++++++++++++++++++++++++++++++++++ >> include/drm/drm_connector.h | 17 ++++++++ >> include/uapi/drm/drm_mode.h | 33 ++++++++++++++++ >> 4 files changed, 136 insertions(+) >> >> diff --git a/drivers/gpu/drm/drm_atomic_uapi.c >> b/drivers/gpu/drm/drm_atomic_uapi.c >> index 86ac339..9df7520 100644 >> --- a/drivers/gpu/drm/drm_atomic_uapi.c >> +++ b/drivers/gpu/drm/drm_atomic_uapi.c >> @@ -729,6 +729,8 @@ static int drm_atomic_connector_set_property(struct >drm_connector *connector, >> return -EINVAL; >> } >> state->content_protection = val; >> + } else if (property == connector->colorspace_property) { >> + state->colorspace = val; >> } else if (property == config->writeback_fb_id_property) { >> struct drm_framebuffer *fb = drm_framebuffer_lookup(dev, >NULL, val); >> int ret = drm_atomic_set_writeback_fb_for_connector(state, >fb); @@ >> -797,6 +799,8 @@ static int drm_atomic_connector_set_property(struct >drm_connector *connector, >> *val = state->picture_aspect_ratio; >> } else if (property == config->content_type_property) { >> *val = state->content_type; >> + } else if (property == connector->colorspace_property) { >> + *val = state->colorspace; >> } else if (property == connector->scaling_mode_property) { >> *val = state->scaling_mode; >> } else if (property == connector->content_protection_property) { >> diff --git a/drivers/gpu/drm/drm_connector.c >> b/drivers/gpu/drm/drm_connector.c index fa9baac..46928f7 100644 >> --- a/drivers/gpu/drm/drm_connector.c >> +++ b/drivers/gpu/drm/drm_connector.c >> @@ -826,6 +826,54 @@ int drm_display_info_set_bus_formats(struct >drm_display_info *info, >> }; >> DRM_ENUM_NAME_FN(drm_get_content_protection_name, >drm_cp_enum_list) >> >> +/* List of HDMI Colorspaces supported */ static const struct >> +drm_prop_enum_list hdmi_colorspace[] = { >Should we call this list hdmi_colorspaces :) ? Ok, will update this. >> + /* For Default case, driver will set the colorspace */ >> + { COLORIMETRY_DEFAULT, "Default" }, >> + /* Standard Definition Colorimetry based on CEA 861 */ >> + { COLORIMETRY_ITU_601, "ITU_601" }, >> + { COLORIMETRY_ITU_709, "ITU_709" }, >> + /* Standard Definition Colorimetry based on IEC 61966-2-4 */ >> + { COLORIMETRY_XV_YCC_601, "XV_YCC_601" }, >> + /* High Definition Colorimetry based on IEC 61966-2-4 */ >> + { COLORIMETRY_XV_YCC_709, "XV_YCC_709" }, >> + /* Colorimetry based on IEC 61966-2-1/Amendment 1 */ >> + { COLORIMETRY_S_YCC_601, "S_YCC_601" }, >> + /* Colorimetry based on IEC 61966-2-5 [33] */ >> + { COLORIMETRY_OPYCC_601, "opYCC_601" }, >> + /* Colorimetry based on IEC 61966-2-5 */ >> + { COLORIMETRY_OPRGB, "opRGB" }, >> + /* Colorimetry based on ITU-R BT.2020 */ >> + { COLORIMETRY_BT2020_RGB, "BT2020_RGB" }, >> + /* Colorimetry based on ITU-R BT.2020 */ >> + { COLORIMETRY_BT2020_YCC, "BT2020_YCC" }, >> + /* Colorimetry based on ITU-R BT.2020 */ >> + { COLORIMETRY_BT2020_CYCC, "BT2020_CYCC" }, }; >> + >> +/* List of DP Colorspaces supported */ >Same here for dp_colorspaces ? Sure. >> +static const struct drm_prop_enum_list dp_colorspace[] = { >> + /* For Default case, driver will set the colorspace */ >> + { COLORIMETRY_DEFAULT, "Default" }, >> + /* Standard Definition Colorimetry based on CEA 861 */ >> + { COLORIMETRY_ITU_601, "ITU_601" }, >> + { COLORIMETRY_ITU_709, "ITU_709" }, >> + /* Standard Definition Colorimetry based on IEC 61966-2-4 */ >> + { COLORIMETRY_XV_YCC_601, "XV_YCC_601" }, >> + /* High Definition Colorimetry based on IEC 61966-2-4 */ >> + { COLORIMETRY_XV_YCC_709, "XV_YCC_709" }, >> + /* Colorimetry based on IEC 61966-2-5 */ >> + { COLORIMETRY_OPRGB, "opRGB" }, >> + /* DP MSA Colorimetry */ >> + { DP_COLORIMETRY_Y_CBCR_ITU_601, "YCBCR_ITU_601" }, >> + { DP_COLORIMETRY_Y_CBCR_ITU_709, "YCBCR_ITU_709" }, >> + { DP_COLORIMETRY_SRGB, "sRGB" }, >> + { DP_COLORIMETRY_RGB_WIDE_GAMUT, "RGB Wide Gamut" }, >> + { DP_COLORIMETRY_SCRGB, "scRGB" }, >> + { DP_COLORIMETRY_DCI_P3, "DCI-P3" }, >> + { DP_COLORIMETRY_CUSTOM_COLOR_PROFILE, "Custom Profile" }, }; >> + >> /** >> * DOC: standard connector properties >> * >> @@ -1402,6 +1450,40 @@ int drm_mode_create_aspect_ratio_property(struct >drm_device *dev) >> EXPORT_SYMBOL(drm_mode_create_aspect_ratio_property); >> >> /** >> + * drm_mode_create_colorspace_property - create colorspace property >> + * Colorspace: >> + * This property helps select a suitable colorspace based on the sink >> + * capability. Modern sink devices support wider gamut like BT2020. >> + * This helps switch to BT2020 mode if the BT2020 encoded video stream >> + * is being played by the user, same for any other colorspace. >I might be wrong, but is this alignment correct as per the property documentation >style ? There are similar documentation for various properties like: drm_mode_create_content_type_property Followed the same format. I hope this should be ok ? I can add some doc reference as well to consolidate all color related stuff in one common place. >> + * @connector: connector to set property on. >> + * >> + * Called by a driver the first time it's needed, must be attached to >> +desired >> + * connectors. >> + * >> + * Returns: >> + * Zero on success, negative errno on failure. >> + */ >> +int drm_mode_create_colorspace_property(struct drm_connector >*connector, >> + const struct drm_prop_enum_list >*props, >> + int num_values) >> +{ >> + struct drm_device *dev = connector->dev; >> + struct drm_property *prop; >> + >> + prop = drm_property_create_enum(dev, DRM_MODE_PROP_ENUM, >> + "Colorspace", >> + props, num_values); >> + if (!prop) >> + return -ENOMEM; >> + >> + connector->colorspace_property = prop; >> + >> + return 0; >> +} >> +EXPORT_SYMBOL(drm_mode_create_colorspace_property); >> + >> +/** >> * drm_mode_create_content_type_property - create content type property >> * @dev: DRM device >> * >> diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h >> index 665b9ca..fa840db 100644 >> --- a/include/drm/drm_connector.h >> +++ b/include/drm/drm_connector.h >> @@ -31,6 +31,7 @@ >> #include <drm/drm_util.h> >> >> #include <uapi/drm/drm_mode.h> >> +#include <drm/drm_property.h> >> >> struct drm_connector_helper_funcs; >> struct drm_modeset_acquire_ctx; >> @@ -497,6 +498,13 @@ struct drm_connector_state { >> unsigned int content_protection; >> >> /** >> + * @colorspace: Connector property to request colorspace >Please fix this documentation, This is not a property, this is just a state variable to >hold the requested property value until next atomic commit. Ok, sure will rectify this. >> + * change on Sink. This is most commonly used to switch to >> + * wider color gamuts like BT2020. >> + */ >> + enum absolute_colorimetry_list colorspace; >> + >> + /** >> * @writeback_job: Writeback job for writeback connectors >> * >> * Holds the framebuffer and out-fence for a writeback connector. >> As @@ -978,6 +986,12 @@ struct drm_connector { >> struct drm_property *content_protection_property; >> >> /** >> + * @colorspace_property: Connector property to set the suitable >> + * colorspace supported by the sink. >> + */ >> + struct drm_property *colorspace_property; >Yep, this is the actual property :) Yes !!! >> + >> + /** >> * @path_blob_ptr: >> * >> * DRM blob property data for the DP MST path property. This should >> only @@ -1248,6 +1262,9 @@ int >drm_connector_attach_scaling_mode_property(struct drm_connector >*connector, >> int drm_connector_attach_content_protection_property( >> struct drm_connector *connector); >> int drm_mode_create_aspect_ratio_property(struct drm_device *dev); >> +int drm_mode_create_colorspace_property(struct drm_connector >*connector, >> + const struct drm_prop_enum_list >*props, >> + int num_values); >> int drm_mode_create_content_type_property(struct drm_device *dev); >> void drm_hdmi_avi_infoframe_content_type(struct hdmi_avi_infoframe >*frame, >> const struct drm_connector_state >*conn_state); diff --git >> a/include/uapi/drm/drm_mode.h b/include/uapi/drm/drm_mode.h index >> d3e0fe3..42efab8 100644 >> --- a/include/uapi/drm/drm_mode.h >> +++ b/include/uapi/drm/drm_mode.h >> @@ -210,6 +210,39 @@ >> #define DRM_MODE_CONTENT_PROTECTION_DESIRED 1 >> #define DRM_MODE_CONTENT_PROTECTION_ENABLED 2 >> >> +/* >> + * This is a consolidated colorimetry list supported by HDMI and >> + * DP protocol standard. The respective connectors will register >> + * a property with the subset of this list (supported by that >> + * respective protocol). Userspace will set the colorspace through >> + * a colorspace property which will be created and exposed to >> + * userspace. >> + */ >> +enum absolute_colorimetry_list { >> + /* For Default case, driver will set the colorspace */ >> + COLORIMETRY_DEFAULT = 0, >> + /* CEA 861 Normal Colorimetry options */ >> + COLORIMETRY_ITU_601, >> + COLORIMETRY_ITU_709, >> + /* CEA 861 Extended Colorimetry Options */ >> + COLORIMETRY_XV_YCC_601, >> + COLORIMETRY_XV_YCC_709, >> + COLORIMETRY_S_YCC_601, >> + COLORIMETRY_OPYCC_601, >> + COLORIMETRY_OPRGB, >> + COLORIMETRY_BT2020_RGB, >> + COLORIMETRY_BT2020_YCC, >> + COLORIMETRY_BT2020_CYCC, >> + /* DP MSA Colorimetry Options */ >> + DP_COLORIMETRY_Y_CBCR_ITU_601, >> + DP_COLORIMETRY_Y_CBCR_ITU_709, >> + DP_COLORIMETRY_SRGB, >> + DP_COLORIMETRY_RGB_WIDE_GAMUT, >> + DP_COLORIMETRY_SCRGB, >> + DP_COLORIMETRY_DCI_P3, >> + DP_COLORIMETRY_CUSTOM_COLOR_PROFILE, >> +}; >> + >> struct drm_mode_modeinfo { >> __u32 clock; >> __u16 hdisplay; >With given minor comments dealt with, please feel free to use: >Reviewed-by: Shashank Sharma <shashank.sharma@intel.com> Thanks Shashank for the review and useful feedback. I will update the series with the fixes suggested. Regards, Uma Shankar >_______________________________________________ >dri-devel mailing list >dri-devel@lists.freedesktop.org >https://lists.freedesktop.org/mailman/listinfo/dri-devel
diff --git a/drivers/gpu/drm/drm_atomic_uapi.c b/drivers/gpu/drm/drm_atomic_uapi.c index 86ac339..9df7520 100644 --- a/drivers/gpu/drm/drm_atomic_uapi.c +++ b/drivers/gpu/drm/drm_atomic_uapi.c @@ -729,6 +729,8 @@ static int drm_atomic_connector_set_property(struct drm_connector *connector, return -EINVAL; } state->content_protection = val; + } else if (property == connector->colorspace_property) { + state->colorspace = val; } else if (property == config->writeback_fb_id_property) { struct drm_framebuffer *fb = drm_framebuffer_lookup(dev, NULL, val); int ret = drm_atomic_set_writeback_fb_for_connector(state, fb); @@ -797,6 +799,8 @@ static int drm_atomic_connector_set_property(struct drm_connector *connector, *val = state->picture_aspect_ratio; } else if (property == config->content_type_property) { *val = state->content_type; + } else if (property == connector->colorspace_property) { + *val = state->colorspace; } else if (property == connector->scaling_mode_property) { *val = state->scaling_mode; } else if (property == connector->content_protection_property) { diff --git a/drivers/gpu/drm/drm_connector.c b/drivers/gpu/drm/drm_connector.c index fa9baac..46928f7 100644 --- a/drivers/gpu/drm/drm_connector.c +++ b/drivers/gpu/drm/drm_connector.c @@ -826,6 +826,54 @@ int drm_display_info_set_bus_formats(struct drm_display_info *info, }; DRM_ENUM_NAME_FN(drm_get_content_protection_name, drm_cp_enum_list) +/* List of HDMI Colorspaces supported */ +static const struct drm_prop_enum_list hdmi_colorspace[] = { + /* For Default case, driver will set the colorspace */ + { COLORIMETRY_DEFAULT, "Default" }, + /* Standard Definition Colorimetry based on CEA 861 */ + { COLORIMETRY_ITU_601, "ITU_601" }, + { COLORIMETRY_ITU_709, "ITU_709" }, + /* Standard Definition Colorimetry based on IEC 61966-2-4 */ + { COLORIMETRY_XV_YCC_601, "XV_YCC_601" }, + /* High Definition Colorimetry based on IEC 61966-2-4 */ + { COLORIMETRY_XV_YCC_709, "XV_YCC_709" }, + /* Colorimetry based on IEC 61966-2-1/Amendment 1 */ + { COLORIMETRY_S_YCC_601, "S_YCC_601" }, + /* Colorimetry based on IEC 61966-2-5 [33] */ + { COLORIMETRY_OPYCC_601, "opYCC_601" }, + /* Colorimetry based on IEC 61966-2-5 */ + { COLORIMETRY_OPRGB, "opRGB" }, + /* Colorimetry based on ITU-R BT.2020 */ + { COLORIMETRY_BT2020_RGB, "BT2020_RGB" }, + /* Colorimetry based on ITU-R BT.2020 */ + { COLORIMETRY_BT2020_YCC, "BT2020_YCC" }, + /* Colorimetry based on ITU-R BT.2020 */ + { COLORIMETRY_BT2020_CYCC, "BT2020_CYCC" }, +}; + +/* List of DP Colorspaces supported */ +static const struct drm_prop_enum_list dp_colorspace[] = { + /* For Default case, driver will set the colorspace */ + { COLORIMETRY_DEFAULT, "Default" }, + /* Standard Definition Colorimetry based on CEA 861 */ + { COLORIMETRY_ITU_601, "ITU_601" }, + { COLORIMETRY_ITU_709, "ITU_709" }, + /* Standard Definition Colorimetry based on IEC 61966-2-4 */ + { COLORIMETRY_XV_YCC_601, "XV_YCC_601" }, + /* High Definition Colorimetry based on IEC 61966-2-4 */ + { COLORIMETRY_XV_YCC_709, "XV_YCC_709" }, + /* Colorimetry based on IEC 61966-2-5 */ + { COLORIMETRY_OPRGB, "opRGB" }, + /* DP MSA Colorimetry */ + { DP_COLORIMETRY_Y_CBCR_ITU_601, "YCBCR_ITU_601" }, + { DP_COLORIMETRY_Y_CBCR_ITU_709, "YCBCR_ITU_709" }, + { DP_COLORIMETRY_SRGB, "sRGB" }, + { DP_COLORIMETRY_RGB_WIDE_GAMUT, "RGB Wide Gamut" }, + { DP_COLORIMETRY_SCRGB, "scRGB" }, + { DP_COLORIMETRY_DCI_P3, "DCI-P3" }, + { DP_COLORIMETRY_CUSTOM_COLOR_PROFILE, "Custom Profile" }, +}; + /** * DOC: standard connector properties * @@ -1402,6 +1450,40 @@ int drm_mode_create_aspect_ratio_property(struct drm_device *dev) EXPORT_SYMBOL(drm_mode_create_aspect_ratio_property); /** + * drm_mode_create_colorspace_property - create colorspace property + * Colorspace: + * This property helps select a suitable colorspace based on the sink + * capability. Modern sink devices support wider gamut like BT2020. + * This helps switch to BT2020 mode if the BT2020 encoded video stream + * is being played by the user, same for any other colorspace. + * @connector: connector to set property on. + * + * Called by a driver the first time it's needed, must be attached to desired + * connectors. + * + * Returns: + * Zero on success, negative errno on failure. + */ +int drm_mode_create_colorspace_property(struct drm_connector *connector, + const struct drm_prop_enum_list *props, + int num_values) +{ + struct drm_device *dev = connector->dev; + struct drm_property *prop; + + prop = drm_property_create_enum(dev, DRM_MODE_PROP_ENUM, + "Colorspace", + props, num_values); + if (!prop) + return -ENOMEM; + + connector->colorspace_property = prop; + + return 0; +} +EXPORT_SYMBOL(drm_mode_create_colorspace_property); + +/** * drm_mode_create_content_type_property - create content type property * @dev: DRM device * diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h index 665b9ca..fa840db 100644 --- a/include/drm/drm_connector.h +++ b/include/drm/drm_connector.h @@ -31,6 +31,7 @@ #include <drm/drm_util.h> #include <uapi/drm/drm_mode.h> +#include <drm/drm_property.h> struct drm_connector_helper_funcs; struct drm_modeset_acquire_ctx; @@ -497,6 +498,13 @@ struct drm_connector_state { unsigned int content_protection; /** + * @colorspace: Connector property to request colorspace + * change on Sink. This is most commonly used to switch to + * wider color gamuts like BT2020. + */ + enum absolute_colorimetry_list colorspace; + + /** * @writeback_job: Writeback job for writeback connectors * * Holds the framebuffer and out-fence for a writeback connector. As @@ -978,6 +986,12 @@ struct drm_connector { struct drm_property *content_protection_property; /** + * @colorspace_property: Connector property to set the suitable + * colorspace supported by the sink. + */ + struct drm_property *colorspace_property; + + /** * @path_blob_ptr: * * DRM blob property data for the DP MST path property. This should only @@ -1248,6 +1262,9 @@ int drm_connector_attach_scaling_mode_property(struct drm_connector *connector, int drm_connector_attach_content_protection_property( struct drm_connector *connector); int drm_mode_create_aspect_ratio_property(struct drm_device *dev); +int drm_mode_create_colorspace_property(struct drm_connector *connector, + const struct drm_prop_enum_list *props, + int num_values); int drm_mode_create_content_type_property(struct drm_device *dev); void drm_hdmi_avi_infoframe_content_type(struct hdmi_avi_infoframe *frame, const struct drm_connector_state *conn_state); diff --git a/include/uapi/drm/drm_mode.h b/include/uapi/drm/drm_mode.h index d3e0fe3..42efab8 100644 --- a/include/uapi/drm/drm_mode.h +++ b/include/uapi/drm/drm_mode.h @@ -210,6 +210,39 @@ #define DRM_MODE_CONTENT_PROTECTION_DESIRED 1 #define DRM_MODE_CONTENT_PROTECTION_ENABLED 2 +/* + * This is a consolidated colorimetry list supported by HDMI and + * DP protocol standard. The respective connectors will register + * a property with the subset of this list (supported by that + * respective protocol). Userspace will set the colorspace through + * a colorspace property which will be created and exposed to + * userspace. + */ +enum absolute_colorimetry_list { + /* For Default case, driver will set the colorspace */ + COLORIMETRY_DEFAULT = 0, + /* CEA 861 Normal Colorimetry options */ + COLORIMETRY_ITU_601, + COLORIMETRY_ITU_709, + /* CEA 861 Extended Colorimetry Options */ + COLORIMETRY_XV_YCC_601, + COLORIMETRY_XV_YCC_709, + COLORIMETRY_S_YCC_601, + COLORIMETRY_OPYCC_601, + COLORIMETRY_OPRGB, + COLORIMETRY_BT2020_RGB, + COLORIMETRY_BT2020_YCC, + COLORIMETRY_BT2020_CYCC, + /* DP MSA Colorimetry Options */ + DP_COLORIMETRY_Y_CBCR_ITU_601, + DP_COLORIMETRY_Y_CBCR_ITU_709, + DP_COLORIMETRY_SRGB, + DP_COLORIMETRY_RGB_WIDE_GAMUT, + DP_COLORIMETRY_SCRGB, + DP_COLORIMETRY_DCI_P3, + DP_COLORIMETRY_CUSTOM_COLOR_PROFILE, +}; + struct drm_mode_modeinfo { __u32 clock; __u16 hdisplay;
This patch adds a colorspace connector property, enabling userspace to switch to various supported colorspaces. This will help enable BT2020 along with other colorspaces. v2: Addressed Maarten and Ville's review comments. Enhanced the colorspace enum to incorporate both HDMI and DP supported colorspaces. Also, added a default option for colorspace. v3: Removed Adobe references from enum definitions as per Ville, Hans Verkuil and Jonas Karlman suggestions. Changed Default to an unset state where driver will assign the colorspace is not chosen by user, suggested by Ville and Maarten. Addressed other misc review comments from Maarten. Split the changes to have separate colorspace property for DP and HDMI. v4: Addressed Chris and Ville's review comments, and created a common colorspace property for DP and HDMI, filtered the list based on the colorspaces supported by the respective protocol standard. v5: Made the property creation helper accept enum list based on platform capabilties as suggested by Shashank. Consolidated HDMI and DP property creation in the common helper. Signed-off-by: Uma Shankar <uma.shankar@intel.com> --- drivers/gpu/drm/drm_atomic_uapi.c | 4 ++ drivers/gpu/drm/drm_connector.c | 82 +++++++++++++++++++++++++++++++++++++++ include/drm/drm_connector.h | 17 ++++++++ include/uapi/drm/drm_mode.h | 33 ++++++++++++++++ 4 files changed, 136 insertions(+)