summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS2
-rw-r--r--lib/Xconfig/main.pm2
-rw-r--r--lib/Xconfig/monitor.pm33
3 files changed, 6 insertions, 31 deletions
diff --git a/NEWS b/NEWS
index f430c60..ca7923e 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,8 @@
- prefer boot display devices when probing cards (fixes at least an issue
with an SLI laptop as reported by Maarten Vanraes)
- add support for Asturian keyboard
+- do not try to probe monitor information via X server on laptops (it
+ doesn't work with recent X servers)
Version 0.95 - 23 April 2011
diff --git a/lib/Xconfig/main.pm b/lib/Xconfig/main.pm
index 0a63a54..d92c27f 100644
--- a/lib/Xconfig/main.pm
+++ b/lib/Xconfig/main.pm
@@ -68,7 +68,7 @@ sub configure_everything {
my $X = {};
my $ok = 1;
- my $probed_info = Xconfig::monitor::probe($raw_X->get_Driver);
+ my $probed_info = Xconfig::monitor::probe();
$options->{VideoRam_probed} = $probed_info->{VideoRam_probed};
$ok &&= $X->{card} = Xconfig::card::configure($in, $raw_X, $do_pkgs, $auto, $options);
$ok &&= $X->{monitors} = Xconfig::monitor::configure($in, $raw_X, int($raw_X->get_devices), $probed_info, $auto);
diff --git a/lib/Xconfig/monitor.pm b/lib/Xconfig/monitor.pm
index d3f6688..0fc2c31 100644
--- a/lib/Xconfig/monitor.pm
+++ b/lib/Xconfig/monitor.pm
@@ -84,7 +84,7 @@ sub configure_auto_install {
if (!is_valid($monitors->[0])) {
my ($first_card) = Xconfig::card::probe();
$card_Driver = $first_card->{Driver} if $first_card;
- put_in_hash($monitors->[0], probe($card_Driver));
+ put_in_hash($monitors->[0], probe());
}
foreach my $monitor (@$monitors) {
@@ -143,7 +143,7 @@ sub choose {
local $::noauto = 0; #- hey, you asked for plug'n play, so i do probe!
delete @$monitor{'VendorName', 'ModelName', 'EISA_ID', 'HorizSync', 'VertRefresh'};
if ($head_nb <= 1) {
- if (my $probed_info = probe($raw_X->get_Driver)) {
+ if (my $probed_info = probe()) {
put_in_hash($monitor, $probed_info);
} else {
log::l("Plug'n Play probing failed, but Xorg may do better");
@@ -213,8 +213,7 @@ sub is_valid {
}
sub probe {
- my ($o_card_Driver) = @_;
- probe_DDC() || probe_DMI() || probe_using_X($o_card_Driver);
+ probe_DDC() || probe_DMI();
}
#- some EDID are much too strict:
@@ -285,32 +284,6 @@ sub use_EDID {
$monitor;
}
-sub probe_using_X {
- my ($card_Driver) = @_;
-
- detect_devices::isLaptop() or return;
-
- $card_Driver ||= do {
- require Xconfig::card;
- my @cards = Xconfig::card::probe();
- $cards[0]{Driver};
- } or return;
-
- require modules;
- my @old_modules = modules::loaded_modules();
- my $resolution = run_program::rooted_get_stdout($::prefix, 'monitor-probe-using-X', '--perl', $card_Driver);
- modules::unload(difference2([ modules::loaded_modules() ], \@old_modules));
-
- $resolution = eval($resolution) or return;
-
- if (my $res = $resolution->[0]{preferred_resolution}) {
- generic_flat_panel($res);
- } else {
- log::l("at least one EDID was found in Xorg.log, so let Xorg autodetect the monitor");
- { VendorName => "Plug'n Play" };
- }
-}
-
sub probe_DMI() {
my $res = detect_devices::probe_unique_name('Resolution');
$res && generic_flat_panel_txt($res);