Re: [gentoo-user] DRM error: couldn't read SADs

2018-02-23 Thread Peter Humphrey
On Saturday, 17 February 2018 10:33:15 GMT Peter Humphrey wrote:
> On Tuesday, 13 February 2018 10:23:45 GMT Peter Humphrey wrote:
> > On Tuesday, 13 February 2018 01:10:16 GMT Jack wrote:
> > > It's been a long time since I've needed to do it, and it was also due
> > > to a (cheap?) KVM switch, but I think there are two things that might
> > > help.  First, if you boot the PC with that monitor connected, it might
> > > actually read the EDID data.  Even if not, if you can capture it (one
> > > time use of a straigt DVI or VGA cable?) you can save it tp a file
> > > using x11-misc/read-edid, and then there is a way to get kernel/X to
> > > read that EDID file at startup instead of trying and failing to get it
> > > directly from the monitor.  If you can't find a reference, I'll dig
> > > and
> > > try to figure out if it's kernel paramater or xorg.conf that you need
> > > to mess with.
> > 
> > Yes, I remember something along those lines - reading EDID from a file
> > instead of the device. I don't think it's that simple though, as the
> > screen is being driven at the right resolution. I just get half-a-dozen
> > or so errors reported during a full day.
> > 
> > I'm expecting the bits to make a direct connection to arrive today, so
> > fingers crossed ...
> 
> For the record, the more direct link (a cable with DisplayPort at one end
> and HDMI at the other) has cleared the SAD problem...

Ahem! Stupid boy; it only kept its head down for a couple of days. Now it 
seems to go a day or two between series of a few errors.

-- 
Regards,
Peter.




Re: [gentoo-user] DRM error: couldn't read SADs

2018-02-17 Thread Peter Humphrey
On Tuesday, 13 February 2018 10:23:45 GMT Peter Humphrey wrote:
> On Tuesday, 13 February 2018 01:10:16 GMT Jack wrote:
> > It's been a long time since I've needed to do it, and it was also due
> > to a (cheap?) KVM switch, but I think there are two things that might
> > help.  First, if you boot the PC with that monitor connected, it might
> > actually read the EDID data.  Even if not, if you can capture it (one
> > time use of a straigt DVI or VGA cable?) you can save it tp a file
> > using x11-misc/read-edid, and then there is a way to get kernel/X to
> > read that EDID file at startup instead of trying and failing to get it
> > directly from the monitor.  If you can't find a reference, I'll dig and
> > try to figure out if it's kernel paramater or xorg.conf that you need
> > to mess with.
> 
> Yes, I remember something along those lines - reading EDID from a file
> instead of the device. I don't think it's that simple though, as the
> screen is being driven at the right resolution. I just get half-a-dozen
> or so errors reported during a full day.
> 
> I'm expecting the bits to make a direct connection to arrive today, so
> fingers crossed ...

For the record, the more direct link (a cable with DisplayPort at one end 
and HDMI at the other) has cleared the SAD problem, but not the balance of 
the picture. And I'm left with no all-inclusive KVM.

Those are problems for another day...

-- 
Regards,
Peter.



Re: [gentoo-user] DRM error: couldn't read SADs

2018-02-13 Thread Peter Humphrey
On Tuesday, 13 February 2018 01:10:16 GMT Jack wrote:

> It's been a long time since I've needed to do it, and it was also due
> to a (cheap?) KVM switch, but I think there are two things that might
> help.  First, if you boot the PC with that monitor connected, it might
> actually read the EDID data.  Even if not, if you can capture it (one
> time use of a straigt DVI or VGA cable?) you can save it tp a file
> using x11-misc/read-edid, and then there is a way to get kernel/X to
> read that EDID file at startup instead of trying and failing to get it
> directly from the monitor.  If you can't find a reference, I'll dig and
> try to figure out if it's kernel paramater or xorg.conf that you need
> to mess with.

Yes, I remember something along those lines - reading EDID from a file 
instead of the device. I don't think it's that simple though, as the screen 
is being driven at the right resolution. I just get half-a-dozen or so 
errors reported during a full day.

I'm expecting the bits to make a direct connection to arrive today, so 
fingers crossed ...

-- 
Regards,
Peter.



Re: [gentoo-user] DRM error: couldn't read SADs

2018-02-12 Thread Jack

On 2018.02.12 19:57, Peter Humphrey wrote:

On Sunday, 11 February 2018 05:41:28 GMT 80x24 wrote:
> On Sun, Feb 11, 2018 at 12:47 AM,
> Peter Humphrey  wrote:
> > [drm:dce_v11_0_afmt_setmode] *ERROR* Couldn't read SADs: 0
> > [...]
> > traps: plugin-containe[6833] general protection ip:7f0a2e1711b1
> > sp:7fff6f64dc30 error:0 in ld-2.25.so[7f0a2e15c000+23000]
> >
> > What is a SAD (other than a seasonal affective disorder)? That  
library
> > comes from glibc, of which I've had 5 versions or revisions in  
that time

> /**
>  * drm_edid_to_sad - extracts SADs from EDID
>  * @edid: EDID to parse
>  * @sads: pointer that will be set to the extracted SADs
>  *
>  * Looks for CEA EDID block and extracts SADs (Short Audio  
Descriptors)

> fr$
> *
>  * Note: The returned pointer needs to be freed using kfree().
>  *
>  * Return: The number of found SADs or negative number on error.
>  */
>
> Considering the term ``EDID'' and some audio related words, I think
> it's reading some info from your monitor.

Hmm. Interesting. Looks like I'll have to revise my screen setup.  
It's a
Samsung LED device with HDMI input. This box outputs HDMI too, but  
the other
boxes I use it on output DVI, so by piecemeal development I've ended  
up with

a four-port DVI switch, all connected with adapter cables.

It seems likely that EDID is getting lost, and I may now also have a  
reason
for the washed-out appearance of the screen. Modern websites with  
their pale
colours are hard to read. Even the green of KMail's quoted text is  
hard.


The other boxes I mentioned can also output VGA, and the screen can  
accept
VGA too and switch between inputs. So I just need a two-port VGA  
switch and
some cables. I've not long since thrown out all the old VGA stuff -  
damn! I

knew I should never throw anything away.


It's been a long time since I've needed to do it, and it was also due  
to a (cheap?) KVM switch, but I think there are two things that might  
help.  First, if you boot the PC with that monitor connected, it might  
actually read the EDID data.  Even if not, if you can capture it (one  
time use of a straigt DVI or VGA cable?) you can save it tp a file  
using x11-misc/read-edid, and then there is a way to get kernel/X to  
read that EDID file at startup instead of trying and failing to get it  
directly from the monitor.  If you can't find a reference, I'll dig and  
try to figure out if it's kernel paramater or xorg.conf that you need  
to mess with.


Jack


Re: [gentoo-user] DRM error: couldn't read SADs

2018-02-12 Thread Peter Humphrey
On Sunday, 11 February 2018 05:41:28 GMT 80x24 wrote:
> On Sun, Feb 11, 2018 at 12:47 AM,
> Peter Humphrey  wrote:
> > [drm:dce_v11_0_afmt_setmode] *ERROR* Couldn't read SADs: 0
> > [...]
> > traps: plugin-containe[6833] general protection ip:7f0a2e1711b1
> > sp:7fff6f64dc30 error:0 in ld-2.25.so[7f0a2e15c000+23000]
> > 
> > What is a SAD (other than a seasonal affective disorder)? That library
> > comes from glibc, of which I've had 5 versions or revisions in that time
> /**
>  * drm_edid_to_sad - extracts SADs from EDID
>  * @edid: EDID to parse
>  * @sads: pointer that will be set to the extracted SADs
>  *
>  * Looks for CEA EDID block and extracts SADs (Short Audio Descriptors)
> fr$
> *
>  * Note: The returned pointer needs to be freed using kfree().
>  *
>  * Return: The number of found SADs or negative number on error.
>  */
> 
> Considering the term ``EDID'' and some audio related words, I think
> it's reading some info from your monitor.

Hmm. Interesting. Looks like I'll have to revise my screen setup. It's a  
Samsung LED device with HDMI input. This box outputs HDMI too, but the other 
boxes I use it on output DVI, so by piecemeal development I've ended up with 
a four-port DVI switch, all connected with adapter cables.

It seems likely that EDID is getting lost, and I may now also have a reason 
for the washed-out appearance of the screen. Modern websites with their pale 
colours are hard to read. Even the green of KMail's quoted text is hard.

The other boxes I mentioned can also output VGA, and the screen can accept 
VGA too and switch between inputs. So I just need a two-port VGA switch and 
some cables. I've not long since thrown out all the old VGA stuff - damn! I 
knew I should never throw anything away.

Thanks for your help.

-- 
Regards,
Peter.




Re: [gentoo-user] DRM error: couldn't read SADs

2018-02-10 Thread 80x24
On Sun, Feb 11, 2018 at 12:47 AM, Peter Humphrey  wrote:
>
> [drm:dce_v11_0_afmt_setmode] *ERROR* Couldn't read SADs: 0
> [...]
> traps: plugin-containe[6833] general protection ip:7f0a2e1711b1 
> sp:7fff6f64dc30 error:0 in ld-2.25.so[7f0a2e15c000+23000]
>
> What is a SAD (other than a seasonal affective disorder)? That library comes
> from glibc, of which I've had 5 versions or revisions in that time

Never heard of it neither. Digging into the kernel source gives

static void radeon_audio_write_sad_regs(struct drm_encoder *encoder)
{
   struct drm_connector *connector = radeon_get_connector_for_encoder$
   struct radeon_encoder *radeon_encoder = to_radeon_encoder(encoder);
   struct cea_sad *sads;
   int sad_count;

   if (!connector)
   return;

   sad_count = drm_edid_to_sad(radeon_connector_edid(connector), $
   if (sad_count <= 0) {
   DRM_ERROR("Couldn't read SADs: %d\n", sad_count);
   return;
   }
   BUG_ON(!sads);

   if (radeon_encoder->audio && radeon_encoder->audio->write_sad_regs)
   radeon_encoder->audio->write_sad_regs(encoder, sads, sad_c$

kfree(sads);
}


in theses files

drivers/gpu/drm/radeon/radeon_audio.c
drivers/gpu/drm/amd/amdgpu/dce_v6_0.c
drivers/gpu/drm/amd/amdgpu/dce_v10_0.c
drivers/gpu/drm/amd/amdgpu/dce_v11_0.c
drivers/gpu/drm/amd/amdgpu/dce_v8_0.c

which ``drm_edid_to_sad‘’ is defined in drivers/gpu/drm/drm_edid.c.
Comments read

/**
 * drm_edid_to_sad - extracts SADs from EDID
 * @edid: EDID to parse
 * @sads: pointer that will be set to the extracted SADs
 *
 * Looks for CEA EDID block and extracts SADs (Short Audio Descriptors) fr$
 *
 * Note: The returned pointer needs to be freed using kfree().
 *
 * Return: The number of found SADs or negative number on error.
 */

Considering the term ``EDID'' and some audio related words, I think
it's reading some info from your monitor.

-- 
Silence is golden.



[gentoo-user] DRM error: couldn't read SADs

2018-02-10 Thread Peter Humphrey
Hello list,

My VGA card is:

# lspci | grep VGA
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] 
Ellesmere [Radeon Pro WX 5100]

I've been getting these entries in dmesg every time I boot the machine, ever
since I installed the card some months ago:

[drm:dce_v11_0_afmt_setmode] *ERROR* Couldn't read SADs: 0
[...]
traps: plugin-containe[6833] general protection ip:7f0a2e1711b1 sp:7fff6f64dc30 
error:0 in ld-2.25.so[7f0a2e15c000+23000]

What is a SAD (other than a seasonal affective disorder)? That library comes
from glibc, of which I've had 5 versions or revisions in that time


The error seems not to be doing any harm, but it'd be good to clear it up.
Google hasn't helped me. Can anyone offer me a hint?

-- 
Regards,
Peter.