drm/i915: Add debugfs to read any DPCD register
Subsystems (2)
PATCH 1/1 drm/i915: Add debugfs to read any DPCD register
This patch creates a connector specific debugfs interface to read any particular DPCD register. The DPCD register address (hex format) is written to 'i915_dpcd_addr' interface and the corresponding value can be read from 'i915_dpcd_val' interface.
Example usage:
echo 0x70 > i915_dpcd_addr
cat i915_dpcd_val
DPCD[0x70]:0x1
---
This patch is based on top of Jani's patch:
"add i915 specific connector debugfs file for DPCD"
[https://freedesktop.org/patch/43332/]
drivers/gpu/drm/i915/i915_debugfs.c | 102 +++++++++++++++++++++++++++++++++++- drivers/gpu/drm/i915/intel_drv.h | 1 + 2 files changed, 102 insertions(+), 1 deletion(-)
drivers/gpu/drm/i915/i915_debugfs.c +101 -1
@@ -4865,6 +4865,101 @@ static const struct file_operations i915_dpcd_fops = { .release = single_release, }; +static ssize_t i915_dpcd_addr_write (struct file *file,const char __user *ubuf, +size_t len,loff_t *offp) +{ +struct seq_file *m = file->private_data; +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); +unsigned int reg_addr; +char tmp[16 ]; +int ret; + +if (!intel_dp) +return -EINVAL ; + +if (len >=sizeof (tmp)) +return -EINVAL ; + +if (copy_from_user (tmp, ubuf, len)) +return -EFAULT ; + + tmp[len] ='\0' ; + + ret =sscanf (tmp,"%x\n" , ®_addr); +if (ret ==0 ) +return -EINVAL ; + + intel_dp->debugfs_dpcd_addr = reg_addr; + +return len; +} + +static int i915_dpcd_addr_show (struct seq_file *m,void *data) +{ +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); + +if (!intel_dp) +return -EINVAL ; + +seq_printf (m,"0x%x\n" , intel_dp->debugfs_dpcd_addr); + +return 0 ; +} + +static int i915_dpcd_addr_open (struct inode *inode,struct file *file) +{ +return single_open (file, i915_dpcd_addr_show, inode->i_private); +} + +static const struct file_operations i915_dpcd_addr_fops = { + .owner =THIS_MODULE , + .open = i915_dpcd_addr_open, + .read = seq_read, + .write = i915_dpcd_addr_write, + .llseek = seq_lseek, + .release = single_release, +}; + +static int i915_dpcd_val_show (struct seq_file *m,void *data) +{ +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); +unsigned int addr; +u8 buf[1 ]; +int ret; + +if (!intel_dp) +return -EINVAL ; + + addr = intel_dp->debugfs_dpcd_addr; + ret =drm_dp_dpcd_readb (&intel_dp->aux, addr, buf); +if (ret <0 ) { +DRM_ERROR ("dpcd read for 0x%x failed:%d\n" , addr, ret); +return ret; + } + +seq_printf (m,"DPCD[0x%x]:0x%x\n" , addr, buf[0 ]); +return 0 ; +} + +static int i915_dpcd_val_open (struct inode *inode,struct file *file) +{ +return single_open (file, i915_dpcd_val_show, inode->i_private); +} + +static const struct file_operations i915_dpcd_val_fops = { + .owner =THIS_MODULE , + .open = i915_dpcd_val_open, + .read = seq_read, + .llseek = seq_lseek, + .release = single_release, +}; +/** * i915_debugfs_connector_add - add i915 specific connector debugfs files * @connector: pointer to a registered drm_connector
@@ -4883,9 +4978,14 @@ int i915_debugfs_connector_add(struct drm_connector *connector)return -ENODEV ;if (connector->connector_type == DRM_MODE_CONNECTOR_DisplayPort || - connector->connector_type == DRM_MODE_CONNECTOR_eDP) + connector->connector_type == DRM_MODE_CONNECTOR_eDP) {debugfs_create_file ("i915_dpcd" ,S_IRUGO , root, connector, &i915_dpcd_fops); +debugfs_create_file ("i915_dpcd_addr" ,S_IRUGO |S_IWUSR , + root, connector, &i915_dpcd_addr_fops); +debugfs_create_file ("i915_dpcd_val" ,S_IRUGO , root, + connector, &i915_dpcd_val_fops); + }return 0 ; }
drivers/gpu/drm/i915/intel_drv.h +1 -0
@@ -642,6 +642,7 @@ struct intel_dp {unsigned long last_power_cycle;unsigned long last_power_on;unsigned long last_backlight_off; +unsigned int debugfs_dpcd_addr;struct notifier_block edp_notifier;
Signature · 6 lines
1.9.1 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 10 lines · Durgadoss R
This patch creates a connector specific debugfs interface to read any particular DPCD register. The DPCD register address (hex format) is written to '
i915_dpcd_addr' interface and the corresponding value can be read from 'i915_dpcd_val' interface.Example usage:
echo0x70>i915_dpcd_addr
cati915_dpcd_val
DPCD[0x70]:0x1
I am still not overjoyed about the interface (because it has a state), but I don't have anything better to suggest either. I'll defer to others to make the taste judgement...
Review comments for the implementation inline.
BR,
Jani.
Quoted 6 lines
Signed-off-by Durgadoss R <[email protected]>---
This patch is based on top of Jani's patch:
"add i915 specific connector debugfs file for DPCD"
[https://freedesktop.org/patch/43332/]
Already committed.
Quoted 16 lines
drivers/gpu/drm/i915/i915_debugfs.c | 102 +++++++++++++++++++++++++++++++++++- drivers/gpu/drm/i915/intel_drv.h | 1 + 2 files changed, 102 insertions(+), 1 deletion(-)drivers/gpu/drm/i915/i915_debugfs.c +3
-0@@ -4865,6 +4865,101 @@ static const struct file_operations i915_dpcd_fops = { .release = single_release, }; +static ssize_t i915_dpcd_addr_write (struct file *file,const char __user *ubuf, +size_t len,loff_t *offp) +{
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4880
Quoted 10 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+struct seq_file *m = file->private_data; +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); +unsigned int reg_addr; +char tmp[16 ]; +int ret; + +if (!intel_dp) +return -EINVAL ;
I think it's highly unlikely this will be NULL. You're more likely to oops above if something went wrong (see enc_to_intel_dp and intel_attached_encoder). Also, -ENODEV?
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4890
Quoted 10 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+ +if (len >=sizeof (tmp)) +return -EINVAL ; + +if (copy_from_user (tmp, ubuf, len)) +return -EFAULT ; + + tmp[len] ='\0' ; + + ret =sscanf (tmp,"%x\n" , ®_addr);
See kstrtouint.
Quoted 6 lines
drivers/gpu/drm/i915/i915_debugfs.c +6
-0+if (ret ==0 ) +return -EINVAL ; + + intel_dp->debugfs_dpcd_addr = reg_addr; + +return len;
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4906
Quoted 10 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+} + +static int i915_dpcd_addr_show (struct seq_file *m,void *data) +{ +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); + +if (!intel_dp) +return -EINVAL ;
Same as above.
Quoted 17 lines
drivers/gpu/drm/i915/i915_debugfs.c +17
-0+ +seq_printf (m,"0x%x\n" , intel_dp->debugfs_dpcd_addr); + +return 0 ; +} + +static int i915_dpcd_addr_open (struct inode *inode,struct file *file) +{ +return single_open (file, i915_dpcd_addr_show, inode->i_private); +} + +static const struct file_operations i915_dpcd_addr_fops = { + .owner =THIS_MODULE , + .open = i915_dpcd_addr_open, + .read = seq_read, + .write = i915_dpcd_addr_write, + .llseek = seq_lseek,
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4933
Quoted 10 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+ .release = single_release, +}; + +static int i915_dpcd_val_show (struct seq_file *m,void *data) +{ +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); +unsigned int addr; +u8 buf[1 ];
Might be more obvious to just have u8 val, and use a pointer to it. *shrug*.
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4880
Quoted 4 lines
drivers/gpu/drm/i915/i915_debugfs.c +4
-0+int ret; + +if (!intel_dp) +return -EINVAL ;
Same as above.
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4942
Quoted 5 lines
drivers/gpu/drm/i915/i915_debugfs.c +5
-0+ + addr = intel_dp->debugfs_dpcd_addr; + ret =drm_dp_dpcd_readb (&intel_dp->aux, addr, buf); +if (ret <0 ) { +DRM_ERROR ("dpcd read for 0x%x failed:%d\n" , addr, ret);
I think there'll already be errors in the log at this point. This is probably redundant.
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4946
Quoted 4 lines
drivers/gpu/drm/i915/i915_debugfs.c +4
-0+return ret; + } + +seq_printf (m,"DPCD[0x%x]:0x%x\n" , addr, buf[0 ]);
For an interface better suited for tools than humans, I'd drop all the fluff and just print the content. Maybe use 0x%02x for format.
Quoted 50 lines
drivers/gpu/drm/i915/i915_debugfs.c +22
-1+return 0 ; +} + +static int i915_dpcd_val_open (struct inode *inode,struct file *file) +{ +return single_open (file, i915_dpcd_val_show, inode->i_private); +} + +static const struct file_operations i915_dpcd_val_fops = { + .owner =THIS_MODULE , + .open = i915_dpcd_val_open, + .read = seq_read, + .llseek = seq_lseek, + .release = single_release, +}; +/** * i915_debugfs_connector_add - add i915 specific connector debugfs files * @connector: pointer to a registered drm_connector @@ -4883,9 +4978,14 @@ int i915_debugfs_connector_add(struct drm_connector *connector)return -ENODEV ;if (connector->connector_type == DRM_MODE_CONNECTOR_DisplayPort || - connector->connector_type == DRM_MODE_CONNECTOR_eDP) + connector->connector_type == DRM_MODE_CONNECTOR_eDP) {debugfs_create_file ("i915_dpcd" ,S_IRUGO , root, connector, &i915_dpcd_fops); +debugfs_create_file ("i915_dpcd_addr" ,S_IRUGO |S_IWUSR , + root, connector, &i915_dpcd_addr_fops); +debugfs_create_file ("i915_dpcd_val" ,S_IRUGO , root, + connector, &i915_dpcd_val_fops); + }return 0 ; }drivers/gpu/drm/i915/intel_drv.h +1
-0@@ -642,6 +642,7 @@ struct intel_dp {unsigned long last_power_cycle;unsigned long last_power_on;unsigned long last_backlight_off; +unsigned int debugfs_dpcd_addr;struct notifier_block edp_notifier;Signature · 1 line
1.9.1
Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 60 lines
-----Original Message-----
From: Nikula, Jani
Sent: Wednesday, April 8, 2015 1:34 PM
To: R, Durgadoss; [email protected]
Cc: R, Durgadoss
Subject: Re: [PATCH] drm/i915: Add debugfs to read any DPCD registerQuoted 10 lines · Durgadoss R
This patch creates a connector specific debugfs interface to read any particular DPCD register. The DPCD register address (hex format) is written to '
i915_dpcd_addr' interface and the corresponding value can be read from 'i915_dpcd_val' interface.Example usage:
echo0x70>i915_dpcd_addr
cati915_dpcd_val
DPCD[0x70]:0x1I am still not overjoyed about the interface (because it has a state), but I don't have anything better to suggest either. I'll defer to others to make the taste judgement...
Review comments for the implementation inline.
BR,
Jani.Quoted 6 lines
Signed-off-by Durgadoss R <[email protected]>---
This patch is based on top of Jani's patch:
"add i915 specific connector debugfs file for DPCD"
[https://freedesktop.org/patch/43332/]Already committed.
Quoted 22 lines
drivers/gpu/drm/i915/i915_debugfs.c | 102 +++++++++++++++++++++++++++++++++++- drivers/gpu/drm/i915/intel_drv.h | 1 + 2 files changed, 102 insertions(+), 1 deletion(-)drivers/gpu/drm/i915/i915_debugfs.c +9
-0@@ -4865,6 +4865,101 @@ static const struct file_operations i915_dpcd_fops = { .release = single_release, }; +static ssize_t i915_dpcd_addr_write (struct file *file,const char __user *ubuf, +size_t len,loff_t *offp) +{ +struct seq_file *m = file->private_data; +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); +unsigned int reg_addr; +char tmp[16 ];
Quoted 8 lines
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4880
Quoted 4 lines
drivers/gpu/drm/i915/i915_debugfs.c +4
-0+int ret; + +if (!intel_dp) +return -EINVAL ;I think it's highly unlikely this will be NULL. You're more likely to oops above if something went wrong (see
enc_to_intel_dpandintel_attached_encoder). Also,-ENODEV?
Ok.. Will remove this check in next version..
Quoted 80 lines
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4890
Quoted 11 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+ +if (len >=sizeof (tmp)) +return -EINVAL ; + +if (copy_from_user (tmp, ubuf, len)) +return -EFAULT ; + + tmp[len] ='\0' ; + + ret =sscanf (tmp,"%x\n" , ®_addr);See kstrtouint.
Quoted 6 lines
drivers/gpu/drm/i915/i915_debugfs.c +6
-0+if (ret ==0 ) +return -EINVAL ; + + intel_dp->debugfs_dpcd_addr = reg_addr; + +return len;drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4906
Quoted 10 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+} + +static int i915_dpcd_addr_show (struct seq_file *m,void *data) +{ +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); + +if (!intel_dp) +return -EINVAL ;Same as above.
Quoted 17 lines
drivers/gpu/drm/i915/i915_debugfs.c +17
-0+ +seq_printf (m,"0x%x\n" , intel_dp->debugfs_dpcd_addr); + +return 0 ; +} + +static int i915_dpcd_addr_open (struct inode *inode,struct file *file) +{ +return single_open (file, i915_dpcd_addr_show, inode->i_private); +} + +static const struct file_operations i915_dpcd_addr_fops = { + .owner =THIS_MODULE , + .open = i915_dpcd_addr_open, + .read = seq_read, + .write = i915_dpcd_addr_write, + .llseek = seq_lseek,drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4933
Quoted 10 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+ .release = single_release, +}; + +static int i915_dpcd_val_show (struct seq_file *m,void *data) +{ +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); +unsigned int addr; +u8 buf[1 ];Might be more obvious to just have u8 val, and use a pointer to it. *shrug*.
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4880
Quoted 4 lines
drivers/gpu/drm/i915/i915_debugfs.c +4
-0+int ret; + +if (!intel_dp) +return -EINVAL ;Same as above.
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4942
Quoted 5 lines
drivers/gpu/drm/i915/i915_debugfs.c +5
-0+ + addr = intel_dp->debugfs_dpcd_addr; + ret =drm_dp_dpcd_readb (&intel_dp->aux, addr, buf); +if (ret <0 ) { +DRM_ERROR ("dpcd read for 0x%x failed:%d\n" , addr, ret);I think there'll already be errors in the log at this point. This is probably redundant.
Quoted 7 lines
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4946
Quoted 4 lines
drivers/gpu/drm/i915/i915_debugfs.c +4
-0+return ret; + } + +seq_printf (m,"DPCD[0x%x]:0x%x\n" , addr, buf[0 ]);For an interface better suited for tools than humans, I'd drop all the fluff and just print the content. Maybe use 0x%02x for format.
I added this because we don't have locking constructs for our state.
For tools, yes, I agree that just a value would do..
Thanks,
Durga
Quoted 46 lines
Quoted 46 lines
drivers/gpu/drm/i915/i915_debugfs.c +22
-1+return 0 ; +} + +static int i915_dpcd_val_open (struct inode *inode,struct file *file) +{ +return single_open (file, i915_dpcd_val_show, inode->i_private); +} + +static const struct file_operations i915_dpcd_val_fops = { + .owner =THIS_MODULE , + .open = i915_dpcd_val_open, + .read = seq_read, + .llseek = seq_lseek, + .release = single_release, +}; +/** * i915_debugfs_connector_add - add i915 specific connector debugfs files * @connector: pointer to a registered drm_connector @@ -4883,9 +4978,14 @@ int i915_debugfs_connector_add(struct drm_connector *connector)return -ENODEV ;if (connector->connector_type == DRM_MODE_CONNECTOR_DisplayPort || - connector->connector_type == DRM_MODE_CONNECTOR_eDP) + connector->connector_type == DRM_MODE_CONNECTOR_eDP) {debugfs_create_file ("i915_dpcd" ,S_IRUGO , root, connector, &i915_dpcd_fops); +debugfs_create_file ("i915_dpcd_addr" ,S_IRUGO |S_IWUSR , + root, connector, &i915_dpcd_addr_fops); +debugfs_create_file ("i915_dpcd_val" ,S_IRUGO , root, + connector, &i915_dpcd_val_fops); + }return 0 ; }drivers/gpu/drm/i915/intel_drv.h +1
-0@@ -642,6 +642,7 @@ struct intel_dp {unsigned long last_power_cycle;unsigned long last_power_on;unsigned long last_backlight_off; +unsigned int debugfs_dpcd_addr;
Quoted 8 lines
Quoted 5 lines
drivers/gpu/drm/i915/intel_drv.h +0
-1struct notifier_block edp_notifier; --1.9.1
--
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 69 lines · Durgadoss
Quoted 60 lines
-----Original Message-----
From: Nikula, Jani
Sent: Wednesday, April 8, 2015 1:34 PM
To: R, Durgadoss; [email protected]
Cc: R, Durgadoss
Subject: Re: [PATCH] drm/i915: Add debugfs to read any DPCD registerQuoted 10 lines · Durgadoss R
This patch creates a connector specific debugfs interface to read any particular DPCD register. The DPCD register address (hex format) is written to '
i915_dpcd_addr' interface and the corresponding value can be read from 'i915_dpcd_val' interface.Example usage:
echo0x70>i915_dpcd_addr
cati915_dpcd_val
DPCD[0x70]:0x1I am still not overjoyed about the interface (because it has a state), but I don't have anything better to suggest either. I'll defer to others to make the taste judgement...
Review comments for the implementation inline.
BR,
Jani.Quoted 6 lines
Signed-off-by Durgadoss R <[email protected]>---
This patch is based on top of Jani's patch:
"add i915 specific connector debugfs file for DPCD"
[https://freedesktop.org/patch/43332/]Already committed.
Quoted 22 lines
drivers/gpu/drm/i915/i915_debugfs.c | 102 +++++++++++++++++++++++++++++++++++- drivers/gpu/drm/i915/intel_drv.h | 1 + 2 files changed, 102 insertions(+), 1 deletion(-)drivers/gpu/drm/i915/i915_debugfs.c +9
-0@@ -4865,6 +4865,101 @@ static const struct file_operations i915_dpcd_fops = { .release = single_release, }; +static ssize_t i915_dpcd_addr_write (struct file *file,const char __user *ubuf, +size_t len,loff_t *offp) +{ +struct seq_file *m = file->private_data; +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); +unsigned int reg_addr; +char tmp[16 ];Quoted 8 lines
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4880
Quoted 4 lines
drivers/gpu/drm/i915/i915_debugfs.c +4
-0+int ret; + +if (!intel_dp) +return -EINVAL ;I think it's highly unlikely this will be NULL. You're more likely to oops above if something went wrong (see
enc_to_intel_dpandintel_attached_encoder). Also,-ENODEV?
Quoted 1 line
Ok.. Will remove this check in next version..
Maybe we should check for some of the intermediate steps in figuring out intel_dp instead. I know, my dpcd dump doesn't do that either... :(
BR,
Jani.
Quoted 151 lines
Quoted 81 lines
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4890
Quoted 12 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+ +if (len >=sizeof (tmp)) +return -EINVAL ; + +if (copy_from_user (tmp, ubuf, len)) +return -EFAULT ; + + tmp[len] ='\0' ; + + ret =sscanf (tmp,"%x\n" , ®_addr);See kstrtouint.
Quoted 6 lines
drivers/gpu/drm/i915/i915_debugfs.c +6
-0+if (ret ==0 ) +return -EINVAL ; + + intel_dp->debugfs_dpcd_addr = reg_addr; + +return len;drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4906
Quoted 10 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+} + +static int i915_dpcd_addr_show (struct seq_file *m,void *data) +{ +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); + +if (!intel_dp) +return -EINVAL ;Same as above.
Quoted 17 lines
drivers/gpu/drm/i915/i915_debugfs.c +17
-0+ +seq_printf (m,"0x%x\n" , intel_dp->debugfs_dpcd_addr); + +return 0 ; +} + +static int i915_dpcd_addr_open (struct inode *inode,struct file *file) +{ +return single_open (file, i915_dpcd_addr_show, inode->i_private); +} + +static const struct file_operations i915_dpcd_addr_fops = { + .owner =THIS_MODULE , + .open = i915_dpcd_addr_open, + .read = seq_read, + .write = i915_dpcd_addr_write, + .llseek = seq_lseek,drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4933
Quoted 10 lines
drivers/gpu/drm/i915/i915_debugfs.c +10
-0+ .release = single_release, +}; + +static int i915_dpcd_val_show (struct seq_file *m,void *data) +{ +struct drm_connector *connector = m->private; +struct intel_dp *intel_dp = +enc_to_intel_dp (&intel_attached_encoder (connector)->base); +unsigned int addr; +u8 buf[1 ];Might be more obvious to just have u8 val, and use a pointer to it. *shrug*.
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4880
Quoted 4 lines
drivers/gpu/drm/i915/i915_debugfs.c +4
-0+int ret; + +if (!intel_dp) +return -EINVAL ;Same as above.
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4942
Quoted 5 lines
drivers/gpu/drm/i915/i915_debugfs.c +5
-0+ + addr = intel_dp->debugfs_dpcd_addr; + ret =drm_dp_dpcd_readb (&intel_dp->aux, addr, buf); +if (ret <0 ) { +DRM_ERROR ("dpcd read for 0x%x failed:%d\n" , addr, ret);I think there'll already be errors in the log at this point. This is probably redundant.
Quoted 7 lines
drivers/gpu/drm/i915/i915_debugfs.c static const struct file_operations i915_dpcd_fops = { · line 4946
Quoted 4 lines
drivers/gpu/drm/i915/i915_debugfs.c +4
-0+return ret; + } + +seq_printf (m,"DPCD[0x%x]:0x%x\n" , addr, buf[0 ]);For an interface better suited for tools than humans, I'd drop all the fluff and just print the content. Maybe use 0x%02x for format.
I added this because we don't have locking constructs for our state.
For tools, yes, I agree that just a value would do..
Thanks,
DurgaQuoted 54 lines
Quoted 49 lines
drivers/gpu/drm/i915/i915_debugfs.c +22
-1+return 0 ; +} + +static int i915_dpcd_val_open (struct inode *inode,struct file *file) +{ +return single_open (file, i915_dpcd_val_show, inode->i_private); +} + +static const struct file_operations i915_dpcd_val_fops = { + .owner =THIS_MODULE , + .open = i915_dpcd_val_open, + .read = seq_read, + .llseek = seq_lseek, + .release = single_release, +}; +/** * i915_debugfs_connector_add - add i915 specific connector debugfs files * @connector: pointer to a registered drm_connector @@ -4883,9 +4978,14 @@ int i915_debugfs_connector_add(struct drm_connector *connector)return -ENODEV ;if (connector->connector_type == DRM_MODE_CONNECTOR_DisplayPort || - connector->connector_type == DRM_MODE_CONNECTOR_eDP) + connector->connector_type == DRM_MODE_CONNECTOR_eDP) {debugfs_create_file ("i915_dpcd" ,S_IRUGO , root, connector, &i915_dpcd_fops); +debugfs_create_file ("i915_dpcd_addr" ,S_IRUGO |S_IWUSR , + root, connector, &i915_dpcd_addr_fops); +debugfs_create_file ("i915_dpcd_val" ,S_IRUGO , root, + connector, &i915_dpcd_val_fops); + }return 0 ; }drivers/gpu/drm/i915/intel_drv.h +1
-1@@ -642,6 +642,7 @@ struct intel_dp {unsigned long last_power_cycle;unsigned long last_power_on;unsigned long last_backlight_off; +unsigned int debugfs_dpcd_addr;struct notifier_block edp_notifier; --Quoted 2 lines
1.9.1
--
Jani Nikula, Intel Open Source Technology Center
Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Task id: 6145 -------------------------------------Summary-------------------------------------
Platform Delta drm-intel-nightly Series Applied
PNV 276/276 276/276 ILK 302/302 302/302 SNB -21 313/313 292/313 IVB 337/337 337/337 BYT 286/286 286/286 HSW 395/395 395/395 BDW 321/321 321/321
-------------------------------------Detailed-------------------------------------
Platform Test drm-intel-nightly Series Applied
SNB igt@kms_mmio_vs_cs_flip@setplane_vs_cs_flip DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@kms_rotation_crc@primary-rotation DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@cursor DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@cursor-dpms DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@debugfs-forcewake-user DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@dpms-mode-unset-non-lpsp DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@dpms-non-lpsp DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@drm-resources-equal DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@fences DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@fences-dpms DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-execbuf DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-idle DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-mmap-cpu DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-mmap-gtt DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-pread DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@i2c DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@modeset-non-lpsp DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@modeset-non-lpsp-stress-no-wait DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@pci-d3-state DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@reg-read-ioctl DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@rte DMESG_WARN(4)PASS(3) DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
Note: You need to pay more attention to line start with '*'
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 69 lines · On Thu, Apr 09, 2015 at 02:54:13PM -0700, [email protected] wrote:
Task id: 6145 -------------------------------------Summary-------------------------------------
Platform Delta drm-intel-nightly Series AppliedPNV 276/276 276/276 ILK 302/302 302/302 SNB -21 313/313 292/313 IVB 337/337 337/337 BYT 286/286 286/286 HSW 395/395 395/395 BDW 321/321 321/321-------------------------------------Detailed-------------------------------------
Platform Test drm-intel-nightly Series Applied
SNB igt@kms_mmio_vs_cs_flip@setplane_vs_cs_flip DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@kms_rotation_crc@primary-rotation DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@cursor DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@cursor-dpms DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@debugfs-forcewake-user DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@dpms-mode-unset-non-lpsp DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@dpms-non-lpsp DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@drm-resources-equal DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@fences DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@fences-dpms DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-execbuf DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-idle DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-mmap-cpu DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-mmap-gtt DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@gem-pread DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@i2c DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@modeset-non-lpsp DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@modeset-non-lpsp-stress-no-wait DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@pci-d3-state DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up
Quoted 8 lines
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@reg-read-ioctl DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
SNB igt@pm_rpm@rte DMESG_WARN(4)PASS(3)DMESG_WARN(1)
(dmesg patch applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_retries,give_up@too many voltage .* give up drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborting@failed to train .* aborting
Note: You need to pay more attention to line start with '*'
Something seems wrong with your test infrastructure, I've seen a bunch of result (from completely unrelated patches) that DP link training is failing all over the place on snb (and sometimes ilk).
Has someone tripped over the cable?
-Daniel
Signature · 7 lines
Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 188 lines
-----Original Message-----
From: Daniel Vetter [mailto:[email protected]] On Behalf Of Daniel Vetter
Sent: Friday, April 10, 2015 3:39 PM
To: He, Shuang
Cc: Gao, Ethan; [email protected]; R, Durgadoss
Subject: Re: [Intel-gfx] [PATCH] drm/i915: Add debugfs to read any DPCD registerQuoted 1 line · On Thu, Apr 09, 2015 at 02:54:13PM -0700, [email protected] wrote:
Tested-by Intel Graphics QA PRTS (Patch Regression Test System Contact:Quoted 10 lines
Task id: 6145 -------------------------------------Summary-------------------------------------
Platform Delta drm-intel-nightly Series AppliedPNV 276/276 276/276 ILK 302/302 302/302 SNB -21 313/313 292/313 IVB 337/337 337/337 BYT 286/286 286/286 HSW 395/395 395/395 BDW 321/321 321/321Quoted 3 lines
-------------------------------------Detailed-------------------------------------
Platform Test drm-intel-nightly Series Applied
SNB igt@kms_mmio_vs_cs_flip@setplane_vs_cs_flipDMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@kms_rotation_crc@primary-rotation DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@cursor DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@cursor-dpms DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@debugfs-forcewake-user DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@dpms-mode-unset-non-lpsp
DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@dpms-non-lpsp DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@drm-resources-equal DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@fences DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@fences-dpms DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-execbuf DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-idle DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-mmap-cpu DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-mmap-gtt DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-pread DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 2 lines
SNB igt@pm_rpm@i2c DMESG_WARN(4)PASS(3)
DMESG_WARN(1)
(dmesg patchapplied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@modeset-non-lpsp DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@modeset-non-lpsp-stress-no-wait
DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@pci-d3-state DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@reg-read-ioctl DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 2 lines
SNB igt@pm_rpm@rte DMESG_WARN(4)PASS(3)
DMESG_WARN(1)
(dmesg patchapplied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
Quoted 7 lines
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
Note: You need to pay more attention to line start with '*'
Something seems wrong with your test infrastructure, I've seen a bunch of result (from completely unrelated patches) that DP link training is failing all over the place on snb (and sometimes ilk).
[He, Shuang] Yes, it seems to happen on same test machine. Is it possible to related to some kernel issue? I see those dmesg warnings happens for almost same set of tests in two rounds of testing on that test machine: igt@pm_rpm*
http://lists.freedesktop.org/archives/intel-gfx/2015-April/064274.html http://lists.freedesktop.org/archives/intel-gfx/2015-April/064289.html while other testing didn't use same hardware seems doesn't have this issue: http://lists.freedesktop.org/archives/intel-gfx/2015-April/064166.html
Is it possible it's hardware specific issue?
Quoted 2 lines
Has someone tripped over the cable?
[He, Shuang] I have just gone to lab and double checked, it's still well connected.
Thanks
--Shuang
Quoted 5 lines
-Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 195 lines · Shuang
Quoted 188 lines
-----Original Message-----
From: Daniel Vetter [mailto:[email protected]] On Behalf Of Daniel Vetter
Sent: Friday, April 10, 2015 3:39 PM
To: He, Shuang
Cc: Gao, Ethan; [email protected]; R, Durgadoss
Subject: Re: [Intel-gfx] [PATCH] drm/i915: Add debugfs to read any DPCD registerQuoted 1 line · On Thu, Apr 09, 2015 at 02:54:13PM -0700, [email protected] wrote:
Tested-by Intel Graphics QA PRTS (Patch Regression Test System Contact:Quoted 10 lines
Task id: 6145 -------------------------------------Summary-------------------------------------
Platform Delta drm-intel-nightly Series AppliedPNV 276/276 276/276 ILK 302/302 302/302 SNB -21 313/313 292/313 IVB 337/337 337/337 BYT 286/286 286/286 HSW 395/395 395/395 BDW 321/321 321/321Quoted 3 lines
-------------------------------------Detailed-------------------------------------
Platform Test drm-intel-nightly Series Applied
SNB igt@kms_mmio_vs_cs_flip@setplane_vs_cs_flipDMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@kms_rotation_crc@primary-rotation DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@cursor DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@cursor-dpms DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@debugfs-forcewake-user DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@dpms-mode-unset-non-lpsp
DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@dpms-non-lpsp DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@drm-resources-equal DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@fences DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@fences-dpms DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-execbuf DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-idle DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-mmap-cpu DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-mmap-gtt DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@gem-pread DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 2 lines
SNB igt@pm_rpm@i2c DMESG_WARN(4)PASS(3)
DMESG_WARN(1)
(dmesg patchapplied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@modeset-non-lpsp DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@modeset-non-lpsp-stress-no-wait
DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@pci-d3-state DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
SNB igt@pm_rpm@reg-read-ioctl DMESG_WARN(4)PASS(3)
DMESG_WARN(1)Quoted 1 line
(dmesg patch
applied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 2 lines
SNB igt@pm_rpm@rte DMESG_WARN(4)PASS(3)
DMESG_WARN(1)
(dmesg patchapplied)drm:intel_dp_start_link_train[i915]]*ERROR*too_many_voltage_ret ries,give_up@too many voltage .* give up
Quoted 1 line
Quoted 7 lines
drm:intel_dp_complete_link_train[i915]]*ERROR*failed_to_train_DP,aborti ng@failed to train .* aborting
Quoted 1 line
Note: You need to pay more attention to line start with '*'
Something seems wrong with your test infrastructure, I've seen a bunch of result (from completely unrelated patches) that DP link training is failing all over the place on snb (and sometimes ilk).
Quoted 6 lines
[He, Shuang] Yes, it seems to happen on same test machine. Is it possible to related to some kernel issue? I see those dmesg warnings happens for almost same set of tests in two rounds of testing on that test machine: igt@pm_rpm*
http://lists.freedesktop.org/archives/intel-gfx/2015-April/064274.html http://lists.freedesktop.org/archives/intel-gfx/2015-April/064289.html while other testing didn't use same hardware seems doesn't have this issue: http://lists.freedesktop.org/archives/intel-gfx/2015-April/064166.htmlIs it possible it's hardware specific issue?
Well imo the problem here is that PRTS reports something as a regression which seems to affect all kernels. That's just noise.
Of course the bug itself is still real (and probably a regression), but I haven't seen a PRTS bisect result for it yet either. Is that stuck somewhere in the queue?
-Daniel
Signature · 7 lines
Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx