Mailinglist Archive: opensuse-commit (1670 mails)
| < Previous | Next > |
commit grub
- From: root@xxxxxxx (h_root)
- Date: Sat, 21 Oct 2006 22:08:45 +0200 (CEST)
- Message-id: <20061021200845.0A82484786@xxxxxxxxxxxxxxx>
Hello community,
here is the log from the commit of package grub
checked in at Sat Oct 21 22:08:45 CEST 2006.
--------
--- arch/i386/grub/grub.changes 2006-10-14 15:58:29.000000000 +0200
+++ /mounts/work_src_done/STABLE/grub/grub.changes 2006-10-20 15:11:47.000000000 +0200
@@ -1,0 +2,8 @@
+Fri Oct 20 15:08:57 CEST 2006 - duwe@xxxxxxx
+
+- re-added intel Mac patch with an extra safety check.
+ Systems where this code doesn't work I'd consider really broken.
+ As a last resort, System Control Port A and KBD controller
+ priority may be reversed, but let's try it this way first.
+
+-------------------------------------------------------------------
Old:
----
grub-a20.patch
New:
----
grub-A20-sysctlportA
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ grub.spec ++++++
--- /var/tmp/diff_new_pack.fek9c0/_old 2006-10-21 22:08:31.000000000 +0200
+++ /var/tmp/diff_new_pack.fek9c0/_new 2006-10-21 22:08:31.000000000 +0200
@@ -13,12 +13,12 @@
# Commandline:
Name: grub
%ifarch x86_64
-BuildRequires: gcc41-32bit glibc-devel-32bit ncurses-32bit ncurses-devel-32bit
+BuildRequires: gcc-32bit glibc-devel-32bit ncurses-32bit ncurses-devel-32bit
%endif
-License: GPL
+License: GNU General Public License (GPL) - all versions
Group: System/Boot
Version: 0.97
-Release: 28
+Release: 30
Source0: %{name}-%{version}.tar.gz
Source1: installgrub
Source2: grubonce
@@ -35,12 +35,12 @@
Patch10: force-LBA-off.diff
Patch11: gcc4-diff
Patch12: %{name}-%{version}-initrdaddr.diff
+Patch13: grub-A20-sysctlportA
Patch20: stage2-dir-callback.diff
Patch21: stage2-wildcard.diff
Patch22: stage2-wildcard-zerowidth.diff
Patch23: stage2-wildcard-doc.diff
Patch24: grub-%{version}-protexec.patch
-Patch25: http://www.scl.ameslab.gov/Projects/mini-xen/grub-a20.patch
URL: http://www.gnu.org/software/grub/grub.en.html
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Summary: Grand Unified Boot Loader
@@ -87,15 +87,15 @@
%patch10 -p1
%patch11 -p1
%patch12 -p1
+# A20 gate haunts even intel macs. Be extra careful,
+# see http://www.win.tue.nl/~aeb/linux/kbd/A20.html
+%patch13 -p1
# Disable the wildcard feature
#%patch20 -p1
#%patch21 -p1
#%patch22 -p1
#%patch23 -p1
%patch24 -p1
-# crude hack for intel Macs -- not enabled by default,
-# see http://www.win.tue.nl/~aeb/linux/kbd/A20.html
-# %patch25 -p1
%build
perl -pi -e 's,/usr/share/grub/i386-pc,/usr/lib/grub,' docs/grub.texi
@@ -184,6 +184,11 @@
exit 0
%changelog -n grub
+* Fri Oct 20 2006 - duwe@xxxxxxx
+- re-added intel Mac patch with an extra safety check.
+ Systems where this code doesn't work I'd consider really broken.
+ As a last resort, System Control Port A and KBD controller
+ priority may be reversed, but let's try it this way first.
* Sat Oct 14 2006 - duwe@xxxxxxx
- disabled the intel mac hack again. Will keep the patch included
anyway to hint people it's off for a reason.
++++++ grub-A20-sysctlportA ++++++
--- grub-0.97/stage2/asm.S.orig 2004-06-19 18:55:22.000000000 +0200
+++ grub-0.97/stage2/asm.S 2006-10-20 12:04:32.000000000 +0200
@@ -1633,13 +1633,23 @@
testw %dx, %dx
jz 1f
incw %ax
-1: stc
+1: stc /* in case int15 does nothing */
int $0x15
jnc 2f
- /* set non-zero if failed */
- movb $1, %ah
-
+ /* Even if the BIOS itself cannot switch, maybe it will tell
+ * us not to use port 0x92.
+ */
+ movw $0x2403, %ax
+ stc
+ int $0x15
+ jnc gotA20info
+ xorb %ah,%ah /* query error: we have no info at all */
+gotA20info: /* check iff only kbd bit is set */
+ andb $0x3,%ah
+ cmpb $0x1,%ah
+ je 2f
+ movb $0xff,%ah
/* save the status */
2: movb %ah, %dl
@@ -1647,11 +1657,39 @@
.code32
popl %ebp
+
+ /* zero means all done, 0x01 means use KBD ctl only, else try both */
+ cmpb $0x01,%dl
+ je kbdctl
testb %dl, %dl
- jnz 3f
+ jnz sysctlA
ret
-3: /* use keyboard controller */
+sysctlA:
+ /*
+ * try to switch gateA20 using PORT92, the "Fast A20 and Init"
+ * register (System Control Port A)
+ */
+ mov $0x92, %dx
+ inb %dx, %al
+ /* skip the port92 code if it's unimplemented (read returns 0xff) */
+ cmpb $0xff, %al
+ jz kbdctl /* use old-style keyboard controller instead */
+
+ /* set or clear bit1, the ALT_A20_GATE bit */
+ movb 4(%esp), %ah
+ testb %ah, %ah
+ jz 4f
+ orb $2, %al
+ jmp 5f
+4: and $0xfd, %al
+
+ /* clear the INIT_NOW bit; don't accidently reset the machine */
+5: and $0xfe, %al
+ outb %al, %dx
+ ret
+
+kbdctl: /* use keyboard controller */
pushl %eax
call gloop1
@@ -1661,9 +1699,12 @@
gloopint1:
inb $K_STATUS
+ cmpb $0xff, %al
+ jz gloopint1_done
andb $K_IBUF_FUL, %al
jnz gloopint1
+gloopint1_done:
movb $KB_OUTPUT_MASK, %al
cmpb $0, 0x8(%esp)
jz gdoit
@@ -1684,6 +1725,8 @@
gloop1:
inb $K_STATUS
+ cmpb $0xff, %al
+ jz gloop2ret
andb $K_IBUF_FUL, %al
jnz gloop1
@@ -1991,6 +2034,11 @@
ENTRY(console_getkey)
push %ebp
+wait_for_key:
+ call EXT_C(console_checkkey)
+ incl %eax
+ jz wait_for_key
+
call EXT_C(prot_to_real)
.code16
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-commit+help@xxxxxxxxxxxx
| < Previous | Next > |