[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: kbd-chooser for DECstation machines

Martin Schulze wrote:
> One problem remains.  During the installation a medium priority
> question (console-tools/archs) is displayed which lists all possible
> keyboard types for mipsel (AT, LK, USB) but has the default set to AT.
> The problem is that this question is only displayed when the user
> explicitly asks the installer to display medium priority dialog boxes
> as well.  On a mipsel system that doesn't have an AT keyboard
> connected the user would be trapped into an AT keyboard, effectively
> rendering his keyboard unusable.

Any idea to mitigate this problem?

> The code for this default setting is in kbd-chooser.h:
> #if defined(AT_KBD) && !defined(PREFERRED_KBD)
> #define PREFERRED_KBD "at"
> #endif
> We could simply declare no preferred keyboard for the mipsel
> architecture (beware, there's __mips__ for both mips and mipsel, and
> __MIPSEL__ for only mipsel).  This would require the dialog to be
> displayed, though, for the user to be able to select the keyboard
> type.  Since it is of medium priority and only high priority dialogs
> are displayed, this may not be sufficient.

Changing this for DECstation machines should fixed with the attached patch.



This is GNU/Linux Country.  On a quiet night, you can hear Windows reboot.

Please always Cc to me when replying to me on the lists.
--- orig/kbd-chooser-1.02/dec-kbd.c	2004-04-01 23:42:22.000000000 +0200
+++ kbd-chooser-1.02/dec-kbd.c	2004-09-30 21:26:04.000000000 +0200
@@ -28,5 +28,14 @@ kbd_t *dec_kbd_get (kbd_t *keyboards, co
 	k->next = keyboards;
 	keyboards = k;
+#if defined(__mipsel___)
+	// /proc must be mounted by this point
+	// assert (check_dir ("/proc") == 1);
+	if (check_dir ("/proc")) {
+		if ((grep ("/proc/cpuinfo","DECstation ") == 0))
+			k->present = TRUE;
+	}
 	return keyboards;

Reply to: