lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <c00c5058effff98b6cd76a0cfadb469c33091e08.camel@perches.com>
Date:   Sun, 07 Feb 2021 02:45:44 -0800
From:   Joe Perches <joe@...ches.com>
To:     Marcin Raszka <djraszit@...il.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] I was wondering why I can't set the resolution to
 2560x1080, while in windows 7 I can without a problem. I looked at the
 radeon driver code and found it doesn't support this resolution. So I made
 some changes. I added the hdmi_mhz parameter. In cmdline I set
 radeon.hdmi_mhz=190 Only tested on the Radeon HD 5830

Your subject needs to be changed and a commit log added.

> diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c b/drivers/gpu/drm/radeon/radeon_connectors.c
[]
> @@ -37,6 +37,8 @@
>  #include <linux/pm_runtime.h>
>  #include <linux/vga_switcheroo.h>
> 
> +extern int hdmimhz;
> +
>  static int radeon_dp_handle_hpd(struct drm_connector *connector)
>  {
>  	struct radeon_connector *radeon_connector = to_radeon_connector(connector);
> @@ -503,7 +505,7 @@ static void radeon_add_common_modes(struct drm_encoder *encoder, struct drm_conn
>  	struct mode_size {
>  		int w;
>  		int h;
> -	} common_modes[17] = {
> +	} common_modes[18] = {

probably better without a specific array size

>  		{ 640,  480},
>  		{ 720,  480},
>  		{ 800,  600},
> @@ -520,10 +522,11 @@ static void radeon_add_common_modes(struct drm_encoder *encoder, struct drm_conn
>  		{1680, 1050},
>  		{1600, 1200},
>  		{1920, 1080},
> -		{1920, 1200}
> +		{1920, 1200},
> +		{2560, 1080}
>  	};
>  
> 
> -	for (i = 0; i < 17; i++) {
> +	for (i = 0; i < 18; i++) {

	for (i = 0; i < ARRAY_SIZE(common_modes); i++) {

> @@ -1491,25 +1494,32 @@ static enum drm_mode_status radeon_dvi_mode_valid(struct drm_connector *connecto
>  	    (mode->clock > 135000))
>  		return MODE_CLOCK_HIGH;
>  
> 
> -	if (radeon_connector->use_digital && (mode->clock > 165000)) {
> +	if (radeon_connector->use_digital && (mode->clock > (hdmimhz * 1000))) {
>  		if ((radeon_connector->connector_object_id == CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_I) ||
>  		    (radeon_connector->connector_object_id == CONNECTOR_OBJECT_ID_DUAL_LINK_DVI_D) ||
> -		    (radeon_connector->connector_object_id == CONNECTOR_OBJECT_ID_HDMI_TYPE_B))
> +		    (radeon_connector->connector_object_id == CONNECTOR_OBJECT_ID_HDMI_TYPE_B)){
> +			printk("MODE_CLOCK_HIHG0 %d", hdmimhz);

unnecessary debugging printks?


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ